2
0

Pystone.js 45 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519
  1. smalltalk.addClass('PyStoneRecord', smalltalk.Object, ['ptrComp', 'discr', 'enumComp', 'intComp', 'stringComp'], 'Pystone');
  2. smalltalk.PyStoneRecord.comment=unescape('Record%20class%20used%20in%20Pystone%20benchmark.')
  3. smalltalk.addMethod(
  4. '_discr',
  5. smalltalk.method({
  6. selector: 'discr',
  7. category: 'accessing',
  8. fn: function (){
  9. var self=this;
  10. return self['@discr'];
  11. return self;},
  12. source: unescape('discr%0A%09%5Ediscr'),
  13. messageSends: [],
  14. referencedClasses: []
  15. }),
  16. smalltalk.PyStoneRecord);
  17. smalltalk.addMethod(
  18. '_discr_',
  19. smalltalk.method({
  20. selector: 'discr:',
  21. category: 'accessing',
  22. fn: function (p){
  23. var self=this;
  24. self['@discr']=p;
  25. return self;},
  26. source: unescape('discr%3A%20p%0A%09discr%20%3A%3D%20p'),
  27. messageSends: [],
  28. referencedClasses: []
  29. }),
  30. smalltalk.PyStoneRecord);
  31. smalltalk.addMethod(
  32. '_enumComp',
  33. smalltalk.method({
  34. selector: 'enumComp',
  35. category: 'accessing',
  36. fn: function (){
  37. var self=this;
  38. return self['@enumComp'];
  39. return self;},
  40. source: unescape('enumComp%0A%09%5EenumComp'),
  41. messageSends: [],
  42. referencedClasses: []
  43. }),
  44. smalltalk.PyStoneRecord);
  45. smalltalk.addMethod(
  46. '_enumComp_',
  47. smalltalk.method({
  48. selector: 'enumComp:',
  49. category: 'accessing',
  50. fn: function (p){
  51. var self=this;
  52. self['@enumComp']=p;
  53. return self;},
  54. source: unescape('enumComp%3A%20p%0A%09enumComp%20%3A%3D%20p'),
  55. messageSends: [],
  56. referencedClasses: []
  57. }),
  58. smalltalk.PyStoneRecord);
  59. smalltalk.addMethod(
  60. '_intComp',
  61. smalltalk.method({
  62. selector: 'intComp',
  63. category: 'accessing',
  64. fn: function (){
  65. var self=this;
  66. return self['@intComp'];
  67. return self;},
  68. source: unescape('intComp%0A%09%5EintComp'),
  69. messageSends: [],
  70. referencedClasses: []
  71. }),
  72. smalltalk.PyStoneRecord);
  73. smalltalk.addMethod(
  74. '_intComp_',
  75. smalltalk.method({
  76. selector: 'intComp:',
  77. category: 'accessing',
  78. fn: function (p){
  79. var self=this;
  80. self['@intComp']=p;
  81. return self;},
  82. source: unescape('intComp%3A%20p%0A%09intComp%20%3A%3D%20p'),
  83. messageSends: [],
  84. referencedClasses: []
  85. }),
  86. smalltalk.PyStoneRecord);
  87. smalltalk.addMethod(
  88. '_ptrComp',
  89. smalltalk.method({
  90. selector: 'ptrComp',
  91. category: 'accessing',
  92. fn: function (){
  93. var self=this;
  94. return self['@ptrComp'];
  95. return self;},
  96. source: unescape('ptrComp%0A%09%5EptrComp'),
  97. messageSends: [],
  98. referencedClasses: []
  99. }),
  100. smalltalk.PyStoneRecord);
  101. smalltalk.addMethod(
  102. '_ptrComp_',
  103. smalltalk.method({
  104. selector: 'ptrComp:',
  105. category: 'accessing',
  106. fn: function (p){
  107. var self=this;
  108. self['@ptrComp']=p;
  109. return self;},
  110. source: unescape('ptrComp%3A%20p%0A%09ptrComp%20%3A%3D%20p'),
  111. messageSends: [],
  112. referencedClasses: []
  113. }),
  114. smalltalk.PyStoneRecord);
  115. smalltalk.addMethod(
  116. '_stringComp',
  117. smalltalk.method({
  118. selector: 'stringComp',
  119. category: 'accessing',
  120. fn: function (){
  121. var self=this;
  122. return self['@stringComp'];
  123. return self;},
  124. source: unescape('stringComp%0A%09%5EstringComp'),
  125. messageSends: [],
  126. referencedClasses: []
  127. }),
  128. smalltalk.PyStoneRecord);
  129. smalltalk.addMethod(
  130. '_stringComp_',
  131. smalltalk.method({
  132. selector: 'stringComp:',
  133. category: 'accessing',
  134. fn: function (p){
  135. var self=this;
  136. self['@stringComp']=p;
  137. return self;},
  138. source: unescape('stringComp%3A%20p%0A%09stringComp%20%3A%3D%20p'),
  139. messageSends: [],
  140. referencedClasses: []
  141. }),
  142. smalltalk.PyStoneRecord);
  143. smalltalk.addMethod(
  144. '_copy',
  145. smalltalk.method({
  146. selector: 'copy',
  147. category: 'copying',
  148. fn: function (){
  149. var self=this;
  150. return smalltalk.send((smalltalk.PyStoneRecord || PyStoneRecord), "_ptrComp_discr_enumComp_intComp_stringComp_", [self['@ptrComp'], self['@discr'], self['@enumComp'], self['@intComp'], self['@stringComp']]);
  151. return self;},
  152. source: unescape('copy%0A%09%5EPyStoneRecord%20ptrComp%3A%20ptrComp%20discr%3A%20discr%20enumComp%3A%20enumComp%20intComp%3A%20intComp%20stringComp%3A%20stringComp'),
  153. messageSends: ["ptrComp:discr:enumComp:intComp:stringComp:"],
  154. referencedClasses: [smalltalk.PyStoneRecord]
  155. }),
  156. smalltalk.PyStoneRecord);
  157. smalltalk.addMethod(
  158. '_ptrComp_discr_enumComp_intComp_stringComp_',
  159. smalltalk.method({
  160. selector: 'ptrComp:discr:enumComp:intComp:stringComp:',
  161. category: 'initialize-release',
  162. fn: function (p, d, e, i, s){
  163. var self=this;
  164. self['@ptrComp']=p;
  165. self['@discr']=d;
  166. self['@enumComp']=e;
  167. self['@intComp']=i;
  168. self['@stringComp']=s;
  169. return self;},
  170. source: unescape('ptrComp%3A%20p%20discr%3A%20d%20enumComp%3A%20e%20intComp%3A%20i%20stringComp%3A%20s%0A%0A%09ptrComp%20%3A%3D%20p.%0A%09discr%20%3A%3D%20d.%0A%09enumComp%20%3A%3D%20e.%0A%09intComp%20%3A%3D%20i.%0A%09stringComp%20%3A%3D%20s'),
  171. messageSends: [],
  172. referencedClasses: []
  173. }),
  174. smalltalk.PyStoneRecord);
  175. smalltalk.addMethod(
  176. '_new',
  177. smalltalk.method({
  178. selector: 'new',
  179. category: 'instance-creation',
  180. fn: function (){
  181. var self=this;
  182. return smalltalk.send(self, "_ptrComp_discr_enumComp_intComp_stringComp_", [nil, (0), (0), (0), (0)]);
  183. return self;},
  184. source: unescape('new%0A%0A%09%5Eself%20ptrComp%3A%20nil%20discr%3A%200%20enumComp%3A%200%20intComp%3A%200%20stringComp%3A%200'),
  185. messageSends: ["ptrComp:discr:enumComp:intComp:stringComp:"],
  186. referencedClasses: []
  187. }),
  188. smalltalk.PyStoneRecord.klass);
  189. smalltalk.addMethod(
  190. '_ptrComp_discr_enumComp_intComp_stringComp_',
  191. smalltalk.method({
  192. selector: 'ptrComp:discr:enumComp:intComp:stringComp:',
  193. category: 'instance-creation',
  194. fn: function (p, d, e, i, s){
  195. var self=this;
  196. return smalltalk.send(smalltalk.send(self, "_new", [], smalltalk.Object.klass), "_ptrComp_discr_enumComp_intComp_stringComp_", [p, d, e, i, s]);
  197. return self;},
  198. source: unescape('ptrComp%3A%20p%20discr%3A%20d%20enumComp%3A%20e%20intComp%3A%20i%20stringComp%3A%20s%0A%0A%09%5Esuper%20new%20ptrComp%3A%20p%20discr%3A%20d%20enumComp%3A%20e%20intComp%3A%20i%20stringComp%3A%20s'),
  199. messageSends: ["ptrComp:discr:enumComp:intComp:stringComp:", "new"],
  200. referencedClasses: []
  201. }),
  202. smalltalk.PyStoneRecord.klass);
  203. smalltalk.addClass('Pystone', smalltalk.Object, ['nulltime', 'ptrGlbNext', 'ptrGlb', 'ident1', 'ident3', 'ident2', 'ident4', 'ident5', 'ident6', 'intGlob', 'boolGlob', 'char1Glob', 'char2Glob', 'array1Glob', 'array2Glob', 'func3', 'func2', 'func1'], 'Pystone');
  204. smalltalk.Pystone.comment=unescape('This%20is%20a%20straight%20translation%20of%20pystone%201.1%20from%20Python%20to%20Squeak.%20Procedures%20have%20been%20mapped%20to%20instance%20side%20methods%2C%20functions%20have%20been%20mapped%20to%20blocks.%20Open%20a%20transcript%20and%20run%3A%0A%0APystone%20run')
  205. smalltalk.addMethod(
  206. '_defineFunctions',
  207. smalltalk.method({
  208. selector: 'defineFunctions',
  209. category: 'as yet unclassified',
  210. fn: function (){
  211. var self=this;
  212. self['@func1']=(function(charPar1, charPar2){var charLoc1=nil;
  213. var charLoc2=nil;
  214. charLoc1=charPar1;charLoc2=charLoc1;return (($receiver = smalltalk.send(charLoc2, "__eq", [charPar2])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return self['@ident2'];})() : (function(){return self['@ident1'];})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return self['@ident2'];}), (function(){return self['@ident1'];})]);});
  215. self['@func2']=(function(strParI1, strParI2){var intLoc=nil;
  216. var charLoc=nil;
  217. intLoc=(1);(function(){while((function(){return (($receiver = intLoc).klass === smalltalk.Number) ? $receiver <=(1) : smalltalk.send($receiver, "__lt_eq", [(1)]);})()) {(function(){return (($receiver = smalltalk.send(smalltalk.send(self['@func1'], "_value_value_", [smalltalk.send(strParI1, "_at_", [intLoc]), smalltalk.send(strParI1, "_at_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])])]), "__eq", [self['@ident1']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){charLoc="A";return intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){charLoc="A";return intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]);})]);})()}})();(($receiver = smalltalk.send((($receiver = charLoc).klass === smalltalk.Number) ? $receiver >="W" : smalltalk.send($receiver, "__gt_eq", ["W"]), "_and_", [(function(){return (($receiver = charLoc).klass === smalltalk.Number) ? $receiver <="Z" : smalltalk.send($receiver, "__lt_eq", ["Z"]);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return intLoc=(7);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return intLoc=(7);})]);return (($receiver = smalltalk.send(charLoc, "__eq", ["X"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return true;})() : (function(){return (($receiver = (($receiver = strParI1).klass === smalltalk.Number) ? $receiver >strParI2 : smalltalk.send($receiver, "__gt", [strParI2])).klass === smalltalk.Boolean) ? ($receiver ? (function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(7) : smalltalk.send($receiver, "__plus", [(7)]);return true;})() : (function(){return false;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(7) : smalltalk.send($receiver, "__plus", [(7)]);return true;}), (function(){return false;})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return true;}), (function(){return (($receiver = (($receiver = strParI1).klass === smalltalk.Number) ? $receiver >strParI2 : smalltalk.send($receiver, "__gt", [strParI2])).klass === smalltalk.Boolean) ? ($receiver ? (function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(7) : smalltalk.send($receiver, "__plus", [(7)]);return true;})() : (function(){return false;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(7) : smalltalk.send($receiver, "__plus", [(7)]);return true;}), (function(){return false;})]);})]);});
  218. self['@func3']=(function(enumParIn){var enumLoc=nil;
  219. enumLoc=enumParIn;return smalltalk.send(enumLoc, "__eq", [self['@ident3']]);});
  220. return self;},
  221. source: unescape('defineFunctions%0A%09%22Functions%20have%20been%20mapped%20to%20blocks%2C%20since%20that%0A%09would%20be%20natural.%22%0A%09%0A%09func1%20%3A%3D%20%5B%3AcharPar1%20%3AcharPar2%20%7C%0A%09%09%7C%20charLoc1%20charLoc2%20%7C%0A%09%09charLoc1%20%3A%3D%20charPar1.%0A%09%09charLoc2%20%3A%3D%20charLoc1.%0A%09%09%28charLoc2%20%3D%20charPar2%29%20ifTrue%3A%20%5Bident2%5D%20ifFalse%3A%20%5Bident1%5D%5D.%0A%0A%09func2%20%3A%3D%20%5B%3AstrParI1%20%3AstrParI2%20%7C%0A%09%09%7C%20intLoc%20charLoc%20%7C%0A%09%09intLoc%20%3A%3D%201.%0A%09%09%5BintLoc%20%3C%3D%201%5D%20whileTrue%3A%20%5B%0A%09%09%09%28%28func1%20value%3A%20%28strParI1%20at%3A%20intLoc%29%20value%3A%20%28strParI1%20at%3A%20intLoc%20+%201%29%29%20%3D%20ident1%29%0A%09%09%09%09ifTrue%3A%20%5B%0A%09%09%09%09%09charLoc%20%3A%3D%20%27A%27.%0A%09%09%09%09%09intLoc%20%3A%3D%20intLoc%20+%201%5D%5D.%0A%09%09%28charLoc%20%3E%3D%20%27W%27%20and%3A%20%5BcharLoc%20%3C%3D%20%27Z%27%5D%29%20ifTrue%3A%20%5B%0A%09%09%09intLoc%20%3A%3D%207%5D.%0A%09%09%28charLoc%20%3D%20%27X%27%29%20ifTrue%3A%20%5Btrue%5D%20ifFalse%3A%20%5B%0A%09%09%09%28strParI1%20%3E%20strParI2%29%20ifTrue%3A%20%5B%0A%09%09%09%09intLoc%20%3A%3D%20intLoc%20+%207.%0A%09%09%09%09true%5D%0A%09%09%09ifFalse%3A%20%5B%0A%09%09%09%09false%5D%5D%5D.%0A%09%0A%09func3%20%3A%3D%20%5B%3AenumParIn%20%7C%0A%09%09%7C%20enumLoc%20%7C%0A%09%09enumLoc%20%3A%3D%20enumParIn.%0A%09%09enumLoc%20%3D%20ident3%5D'),
  222. messageSends: ["ifTrue:ifFalse:", unescape("%3D"), "whileTrue:", unescape("%3C%3D"), "ifTrue:", "value:value:", "at:", unescape("+"), "and:", unescape("%3E%3D"), unescape("%3E")],
  223. referencedClasses: []
  224. }),
  225. smalltalk.Pystone);
  226. smalltalk.addMethod(
  227. '_main_',
  228. smalltalk.method({
  229. selector: 'main:',
  230. category: 'as yet unclassified',
  231. fn: function (loops){
  232. var self=this;
  233. self['@ident1']=(1);
  234. self['@ident2']=(2);
  235. self['@ident3']=(3);
  236. self['@ident4']=(4);
  237. self['@ident5']=(5);
  238. self['@ident6']=(6);
  239. self['@intGlob']=(0);
  240. self['@boolGlob']=false;
  241. self['@char1Glob']=smalltalk.send((smalltalk.String || String), "_value_", [(0)]);
  242. self['@char2Glob']=smalltalk.send((smalltalk.String || String), "_value_", [(0)]);
  243. self['@array1Glob']=smalltalk.send((smalltalk.Array || Array), "_new", []);
  244. smalltalk.send((51), "_timesRepeat_", [(function(){return smalltalk.send(self['@array1Glob'], "_add_", [(0)]);})]);
  245. self['@array2Glob']=smalltalk.send(smalltalk.send(smalltalk.send((1), "_to_", [(51)]), "_collect_", [(function(i){return smalltalk.send(self['@array1Glob'], "_copy", []);})]), "_asArray", []);
  246. smalltalk.send(self, "_defineFunctions", []);
  247. smalltalk.send(self, "_pystones_block_", [loops, (function(benchtime, stones){smalltalk.send(self, "_log_", [smalltalk.send(smalltalk.send(smalltalk.send(unescape("Pystone%281.1%29%20time%20for%20"), "__comma", [smalltalk.send(loops, "_asString", [])]), "__comma", [unescape("%20passes%20%3D%20")]), "__comma", [smalltalk.send(benchtime, "_asString", [])])]);return smalltalk.send(self, "_log_", [smalltalk.send(smalltalk.send("This machine benchmarks at ", "__comma", [smalltalk.send((($receiver = smalltalk.send((($receiver = stones).klass === smalltalk.Number) ? $receiver /(0.1) : smalltalk.send($receiver, "__slash", [(0.1)]), "_rounded", [])).klass === smalltalk.Number) ? $receiver *(0.1) : smalltalk.send($receiver, "__star", [(0.1)]), "_asString", [])]), "__comma", [unescape("%20pystones/second")])]);})]);
  248. return self;},
  249. source: unescape('main%3A%20loops%0A%09%22Adaption%20of%20pystone.py%20version%201.9%20from%20Python.%22%0A%0A%09ident1%20%3A%3D%201.%20ident2%20%3A%3D%202.%20ident3%20%3A%3D%203.%20ident4%20%3A%3D%204.%20ident5%20%3A%3D%205.%20ident6%20%3A%3D%206.%0A%09intGlob%20%3A%3D%200.%0A%09boolGlob%20%3A%3D%20false.%0A%09char1Glob%20%3A%3D%20String%20value%3A%200.%0A%09char2Glob%20%3A%3D%20String%20value%3A%200.%0A%09array1Glob%20%3A%3D%20Array%20new.%0A%20%20%20%20%20%20%20%2051%20timesRepeat%3A%20%5B%20array1Glob%20add%3A%200%5D.%0A%09array2Glob%20%3A%3D%20%28%281%20to%3A%2051%29%20collect%3A%20%5B%3Ai%20%7C%20array1Glob%20copy%5D%29%20asArray.%0A%0A%09self%20defineFunctions.%0A%0A%09self%20pystones%3A%20loops%20block%3A%20%5B%3Abenchtime%20%3Astones%20%7C%0A%09%09self%20log%3A%20%27Pystone%281.1%29%20time%20for%20%27%2C%20loops%20asString%2C%20%27%20passes%20%3D%20%27%2C%20benchtime%20asString.%0A%09%09self%20log%3A%20%27This%20machine%20benchmarks%20at%20%27%2C%0A%09%09%09%28%28stones%20/%200.1%29%20rounded%20*%200.1%29%20asString%2C%20%27%20pystones/second%27%5D'),
  250. messageSends: ["value:", "new", "timesRepeat:", "add:", "asArray", "collect:", "to:", "copy", "defineFunctions", "pystones:block:", "log:", unescape("%2C"), "asString", unescape("*"), "rounded", unescape("/")],
  251. referencedClasses: [smalltalk.String,smalltalk.Array]
  252. }),
  253. smalltalk.Pystone);
  254. smalltalk.addMethod(
  255. '_log_',
  256. smalltalk.method({
  257. selector: 'log:',
  258. category: 'as yet unclassified',
  259. fn: function (aString){
  260. var self=this;
  261. (($receiver = smalltalk.send((typeof smalltalk == 'undefined' ? nil : smalltalk), "_at_", ["Transcript"])) == nil || $receiver == undefined) ? (function(){return smalltalk.send((typeof console == 'undefined' ? nil : console), "_log_", [aString]);})() : (function(){return (function($rec){smalltalk.send($rec, "_show_", [aString]);return smalltalk.send($rec, "_cr", []);})((smalltalk.Transcript || Transcript));})();
  262. return self;},
  263. source: unescape('log%3A%20aString%0A%09%28smalltalk%20at%3A%20%23Transcript%29%0A%09%09ifNotNil%3A%20%5B%0A%09%09%09Transcript%20show%3A%20aString%3Bcr%5D%0A%09%09ifNil%3A%20%5B%0A%09%09%09console%20log%3A%20aString%5D'),
  264. messageSends: ["ifNotNil:ifNil:", "at:", "log:", "show:", "cr"],
  265. referencedClasses: []
  266. }),
  267. smalltalk.Pystone);
  268. smalltalk.addMethod(
  269. '_proc0_block_',
  270. smalltalk.method({
  271. selector: 'proc0:block:',
  272. category: 'as yet unclassified',
  273. fn: function (loops, aBlock){
  274. var self=this;
  275. var string1Loc=nil;
  276. var starttime=nil;
  277. var intLoc1=nil;
  278. var intLoc2=nil;
  279. var string2Loc=nil;
  280. var enumLoc=nil;
  281. var intLoc3=nil;
  282. var charIndex=nil;
  283. var benchtime=nil;
  284. smalltalk.send(loops, "_timesRepeat_", [(function(){return nil;})]);
  285. benchtime=smalltalk.send((smalltalk.Date || Date), "_millisecondsToRun_", [(function(){self['@ptrGlbNext']=smalltalk.send((smalltalk.PyStoneRecord || PyStoneRecord), "_new", []);self['@ptrGlb']=smalltalk.send((smalltalk.PyStoneRecord || PyStoneRecord), "_new", []);smalltalk.send(self['@ptrGlb'], "_ptrComp_", [self['@ptrGlbNext']]);smalltalk.send(self['@ptrGlb'], "_discr_", [self['@ident1']]);smalltalk.send(self['@ptrGlb'], "_enumComp_", [self['@ident3']]);smalltalk.send(self['@ptrGlb'], "_intComp_", [(40)]);smalltalk.send(self['@ptrGlb'], "_stringComp_", [unescape("DHRYSTONE%20PROGRAM%2C%20SOME%20STRING")]);string1Loc=unescape("DHRYSTONE%20PROGRAM%2C%201%27ST%20STRING");smalltalk.send(smalltalk.send(self['@array2Glob'], "_at_", [(8)]), "_at_put_", [(7), (10)]);return smalltalk.send(loops, "_timesRepeat_", [(function(){(function($rec){smalltalk.send($rec, "_proc5", []);return smalltalk.send($rec, "_proc4", []);})(self);intLoc1=(2);intLoc2=(3);string2Loc=unescape("DHRYSTONE%20PROGRAM%2C%202%27ND%20STRING");enumLoc=self['@ident2'];self['@boolGlob']=smalltalk.send(smalltalk.send(self['@func2'], "_value_value_", [string1Loc, string2Loc]), "_not", []);(function(){while((function(){return (($receiver = intLoc1).klass === smalltalk.Number) ? $receiver <intLoc2 : smalltalk.send($receiver, "__lt", [intLoc2]);})()) {(function(){intLoc3=(($receiver = (5) * intLoc1).klass === smalltalk.Number) ? $receiver -intLoc2 : smalltalk.send($receiver, "__minus", [intLoc2]);intLoc3=smalltalk.send(self, "_proc7_with_", [intLoc1, intLoc2]);return intLoc1=(($receiver = intLoc1).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]);})()}})();smalltalk.send(self, "_proc8_with_with_with_", [self['@array1Glob'], self['@array2Glob'], intLoc1, intLoc3]);self['@ptrGlb']=smalltalk.send(self, "_proc1_", [self['@ptrGlb']]);charIndex="A";(function(){while((function(){return (($receiver = charIndex).klass === smalltalk.Number) ? $receiver <=self['@char2Glob'] : smalltalk.send($receiver, "__lt_eq", [self['@char2Glob']]);})()) {(function(){(($receiver = smalltalk.send(enumLoc, "__eq", [smalltalk.send(self['@func1'], "_value_value_", [charIndex, "C"])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumLoc=smalltalk.send(self, "_proc6_", [self['@ident1']]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumLoc=smalltalk.send(self, "_proc6_", [self['@ident1']]);})]);return charIndex=smalltalk.send((smalltalk.String || String), "_value_", [(($receiver = smalltalk.send(charIndex, "_asciiValue", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])]);})()}})();intLoc3=(($receiver = intLoc2).klass === smalltalk.Number) ? $receiver *intLoc1 : smalltalk.send($receiver, "__star", [intLoc1]);intLoc2=(($receiver = intLoc3).klass === smalltalk.Number) ? $receiver /intLoc1 : smalltalk.send($receiver, "__slash", [intLoc1]);intLoc2=(($receiver = (7) * (($receiver = intLoc3).klass === smalltalk.Number) ? $receiver -intLoc2 : smalltalk.send($receiver, "__minus", [intLoc2])).klass === smalltalk.Number) ? $receiver -intLoc1 : smalltalk.send($receiver, "__minus", [intLoc1]);return intLoc1=smalltalk.send(self, "_proc2_", [intLoc1]);})]);})]);
  286. return smalltalk.send(aBlock, "_value_value_", [(($receiver = benchtime).klass === smalltalk.Number) ? $receiver /(1000) : smalltalk.send($receiver, "__slash", [(1000)]), (($receiver = (($receiver = loops).klass === smalltalk.Number) ? $receiver /benchtime : smalltalk.send($receiver, "__slash", [benchtime])).klass === smalltalk.Number) ? $receiver *(1000) : smalltalk.send($receiver, "__star", [(1000)])]);
  287. return self;},
  288. source: unescape('proc0%3A%20loops%20block%3A%20aBlock%0A%09%7C%20string1Loc%20starttime%20intLoc1%20intLoc2%20string2Loc%20enumLoc%20intLoc3%20charIndex%20benchtime%20%7C%0A%0A%09loops%20timesRepeat%3A%20%5B%5D.%0A%0A%09benchtime%20%3A%3D%20Date%20millisecondsToRun%3A%20%5B%0A%09ptrGlbNext%20%3A%3D%20PyStoneRecord%20new.%0A%09ptrGlb%20%3A%3D%20PyStoneRecord%20new.%0A%09ptrGlb%20ptrComp%3A%20ptrGlbNext.%0A%09ptrGlb%20discr%3A%20ident1.%0A%09ptrGlb%20enumComp%3A%20ident3.%0A%09ptrGlb%20intComp%3A%2040.%0A%09ptrGlb%20stringComp%3A%20%27DHRYSTONE%20PROGRAM%2C%20SOME%20STRING%27.%0A%09string1Loc%20%3A%3D%20%27DHRYSTONE%20PROGRAM%2C%201%27%27ST%20STRING%27.%0A%09%0A%09%28array2Glob%20at%3A%208%29%20at%3A%207%20put%3A%2010.%0A%09%221%20to%3A%20loops%20-%201%20do%3A%20%5B%3Ai%20%7C%20%20%20%20%20%20%20Changed%20this%20to%20use%20timesRepeat%3A%20since%20i%20is%20not%20used%20at%20all%20in%20the%20loop%22%0A%09loops%20timesRepeat%3A%20%5B%0A%09%09self%20proc5%3B%20proc4.%0A%09%09intLoc1%20%3A%3D%202.%0A%09%09intLoc2%20%3A%3D%203.%0A%09%09string2Loc%20%3A%3D%20%27DHRYSTONE%20PROGRAM%2C%202%27%27ND%20STRING%27.%0A%09%09enumLoc%20%3A%3D%20ident2.%0A%09%09boolGlob%20%3A%3D%20%28func2%20value%3A%20string1Loc%20value%3A%20string2Loc%29%20not.%0A%09%09%5BintLoc1%20%3C%20intLoc2%5D%20whileTrue%3A%20%5B%0A%09%09%09intLoc3%20%3A%3D%205%20*%20intLoc1%20-%20intLoc2.%0A%09%09%09intLoc3%20%3A%3D%20self%20proc7%3A%20intLoc1%20with%3A%20intLoc2.%0A%09%09%09intLoc1%20%3A%3D%20intLoc1%20+%201%5D.%0A%09%20%09self%20proc8%3Aarray1Glob%20with%3A%20array2Glob%20with%3A%20intLoc1%20with%3A%20intLoc3.%0A%09%09ptrGlb%20%3A%3D%20self%20proc1%3A%20ptrGlb.%0A%09%09charIndex%20%3A%3D%20%27A%27.%0A%09%09%5BcharIndex%20%3C%3D%20char2Glob%5D%20whileTrue%3A%20%5B%0A%09%09%09%28enumLoc%20%3D%20%28func1%20value%3A%20charIndex%20value%3A%20%27C%27%29%29%0A%09%09%09%09%09ifTrue%3A%20%5BenumLoc%20%3A%3D%20self%20proc6%3A%20ident1%5D.%0A%09%09%09charIndex%20%3A%3D%20String%20value%3A%20%28charIndex%20asciiValue%20+%201%29%5D.%0A%09%09intLoc3%20%3A%3D%20intLoc2%20*%20intLoc1.%0A%09%09intLoc2%20%3A%3D%20intLoc3%20/%20intLoc1.%0A%09%09intLoc2%20%3A%3D%207%20*%20%28intLoc3%20-%20intLoc2%29%20-%20intLoc1.%0A%09%09intLoc1%20%3A%3D%20self%20proc2%3A%20intLoc1%5D%5D.%0A%20%20%20%20%5E%20aBlock%20value%3A%20%28benchtime%20/%201000%29%20value%3A%20%28loops%20/%20benchtime%29%20*%201000'),
  289. messageSends: ["timesRepeat:", "millisecondsToRun:", "new", "ptrComp:", "discr:", "enumComp:", "intComp:", "stringComp:", "at:put:", "at:", "proc5", "proc4", "not", "value:value:", "whileTrue:", unescape("%3C"), unescape("-"), unescape("*"), "proc7:with:", unescape("+"), "proc8:with:with:with:", "proc1:", unescape("%3C%3D"), "ifTrue:", unescape("%3D"), "proc6:", "value:", "asciiValue", unescape("/"), "proc2:"],
  290. referencedClasses: [smalltalk.Date,smalltalk.PyStoneRecord,smalltalk.String]
  291. }),
  292. smalltalk.Pystone);
  293. smalltalk.addMethod(
  294. '_proc1_',
  295. smalltalk.method({
  296. selector: 'proc1:',
  297. category: 'as yet unclassified',
  298. fn: function (ptrParIn){
  299. var self=this;
  300. var nextRecord=nil;
  301. var tmp=nil;
  302. tmp=ptrParIn;
  303. nextRecord=smalltalk.send(self['@ptrGlb'], "_copy", []);
  304. smalltalk.send(ptrParIn, "_ptrComp_", [nextRecord]);
  305. smalltalk.send(ptrParIn, "_intComp_", [(5)]);
  306. smalltalk.send(nextRecord, "_intComp_", [smalltalk.send(ptrParIn, "_intComp", [])]);
  307. smalltalk.send(nextRecord, "_ptrComp_", [smalltalk.send(ptrParIn, "_ptrComp", [])]);
  308. smalltalk.send(nextRecord, "_ptrComp_", [smalltalk.send(self, "_proc3_", [smalltalk.send(nextRecord, "_ptrComp", [])])]);
  309. (($receiver = smalltalk.send(smalltalk.send(nextRecord, "_discr", []), "__eq", [self['@ident1']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(nextRecord, "_intComp_", [(6)]);smalltalk.send(nextRecord, "_enumComp_", [smalltalk.send(self, "_proc6_", [smalltalk.send(ptrParIn, "_enumComp", [])])]);smalltalk.send(nextRecord, "_ptrComp_", [smalltalk.send(self['@ptrGlb'], "_ptrComp", [])]);return smalltalk.send(nextRecord, "_intComp_", [smalltalk.send(self, "_proc7_with_", [smalltalk.send(nextRecord, "_intComp", []), (10)])]);})() : (function(){return tmp=smalltalk.send(nextRecord, "_copy", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(nextRecord, "_intComp_", [(6)]);smalltalk.send(nextRecord, "_enumComp_", [smalltalk.send(self, "_proc6_", [smalltalk.send(ptrParIn, "_enumComp", [])])]);smalltalk.send(nextRecord, "_ptrComp_", [smalltalk.send(self['@ptrGlb'], "_ptrComp", [])]);return smalltalk.send(nextRecord, "_intComp_", [smalltalk.send(self, "_proc7_with_", [smalltalk.send(nextRecord, "_intComp", []), (10)])]);}), (function(){return tmp=smalltalk.send(nextRecord, "_copy", []);})]);
  310. smalltalk.send(nextRecord, "_ptrComp_", [nil]);
  311. return tmp;
  312. return self;},
  313. source: unescape('proc1%3A%20ptrParIn%0A%09%7C%20nextRecord%20tmp%20%7C%0A%09tmp%20%3A%3D%20ptrParIn.%0A%09nextRecord%20%3A%3D%20ptrGlb%20copy.%0A%09ptrParIn%20ptrComp%3A%20nextRecord.%0A%09ptrParIn%20intComp%3A%205.%0A%09nextRecord%20intComp%3A%20ptrParIn%20intComp.%0A%09nextRecord%20ptrComp%3A%20ptrParIn%20ptrComp.%0A%09nextRecord%20ptrComp%3A%20%28self%20proc3%3A%20nextRecord%20ptrComp%29.%0A%09%28nextRecord%20discr%20%3D%20ident1%29%20ifTrue%3A%20%5B%0A%09%09nextRecord%20intComp%3A%206.%0A%09%09nextRecord%20enumComp%3A%20%28self%20proc6%3A%20ptrParIn%20enumComp%29.%0A%09%09nextRecord%20ptrComp%3A%20ptrGlb%20ptrComp.%0A%09%09nextRecord%20intComp%3A%20%28self%20proc7%3A%20nextRecord%20intComp%20with%3A%2010%29%20%5D%0A%09ifFalse%3A%20%5B%0A%09%09tmp%20%3A%3D%20nextRecord%20copy%5D.%0A%09nextRecord%20ptrComp%3A%20nil.%0A%09%5Etmp'),
  314. messageSends: ["copy", "ptrComp:", "intComp:", "intComp", "ptrComp", "proc3:", "ifTrue:ifFalse:", unescape("%3D"), "discr", "enumComp:", "proc6:", "enumComp", "proc7:with:"],
  315. referencedClasses: []
  316. }),
  317. smalltalk.Pystone);
  318. smalltalk.addMethod(
  319. '_proc2_',
  320. smalltalk.method({
  321. selector: 'proc2:',
  322. category: 'as yet unclassified',
  323. fn: function (intParIO){
  324. var self=this;
  325. try{var tmp=nil;
  326. var intLoc=nil;
  327. var enumLoc=nil;
  328. tmp=intParIO;
  329. intLoc=(($receiver = intParIO).klass === smalltalk.Number) ? $receiver +(10) : smalltalk.send($receiver, "__plus", [(10)]);
  330. (function(){while((function(){return true;})()) {(function(){(($receiver = smalltalk.send(self['@char1Glob'], "__eq", ["A"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]);tmp=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -self['@intGlob'] : smalltalk.send($receiver, "__minus", [self['@intGlob']]);return enumLoc=self['@ident1'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){intLoc=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]);tmp=(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -self['@intGlob'] : smalltalk.send($receiver, "__minus", [self['@intGlob']]);return enumLoc=self['@ident1'];})]);return (($receiver = smalltalk.send(enumLoc, "__eq", [self['@ident1']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_proc2_', fn: function(){return tmp}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_proc2_', fn: function(){return tmp}})})();})]);})()}})();
  331. return self;
  332. } catch(e) {if(e.name === 'stReturn' && e.selector === '_proc2_'){return e.fn()} throw(e)}},
  333. source: unescape('proc2%3A%20intParIO%0A%09%7C%20tmp%20intLoc%20enumLoc%20%7C%0A%09tmp%20%3A%3D%20intParIO.%0A%09intLoc%20%3A%3D%20intParIO%20+%2010.%0A%09%5Btrue%5D%20whileTrue%3A%20%5B%0A%09%09%28char1Glob%20%3D%20%27A%27%29%20ifTrue%3A%20%5B%0A%09%09%09intLoc%20%3A%3D%20intLoc%20-%201.%0A%09%09%09tmp%20%3A%3D%20intLoc%20-%20intGlob.%0A%09%09%09enumLoc%20%3A%3D%20ident1%5D.%0A%09%09%28enumLoc%20%3D%20ident1%29%20ifTrue%3A%20%5B%0A%09%09%09%5E%20tmp%5D%5D'),
  334. messageSends: [unescape("+"), "whileTrue:", "ifTrue:", unescape("%3D"), unescape("-")],
  335. referencedClasses: []
  336. }),
  337. smalltalk.Pystone);
  338. smalltalk.addMethod(
  339. '_proc3_',
  340. smalltalk.method({
  341. selector: 'proc3:',
  342. category: 'as yet unclassified',
  343. fn: function (ptrParOut){
  344. var self=this;
  345. var tmp=nil;
  346. tmp=ptrParOut;
  347. (($receiver = self['@ptrGlb']) == nil || $receiver == undefined) ? (function(){return self['@intGlob']=(100);})() : (function(){return tmp=smalltalk.send(self['@ptrGlb'], "_ptrComp", []);})();
  348. smalltalk.send(self['@ptrGlb'], "_intComp_", [smalltalk.send(self, "_proc7_with_", [(10), self['@intGlob']])]);
  349. return tmp;
  350. return self;},
  351. source: unescape('proc3%3A%20ptrParOut%0A%09%7C%20tmp%20%7C%0A%09tmp%20%3A%3D%20ptrParOut.%0A%09ptrGlb%20ifNotNil%3A%20%5B%0A%09%09tmp%20%3A%3D%20ptrGlb%20ptrComp%5D%0A%09ifNil%3A%20%5B%0A%09%09intGlob%20%3A%3D%20100%5D.%0A%09ptrGlb%20intComp%3A%20%28self%20proc7%3A%2010%20with%3A%20intGlob%29.%0A%09%5Etmp'),
  352. messageSends: ["ifNotNil:ifNil:", "ptrComp", "intComp:", "proc7:with:"],
  353. referencedClasses: []
  354. }),
  355. smalltalk.Pystone);
  356. smalltalk.addMethod(
  357. '_proc4',
  358. smalltalk.method({
  359. selector: 'proc4',
  360. category: 'as yet unclassified',
  361. fn: function (){
  362. var self=this;
  363. var boolLoc=nil;
  364. boolLoc=smalltalk.send(self['@char1Glob'], "__eq", ["A"]);
  365. boolLoc=smalltalk.send(boolLoc, "_|", [self['@boolGlob']]);
  366. self['@char2Glob']="B";
  367. return self;},
  368. source: unescape('proc4%0A%09%7C%20boolLoc%20%7C%0A%09boolLoc%20%3A%3D%20char1Glob%20%3D%20%27A%27.%0A%09boolLoc%20%3A%3D%20boolLoc%20%7C%20boolGlob.%0A%09char2Glob%20%3A%3D%20%27B%27'),
  369. messageSends: [unescape("%3D"), unescape("%7C")],
  370. referencedClasses: []
  371. }),
  372. smalltalk.Pystone);
  373. smalltalk.addMethod(
  374. '_proc5',
  375. smalltalk.method({
  376. selector: 'proc5',
  377. category: 'as yet unclassified',
  378. fn: function (){
  379. var self=this;
  380. self['@char1Glob']="A";
  381. self['@boolGlob']=false;
  382. return self;},
  383. source: unescape('proc5%0A%09char1Glob%20%3A%3D%20%27A%27.%0A%09boolGlob%20%3A%3D%20false'),
  384. messageSends: [],
  385. referencedClasses: []
  386. }),
  387. smalltalk.Pystone);
  388. smalltalk.addMethod(
  389. '_proc6_',
  390. smalltalk.method({
  391. selector: 'proc6:',
  392. category: 'as yet unclassified',
  393. fn: function (enumParIn){
  394. var self=this;
  395. var enumParOut=nil;
  396. enumParOut=enumParIn;
  397. (($receiver = smalltalk.send(self['@func3'], "_value_", [enumParIn])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return enumParOut=self['@ident4'];})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return enumParOut=self['@ident4'];})]);
  398. (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident1']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident1'];})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident2']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (($receiver = (($receiver = self['@intGlob']).klass === smalltalk.Number) ? $receiver >(100) : smalltalk.send($receiver, "__gt", [(100)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident1'];})() : (function(){return enumParOut=self['@ident4'];})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident1'];}), (function(){return enumParOut=self['@ident4'];})]);})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident3']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident2'];})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident2'];}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (($receiver = (($receiver = self['@intGlob']).klass === smalltalk.Number) ? $receiver >(100) : smalltalk.send($receiver, "__gt", [(100)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident1'];})() : (function(){return enumParOut=self['@ident4'];})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident1'];}), (function(){return enumParOut=self['@ident4'];})]);}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident3']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident2'];})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident2'];}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident1'];}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident2']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (($receiver = (($receiver = self['@intGlob']).klass === smalltalk.Number) ? $receiver >(100) : smalltalk.send($receiver, "__gt", [(100)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident1'];})() : (function(){return enumParOut=self['@ident4'];})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident1'];}), (function(){return enumParOut=self['@ident4'];})]);})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident3']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident2'];})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident2'];}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (($receiver = (($receiver = self['@intGlob']).klass === smalltalk.Number) ? $receiver >(100) : smalltalk.send($receiver, "__gt", [(100)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident1'];})() : (function(){return enumParOut=self['@ident4'];})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident1'];}), (function(){return enumParOut=self['@ident4'];})]);}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident3']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident2'];})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return enumParOut=self['@ident2'];}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident4']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return nil;})() : (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return nil;}), (function(){return (($receiver = smalltalk.send(enumParIn, "__eq", [self['@ident5']])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return enumParOut=self['@ident3'];})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return enumParOut=self['@ident3'];})]);})]);})]);})]);})]);
  399. return enumParOut;
  400. return self;},
  401. source: unescape('proc6%3A%20enumParIn%0A%09%7C%20enumParOut%20%7C%0A%09enumParOut%20%3A%3D%20enumParIn.%0A%09%28func3%20value%3A%20enumParIn%29%20ifFalse%3A%20%5B%0A%09%09enumParOut%20%3A%3D%20ident4%5D.%0A%09%28enumParIn%20%3D%20ident1%29%20ifTrue%3A%20%5B%0A%09%09enumParOut%20%3A%3D%20ident1%5D%20ifFalse%3A%20%5B%0A%09%28enumParIn%20%3D%20ident2%29%20ifTrue%3A%20%5B%0A%09%09%09intGlob%20%3E%20100%20ifTrue%3A%20%5B%0A%09%09%09%09enumParOut%20%3A%3D%20ident1%5D%0A%09%09%09ifFalse%3A%20%5B%0A%09%09%09%09enumParOut%20%3A%3D%20ident4%5D%5D%20ifFalse%3A%20%5B%0A%09%28enumParIn%20%3D%20ident3%29%20ifTrue%3A%20%5B%0A%09%09enumParOut%20%3A%3D%20ident2%5D%20ifFalse%3A%20%5B%0A%09%28enumParIn%20%3D%20ident4%29%20ifTrue%3A%20%5B%5D%20ifFalse%3A%20%5B%0A%09%28enumParIn%20%3D%20ident5%29%20ifTrue%3A%20%5B%0A%09%09enumParOut%20%3A%3D%20ident3%5D%5D%5D%5D%5D.%0A%09%5EenumParOut'),
  402. messageSends: ["ifFalse:", "value:", "ifTrue:ifFalse:", unescape("%3D"), unescape("%3E"), "ifTrue:"],
  403. referencedClasses: []
  404. }),
  405. smalltalk.Pystone);
  406. smalltalk.addMethod(
  407. '_proc7_with_',
  408. smalltalk.method({
  409. selector: 'proc7:with:',
  410. category: 'as yet unclassified',
  411. fn: function (intParI1, intParI2){
  412. var self=this;
  413. var intLoc=nil;
  414. var intParOut=nil;
  415. intLoc=(($receiver = intParI1).klass === smalltalk.Number) ? $receiver +(2) : smalltalk.send($receiver, "__plus", [(2)]);
  416. intParOut=(($receiver = intParI2).klass === smalltalk.Number) ? $receiver +intLoc : smalltalk.send($receiver, "__plus", [intLoc]);
  417. return intParOut;
  418. return self;},
  419. source: unescape('proc7%3A%20intParI1%20with%3A%20intParI2%0A%09%7C%20intLoc%20intParOut%20%7C%0A%09intLoc%20%3A%3D%20intParI1%20+%202.%0A%09intParOut%20%3A%3D%20intParI2%20+%20intLoc.%0A%09%5E%20intParOut'),
  420. messageSends: [unescape("+")],
  421. referencedClasses: []
  422. }),
  423. smalltalk.Pystone);
  424. smalltalk.addMethod(
  425. '_proc8_with_with_with_',
  426. smalltalk.method({
  427. selector: 'proc8:with:with:with:',
  428. category: 'as yet unclassified',
  429. fn: function (array1Par, array2Par, intParI1, intParI2){
  430. var self=this;
  431. var intLoc=nil;
  432. intLoc=(($receiver = intParI1).klass === smalltalk.Number) ? $receiver +(5) : smalltalk.send($receiver, "__plus", [(5)]);
  433. smalltalk.send(array1Par, "_at_put_", [intLoc, intParI2]);
  434. smalltalk.send(array1Par, "_at_put_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]), smalltalk.send(array1Par, "_at_", [intLoc])]);
  435. smalltalk.send(array1Par, "_at_put_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(30) : smalltalk.send($receiver, "__plus", [(30)]), intLoc]);
  436. smalltalk.send(intLoc, "_to_do_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]), (function(intIndex){smalltalk.send(smalltalk.send(array2Par, "_at_", [intLoc]), "_at_put_", [intIndex, intLoc]);smalltalk.send(smalltalk.send(array2Par, "_at_", [intLoc]), "_at_put_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]), (($receiver = smalltalk.send(smalltalk.send(array2Par, "_at_", [intLoc]), "_at_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])]);return smalltalk.send(smalltalk.send(array2Par, "_at_", [(($receiver = intLoc).klass === smalltalk.Number) ? $receiver +(20) : smalltalk.send($receiver, "__plus", [(20)])]), "_at_put_", [intLoc, smalltalk.send(array1Par, "_at_", [intLoc])]);})]);
  437. self['@intGlob']=(5);
  438. return self;},
  439. source: unescape('proc8%3A%20array1Par%20with%3A%20array2Par%20with%3A%20intParI1%20with%3A%20intParI2%0A%09%7C%20intLoc%20%7C%0A%09intLoc%20%3A%3D%20intParI1%20+%205.%0A%09array1Par%20at%3A%20intLoc%20put%3A%20intParI2.%0A%09array1Par%20at%3A%20intLoc%20+%201%20put%3A%20%28array1Par%20at%3A%20intLoc%29.%0A%09array1Par%20at%3A%20intLoc%20+%2030%20put%3A%20intLoc.%0A%09intLoc%20to%3A%20intLoc%20+%201%20do%3A%20%5B%3AintIndex%20%7C%0A%09%09%28array2Par%20at%3A%20intLoc%29%20at%3A%20intIndex%20put%3A%20intLoc.%0A%09%09%28array2Par%20at%3A%20intLoc%29%20at%3A%20intLoc%20-%201%20put%3A%20%28%28array2Par%20at%3A%20intLoc%29%20at%3A%20intLoc%20-%201%29%20+%201.%0A%09%09%28array2Par%20at%3A%20intLoc%20+%2020%29%20at%3A%20intLoc%20put%3A%20%28array1Par%20at%3A%20intLoc%29%5D.%0A%09intGlob%20%3A%3D%205'),
  440. messageSends: [unescape("+"), "at:put:", "at:", "to:do:", unescape("-")],
  441. referencedClasses: []
  442. }),
  443. smalltalk.Pystone);
  444. smalltalk.addMethod(
  445. '_pystones_block_',
  446. smalltalk.method({
  447. selector: 'pystones:block:',
  448. category: 'as yet unclassified',
  449. fn: function (loops, aBlock){
  450. var self=this;
  451. return smalltalk.send(self, "_proc0_block_", [loops, aBlock]);
  452. return self;},
  453. source: unescape('pystones%3A%20loops%20block%3A%20aBlock%0A%09%5Eself%20proc0%3A%20loops%20block%3A%20aBlock'),
  454. messageSends: ["proc0:block:"],
  455. referencedClasses: []
  456. }),
  457. smalltalk.Pystone);
  458. smalltalk.Pystone.klass.iVarNames = ['nulltime'];
  459. smalltalk.addMethod(
  460. '_main',
  461. smalltalk.method({
  462. selector: 'main',
  463. category: 'as yet unclassified',
  464. fn: function (){
  465. var self=this;
  466. smalltalk.send(self, "_run_", [(50000)]);
  467. return self;},
  468. source: unescape('main%0A%09%22self%20main%22%0A%09%0A%09self%20run%3A%2050000'),
  469. messageSends: ["run:"],
  470. referencedClasses: []
  471. }),
  472. smalltalk.Pystone.klass);
  473. smalltalk.addMethod(
  474. '_run_',
  475. smalltalk.method({
  476. selector: 'run:',
  477. category: 'as yet unclassified',
  478. fn: function (loops){
  479. var self=this;
  480. smalltalk.send(smalltalk.send(self, "_new", []), "_main_", [loops]);
  481. return self;},
  482. source: unescape('run%3A%20loops%0A%09%22self%20run%3A%2050000%22%0A%09%0A%09self%20new%20main%3A%20loops'),
  483. messageSends: ["main:", "new"],
  484. referencedClasses: []
  485. }),
  486. smalltalk.Pystone.klass);