Class: Hilbert::Lexer::MainLexer
- Extended by:
- Tokens
- Defined in:
- lib/hilbert/lexer/main_lexer.rb
Constant Summary
Constants included from Tokens
Tokens::ANYSP, Tokens::ANYSTR, Tokens::BICO, Tokens::BRCS, Tokens::BRCT, Tokens::CLN, Tokens::CMA, Tokens::COND, Tokens::CONJ, Tokens::DEFLOGIC, Tokens::DIFF_SYM, Tokens::DISJ, Tokens::DIV, Tokens::E, Tokens::EMBEDDED_FUNC, Tokens::EQL, Tokens::EVALOGIC, Tokens::EXP, Tokens::FLO, Tokens::FORMULA, Tokens::FUNCCN, Tokens::FUNCCV, Tokens::FUNCCVN, Tokens::FUNCV, Tokens::INF, Tokens::INT, Tokens::INTE_SYM, Tokens::LBRCS, Tokens::LBRCT, Tokens::LDARW, Tokens::LIM_SYM, Tokens::LPRN, Tokens::LSARW, Tokens::MUL, Tokens::NEGA, Tokens::NLIN, Tokens::NONL, Tokens::NUM, Tokens::NUMS_BY_CMA, Tokens::NUMS_BY_SP, Tokens::NUMS_BY_SP_BY_SCLN_OR_NELN, Tokens::OPE, Tokens::PI, Tokens::PLS, Tokens::PRN, Tokens::PROVAR, Tokens::RBRCS, Tokens::RBRCT, Tokens::RDARW, Tokens::RPRN, Tokens::RSARW, Tokens::SCLN, Tokens::SCLN_OR_NELN, Tokens::SGM_SYM, Tokens::SPC, Tokens::SPCS, Tokens::SUB, Tokens::USER_FUNC, Tokens::VAR, Tokens::VARNUM, Tokens::VARNUMS_BY_CMA, Tokens::VARS_BY_CMA
Instance Attribute Summary
Attributes inherited from Base
Class Method Summary collapse
Methods inherited from Base
clear!, execute, #get_els, #get_value, #initialize, #parsed!, rule, #scan, #squash!, #token_rule_hash, #token_str, #values
Constructor Details
This class inherits a constructor from Hilbert::Lexer::Base
Class Method Details
.zfc_analysis! ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/hilbert/lexer/main_lexer.rb', line 16 def zfc_analysis! clear! rule(/postulate zfc_analysis/) { :POST_ZFC } rule(/paradox\?/) { :P_PARAD } rule(/\A.*[A-RT-Z].*\?.*\z/m) { :EVALOGIC } rule(/\A.*[A-RT-Z].*\z/m) { :DEFLOGIC } rule(/(#{FUNCCV})#{ANYSP}#{EQL}#{ANYSP}(#{FORMULA})/) { :DEF_FUNC } rule(/#{INTE_SYM}#{ANYSP}#{LPRN}(#{ANYSTR})#{RPRN}#{LBRCT}(#{ANYSTR})#{RBRCT}/) { :INTEGRAL } rule(/#{DIFF_SYM}(#{VAR}) (#{FORMULA})/) { :DIFFERENTIAL } rule(/#{LIM_SYM}#{LBRCT}(#{VAR})#{RSARW}(#{VARNUM})#{RBRCT} (#{FORMULA})/) { :LIMIT } rule(/#{SGM_SYM}#{LBRCT}(#{VAR})#{EQL}(#{INT})#{CMA}#{ANYSP}(#{INT})#{RBRCT} (#{FORMULA})/) { :SIGMA } rule(/#{LPRN}(#{NUMS_BY_SP})#{RPRN}/) { :VECTOR } rule(/#{LPRN}(#{NUMS_BY_SP_BY_SCLN_OR_NELN})#{RPRN}t/m) { :TMATRIX } rule(/#{LPRN}(#{NUMS_BY_SP_BY_SCLN_OR_NELN})#{RPRN}/m) { :MATRIX } rule(/#{FUNCCN}/) { :FUNCCN } rule(/#{LPRN}/) { :LPRN } rule(/#{RPRN}/) { :RPRN } rule(/#{LBRCS}/) { :LBRCS } rule(/#{RBRCS}/) { :RBRCS } rule(/[ \t\f]/) rule(/(\r|\n)+/) { :NULL } rule(/[^\(\)\{\}(\n\n)]+/) { :CONT } end |