PluggableParseNodeVisitor.st
author Jan Vrany <jan.vrany@labware.com>
Tue, 25 Aug 2020 12:20:06 +0100
branchjv
changeset 4723 524785227024
parent 3841 a22f33410bdf
parent 4543 b2f5c92b579b
permissions -rw-r--r--
Merge branch 'default'

"
 COPYRIGHT (c) 2006 by eXept Software AG
              All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"
"{ Package: 'stx:libcomp' }"

"{ NameSpace: Smalltalk }"

ParseNodeVisitor subclass:#PluggableParseNodeVisitor
	instanceVariableNames:'actionsPerNodeType'
	classVariableNames:''
	poolDictionaries:''
	category:'System-Compiler-Support'
!

!PluggableParseNodeVisitor class methodsFor:'documentation'!

copyright
"
 COPYRIGHT (c) 2006 by eXept Software AG
              All Rights Reserved

 This software is furnished under a license and may be used
 only in accordance with the terms of that license and with the
 inclusion of the above copyright notice.   This software may not
 be provided or otherwise made available to, or used by, any
 other person.  No title to or ownership of the software is
 hereby transferred.
"
!

documentation
"
    obsolete not, because the superclass is now pluggable.
    left in the system for a while for backward compatibility.

    a pluggable node visitor.
    setup with:
        actionForNodeClass:aClass put:aBlock
        
    for example, if you are only interested in assignments,
    use the following code:
        |v|
        v := PluggableParseNodeVisitor new.
        v actionForNodeClass:AssignmentNode put:[:node | Transcript showCR:node. true].
        v visit:(Parser parse:code in:someClass.
"
! !

!PluggableParseNodeVisitor class methodsFor:'queries'!

isObsolete   
    ^ true
! !

!PluggableParseNodeVisitor class methodsFor:'documentation'!

version
    ^ '$Header$'
!

version_CVS
    ^ '$Header$'
! !