boot2

Playing with the boostrap
git clone https://git.ryansepassi.com/git/boot2.git
Log | Files | Refs | README

00206.c (636B)


      1 #include <stdio.h>
      2 
      3 int main()
      4 {
      5     /* must not affect how #pragma ppop_macro works */
      6     #define pop_macro foobar1
      7 
      8     /* must not affect how #pragma push_macro works */
      9     #define push_macro foobar2
     10 
     11     #undef abort
     12     #define abort "111"
     13     printf("abort = %s\n", abort);
     14 
     15     #pragma push_macro("abort")
     16     #undef abort
     17     #define abort "222"
     18     printf("abort = %s\n", abort);
     19 
     20     #pragma push_macro("abort")
     21     #undef abort
     22     #define abort "333"
     23     printf("abort = %s\n", abort);
     24 
     25     #pragma pop_macro("abort")
     26     printf("abort = %s\n", abort);
     27 
     28     #pragma pop_macro("abort")
     29     printf("abort = %s\n", abort);
     30 }