|
Class: RBPragmaNode
Object
|
+--RBProgramNode
|
+--RBPragmaNode
- Package:
- stx:goodies/refactoryBrowser/parser
- Category:
- Refactory-AST-Nodes
- Version:
- rev:
1.12
date: 2024/02/09 11:35:46
- user: stefan
- file: RBPragmaNode.st directory: goodies/refactoryBrowser/parser
- module: stx stc-classLibrary: parser
instance creation
-
selectorParts: keywordTokens arguments: valueNodes
-
accessing
-
argumentAt: keywordSelector
-
-
argumentAt: keywordSelector ifAbsent: absentBlock
-
-
argumentCount
-
-
arguments
-
-
arguments: aLiteralCollection
-
-
children
-
-
numArgs
-
marked as obsolete by Stefan Vogel at 9-Feb-2024
** This is an obsolete interface - do not use it (it may vanish in future versions) **
-
selector
-
-
selector: aSelector
-
-
sentMessages
-
warning: returns a string collection because we avoid creating symbols when parsing
-
start
-
-
stop
-
accessing-token
-
left
-
-
left: anInteger
-
-
right
-
-
right: anInteger
-
comparing
-
= anObject
-
(comment from inherited method)
return true if the receiver and the arg have the same structure.
Notice:
This method is partially open coded (inlined) by the compiler(s)
identical objects are always considered equal.
redefining it may not work as expected.
-
equalTo: anObject withMapping: aDictionary
-
(comment from inherited method)
return true, if I am equal to another node, with a given variable name mapping.
-
hash
-
(comment from inherited method)
return an Integer useful as a hash key for the receiver.
This hash should return same values for objects with same
contents (i.e. use this to hash on structure)
-
semanticallyEqualTo: anObject withMapping: aDictionary
-
(comment from inherited method)
return true, if I am semantically equal to another node, with a given variable name mapping.
Semantical equalTo: is defined slightly less strict, than equalTo:.
Both check the parsetree, ignoring formatting and comments.
However, in some situations, semanticallyEqualTo: detects the same intention,
(which is mostly heuristic and builtin knowledge).
For example:
foo isNil ifTrue:e1 ifFalse:e2
is semantcallyEqualTo:
foo notNil ifTrue:e2 ifFalse:e1
and also to:
foo isNil ifFalse:e2 ifTrue:e1
The fallback implemented here is to ask for the regular equality.
Side effect: update the mapping dictionary as required to reflect a matching mapping (if possible)
copying-private
-
postCopy
-
initialization
-
selectorParts: keywordTokens arguments: valueNodes
-
matching
-
copyInContext: aDictionary
-
-
match: aNode inContext: aDictionary
-
private
-
buildSelector
-
to be checked: this creates symbols, although it probably shouldn't
-
selectorParts
-
-
selectorParts: tokenCollection
-
replacing
-
replaceNode: aNode withNode: anotherNode
-
testing
-
isBinary
-
-
isFaulty
-
-
isKeyword
-
-
isPragma
-
-
isPrimitive
-
-
isUnary
-
visiting
-
acceptVisitor: aProgramNodeVisitor
-
|