#include <clang_c_lexer.h>
◆ clang_c_lexert()
| clang_c_lexert::clang_c_lexert |
( |
| ) |
|
◆ ~clang_c_lexert()
| clang_c_lexert::~clang_c_lexert |
( |
| ) |
|
|
default |
◆ parse_expr()
| expr2tc clang_c_lexert::parse_expr |
( |
const std::string & | expr | ) |
|
Parse a C scalar-expression string into an IRep2 expression tree.
Uses the Clang raw lexer and NumericLiteralParser. Supports comparison operators (==, !=, <, <=, >, >=) composed with && and || and parenthesised sub-expressions.
The special token
- Returns
- is emitted as symbol2tc(int64, "\\result"). Integer constants are emitted as constant_int2tc(int64, N). Callers are responsible for retyping these nodes to the target type before use.
- Parameters
-
| expr | The expression string to parse. |
- Returns
- The parsed IRep2 expression, or a null expr2tc on parse error.
The documentation for this class was generated from the following files: