You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I know this sounds like a really niche example, but it was made as simple as possible. This behavior is actually quite common with "strange" includes. Since I guess it's not the expected behavior and it's causing me a lot of problems in my analysis I wanted to know if it's possible to fix it.
//FILE intval.h
1
// FILEmain.c
int a =
#include "intval.h"
;
int main() { ; }
I'm not sure I understand what's wrong in the coordinates; could you elaborate in more detail what you see, what you expect to see and why? Provide a minimal example with preprocessed code fed to pycparser, please.
Hello Eli,
code is in the first part of the first post.
Preprocessed code is in the bottom of the same post.
What i expect is that the coordinates for this token:
Constant : int, 1 (at C:/Users/Corrado/Desktop/main.c:1:1)
were instead (at C:/Users/Corrado/Desktop/intval.h:1:1), since it comes from this piece of code:
I know this sounds like a really niche example, but it was made as simple as possible. This behavior is actually quite common with "strange" includes. Since I guess it's not the expected behavior and it's causing me a lot of problems in my analysis I wanted to know if it's possible to fix it.
Ast show with coordinates:
The pointed coordinate is wrong. Directives inserted by cpp preprocessor were right and reports correctly when i am entering and leaving the file.
cpp -E output:
The text was updated successfully, but these errors were encountered: