1
0
mirror of https://github.com/ThrowTheSwitch/Unity.git synced 2026-01-23 00:15:58 +01:00

Option to exclude setjump/longjmp, setjmp.h

Using this option changes the control flow of Unity, but is useful on
constrained embedded systems. You can't fully simulate the power of
'longjmp' with just 'return', but Unity still works well, all tests pass.
This commit is contained in:
jsalling
2017-01-14 11:15:30 -06:00
parent ee38219498
commit ef1e2ad58c
2 changed files with 13 additions and 1 deletions

View File

@@ -99,7 +99,9 @@ void testUnitySizeInitializationReminder(void)
UNITY_COUNTER_TYPE TestIgnores;
UNITY_COUNTER_TYPE CurrentTestFailed;
UNITY_COUNTER_TYPE CurrentTestIgnored;
#ifndef UNITY_EXCLUDE_SETJMP_H
jmp_buf AbortFrame;
#endif
} _Expected_Unity;
#else
struct {
@@ -113,7 +115,9 @@ void testUnitySizeInitializationReminder(void)
UNITY_COUNTER_TYPE TestIgnores;
UNITY_COUNTER_TYPE CurrentTestFailed;
UNITY_COUNTER_TYPE CurrentTestIgnored;
#ifndef UNITY_EXCLUDE_SETJMP_H
jmp_buf AbortFrame;
#endif
} _Expected_Unity;
#endif