4543
|
1 |
"{ Encoding: utf8 }"
|
|
2 |
|
3782
|
3 |
"{ Package: 'stx:libcomp' }"
|
|
4 |
|
|
5 |
"{ NameSpace: Smalltalk }"
|
|
6 |
|
|
7 |
ParseNodeVisitor subclass:#PluggableParseNodeVisitor
|
|
8 |
instanceVariableNames:'actionsPerNodeType'
|
|
9 |
classVariableNames:''
|
|
10 |
poolDictionaries:''
|
|
11 |
category:'System-Compiler-Support'
|
|
12 |
!
|
|
13 |
|
|
14 |
!PluggableParseNodeVisitor class methodsFor:'documentation'!
|
|
15 |
|
|
16 |
documentation
|
|
17 |
"
|
4543
|
18 |
obsolete not, because the superclass is now pluggable.
|
|
19 |
left in the system for a while for backward compatibility.
|
|
20 |
|
3782
|
21 |
a pluggable node visitor.
|
|
22 |
setup with:
|
|
23 |
actionForNodeClass:aClass put:aBlock
|
|
24 |
|
|
25 |
for example, if you are only interested in assignments,
|
|
26 |
use the following code:
|
|
27 |
|v|
|
|
28 |
v := PluggableParseNodeVisitor new.
|
|
29 |
v actionForNodeClass:AssignmentNode put:[:node | Transcript showCR:node. true].
|
|
30 |
v visit:(Parser parse:code in:someClass.
|
|
31 |
"
|
|
32 |
! !
|
|
33 |
|
4543
|
34 |
!PluggableParseNodeVisitor class methodsFor:'queries'!
|
3782
|
35 |
|
4543
|
36 |
isObsolete
|
|
37 |
^ true
|
3782
|
38 |
! !
|
|
39 |
|
|
40 |
!PluggableParseNodeVisitor class methodsFor:'documentation'!
|
|
41 |
|
|
42 |
version
|
|
43 |
^ '$Header$'
|
|
44 |
!
|
|
45 |
|
|
46 |
version_CVS
|
|
47 |
^ '$Header$'
|
|
48 |
! !
|
|
49 |
|