[Vm-dev] VM Maker: Cog-eem.101.mcz
commits at source.squeak.org
commits at source.squeak.org
Wed Sep 25 06:47:26 UTC 2013
Eliot Miranda uploaded a new version of Cog to project VM Maker:
http://source.squeak.org/VMMaker/Cog-eem.101.mcz
==================== Summary ====================
Name: Cog-eem.101
Author: eem
Time: 24 September 2013, 11:47:09.097 pm
UUID: 0e43bfd4-7860-4b18-b7f3-3ef0a17c0ce8
Ancestors: Cog-eem.100
SpurBootstrap
Add a method for digitValue: that doesn't use CharacterTable.
N.B. uses such as this in RePattern
pattern _ (aString, (Character characterTable at: 1) asString). "Must be Zero-Terminated"
must change. In the above case the following is equivalent and faster:
pattern _ (aString, (ByteString new: 1). "Must be Zero-Terminated"
=============== Diff against Cog-eem.100 ===============
Item was added:
+ ----- Method: SpurBootstrap class>>CharacterclassPROTOTYPEdigitValue: (in category 'method prototypes') -----
+ CharacterclassPROTOTYPEdigitValue: x
+ "Answer the Character whose digit value is x. For example,
+ answer $9 for x=9, $0 for x=0, $A for x=10, $Z for x=35."
+
+ | n |
+ n := x asInteger.
+ ^self value: (n < 10 ifTrue: [n + 48] ifFalse: [n + 55])!
More information about the Vm-dev
mailing list