# | Line 66 | Line 66 | namespace oopse { | |
---|---|---|
66 | ||
67 | clausePrimitive ::= clauseComparator | | |
68 | clauseWithin | | |
69 | < | clauseChemObject | |
69 | > | clauseName | |
70 | none | all | | |
71 | ( clauseOr ) | |
72 | ||
# | Line 75 | Line 75 | namespace oopse { | |
75 | clauseWithin ::= WITHIN ( clauseDistance , expression ) | |
76 | ||
77 | clauseDistance ::= integer | decimal | |
78 | < | |
79 | < | clauseChemObject::= {clauseMolecule} | {clauseStuntDouble} |
78 | > | |
79 | > | clauseName::= *|string{.string{.string}} |
80 | ||
81 | – | clauseMolecule ::= {clauseMolName} | {clauseMolIndex} |
81 | ||
83 | – | clauseMolName ::= molname clauseName |
84 | – | |
85 | – | clauseName::= *|string |
86 | – | |
87 | – | clauseMolIndex ::= molindex clauseIndex |
88 | – | |
89 | – | clauseIndex ::= integer {- integer } |
90 | – | |
91 | – | clauseStuntDouble ::= {clauseStuntDoubleName} | {clauseStuntDoubleIndex} |
92 | – | |
93 | – | clauseStuntDoubleName ::= name clauseName |
94 | – | |
95 | – | clauseStuntDoubleIndex ::= index clauseIndex |
96 | – | |
82 | * </pre> | |
83 | */ | |
84 | class SelectionCompiler{ | |
# | Line 121 | Line 106 | class SelectionCompiler{ | |
106 | strError += filename; | |
107 | } | |
108 | ||
124 | – | strError += " line#" + lineCurrent; |
109 | return strError; | |
110 | } | |
111 | ||
# | Line 132 | Line 116 | class SelectionCompiler{ | |
116 | ||
117 | ||
118 | bool lookingAtLeadingWhitespace(); | |
119 | < | bool lookingAtComment(); |
119 | > | //bool lookingAtComment(); |
120 | bool lookingAtEndOfLine(); | |
121 | bool lookingAtEndOfStatement(); | |
122 | bool lookingAtString(); | |
# | Line 154 | Line 138 | class SelectionCompiler{ | |
138 | bool clausePrimitive(); | |
139 | bool clauseWithin(); | |
140 | bool clauseComparator(); | |
141 | < | bool clauseName(int tok); |
142 | < | bool clauseIndex(int tok); |
159 | < | |
141 | > | bool clauseChemObjName(); |
142 | > | bool clauseIndex(); |
143 | Token tokenNext(); | |
144 | boost::any valuePeek(); | |
145 | int tokPeek(); | |
146 | ||
147 | bool addTokenToPostfix(const Token& token); | |
148 | + | bool isNameValid(const std::string& name); |
149 | ||
166 | – | |
150 | bool compileError(const std::string& errorMessage) { | |
151 | std::cerr << "SelectionCompiler Error: " << errorMessage << std::endl; | |
152 | error = true; | |
# | Line 220 | Line 203 | class SelectionCompiler{ | |
203 | return compileError("comparison operator expected"); | |
204 | } | |
205 | ||
206 | < | bool integerExpected() { |
207 | < | return compileError("integer expected"); |
206 | > | bool numberExpected() { |
207 | > | return compileError("number expected"); |
208 | } | |
209 | ||
210 | bool numberOrKeywordExpected() { |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |