fragment
JavaLetter
: [a-zA-Z$_] // these are the "java letters" below 0x7F
| // covers all characters above 0x7F which are not a surrogate
~[\u0000-\u007F\uD800-\uDBFF]
{Character.isJavaIdentifierStart(_input.LA(-1))}?
| // covers UTF-16 surrogate pairs encodings for U+10000 to U+10FFFF
[\uD800-\uDBFF] [\uDC00-\uDFFF]
{Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))}?
;
fragment
JavaLetterOrDigit
: [a-zA-Z0-9$_] // these are the "java letters or digits" below 0x7F
| // covers all characters above 0x7F which are not a surrogate
~[\u0000-\u007F\uD800-\uDBFF]
{Character.isJavaIdentifierPart(_input.LA(-1))}?
| // covers UTF-16 surrogate pairs encodings for U+10000 to U+10FFFF
[\uD800-\uDBFF] [\uDC00-\uDFFF]
{Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))}?
;`
Produces this Rust lexer:
`
// Generated from Colloid.g4 by ANTLR 4.8
![allow(dead_code)]
![allow(non_snake_case)]
![allow(non_upper_case_globals)]
![allow(unused_imports)]
use antlr_rust::atn::ATN;
use antlr_rust::char_stream::CharStream;
use antlr_rust::lexer::{BaseLexer, Lexer, LexerRecog};
use antlr_rust::atn_deserializer::ATNDeserializer;
use antlr_rust::dfa::DFA;
use antlr_rust::lexer_atn_simulator::{LexerATNSimulator, ILexerATNSimulator};
use antlr_rust::PredictionContextCache;
use antlr_rust::recognizer::{Recognizer,Actions};
use antlr_rust::error_listener::ErrorListener;
use antlr_rust::token_source::TokenSource;
use antlr_rust::common_token_factory::TokenFactory;
use antlr_rust::token::*;
use antlr_rust::rule_context::BaseRuleContext;
use antlr_rust::parser_rule_context::{ParserRuleContext,LexerContext,cast};
use antlr_rust::vocabulary::{Vocabulary,VocabularyImpl};
use std::sync::Arc;
use std::cell::RefCell;
use std::rc::Rc;
use std::ops::{Deref, DerefMut};
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidlexer.rs:55:2
|
55 | lazy_static!{
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidlexer.rs:209:2
|
209 | lazy_static! {
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidparser.rs:54:2
|
54 | lazy_static!{
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidparser.rs:212:1
|
212 | lazy_static! {
| ^^^^^^^^^^^
error[E0425]: cannot find value _ATN in this scope
--> colloid-parser/src/parser/colloidlexer.rs:111:6
|
111 | _ATN.clone(),
| ^^^^ not found in this scope
error[E0425]: cannot find value _decision_to_DFA in this scope
--> colloid-parser/src/parser/colloidlexer.rs:112:6
|
112 | _decision_to_DFA.clone(),
| ^^^^^^^^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _shared_context_cache in this scope
--> colloid-parser/src/parser/colloidlexer.rs:113:6
|
113 | _shared_context_cache.clone(),
| ^^^^^^^^^^^^^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:155:7
|
155 | Character.isJavaIdentifierStart(_input.LA(-1))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:155:39
|
155 | Character.isJavaIdentifierStart(_input.LA(-1))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:7
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:39
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:158:62
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:67
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:158:83
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:88
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:169:7
|
169 | Character.isJavaIdentifierPart(_input.LA(-1))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:169:38
|
169 | Character.isJavaIdentifierPart(_input.LA(-1))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:7
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:38
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:172:61
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:66
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:172:82
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:87
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value _ATN in this scope
--> colloid-parser/src/parser/colloidparser.rs:79:4
|
79 | _ATN.clone(),
| ^^^^ not found in this scope
error[E0425]: cannot find value _decision_to_DFA in this scope
--> colloid-parser/src/parser/colloidparser.rs:80:4
|
80 | _decision_to_DFA.clone(),
| ^^^^^^^^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _shared_context_cache in this scope
--> colloid-parser/src/parser/colloidparser.rs:81:4
|
81 | _shared_context_cache.clone(),
| ^^^^^^^^^^^^^^^^^^^^^ a field by this name exists in Self
error[E0425]: cannot find value VOCABULARY in this scope
--> colloid-parser/src/parser/colloidparser.rs:125:51
|
125 | fn get_vocabulary(&self) -> &dyn Vocabulary { &**VOCABULARY }
| ^^^^^^^^^^ not found in this scope
warning: unnecessary parentheses around method argument
--> colloid-parser/src/parser/colloidlexer.rs:158:61
Some errors have detailed explanations: E0423, E0425.
For more information about an error, try rustc --explain E0423.
error: could not compile colloid-parser.
To learn more, run the command again with --verbose.
matijak@Matijas-MBP colloid-llvm % clear
matijak@Matijas-MBP colloid-llvm % cargo build
Compiling colloid-parser v0.1.0 (/Users/matijak/ClionProjects/colloid-llvm/colloid-parser)
error: expected one of ), ,, ., ?, or an operator, found _input
--> colloid-parser/src/parser/colloidlexer.rs:158:67
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidlexer.rs:55:2
|
55 | lazy_static!{
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidlexer.rs:209:2
|
209 | lazy_static! {
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidparser.rs:54:2
|
54 | lazy_static!{
| ^^^^^^^^^^^
error: cannot find macro lazy_static in this scope
--> colloid-parser/src/parser/colloidparser.rs:212:1
|
212 | lazy_static! {
| ^^^^^^^^^^^
error[E0425]: cannot find value _ATN in this scope
--> colloid-parser/src/parser/colloidlexer.rs:111:6
|
111 | _ATN.clone(),
| ^^^^ not found in this scope
error[E0425]: cannot find value _decision_to_DFA in this scope
--> colloid-parser/src/parser/colloidlexer.rs:112:6
|
112 | _decision_to_DFA.clone(),
| ^^^^^^^^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _shared_context_cache in this scope
--> colloid-parser/src/parser/colloidlexer.rs:113:6
|
113 | _shared_context_cache.clone(),
| ^^^^^^^^^^^^^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:155:7
|
155 | Character.isJavaIdentifierStart(_input.LA(-1))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:155:39
|
155 | Character.isJavaIdentifierStart(_input.LA(-1))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:7
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:39
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:158:62
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:67
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:158:83
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^ not a value
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:158:88
|
158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:169:7
|
169 | Character.isJavaIdentifierPart(_input.LA(-1))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value _input in this scope
--> colloid-parser/src/parser/colloidlexer.rs:169:38
|
169 | Character.isJavaIdentifierPart(_input.LA(-1))
| ^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:7
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0425]: cannot find value Character in this scope
--> colloid-parser/src/parser/colloidlexer.rs:172:38
|
172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))
| ^^^^^^^^^ not found in this scope
error[E0423]: expected value, found builtin type char
--> colloid-parser/src/parser/colloidlexer.rs:172:61
The following grammar file>
`grammar Colloid;
identifier: Identifier;
// lexer
TERMINATOR : '\n'; TAB : '\t';
WS : [ \r\u000C]+ -> skip; COMMENT : '/' .? '/' -> skip; LINE_COMMENT : '//' ~[\r\n] -> skip;
//Identifier : // 'a' .. 'z';
Identifier : JavaLetter JavaLetterOrDigit* ;
fragment JavaLetter : [a-zA-Z$_] // these are the "java letters" below 0x7F | // covers all characters above 0x7F which are not a surrogate ~[\u0000-\u007F\uD800-\uDBFF] {Character.isJavaIdentifierStart(_input.LA(-1))}? | // covers UTF-16 surrogate pairs encodings for U+10000 to U+10FFFF [\uD800-\uDBFF] [\uDC00-\uDFFF] {Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))}? ;
fragment JavaLetterOrDigit : [a-zA-Z0-9$_] // these are the "java letters or digits" below 0x7F | // covers all characters above 0x7F which are not a surrogate ~[\u0000-\u007F\uD800-\uDBFF] {Character.isJavaIdentifierPart(_input.LA(-1))}? | // covers UTF-16 surrogate pairs encodings for U+10000 to U+10FFFF [\uD800-\uDBFF] [\uDC00-\uDFFF] {Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1)))}? ;`
Produces this Rust lexer:
` // Generated from Colloid.g4 by ANTLR 4.8
![allow(dead_code)]
![allow(non_snake_case)]
![allow(non_upper_case_globals)]
![allow(unused_imports)]
use antlr_rust::atn::ATN; use antlr_rust::char_stream::CharStream; use antlr_rust::lexer::{BaseLexer, Lexer, LexerRecog}; use antlr_rust::atn_deserializer::ATNDeserializer; use antlr_rust::dfa::DFA; use antlr_rust::lexer_atn_simulator::{LexerATNSimulator, ILexerATNSimulator}; use antlr_rust::PredictionContextCache; use antlr_rust::recognizer::{Recognizer,Actions}; use antlr_rust::error_listener::ErrorListener; use antlr_rust::token_source::TokenSource; use antlr_rust::common_token_factory::TokenFactory; use antlr_rust::token::*; use antlr_rust::rule_context::BaseRuleContext; use antlr_rust::parser_rule_context::{ParserRuleContext,LexerContext,cast}; use antlr_rust::vocabulary::{Vocabulary,VocabularyImpl};
use std::sync::Arc; use std::cell::RefCell; use std::rc::Rc; use std::ops::{Deref, DerefMut};
pub struct ColloidLexer { base: BaseLexer,
// static { RuntimeMetaData.checkVersion("4.8", RuntimeMetaData.VERSION); }
}
impl Deref for ColloidLexer{ type Target = BaseLexer;
}
impl DerefMut for ColloidLexer{ fn deref_mut(&mut self) -> &mut Self::Target { &mut self.base } }
impl ColloidLexer { fn get_rule_names(&self) -> &'static [&'static str] { &ruleNames } fn get_literal_names(&self) -> &[Option<&str>] { &_LITERAL_NAMES }
}
pub struct ColloidLexerActions { }
impl ColloidLexerActions{ }
impl LexerRecog for ColloidLexerActions{ }
impl Recognizer for ColloidLexerActions {}
impl Actions for ColloidLexerActions{ type Recog = BaseLexer;
fn sempred(_localctx: &dyn ParserRuleContext, rule_index: isize, pred_index: isize,
recog:&mut ::Recog
) -> bool {
match rule_index {
6 =>
Self::JavaLettersempred(cast::<,LexerContext >(_localctx), pred_index, recog),
7 =>
Self::JavaLetterOrDigitsempred(cast::<,LexerContext >(_localctx), predindex, recog),
=> true
}
}
}
impl TokenSource for ColloidLexer { fn next_token(&mut self) -> Box {
self.base.next_token()
}
}
`
The compilation of which produces the following errors:
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:158:67)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:158:88)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:172:66)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:172:87)
,,
,.
,?
, or an operator,
error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidlexer.rs:55:2 | 55 | lazy_static!{ | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidlexer.rs:209:2 | 209 | lazy_static! { | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidparser.rs:54:2 | 54 | lazy_static!{ | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidparser.rs:212:1 | 212 | lazy_static! { | ^^^^^^^^^^^error[E0425]: cannot find value
_ATN
in this scope --> colloid-parser/src/parser/colloidlexer.rs:111:6 | 111 | _ATN.clone(), | ^^^^ not found in this scopeerror[E0425]: cannot find value
_decision_to_DFA
in this scope --> colloid-parser/src/parser/colloidlexer.rs:112:6 | 112 | _decision_to_DFA.clone(), | ^^^^^^^^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_shared_context_cache
in this scope --> colloid-parser/src/parser/colloidlexer.rs:113:6 | 113 | _shared_context_cache.clone(), | ^^^^^^^^^^^^^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:155:7 | 155 | Character.isJavaIdentifierStart(_input.LA(-1)) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:155:39 | 155 | Character.isJavaIdentifierStart(_input.LA(-1)) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:7 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:39 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:158:62 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:67 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:158:83 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:88 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:169:7 | 169 | Character.isJavaIdentifierPart(_input.LA(-1)) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:169:38 | 169 | Character.isJavaIdentifierPart(_input.LA(-1)) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:7 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:38 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:172:61 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:66 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:172:82 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:87 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
_ATN
in this scope --> colloid-parser/src/parser/colloidparser.rs:79:4 | 79 | _ATN.clone(), | ^^^^ not found in this scopeerror[E0425]: cannot find value
_decision_to_DFA
in this scope --> colloid-parser/src/parser/colloidparser.rs:80:4 | 80 | _decision_to_DFA.clone(), | ^^^^^^^^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_shared_context_cache
in this scope --> colloid-parser/src/parser/colloidparser.rs:81:4 | 81 | _shared_context_cache.clone(), | ^^^^^^^^^^^^^^^^^^^^^ a field by this name exists inSelf
error[E0425]: cannot find value
VOCABULARY
in this scope --> colloid-parser/src/parser/colloidparser.rs:125:51 | 125 | fn get_vocabulary(&self) -> &dyn Vocabulary { &**VOCABULARY } | ^^^^^^^^^^ not found in this scopewarning: unnecessary parentheses around method argument --> colloid-parser/src/parser/colloidlexer.rs:158:82 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ help: remove these parentheses
warning: unnecessary parentheses around method argument --> colloid-parser/src/parser/colloidlexer.rs:172:60 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ help: remove these parentheses
warning: unnecessary parentheses around method argument --> colloid-parser/src/parser/colloidlexer.rs:172:81 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ help: remove these parentheses
std::any::Any
--> colloid-parser/src/parser/colloidlistener.rs:6:5= note:
#[warn(unused_imports)]
on by defaulterror: aborting due to 31 previous errors
Some errors have detailed explanations: E0423, E0425. For more information about an error, try
rustc --explain E0423
. error: could not compilecolloid-parser
.)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:158:67)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:158:88)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:172:66)
,,
,.
,?
, or an operator,
)
,,
,.
,?
, or an operator, found_input
--> colloid-parser/src/parser/colloidlexer.rs:172:87)
,,
,.
,?
, or an operator,
error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidlexer.rs:55:2 | 55 | lazy_static!{ | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidlexer.rs:209:2 | 209 | lazy_static! { | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidparser.rs:54:2 | 54 | lazy_static!{ | ^^^^^^^^^^^error: cannot find macro
lazy_static
in this scope --> colloid-parser/src/parser/colloidparser.rs:212:1 | 212 | lazy_static! { | ^^^^^^^^^^^error[E0425]: cannot find value
_ATN
in this scope --> colloid-parser/src/parser/colloidlexer.rs:111:6 | 111 | _ATN.clone(), | ^^^^ not found in this scopeerror[E0425]: cannot find value
_decision_to_DFA
in this scope --> colloid-parser/src/parser/colloidlexer.rs:112:6 | 112 | _decision_to_DFA.clone(), | ^^^^^^^^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_shared_context_cache
in this scope --> colloid-parser/src/parser/colloidlexer.rs:113:6 | 113 | _shared_context_cache.clone(), | ^^^^^^^^^^^^^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:155:7 | 155 | Character.isJavaIdentifierStart(_input.LA(-1)) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:155:39 | 155 | Character.isJavaIdentifierStart(_input.LA(-1)) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:7 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:39 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:158:62 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:67 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0423]: expected value, found builtin type
char
--> colloid-parser/src/parser/colloidlexer.rs:158:83 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^ not a valueerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:158:88 | 158 | Character.isJavaIdentifierStart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:169:7 | 169 | Character.isJavaIdentifierPart(_input.LA(-1)) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
_input
in this scope --> colloid-parser/src/parser/colloidlexer.rs:169:38 | 169 | Character.isJavaIdentifierPart(_input.LA(-1)) | ^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:7 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopeerror[E0425]: cannot find value
Character
in this scope --> colloid-parser/src/parser/colloidlexer.rs:172:38 | 172 | Character.isJavaIdentifierPart(Character.toCodePoint((char)_input.LA(-2), (char)_input.LA(-1))) | ^^^^^^^^^ not found in this scopechar
--> colloid-parser/src/parser/colloidlexer.rs:172:61...
Sorry for the poor formatting, doesn't seem I can get it to work properly.