Cface__CConstNode.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Thu, 17 Sep 2015 07:36:40 +0100
changeset 49 307d55f736ec
parent 41 edb5e4849b79
permissions -rw-r--r--
LLVM bindings: allow to specify path to llvm-config ..by setting LLVM_CONFIG variable when generating definitions for LLVM bindings. Example: make LVM_CONFIG=~/Projects/LLVM/sources1/build/Debug+Asserts/bin/llvm-config

"{ Package: 'jv:cface' }"

"{ NameSpace: Cface }"

CModifierNode subclass:#CConstNode
	instanceVariableNames:''
	classVariableNames:''
	poolDictionaries:''
	category:'Cface-C AST'
!

!CConstNode class methodsFor:'documentation'!

history

    "Created: / 25-10-2007 / 16:58:14 / haja"
    "Created: #id / 25-10-2007 / 16:58:17 / haja"
    "Created: #id: / 29-10-2007 / 20:48:37 / haja"
    "Created: #acceptVisitor: / 02-11-2007 / 10:41:30 / haja"
    "Created: #acceptNameVisitor: / 05-11-2007 / 17:37:52 / haja"
    "Deleted: #acceptNameVisitor: / 12-11-2007 / 09:46:40 / haja"
    "Created: #buildTypeCheckFor:on: / 19-12-2007 / 15:57:17 / haja"
    "Created: #buildObjectCreationOn: / 19-12-2007 / 16:40:59 / haja"
    "Created: #buildValueExtractionFor:on: / 19-12-2007 / 17:30:58 / haja"
    "Created: #buildObjectCreationFor:on: / 19-12-2007 / 17:39:29 / haja"
    "Deleted: #buildObjectCreationOn: / 19-12-2007 / 17:39:31 / haja"
    "Created: #buildCTypeOn: / 19-12-2007 / 18:20:45 / haja"
    "Created: #buildTypeDescriptionOn: / 20-12-2007 / 12:19:58 / haja"
! !

!CConstNode class methodsFor:'instance creation'!

id:anId

    | defConstNode |

    defConstNode := self new.
    defConstNode id:anId.

    ^defConstNode

    "Created: / 29-10-2007 / 20:48:37 / haja"
! !

!CConstNode methodsFor:'accessing'!

cName
    ^ 'const ', super cName

    "Created: / 06-07-2015 / 07:32:43 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!

ffiPointerTypeSymbol

    ^type ffiPointerTypeSymbol

    "Created: / 18-07-2011 / 16:46:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!

ffiTypeSymbol

    ^type ffiTypeSymbol

    "Created: / 10-07-2008 / 20:15:12 / Jan Vrany <vranyj1@fel.cvut.cz>"
!

smalltalkClassName
    ^ type smalltalkClassName

    "Created: / 04-07-2008 / 11:55:29 / Jan Vrany <vranyj1@fel.cvut.cz>"
    "Modified: / 10-07-2008 / 08:01:16 / Jan Vrany <vranyj1@fel.cvut.cz>"
!

smalltalkClassNameWithNamespace

    ^type smalltalkClassNameWithNamespace

    "Created: / 04-07-2008 / 11:56:36 / Jan Vrany <vranyj1@fel.cvut.cz>"
! !

!CConstNode methodsFor:'printing'!

printOn: stream indent: indent

    stream 
        nextPutAll:'const '; 
        cr;
        next: indent + 1 put: Character tab.

    type printOn: stream indent: indent + 1.

    "Created: / 04-03-2008 / 10:57:12 / janfrog"
! !

!CConstNode methodsFor:'testing'!

isAnonymous

    ^type isAnonymous

    "Created: / 04-07-2008 / 11:56:05 / Jan Vrany <vranyj1@fel.cvut.cz>"
!

isCCharNode
    ^ type isCCharNode

    "Created: / 04-07-2008 / 09:27:56 / Jan Vrany <vranyj1@fel.cvut.cz>"
!

isCConstNode
    ^ true

    "Created: / 17-02-2008 / 21:52:38 / janfrog"
!

isCStructNode
    ^ type isCStructNode

    "Created: / 04-07-2008 / 09:28:04 / Jan Vrany <vranyj1@fel.cvut.cz>"
!

isCStructredNode
    ^ type isCStructuredNode

    "Created: / 06-07-2015 / 23:02:20 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!

isForeign

    ^type isForeign

    "Created: / 04-07-2008 / 11:56:15 / Jan Vrany <vranyj1@fel.cvut.cz>"
! !

!CConstNode methodsFor:'visiting'!

acceptVisitor:aVisitor 
    "Double dispatch back to the visitor, passing my type encoded in
     the selector (visitor pattern)"
    "stub code automatically generated - please change if required"
    
    ^ aVisitor visitCConstNode:self

    "Created: / 02-11-2007 / 10:41:30 / haja"
    "Modified: / 10-02-2008 / 10:44:45 / janfrog"
!

isUnresolved
    ^ type isUnresolved

    "Created: / 06-07-2015 / 22:41:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !

!CConstNode class methodsFor:'documentation'!

version
    ^ '$Id$'
!

version_SVN
    ^ '$Id$'
! !