/* setjmp.h: nonlocal gotos. */

#ifndef _SETJMP_H
#define _SETJMP_H

#include <bits/attrs.h>
#include <bits/setjmp-types.h>

#ifdef __cplusplus
extern "C"
{
#endif

    /* Saves the current execution state in env. */
    int setjmp(jmp_buf env);

    /* Right now, does the exact same thing as setjmp() (savesigs is ignored), since signals are not implemented. */
    int sigsetjmp(sigjmp_buf env, int savesigs);

    /* Restores the execution state saved in env by a setjmp() call. */
    __noreturn void longjmp(jmp_buf env, int val);

    /* Right now, does the exact same as longjmp(), since signals are not implemented. */
    __noreturn void siglongjmp(sigjmp_buf env, int val);

#ifdef __cplusplus
}
#endif

#endif