compiler/tests/PPCContextMementoTest.st
author Jan Vrany <jan.vrany@fit.cvut.cz>
Tue, 16 Jun 2015 06:45:26 +0100
changeset 489 0ca7a70db0f5
parent 452 9f4558b3be66
permissions -rw-r--r--
Fix in codegen for inlined sequence nodes. For inlined sequence nodes, generate nested ifs rather than sequential code which does not work when inlined. The reason is that #codeReturn: in inline generates instvar assignment, not method return, so in sequential code the next child of a sequence will be probed even if previous failed. If that happends, the whole sequence fail and therefore we must generate nested ifs to correctly handle this w.r.t. inlining.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
391
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     1
"{ Package: 'stx:goodies/petitparser/compiler/tests' }"
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     2
422
116d2b2af905 To fold
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 420
diff changeset
     3
"{ NameSpace: Smalltalk }"
116d2b2af905 To fold
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 420
diff changeset
     4
391
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     5
PPContextMementoTest subclass:#PPCContextMementoTest
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     6
	instanceVariableNames:''
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     7
	classVariableNames:''
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     8
	poolDictionaries:''
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
     9
	category:'PetitCompiler-Tests-Context'
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    10
!
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    11
420
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    12
391
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    13
!PPCContextMementoTest methodsFor:'as yet unclassified'!
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    14
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    15
memento
452
9f4558b3be66 Updated to PetitCompiler-JanKurs.111, PetitCompiler-Tests-JanKurs.51, PetitCompiler-Benchmarks-JanKurs.7, added PetitCompiler-Extras-Tests-JanKurs.4
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 422
diff changeset
    16
    ^ PPCContextMemento new
391
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    17
! !
553a5456963b Ported PetitCompiler-(Tests).
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
diff changeset
    18
420
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    19
!PPCContextMementoTest class methodsFor:'documentation'!
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    20
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    21
version_HG
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    22
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    23
    ^ '$Changeset: <not expanded> $'
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    24
! !
b2f2f15cef26 Moved benchmarks to a separate package
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 392
diff changeset
    25