Syntax Errors
The parser raises these errors when the token stream doesn’t match expected grammar. Syntax errors always include the offending token and its position in the file.The examples above illustrate the most common triggers for each error. The same error message can be raised in other contexts — always read the position information alongside the message to locate the exact problem.
Deprecated Keyword Errors
The lexer raises these errors immediately when it encounters a deprecated C11 keyword. Compilation stops as soon as the keyword is found, before any further parsing takes place.Scope Errors
The structurer raises scope errors while building the Callee/Caller/Scope graph. These errors indicate conflicts in how names are declared and used across scopes.Remember that
for loop init declarations create their own child scope. A variable declared in a for init is not visible in the enclosing function scope, but it will conflict with another variable of the same name declared in the same for header.Memory Errors
The simulation pass raises memory errors during static analysis of pointer lifetimes and function call graphs.Understanding autoremove and robbery
Understanding autoremove and robbery
When you declare a pointer with
autoremove, the simulation pass determines the last point in your code where that pointer is used and inserts a free call there automatically.Use after autoremove drop means you reference the pointer again after that auto-inserted free. To fix this, either extend the pointer’s lifetime by moving the last use later, or switch to manual free.Invalid robbery means you attempted to “rob” (transfer ownership of) a pointer that was not declared with autoremove. Only autoremove pointers can be the target of a robbery operation.