1
0
Fork 0
mirror of synced 2025-09-23 20:28:36 +00:00

rename pest rule

This commit is contained in:
dark64 2022-11-21 17:39:19 +01:00
parent 5e3b8ff690
commit b8fe979a91
2 changed files with 3 additions and 3 deletions

View file

@ -2,8 +2,8 @@ file = { SOI ~ pragma? ~ symbol_declaration* ~ EOI }
pragma = { "#pragma" ~ "curve" ~ curve }
curve = @{ (ASCII_ALPHANUMERIC | "_") * }
raw_string = @{(!"\"" ~ ANY)*}
quoted_string = ${ "\"" ~ raw_string ~ "\"" }
string = @{(!"\"" ~ ANY)*}
quoted_string = ${ "\"" ~ string ~ "\"" }
semicolon = _{";"}
symbol_declaration = { (((import_directive | const_definition | type_definition) ~ semicolon) | (ty_struct_definition | function_definition)) }

View file

@ -387,7 +387,7 @@ mod ast {
}
#[derive(Debug, FromPest, PartialEq, Eq, Clone)]
#[pest_ast(rule(Rule::raw_string))]
#[pest_ast(rule(Rule::string))]
pub struct RawString<'ast> {
#[pest_ast(outer(with(span_into_str)))]
pub value: String,