global constants without using #define

前端 未结 2 604
面向向阳花
面向向阳花 2021-02-07 14:04

Ok, I\'m looking to define a set of memory addresses as constants in a .h file that\'s used by a bunch of .c files (we\'re in C, not C++). I want to be able to see the name<

2条回答
  •  情深已故
    2021-02-07 14:32

    If you're compiling with gcc, you can add the -ggdb3 switch, which will tell gcc to store macro information (i.e. #defines) so that they can be used inside gdb.

提交回复
热议问题