diff options
Diffstat (limited to 'libcpp/macro.c')
-rw-r--r-- | libcpp/macro.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libcpp/macro.c b/libcpp/macro.c index bf473ea..43f2baa 100644 --- a/libcpp/macro.c +++ b/libcpp/macro.c @@ -3646,3 +3646,11 @@ cpp_macro_definition (cpp_reader *pfile, cpp_hashnode *node) *buffer = '\0'; return pfile->macro_buffer; } + +/* Get the line at which the macro was defined. */ + +source_location +cpp_macro_definition_location (cpp_hashnode *node) +{ + return node->value.macro->line; +} |