PrimaryNd.st
author Claus Gittinger <cg@exept.de>
Sat, 20 Sep 1997 23:03:33 +0200
changeset 612 2748896a66c8
parent 263 3b21d0991eff
child 711 25b9a501b97d
permissions -rw-r--r--
comments

"
 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.
"

'From Smalltalk/X, Version:3.1.10 on 20-sep-1997 at 11:48:45 pm'                !

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

!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.
"
!

documentation
"
    node for parse-trees, representing primaries (variables & literals)
    This is a helper class for the compiler.

    [author:]
        Claus Gittinger
"
! !

!PrimaryNode methodsFor:'accessing'!

value
    ^ value
! !

!PrimaryNode methodsFor:'code generation'!

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

codeOn:aStream inBlock:codeBlock for:aCompiler
    ^ self subclassResponsibility
!

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

!PrimaryNode methodsFor:'evaluating'!

evaluate
    ^ self subclassResponsibility
!

store:aValue
    ^ self subclassResponsibility
! !

!PrimaryNode methodsFor:'printing'!

displayString
    "return a string for display in inspectors etc."

    ^ self subclassResponsibility

    "Modified: 20.9.1997 / 11:41:19 / cg"
!

printOn:aStream indent:i
    ^ self subclassResponsibility
! !

!PrimaryNode methodsFor:'queries'!

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

    ^ true
! !

!PrimaryNode class methodsFor:'documentation'!

version
    ^ '$Header: /cvs/stx/stx/libcomp/Attic/PrimaryNd.st,v 1.17 1997-09-20 21:03:31 cg Exp $'
! !