Skip to content

Commit 18207cd

Browse files
committed
Guard GCC13 pragma
1 parent f837f24 commit 18207cd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

py/stackctrl.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,10 @@ void mp_stack_ctrl_init(void) {
3131
// Force routine to not be inlined. Better guarantee than MP_NOINLINE for -flto.
3232
__asm volatile ("");
3333
#pragma GCC diagnostic push
34+
#if __GNUC__ > 12
35+
// Introduced in GCC 13
3436
#pragma GCC diagnostic ignored "-Wdangling-pointer"
37+
#endif
3538
volatile int stack_dummy;
3639
MP_STATE_THREAD(stack_top) = (char *)&stack_dummy;
3740
#pragma GCC diagnostic pop

0 commit comments

Comments
 (0)