#include "defs.h"
#include "block.h"
#include "charset.h"
#include "cp-support.h"
#include "gdbsupport/gdb_obstack.h"
#include "gdbsupport/gdb_regex.h"
#include "rust-lang.h"
#include "parser-defs.h"
#include "gdbsupport/selftest.h"
#include "value.h"
#include "gdbarch.h"
#include "rust-exp.h"
Go to the source code of this file.
|
| enum | token_type : int {
GDBVAR = 256
, IDENT
, COMPLETE
, INTEGER
,
DECIMAL_INTEGER
, STRING
, BYTESTRING
, FLOAT
,
COMPOUND_ASSIGN
, KW_AS
, KW_IF
, KW_TRUE
,
KW_FALSE
, KW_SUPER
, KW_SELF
, KW_MUT
,
KW_EXTERN
, KW_CONST
, KW_FN
, KW_SIZEOF
,
DOTDOT
, DOTDOTEQ
, OROR
, ANDAND
,
EQEQ
, NOTEQ
, LTEQ
, GTEQ
,
LSH
, RSH
, COLONCOLON
, ARROW
} |
| |
◆ ALL_OPS
Value:
#define OPERATION(TOKEN, PRECEDENCE, TYPE)
◆ ASSIGN_PREC
◆ FLOAT_TYPE1
◆ FLOAT_TYPE2
◆ INT_TEXT
◆ INT_TYPE
◆ NUM_SUBEXPRESSIONS
| #define NUM_SUBEXPRESSIONS 8 |
◆ OPERATION [1/2]
| #define OPERATION |
( |
|
TOKEN, |
|
|
|
PRECEDENCE, |
|
|
|
TYPE |
|
) |
| |
Value: case TOKEN: \
precedence = PRECEDENCE; \
lex (); \
break;
◆ OPERATION [2/2]
| #define OPERATION |
( |
|
TOKEN, |
|
|
|
PRECEDENCE, |
|
|
|
TYPE |
|
) |
| |
Value: case TOKEN: \
lhs.op = make_operation<TYPE> (std::move (lhs.op), \
std::move (rhs.op)); \
break;
◆ token_type
| Enumerator |
|---|
| GDBVAR | |
| IDENT | |
| COMPLETE | |
| INTEGER | |
| DECIMAL_INTEGER | |
| STRING | |
| BYTESTRING | |
| FLOAT | |
| COMPOUND_ASSIGN | |
| KW_AS | |
| KW_IF | |
| KW_TRUE | |
| KW_FALSE | |
| KW_SUPER | |
| KW_SELF | |
| KW_MUT | |
| KW_EXTERN | |
| KW_CONST | |
| KW_FN | |
| KW_SIZEOF | |
| DOTDOT | |
| DOTDOTEQ | |
| OROR | |
| ANDAND | |
| EQEQ | |
| NOTEQ | |
| LTEQ | |
| GTEQ | |
| LSH | |
| RSH | |
| COLONCOLON | |
| ARROW | |
Definition at line 84 of file rust-parse.c.
◆ _initialize_rust_exp()
| void _initialize_rust_exp |
( |
| ) |
|
◆ ends_raw_string()
| static bool ends_raw_string |
( |
const char * |
str, |
|
|
int |
n |
|
) |
| |
|
static |
◆ lex_multibyte_char()
| static uint32_t lex_multibyte_char |
( |
const char * |
text, |
|
|
int * |
len |
|
) |
| |
|
static |
◆ munge_name_and_block()
| static void munge_name_and_block |
( |
const char ** |
name, |
|
|
const struct block ** |
block |
|
) |
| |
|
static |
◆ rust_identifier_start_p()
| static bool rust_identifier_start_p |
( |
char |
c | ) |
|
|
static |
◆ space_then_number()
| static bool space_then_number |
( |
const char * |
string | ) |
|
|
static |
◆ starts_raw_string()
| static int starts_raw_string |
( |
const char * |
str | ) |
|
|
static |
◆ identifier_tokens
◆ number_regex
◆ number_regex_text
| const char number_regex_text[] |
|
static |
Initial value:=
"^("
"[0-9][0-9_]*\\.[0-9][0-9_]*([eE][-+]?[0-9][0-9_]*)?(f32|f64)?"
#define FLOAT_TYPE1
"|"
#define FLOAT_TYPE2
"[0-9][0-9_]*[eE][-+]?[0-9][0-9_]*(f32|f64)?"
"|"
"[0-9][0-9_]*\\."
"|"
#define INT_TEXT
#define INT_TYPE
"(0x[a-fA-F0-9_]+|0o[0-7_]+|0b[01_]+|[0-9][0-9_]*)"
"([iu](size|8|16|32|64))?"
")"
Definition at line 40 of file rust-parse.c.
◆ operator_tokens