Compiler package's implementation of #evaluate: is broken

Project:GNU Smalltalk
Component:STInST
Category:bug
Priority:normal
Assigned:bonzinip
Status:fixed
Description

st> PackageLoader fileInPackage: 'Compiler'.
...
st> Behavior evaluate: '3'
nil

Should be "3" of course.

Updates

#1 submitted by Gwenael Casaccio on Sat, 12/11/2010 - 16:26

index a98719d..550ae39 100644
--- a/packages/stinst/compiler/StartCompiler.st

+++ b/packages/stinst/compiler/StartCompiler.st

@@ -84,14 +84,13 @@ Behavior extend [

    evalString: aString to: anObject [
       

- ^STInST.STEvaluationDriver new parseSmalltalk: aString
- with: self evaluatorClass

+ ^ self evalString: aString to: anObject ifError: [ :f :l :m | self error: (m displayString) ]

    ]

    evalString: aString to: anObject ifError: aBlock [
       
       ^STInST.STEvaluationDriver new 

- parseSmalltalk: aString

+ parseSmalltalk: '^ [', aString, ' ] value'

           with: self evaluatorClass
           onError: 
               [:m :l |

#2 submitted by Paolo Bonzini on Mon, 12/13/2010 - 09:42
Status:active» fixed

Fixed in aa62468.

User login