IRJump.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Thu, 30 Oct 2014 22:27:09 +0000
changeset 44 840c68a91cdd
parent 43 c8afb8e4c3cc
permissions -rw-r--r--
Tests moved to separate subpackage to follow St/X conventions.

"{ Package: 'ctu:ircompiler' }"

IRInstruction subclass:#IRJump
	instanceVariableNames:'destination'
	classVariableNames:''
	poolDictionaries:''
	category:'IR Compiler-IR'
!

IRJump comment:'Instruction "goto: labelNum"'
!


!IRJump methodsFor:'accessing'!

destination

	^ destination
!

destination: aSequence

	destination := aSequence
!

successorSequences

	^ {destination}
! !

!IRJump methodsFor:'interpret'!

executeOn: interpreter

	^ interpreter goto: destination orderNumber
! !

!IRJump methodsFor:'testing'!

isGoto
	"is unconditional jump"

	^ true
!

isJump
	"goto or if"

	^ true
! !

!IRJump class methodsFor:'documentation'!

version_CVS
    ^ 'Header: /cvs/stx/cvut/stx/goodies/newcompiler/IRJump.st,v 1.3 2009/10/08 12:01:23 fm Exp '
!

version_SVN
    ^ '$Id::                                                                                                                        $'
! !