Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cc sema #125

Open
wants to merge 13 commits into
base: main
Choose a base branch
from
Open

Cc sema #125

wants to merge 13 commits into from

Conversation

Supercip971
Copy link
Member

No description provided.

Supercip971 and others added 13 commits May 23, 2022 00:22
- now we detect int / bool / char ...
- fixed this case:

```c
int v = 0;
// as int was not a recognized type, this was resulting in an empty expr
```

- fixed cc dump of argument
- now we store a range of position
note: we can't just use a range because we may do later on macro expansion in it:

```c
test b;

// ---- error

2  |  test b;
    |  ^^^ in expansion of macro test
    |     |
1  |  #define test (void* aaaa)
    |                                        ^^^^ invalid identifier in type
```
- used because global variable are handled differently than local variable
+ added sema_scope _reset
+ added pass in sema
+ remove visit_statement
+ format code
- use a simpler structure
- reformat code
- removed CREF macro
+ put scan_srcref_info in it
- also moved cc error dumping in the parse error handling translation unit
- simplified code of error dumping (even if it is still a little bit cursed)
- renamed struct of srcref to make simpler to understad what is a characted index and what is a line index
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants