This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <setjmp.h> | |
static jmp_buf buf1, buf2; | |
#define FOR(VAR, START, FINISH) if (!setjmp(buf1)) { for (int (VAR) = START; (VAR) <= (FINISH); (VAR)++) { | |
#define NEXT if (!setjmp(buf2)) continue | |
#define ENDFOR longjmp(buf1, 1); } longjmp(buf2, 1); } | |