Codebase list ohcount / 78cfc95f-7386-42a8-9c13-3be662a077b3/main test / expected_dir / smalltalk1.st
78cfc95f-7386-42a8-9c13-3be662a077b3/main

Tree @78cfc95f-7386-42a8-9c13-3be662a077b3/main (Download .tar.gz)

smalltalk1.st @78cfc95f-7386-42a8-9c13-3be662a077b3/mainraw · history · blame

smalltalk	comment	"======================================================================
smalltalk	comment	|
smalltalk	comment	|   Benchmark for streams
smalltalk	comment	|
smalltalk	comment	|
smalltalk	comment	 ======================================================================"
smalltalk	blank	
smalltalk	blank	
smalltalk	code	Eval [
smalltalk	code	    n := Smalltalk arguments isEmpty
smalltalk	code		ifTrue: [ 10000 ]
smalltalk	code		ifFalse: [ 1 max: Smalltalk arguments first asInteger ].
smalltalk	blank	
smalltalk	code	    hello := String new writeStream.
smalltalk	code	    n timesRepeat: [ hello nextPutAll: 'hello
smalltalk	code	\' ].  "this is a comment
smalltalk	comment	so this line is a comment too\"
smalltalk	code	    hello position displayNl
smalltalk	code	"but the previous one, and this one too, are not!" ]