-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
- Chap16
16.9 Class creation messages Page182
Better instance creation for additions:
EEAdditionTest >> testEvaluateWithClassCreationMessage
| ep1 ep2 |
ep1 := EConstant constant5.
ep2 := EConstant constant3.
self assert: (EAddition left: ep1 right: ep2) evaluate equals: 8
Ici on n'a pas encore définir message constant5 et constant3.
- 16.11 Printing Page186
Printing constant
EConstantTest >> testPrinting
self assert: (EConstant value: 5) printString equals: '5'
Ici on peut remplace (EConstant value: 5) à EConstant constant5
16.16 Variables Page195
Back to variable expressions
EVariable >> printOn: aStream
aStream nexPutAll: id asString
Il manque un 't': nextPutAll: .
Metadata
Metadata
Assignees
Labels
No labels