extensions.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Wed, 15 Jun 2016 23:46:29 +0100
changeset 23 d2d9a2d4d6bf
parent 2 88445baa732f
child 43 ed4fcb347f0f
permissions -rw-r--r--
Added README, licenses and copyright notices.

"{ Package: 'jv:dragonfly' }"!

!CompiledCode methodsFor:'accessing'!

codeObject
    "Return the CompiledCodeObject for this compiled code. Throw an exception
     if the method is not yet compiled or is not dynamically compiled (i.e, 
     if it's statically compiled)"

    self isDynamic ifTrue:[ 
        ^ CompiledCodeObject forCompiledCode: self
    ].
    self error: 'Not a dynamic code'

    "Created: / 05-12-2015 / 23:44:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !

!CompiledCode methodsFor:'inspecting'!

inspector2TabMachineCode
    <inspector2Tab>

    self isDynamic ifTrue:[
        | codeObject tab |

        codeObject :=self codeObject.
        codeObject notNil ifTrue:[ 
            tab := codeObject inspector2TabText.
            tab notNil ifTrue:[ 
                tab label: 'Machine Code'.
                tab priority: 10.
                ^ tab.
            ].                    
        ].
    ].
    ^ nil

    "Created: / 14-12-2015 / 22:05:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !

!jv_dragonfly class methodsFor:'documentation'!

extensionsVersion_HG

    ^ '$Changeset: <not expanded> $'
! !