PrimaryNode.st
author claus
Thu, 02 Jun 1994 22:26:28 +0200
changeset 20 f8dd8ba75205
parent 19 84a1ddf215a5
child 33 8985ec2f9e82
permissions -rw-r--r--
*** empty log message ***

"
 COPYRIGHT (c) 1989 by Claus Gittinger
              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.
"

ParseNode subclass:#PrimaryNode
       instanceVariableNames:'value'
       classVariableNames:''
       poolDictionaries:''
       category:'System-Compiler-Support'
!

PrimaryNode comment:'
COPYRIGHT (c) 1989 by Claus Gittinger
             All Rights Reserved
'!

!PrimaryNode class methodsFor:'documentation'!

copyright
"
 COPYRIGHT (c) 1989 by Claus Gittinger
              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.
"
!

version
"
$Header: /cvs/stx/stx/libcomp/PrimaryNode.st,v 1.7 1994-06-02 20:26:13 claus Exp $
"
!

documentation
"
    node for parse-trees, representing primaries (variables & literals)
"
! !

!PrimaryNode methodsFor:'accessing'!

value
    ^ value
! !

!PrimaryNode methodsFor:'queries'!

isPrimary
    "return true, if this is a node for a primary (i.e. non-send)"

    ^ true
! !

!PrimaryNode methodsFor:'evaluating'!

evaluate
    ^ self subclassResponsibility
!

store:aValue
    ^ self subclassResponsibility
! !

!PrimaryNode methodsFor:'code generation'!

codeForSideEffectOn:aStream inBlock:b
    "no code at all"
    ^ self
!

codeOn:aStream inBlock:codeBlock
    ^ self subclassResponsibility
!

codeStoreOn:aStream inBlock:codeBlock valueNeeded:valueNeeded
    ^ self subclassResponsibility
! !

!PrimaryNode methodsFor:'printing'!

displayString
    ^ self subclassResponsibility
!

printOn:aStream indent:i
    ^ self subclassResponsibility
! !