Ver Fonte

Build site image; npm install;bower install;grunt devel

Thomas Rake há 11 anos atrás
pai
commit
7575f504ce
100 ficheiros alterados com 114572 adições e 0 exclusões
  1. 45 0
      bower_components/amber-ide-starter-dialog/.bower.json
  2. 22 0
      bower_components/amber-ide-starter-dialog/LICENSE-MIT
  3. 11 0
      bower_components/amber-ide-starter-dialog/README.md
  4. 5 0
      bower_components/amber-ide-starter-dialog/blockui.amd.json
  5. 36 0
      bower_components/amber-ide-starter-dialog/bower.json
  6. 33 0
      bower_components/amber-ide-starter-dialog/lib/idestarter.js
  7. 5 0
      bower_components/amber-ide-starter-dialog/local.amd.json
  8. 5 0
      bower_components/amber-ide-starter-dialog/mousetrap.amd.json
  9. 37 0
      bower_components/amber/.bower.json
  10. 313 0
      bower_components/amber/API-CHANGES.txt
  11. 399 0
      bower_components/amber/CHANGELOG
  12. 117 0
      bower_components/amber/CONTRIBUTING.md
  13. 100 0
      bower_components/amber/Gruntfile.js
  14. 22 0
      bower_components/amber/LICENSE
  15. 89 0
      bower_components/amber/README.md
  16. 27 0
      bower_components/amber/bower.json
  17. 10 0
      bower_components/amber/codemirror.amd.json
  18. 5 0
      bower_components/amber/es5-shim.amd.json
  19. BIN
      bower_components/amber/favicon.ico
  20. 10 0
      bower_components/amber/jquery-ui.amd.json
  21. 5 0
      bower_components/amber/jquery.amd.json
  22. 14 0
      bower_components/amber/local.amd.json
  23. 40 0
      bower_components/amber/package.json
  24. 10 0
      bower_components/amber/require-css.amd.json
  25. 490 0
      bower_components/amber/src/Benchfib.js
  26. 124 0
      bower_components/amber/src/Benchfib.st
  27. 3593 0
      bower_components/amber/src/Compiler-AST.js
  28. 842 0
      bower_components/amber/src/Compiler-AST.st
  29. 1552 0
      bower_components/amber/src/Compiler-Core.js
  30. 353 0
      bower_components/amber/src/Compiler-Core.st
  31. 300 0
      bower_components/amber/src/Compiler-Exceptions.js
  32. 109 0
      bower_components/amber/src/Compiler-Exceptions.st
  33. 6152 0
      bower_components/amber/src/Compiler-IR.js
  34. 1329 0
      bower_components/amber/src/Compiler-IR.st
  35. 2625 0
      bower_components/amber/src/Compiler-Inlining.js
  36. 636 0
      bower_components/amber/src/Compiler-Inlining.st
  37. 3863 0
      bower_components/amber/src/Compiler-Interpreter.js
  38. 975 0
      bower_components/amber/src/Compiler-Interpreter.st
  39. 2708 0
      bower_components/amber/src/Compiler-Semantic.js
  40. 625 0
      bower_components/amber/src/Compiler-Semantic.st
  41. 3009 0
      bower_components/amber/src/Compiler-Tests.js
  42. 781 0
      bower_components/amber/src/Compiler-Tests.st
  43. 196 0
      bower_components/amber/src/Examples.js
  44. 55 0
      bower_components/amber/src/Examples.st
  45. 5684 0
      bower_components/amber/src/IDE.js
  46. 2397 0
      bower_components/amber/src/IDE.st
  47. 1241 0
      bower_components/amber/src/Kernel-Announcements.js
  48. 439 0
      bower_components/amber/src/Kernel-Announcements.st
  49. 3556 0
      bower_components/amber/src/Kernel-Classes.js
  50. 891 0
      bower_components/amber/src/Kernel-Classes.st
  51. 10040 0
      bower_components/amber/src/Kernel-Collections.js
  52. 2337 0
      bower_components/amber/src/Kernel-Collections.st
  53. 841 0
      bower_components/amber/src/Kernel-Exceptions.js
  54. 227 0
      bower_components/amber/src/Kernel-Exceptions.st
  55. 3886 0
      bower_components/amber/src/Kernel-ImportExport.js
  56. 954 0
      bower_components/amber/src/Kernel-ImportExport.st
  57. 5408 0
      bower_components/amber/src/Kernel-Infrastructure.js
  58. 1426 0
      bower_components/amber/src/Kernel-Infrastructure.st
  59. 2996 0
      bower_components/amber/src/Kernel-Methods.js
  60. 784 0
      bower_components/amber/src/Kernel-Methods.st
  61. 6052 0
      bower_components/amber/src/Kernel-Objects.js
  62. 1394 0
      bower_components/amber/src/Kernel-Objects.st
  63. 12244 0
      bower_components/amber/src/Kernel-Tests.js
  64. 2713 0
      bower_components/amber/src/Kernel-Tests.st
  65. 115 0
      bower_components/amber/src/Kernel-Transcript.js
  66. 35 0
      bower_components/amber/src/Kernel-Transcript.st
  67. 962 0
      bower_components/amber/src/SUnit-Tests.js
  68. 186 0
      bower_components/amber/src/SUnit-Tests.st
  69. 1859 0
      bower_components/amber/src/SUnit.js
  70. 458 0
      bower_components/amber/src/SUnit.st
  71. 5765 0
      bower_components/amber/src/Web.js
  72. 1181 0
      bower_components/amber/src/Web.st
  73. 1162 0
      bower_components/amber/support/boot.js
  74. 5 0
      bower_components/amber/support/browser-compatibility.js
  75. 13 0
      bower_components/amber/support/deploy.js
  76. 3 0
      bower_components/amber/support/deprecated-vm-files/_st.js
  77. 3 0
      bower_components/amber/support/deprecated-vm-files/as-receiver.js
  78. 3 0
      bower_components/amber/support/deprecated-vm-files/boot.js
  79. 3 0
      bower_components/amber/support/deprecated-vm-files/globals.js
  80. 3 0
      bower_components/amber/support/deprecated-vm-files/nil.js
  81. 4 0
      bower_components/amber/support/deprecated-vm-files/smalltalk.js
  82. 16 0
      bower_components/amber/support/devel.js
  83. 10 0
      bower_components/amber/support/ensure-console.js
  84. 86 0
      bower_components/amber/support/helpers.js
  85. 17 0
      bower_components/amber/support/lang.js
  86. 3820 0
      bower_components/amber/support/parser.js
  87. 270 0
      bower_components/amber/support/parser.pegjs
  88. 36 0
      bower_components/amber/support/requirejs/require.min.js
  89. 546 0
      bower_components/amber/support/resources/amber.css
  90. BIN
      bower_components/amber/support/resources/off.amber.png
  91. BIN
      bower_components/amber/support/resources/offHover.amber.png
  92. BIN
      bower_components/amber/support/resources/sprite.amber.png
  93. BIN
      bower_components/amber/support/resources/tinylogo.amber.png
  94. 42 0
      bower_components/blockui/.bower.json
  95. 38 0
      bower_components/blockui/README.md
  96. 34 0
      bower_components/blockui/blockUI.jquery.json
  97. 34 0
      bower_components/blockui/bower.json
  98. 619 0
      bower_components/blockui/jquery.blockUI.js
  99. 21 0
      bower_components/bootstrap2.3.2/.bower.json
  100. 36 0
      bower_components/bootstrap2.3.2/.gitignore

+ 45 - 0
bower_components/amber-ide-starter-dialog/.bower.json

@@ -0,0 +1,45 @@
+{
+  "name": "amber-ide-starter-dialog",
+  "description": "Hidden modal dialog to open Amber IDEs",
+  "version": "0.1.0",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/index.html",
+    "/config.js",
+    "test",
+    "tests"
+  ],
+  "authors": [
+    {
+      "name": "Herbert Vojčík",
+      "email": "herby@mailbox.sk"
+    }
+  ],
+  "homepage": "https://github.com/amber-smalltalk/amber-ide-starter",
+  "keywords": [
+    "Amber",
+    "Smalltalk"
+  ],
+  "license": [
+    "MIT"
+  ],
+  "private": false,
+  "dependencies": {
+    "mousetrap": "^1.4.6",
+    "blockui": "2.65"
+  },
+  "devDependencies": {
+    "requirejs": "~2.1.15"
+  },
+  "_release": "0.1.0",
+  "_resolution": {
+    "type": "version",
+    "tag": "0.1.0",
+    "commit": "4d00a225503644c8485f50ae873f4dd209c1d377"
+  },
+  "_source": "git://github.com/amber-smalltalk/amber-ide-starter.git",
+  "_target": "^0.1.0",
+  "_originalSource": "amber-ide-starter-dialog"
+}

+ 22 - 0
bower_components/amber-ide-starter-dialog/LICENSE-MIT

@@ -0,0 +1,22 @@
+Copyright (c) 2014 Herbert Vojčík
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.

+ 11 - 0
bower_components/amber-ide-starter-dialog/README.md

@@ -0,0 +1,11 @@
+# Amber Smalltalk IDE starter menu
+
+Hidden modal dialog to open Amber IDEs
+
+Include as devDependency in your Amber project:
+
+```
+bower install amber-ide-starter-dialog --save-dev
+```
+
+and include `require(['amber-ide-starter-dialog'], function (s) { s.start(); });` in your index.html.

+ 5 - 0
bower_components/amber-ide-starter-dialog/blockui.amd.json

@@ -0,0 +1,5 @@
+{
+    "paths": {
+        "jquery.blockUI": "jquery.blockUI"
+    }
+}

+ 36 - 0
bower_components/amber-ide-starter-dialog/bower.json

@@ -0,0 +1,36 @@
+{
+  "name": "amber-ide-starter-dialog",
+  "description": "Hidden modal dialog to open Amber IDEs",
+  "version": "0.1.0",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/index.html",
+    "/config.js",
+    "test",
+    "tests"
+  ],
+  "authors": [
+    {
+      "name": "Herbert Vojčík",
+      "email": "herby@mailbox.sk"
+    }
+  ],
+  "homepage": "https://github.com/amber-smalltalk/amber-ide-starter",
+  "keywords": [
+    "Amber",
+    "Smalltalk"
+  ],
+  "license": [
+    "MIT"
+  ],
+  "private": false,
+  "dependencies": {
+    "mousetrap": "^1.4.6",
+    "blockui": "2.65"
+  },
+  "devDependencies": {
+    "requirejs": "~2.1.15"
+  }
+}

+ 33 - 0
bower_components/amber-ide-starter-dialog/lib/idestarter.js

@@ -0,0 +1,33 @@
+define(["jquery", "mousetrap", "jquery.blockUI"], function ($, mouseTrap) {
+    var exports = {
+        html: "<p><em>Esc</em> to escape; <em>Shift Shift Ctrl Shift</em> to show again</p>" +
+            "<p><button class=\"unblockUI\" onclick=\"require('amber/helpers').globals.Browser._open()\">legacy IDE</button>" +
+            "<button class=\"unblockUI\" onclick=\"require('amber/helpers').popupHelios()\">Helios IDE</button></p>",
+        keystroke: "shift shift ctrl shift",
+        start: function () {
+            $(document).ready(openMe);
+        }
+    };
+
+    function openMe() {
+        $.blockUI({message: exports.html});
+        $(".unblockUI").on("click", closeMe);
+        $(document).on("keyup", escapeBinding);
+        mouseTrap.unbind(exports.keystroke);
+    }
+
+    function closeMe() {
+        $.unblockUI();
+        $(".unblockUI").off("click", closeMe);
+        $(document).off("keyup", escapeBinding);
+        mouseTrap.bind(exports.keystroke, openMe);
+    }
+
+    function escapeBinding(event) {
+        if (event.keyCode == 27) { //esc
+            closeMe();
+        }
+    }
+
+    return exports;
+});

+ 5 - 0
bower_components/amber-ide-starter-dialog/local.amd.json

@@ -0,0 +1,5 @@
+{
+    "paths": {
+        "amber-ide-starter-dialog": "lib/idestarter"
+    }
+}

+ 5 - 0
bower_components/amber-ide-starter-dialog/mousetrap.amd.json

@@ -0,0 +1,5 @@
+{
+    "paths": {
+        "mousetrap": "mousetrap"
+    }
+}

+ 37 - 0
bower_components/amber/.bower.json

@@ -0,0 +1,37 @@
+{
+  "name": "amber",
+  "version": "0.13.3",
+  "main": "support/amber.js",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/external",
+    "/internal",
+    "/my",
+    "config.js",
+    "/test_runner.js",
+    "test",
+    "tests"
+  ],
+  "dependencies": {
+    "jquery": ">=1.7.0",
+    "jquery-ui": ">=1.9.2",
+    "es5-shim": "^4.0.3",
+    "require-css": "^0.1.2",
+    "codemirror": "^4.7.0"
+  },
+  "devDependencies": {
+    "jquery": ">=1.7.0 <2.1.0"
+  },
+  "homepage": "https://github.com/amber-smalltalk/amber",
+  "_release": "0.13.3",
+  "_resolution": {
+    "type": "version",
+    "tag": "0.13.3",
+    "commit": "863290215dc130475cc3427a909c13eaf94d03d4"
+  },
+  "_source": "git://github.com/amber-smalltalk/amber.git",
+  "_target": "^0.13.3",
+  "_originalSource": "amber"
+}

+ 313 - 0
bower_components/amber/API-CHANGES.txt

@@ -0,0 +1,313 @@
+0.14.0:
+
++ Object >>
+  + asJQuery
+  + asJQueryInContext:
++ BlockClosure >>
+  + asJQuery
+  + asJQueryInContext:
+
+
+0.13.2:
+
++ SourceArea class >>
+  + codeMirror
+
+
+0.13.1:
+
+* String >> asSelector is now String >> asJavaScriptMethodName
+* String >> asJavaScriptSelector is now String >> asJavaScriptPropertyName
+* smalltalk.selector is now smalltalk.st2js
+* smalltalk.convertSelector is now smalltalk.js2st
+* Collection >> ifEmpty:ifNotEmpty: family passes self to ifNotEmpty: block
+* Smalltalk vm is now Smalltalk core
+* boot.js's .vm is now .api
+* amber load sets' .vm is now .api
+* Internal variables smalltalk/globals/_st are now $core/$globals/$recv
+
++ smalltalk.
+  + accessJavaScript
++ Object >>
+  + postMessageTo:
+  + postMessageTo:origin:
++ Class >>
+  + heliosClass
++ SmalltalkImage >>
+  + core
++ amber/boot exports
+  + api
++ amber/{devel,deploy,lang} exports
+  + api
+
+- ProtoObject class >>
+  - heliosClass
+- Object class >>
+  - heliosClass
+
+
+0.12.6:
+
++ String >>
+  + value:
++ ProtocolAnnouncement >>
+  + package
++ Behavior >>
+  + isTestClass
++ Package >>
+  + isTestPackage
++ amber/{devel,deploy,lang} exports
+  + nil
++ amber/helpers exports
+  + nil
+
+
+0.12.4:
+
+* Package Canvas renamed to Web
+
+* Object >> try:catch: deprecated in favour of BlockClosure >> tryCatch:
+
++ Announcer >>
+  + on:do:for:
++ Node >>
+  + navigationNodeAt:ifAbsent:
++ BlockClosure >>
+  + tryCatch:
++ Environment >>
+  + evaluate:for:
++ AmberCli >>
+  + version:
++ Object >>
+  + deprecatedAPI:
+- Environment >>
+  - eval:on:
+  - evaluateString:on:
+
+
+0.12.3:
+
+* Package Import-Export renamed to Kernel-ImportExport
+* A dozen of methods moved from Object to ProtoObject
+
+* HashedCollection >> at:ifAbsentPut: pushed up to SequenceableCollection
+* HashedCollection >> , is now allowed (removed shouldNotImplement)
+* HashedCollection and Dictionary both subclasses of AssociativeCollection
+* Smalltalk class moved to SmalltalkImage class, Smalltalk is now global var
+* Smalltalk current deprecated in favour of Smalltalk
+* Smalltalk at:[put:] deprecated in favour of Smalltalk globals at:[put:]
+* <smalltalk.ClassName> deprecated in favour of <globals.ClassName>
+
++ CompiledMethod >>
+  + defaultProtocol
++ Behavior >>
+  + compile:protocol:
+  + removeProtocolIfEmpty:
++ Package >>
+  + load
+  + loadFromNamespace:
++ Package class >>
+  + load:
+  + load:fromNamespace:
++ PackageTransport >> load
++ PackageHandler >> load:
++ AmdPackageHandler >> load:
++ Set >> removeAll
++ AssociativeCollection class
++ BucketStore class
++ SmalltalkImage >>
+  + globals
+  + vm
+  + settings
++ Setting class
++ String >>
+  + asSetting
+  + asSettingIfAbsent:
+  + settingValue
+  + settingValueIfAbsent:
+  + settingValue:
++ Smalltalk global variable
+
+- CompiledMethod >>
+  - category: (use #protocol:)
+  - defaultCategory
+- Behavior >> compile:category:
+- HTMLCanvas class >>
+  - browserVersion
+  - isMSIE
+  - isMozilla
+  - isOpera
+  - isWebkit
+
+
+0.12.2:
+
+* Collection >> contains: is deprecated in favor of anySatisfy:
+
+
++ Announcer >> on:doOnce:
++ String >>
+  + uriEncoded
+  + uriDecoded
+  + uriComponentEncoded
+  + uriComponentDecoded
++ Collection >>
+  + removeAll
+  + ifEmpty:ifNotEmpty:
+  + ifNotEmpty:ifEmpty:
+  + anyOne
+  + noneSatisfy:
+  + anySatisfy:
+  + allSatisfy:
+
+
+0.12.0:
+
+* SmalltalkMethodContext.prototype.fillBlock() takes a third 'index' parameter
+* Existing classes moved to new KernelInfrastructure package
+* ImporterExporter
+  * are now StreamExporters
+  * aware of AMD namespaces
+  * support transport types and commit channels
+
+
++ Node >>
+  + nextChild
+  + method
+  + postCopy
+  + isCascadeNode
+  + isLastChild
++ BlockNode >>
+  + nextNode:
+  + nextChild
++ SendNode >>
+  + isCascadeSendNode
+  + shouldBeAliased
++ CompiledMethod >> sendTo:arguments:
++ Array >>
+  + addFirst:
+  + removeLast
++ Number >>
+  + ceiling
+  + floor
+  + asNumber
+  + //
+  + cos
+  + sin
+  + tan
+  + arcCos
+  + arcSin
+  + arcTan
+  + log
+  + log:
+  + raisedTo:
+  + sign
+  + **
+  + ln
+  + e
++ String class >> esc
++ String >>
+  + asMutator
+  + capitalized
+  + isCapitalized
++ JSProxy >> printString
++ Behavior >>
+  + ownProtocols
+  + ownMethods
++ JSStream >> nextPutSendIndexFor:
++ InterfacingObject class
++ Interpreter class
++ DocumentFragmentTag class
++ AbstractExporter class
++ PlatformInterface class
+
+
+- Node >> extent
+- JSStream >> nextPutStatement:with:
+- Smalltalk.installSuperclass()
+- ClassReferenceNode class (now handled via VariableNode)
+
+
+0.11.0:
+
+* AnnouncementSubscription use #valuable: instead of #block: (deprecated)
+* AbstractCodeGenerator inherits from Object, not NodeVisitor
+* Object>>printString
+* replace >>printString with >>printOn:
+* replace >>storeString with >>printString
+* PackageLoader is now PackageHandler (>>commit: >>setupPackagenamed:prefix: >>ajaxPutAt:data:
+* Package>>fetch: is now Package>>load:
+* Package>>fetch:prefix: is now Package>>load:prefix:
+* Queue>>front replaced by Queue>>next
+* Queue>>frontIfAbsent: replaced by Queue>>nextIfAbsent:
+* Queue>>back: replaced by Queue>>nextPut:
+* smalltalk.addMethod() does not use explicit JS selector
+* JSObjectProxy>>canForwardMessage: replaced by use of JSObjectProxy>>lookupProperty: with asJavaScriptSelector
+* JSObjectProxy>>forwardMessage: replaced by explicit JSObjectProxy>>forwardMessage:withArguments:
+* String>>asJavaScriptSelector moved to Kernel-Objects package
+
++ Object>>asString
++ Object>>putOn:
++ String>>isVowel
++ Collection>>putOn:
++ CharacterArray>>putOn:
++ Stream>><<
++ Stream>>write
++ SequenceableCollection>>newStream
++ SequenceableCollection>>readStream
++ SequenceableCollection>>stream
++ SequenceableCollection>>streamClass
++ SequenceableCollection>>writeStream
++ Collection>>isImmutable
++ Stream>>nextPutString:
++ StringStream>>nextPutString:
++ JSStream>>nextPutClassRefFunction:
++ String>>crlfSanitized
++ inlined Block now also responds to >>value:
++ Parser: split literal into runtimeLiteral and parseTimeLiteral
++ Parser: write #(4 #(5 6 #()) 7) as #(4 (5 6 ()) 7)
++ Parser: write #(#on:do: #Object) as #(on:do: Object)
++ Parser: Symbols for binarie selectores
++ Package>>commit
++ AIContext>>initializeLocals
++ ASTInterpreter>>withBlockContext:
++ smalltalk.allSelectors()
++ Object>>isCompiledMethod
++ Object>>isPackage
++ Object>>isBehavior
++ ClassMoved Announcemen class
++ Behavior>>includesBehavior:
++ Environment>>classes
++ Environment>>allSelectors
++ Environment>>removeProtocol:
++ Environment>>renameProtocol:to:in:
++ CompiledMethod>>protocol:
++ Smalltalk>>globalJsVariables
++ Smalltalk>>addGlobalJsVariable:
++ Smalltalk>>deleteGlobalJsVariable:
+
+
+- Object>>storeOn:
+- Object>>log:block:
+- Object>>printNl
+- Compiler-IR.st >>javascriptSelector
+- Compiler-IR.st >>nextPutVar:
+- Kernel-Collections.st >>asSuperSelector
+- Collection>>readStream
+- Collection>>stream
+- Collection>>streamClass
+- Collection>>writeStream
+- Symbol class (replaced with String)
+- IRInlinedNonLocalReturn class
+- IRInlinedSend>>nonLocalReturnInliner
+- IRNonLocalReturnInliner class
+- Package>>dependencies
+- Package>>dependencies:
+- Package>>properties
+- Package>>jsProperties
+- Package>>jsProperties:
+- Package>>propertiesAsJSON
+- Package>>propertyAt:
+- Package>>propertyAt:ifAbsent:
+- Package>>propertyAt:put:
+- Browser>>ajaxPutAt:data:

+ 399 - 0
bower_components/amber/CHANGELOG

@@ -0,0 +1,399 @@
+1st Jan 2015 - Release 0.14.0
+===================================
+
+Highlights:
+
+* Removed deprecated stuff and backward compatibility support code.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.13.0...0.14.0
+Issues:  https://github.com/amber-smalltalk/amber/issues?q=is%3Aissue+is%3Aclosed+milestone%3A0.14.0
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+18th Dec 2014 - Release 0.13.3
+===================================
+
+This is a planned maintenance release.
+It contains everything 0.14.0 contains,
+but it retains all the backwards compatibility stuff,
+which is going to be removed in 0.14.0.
+
+
+22th Oct 2014 - Release 0.13.2
+===================================
+
+This is maintenance release to upgrade CodeMirror
+jointly in Amber and Helios.
+
+Highlights:
+
+* CodeMirror upgrade for Amber and Helios.
+* Cleaned of all (as far as findable) uses of deprecated code.
+* Recompile using `grunt` in Windows now does not add cr characters.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.13.0...0.13.2
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+10th Oct 2014 - Release 0.13.1
+===================================
+
+Highlights:
+
+* Reworked cleaner DNU handling in core.
+* `amber init` fully embraced as the way to create new project.
+* Helios IDE is extracted and is now a project on its own.
+  * It is included as dev-dependency in any new project by default.
+* Movable data out of index.html:
+  * list of production packages in deploy.js;
+  * list of development packages in devel.js;
+  * project amd mappings in local.amd.json;
+  * libraries' amd mappings in lib_directory.amd.json.
+* 'Batteries included' deployment via `grunt deploy`.
+* 0.13.1 because of technical issues w/ 0.13.0 release process.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.6...0.13.0
+Issues:  https://github.com/amber-smalltalk/amber/issues?q=is%3Aissue+is%3Aclosed+milestone%3A0.13.0
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+1st July 2014 - Release 0.12.6
+===================================
+
+Highlights:
+
+* SUnit Runner in Helios IDE.
+* `amber` and `amberc` cli moved to `external` directory
+  and to dedicated npm package.
+* Bootstrap 3 can be used in Amber projects
+  (no more nameclash with Helios' bootstrap 2 using bootstrap2.3.2 name).
+* Wider range of jQuery versions allowed.
+* Amber now parses `$c` character literal.
+* `amber` is not to be installed globally any more.
+  Instead, `npm install -g amber-cli` installs cli tooling.
+* After installing the cli tooling, `amber init` initializes
+  new project if run in empty directory.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.4...0.12.6
+Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=13&state=closed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+11th April 2014 - Release 0.12.4
+===================================
+
+Highlights:
+
+* Fixed backward compatibility for pre-0.12.3 loader syntax.
+* `namespace/_source` is not needed to map and is recommended
+  not to use; `.st` files are by default committed to the `.js` location.
+* All sources, including js files into the src/ directory
+* Many improvements in Helios, especially in its debugger and
+  inspector, as well as UI-related improvements
+* New Helios dark theme by @BenjaminVanRyseghem
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.3...0.12.4
+Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=12&state=closed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+22nd Jan 2014 - Release 0.12.3
+===================================
+
+Highlights:
+
+* JQuery updated to ~1.10.2; jquery-ui updated to match
+* Subclasses of `nil` can be created
+* Several fixes for IE8
+* amber.js can be loaded asynchronously (it must
+  have an id 'amber-path-mapper' in that case)
+* CodeMirror updated to ~3.20.0
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.2...0.12.3
+Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=11&state=closed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+03rd December 2013 - Release 0.12.2
+===================================
+
+Highlights:
+
+* Loading Amber in nested pages now possible (via additional `data-libs` attribute of the `<script>` tag which loads `amber.js`)
+* IDE related fixes
+* Contributions Guide
+* Improved Collections
+* Amber Server responds with `not found` instead of `internal server error` if `index.html` could not be found
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.1...0.12.2
+Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=10&state=closed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+14th November 2013 - Release 0.12.1
+===================================
+
+Fixes a bug in Helios preventing class definitions from being compiled
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.12.0...0.12.1
+Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=9&state=closed
+
+
+11th November 2013 - Release 0.12.0
+===================================
+
+After 3 months of work we are pleased to announce the 0.12.0 release of Amber.
+
+Besides the usual bug fixes a lot of new features have emerged.
+
+The biggest change is the switch to RequireJS to specify Amber package dependencies
+and for loading the packages as AMD modules.
+Amber is now additionally available as Bower [2] component.
+Bower is also used to manage required JavaScript libraries which don't have to be kept
+around in the repository anymore.
+
+The repository layout was restructured to provide a cleaner separation of different Amber parts:
+* Smalltalk code is located in 'st'
+* Compiled Amber packages are located in 'js'
+* Supporting JavaScript code is located in 'support'
+
+Together with the RequireJS changes the specifying their dependencies the Brickz [3]
+reconfigurable micro composition system was introduced.
+This is used for
+
+On the Smalltalk side support has been added for writing exponential numbers of the form 2e5.
+
+Helios (the new IDE) is progressing nicely and has seen a lot of improvements.
+One of the great parts is the new stepping debugger which is also making progress.
+To try Helios, open the helios.html page or
+evaluate in any other amber page `require('amber/helpers').popupHelios()`.
+
+The last enhancements target the commandline compiler which can be used as
+`amberc` (an executable script) or as a Grunt task.
+The following features have been added:
+ * generation of shebang line (#!/usr/bin/env node)
+ * specification of target namespace (`-n` flag; `amd_namespace` option in Grunt)
+ * specification of additional library directories (`-L` flag; `library_dirs` option in Grunt)
+The following features have been removed:
+ * creation of *.deploy.js files (`-d` flag; `deploy` option in Grunt)
+ * optimization passes via Closure compiler (`-o`/`-O` flags; `closure_jar` option in Grunt)
+   The same behavior can be achieved by using specific Grunt tasks
+
+Additionally, the Grunt task now handles the -v/--verbose flag which triggers the same behavior
+as the `verbose` option which can be specified in the Gruntfile.
+
+
+Some numbers about this release (starting from 0.11.0):
+
+* 660 commits
+* 10 committers
+* 66 unit tests added
+* 152 issues were closed
+* 379 unit tests in total
+
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.11.0...0.12.0
+Issues: https://github.com/amber-smalltalk/amber/issues?direction=desc&milestone=8&page=1&sort=updated&state=closed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+* Installing Amber from NPM
+
+To install Amber from NPM, run
+
+    npm install amber
+
+* Installing Amber from Bower
+
+To install Amber from Bower, run
+
+    bower install amber
+
+* Migration from Amber 0.11.0
+
+First, the loading of JavaScript files must be adapted. The custom loader has been replaced with
+requirejs for loading files in the browser. New loader code is thouroughly
+explained in [4].
+
+After updating the loader part, `.st` files need to be recompiled
+into new AMD `.js` files. During loader changes, a namespace was choosen and will be needed for recompilation.
+
+Go to your directory with `.st` files and issue this from the shell:
+
+```sh
+<path-to-amber>/bin/amberc -l SUnit,Canvas -n <chosen-namespace> -D <path-for-compiled-js-files> *.st
+```
+
+In windows, use `\` as path separator, the rest is identical.
+
+The `-l SUnit,Canvas` is just a general guess, if your code depends on more (or less) non-kernel packages from amber, list them here accordingly.
+
+This migrate scenario only covers simple deployments with your project's code and amber.
+If your project is more complicated, using libraries and packages from multiple sources,
+it is hard to give general advices to migrate - you must do it library by library,
+giving each location its own namespace, and `-L` option of `amberc`
+comes handy when integrating; ask on the mailing list if problems arise.
+
+[1] http://requirejs.org/
+[2] http://bower.io/
+[3] https://github.com/amber-smalltalk/brikz
+[4] https://github.com/amber-smalltalk/amber/wiki/How-to-load-amber
+
+
+09th July 2013 - Release 0.11.0
+===============================
+
+Three months have passed and we are happy to announce the release
+of Amber 0.11.0!
+
+Some numbers about this release:
+
+* 494 commits
+* 13 committers
+* increasing the number of core committers to 25
+* 50 unit tests added to the kernel
+* 313 unit tests in total
+
+Since the last release 60 issues were closed, bringing us to 499
+issues closed.
+
+This release includes a lot of bug fixes, improvements to the
+CLI, as well as a preview of the next IDE, named Helios. Amber
+now also uses a CI server [1].
+
+To try the Helios, the new IDE, open the helios.html page, or
+evaluate in any other amber page `amber.loadHelios()`.
+
+The compiler also received some improvements, especially
+regarding message send optimisations and super sends.
+
+Here's the list of commits and closed issues:
+https://github.com/amber-smalltalk/amber/compare/0.10.0...0.11.0
+https://github.com/amber-smalltalk/amber/issues?direction=desc&milestone=6&page=1&sort=updated&state=closed
+
+There is a lot more to come with Helios, a stepping debugger
+based on the AST is in progress and currently in the 'debugger'
+branch on GitHub.
+
+* Installing Amber from NPM
+
+To install amber from NPM, run
+
+    npm install amber
+
+
+* Migration from Amber 0.10.0
+
+Amber compiled code should be compatible with Amber 0.10.0, but
+recompiling is needed in order to get contexts working:
+
+    Compiler new recompile: (Package named: 'MyPackage') classes.
+    (Package named: 'MyPackage') commit
+
+For API related changes see the file API-CHANGES.txt.
+
+
+13th March 2013 - Release 0.10.0
+================================
+
+Here's a summary of change since the 0.9.1 release:
+
+- Travis CI jobs
+- Almost 300 issues closed
+- 150 new unit tests written
+- All classes in the Kernel are documented
+
+- New and much improved compiler toolchain, providing:
+  - Semantic analysis
+  - AST Node annotation
+  - Intermediate representation (easier to optimize)
+  - Better inlining
+  - an AST interpreter
+  - support for blocks contexts
+
+- New build system based on grunt.js, replacing the old makefiles
+- New bin/amberc compiler written in Amber/Node.js
+- SUnit improvements and cleanup, with support for async assertions
+- Improved ClassBuilder with better class migration support
+- Improved loader for third party packages
+- New: Announcements
+- Classes can be augmented by light-weight methods created from blocks
+- Snippets of HTML can be marked to become virtual tags in HTMLCanvas
+- Amber server supports Basic HTTP authentication (not recommended for production environments/unencrypted connections)
+- New IDE on it's way for Amber 1.0
+
+
+
+16th January 2012 - Release 0.9.1
+=================================
+
+Here's a summary of changes since the 0.9 release:
+
+- 80 new unit tests written
+- 52 issues fixed
+- All classes in Kernel-Objects, Kernel-Classes and Kernel-Methods has been documented
+- New documentation framework (see http://amber-lang.net/documentation.html)
+- Better class organisations, "Kernel" package split into several packages
+- First class packages have replaced class categories
+- Internet Explorer 7+ compatibility
+- New Announcement framework ported from Pharo
+- New console-based REPL written in Amber using node.js
+- Symbol class implemented together with object identity and #==
+- New OrderedCollection and Set implementation
+- Dictionary can now have any kind of object as keys. String-key dictionary has been renamed HashedCollection
+- New TwitterWall example
+- Improved HTML Canvas, now compatible with IE7
+- Improved JSObjectProxy for seamless JavaScript objects access from Amber
+- No more jQuery binding. Amber is fully capable of sending messages to JavaScript objects
+
+13th September 2011 - Release 0.9
+=================================
+Amber has been evolving furiously since the presentation at ESUG 2011 in Edinburgh less than 3 weeks ago.
+
+This is a summary:
+
+Language, compiler and runtime
+
+- New 100x faster parser built using PEGjs instead of the old parser built using PetitParser.
+- New much faster ChunkParser implementation in handwritten Amber instead of using PetitParser.
+- Improved parsing error report with quoted source code plus marker pinpointing parsing error.
+- Removed PetitParser since it is no longer needed by Amber itself.
+- Added compiler optimizations in the form of speculative inlining of specific messages and control structures.
+- Added support for dynamic Arrays, just like in Squeak/Pharo.
+- Added support for similar dynamic Dictionaries, not seen in other Smalltalks.
+- Added & and | as allowed binary selectors and implemented them in Boolean.
+- Added a Set implementation.
+- Added first basic support for real Packages with dependency information.
+
+...and various extensions, enhancements and bug fixes to the library classes.
+
+
+Development environment
+
+- A working Debugger with integrated inspector, proceed etc.
+- A new structure with
+- A working amberc command line compiler including a Makefile for recompiling the whole Amber.
+- Enabled TestRunner in the IDE for running unit tests based on SUnit.
+- Added "File in" button in Workspace to easily paste and filein source code in chunk format in the IDE.
+
+
+Example code and ports
+
+- Ported ProfStef interactive tutorial, available on Amber homepage but also in examples directory.
+- Included the ESUG presentation as an example also in the examples directory.
+- Several new examples running on Node.js and webOS included, all with Makefiles.
+
+
+Various other things
+
+- Issue tracker on github now used as primary source, closed a bunch of reported issues.
+- Wiki pages on github with information on how to port code from other Smalltalks, lists of articles, tutorials, roadmap and more.
+

+ 117 - 0
bower_components/amber/CONTRIBUTING.md

@@ -0,0 +1,117 @@
+TL;DR: Setup your Amber clone
+====
+
+Amber repository contains more parts:
+
+1. Amber language itself (in root directory). This is released.
+1. Amber development helpers and CLI tool (in `external/` subdirectories). Not part of release.
+1. In `internal/` directory, there are development files (`index.html` and its friends).  Not part of release.
+1. A place for other modules cloned in parallel with Amber (`my`)[1]. Not part of release. Not pushed to git.
+
+To get your clone, follow this list:
+
+1. Create a fork of the repository on GitHub
+1. Clone the fork and go to its directory.
+1. Install the tools: ```npm install -g amber-cli grunt-cli bower```.
+1. Run ```npm install``` to install dependencies listed in package.json. Used by development tools. See [here](https://www.npmjs.org/doc/cli/npm-install.html) for more info.
+1. Run ```bower install``` to install dependencies listed in bower.json. Used by Amber in browser. See [here](http://bower.io/) for more info.
+1. Get your copy of Helios IDE into directory `my/helios`, depending if you have your fork or want to use stock version:
+  ```git clone git@github.com:<amber-smalltalk | your username>/helios.git my/helios```.
+1. Install Helios' dependencies: ```cd my/helios && bower install && cd ../..```.
+1. Run ```grunt devel```. Prepares some transient files.
+1. Run ```amber serve```. Starts the integrated development server.
+
+Now you should be able to start Amber devlopment page at `http://localhost:4000/internal/` and commit changes you do to disk.
+
+[1] Directory `my` is in .gitignore, so it is not present after clone,
+but because of being in .gitignore, it is "safe haven" to clone other repos into.
+Created especially for being able to have your fork of Amber in parallel with
+either you fork of Helios, to develop it in parallel, or with stock repo, just to use it.
+
+Start Contributing by talking about Amber
+=========================================
+
+* Talk to us on [the gitter.im room](https://gitter.im/amber-smalltalk/amber)
+* Join our [Mailinglist/Google Group](http://groups.google.com/group/amber-lang)
+* Follow [@AmberSmalltalk](https://twitter.com/AmberSmalltalk) on Twitter
+* Circle Amber Smalltalk on [Google+](https://plus.google.com/u/0/107038882958653788078)
+* Talk to us on [the #amber-lang IRC channel](irc://irc.freenode.net/amber-lang)
+
+
+Filing Issues
+=============
+
+If you think Amber is not working as expected, You can start by asking on gitter room, IRC or the Mailinglist.
+Please make sure that you have first checked the following guides:
+
+**TODO** update these
+* [Getting Started](https://github.com/amber-smalltalk/amber/wiki/Getting-started)
+* [Writing My First App](https://github.com/amber-smalltalk/amber/wiki/Writing-my-first-app)
+* [How To Load Amber](https://github.com/amber-smalltalk/amber/wiki/How-to-load-amber)
+* [Amber FAQ](https://github.com/amber-smalltalk/amber/wiki/FAQ)
+
+If the issue can not be resolved you should file an issue on the respective tracker.
+
+Before reporting an issue, try to reduce the issue to the bare minimum required to reproduce it.
+This allows us to track down and fix the issue in an easier and faster way.
+
+Additionally, you should give us enough information to reproduce the issue.
+Therefore, include versions of your OS, Amber, Node.js, Grunt, and possibly used libraries as well as sample code.
+If you don't list the exact steps required to reproduce the issue we won't be able to fix it.
+
+Afterwards, report the issue on one of the following trackers:
+
+* [Amber Issues](https://github.com/amber-smalltalk/amber/issues)
+* [Helios IDE Issues](https://github.com/amber-smalltalk/helios/issues)
+* [Amber Examples Issues](https://github.com/amber-smalltalk/amber-examples/issues)
+* [Amber Website Issues](https://github.com/amber-smalltalk/amber-website/issues)
+
+
+Developing Amber
+================
+
+If you want to get started developing Amber itself there are a few links to get you started
+
+* [The Roadmap](https://github.com/amber-smalltalk/amber/wiki/Roadmap) gives a rough idea about where Amber is heading towards
+* [The Contributions Page](https://github.com/amber-smalltalk/amber/wiki/Contributions) contains some ideas which we would love to integrate into Amber
+* [The Amber FAQ](https://github.com/amber-smalltalk/amber/wiki/FAQ) contains Answers to commonly arising questions
+* [The Amber CookBook](https://github.com/amber-smalltalk/amber/wiki/Amber-cookbook) contains recipies about working with Amber and its IDE
+* [The Amber Porting Guide](https://github.com/amber-smalltalk/amber/wiki/Porting-code-from-other-Smalltalk-dialects) contains information about porting code from other Smalltalk dialects
+* [The Amber JavaScript Guide](https://github.com/amber-smalltalk/amber/wiki/From-smalltalk-to-javascript-and-back) contains information about how Amber and JavaScript are mapped to each other
+
+If you want to get serious with Amber development you should read the [Coding Conventions](https://github.com/amber-smalltalk/amber/wiki/Coding-conventions)
+and check if you have all development dependencies installed (as indicated in [Getting Started](https://github.com/amber-smalltalk/amber/wiki/Getting-started)):
+
+* Git (to get a clone of the repository, use Git for Windows in Windows)
+* Node.js (to run the Amber development server)
+* NPM (to install required Node.js packages)
+* Bower (to install required client side libraries)
+* Grunt-Cli (to compile Amber on the commandline)
+
+Creating a Pull Request
+-----------------------
+
+The Amber development model currently revolves around Pull Requests which are created through GitHub
+
+1. Update to latest Amber master (```git pull```)
+2. Develop your feature or bugfix in a local branch (not in ```master```)
+3. Create unittest for your feature or bugfix (your feature/fix will be integrated a lot faster if unittests are present)
+4. Enhance/fix Amber
+5. Run the unittests
+6. Commit your changes to disk if all tests are green
+7. Try to split your fix into small Git commits if multiple changes are involved (this makes it easier for us to review the changes)
+8. If you created / deleted / moved API, update API-CHANGES.txt appropriately and commit.
+8. Push the changes to your fork on GitHub ```git push <your repo> <your branchname>```
+9. Submit Pull Request (usually for the Amber master branch)
+
+
+Compiling Amber with Grunt
+--------------------------
+
+Amber uses [Grunt.js](http://gruntjs.com/) as build system since version `0.10.0` (in case of Windows issues check the [Grunt.js on Windows](http://gruntjs.com/frequently-asked-questions#does-grunt-work-on-windows)).
+
+If you created your clone according to the "Setting up your Amber clone", you should run
+
+    grunt
+
+in Amber directory to start building from CLI.

+ 100 - 0
bower_components/amber/Gruntfile.js

@@ -0,0 +1,100 @@
+var path = require('path');
+
+module.exports = function(grunt) {
+
+  grunt.loadTasks('./internal/grunt-tasks');
+  grunt.loadNpmTasks('amber-dev');
+
+  grunt.loadNpmTasks('grunt-contrib-jshint');
+  grunt.loadNpmTasks('grunt-contrib-clean');
+  grunt.loadNpmTasks('grunt-execute');
+
+  grunt.registerTask('default', ['peg', 'amberc:all']);
+  grunt.registerTask('amberc:all', ['amberc:amber', 'amberc:cli']);
+  grunt.registerTask('test', ['amberc:test_runner', 'execute:test_runner', 'clean:test_runner']);
+  grunt.registerTask('devel', ['amdconfig:amber']);
+
+  grunt.initConfig({
+    pkg: grunt.file.readJSON('package.json'),
+
+    meta: {
+      banner: '/*!\n <%= pkg.title || pkg.name %> - v<%= pkg.version %> - <%= grunt.template.today("yyyy-mm-dd") %> \n License: <%= pkg.license.type %> \n*/\n'
+    },
+
+    peg: {
+      parser: {
+        options: {
+          cache: true,
+          export_var: '$globals.SmalltalkParser'
+        },
+        src: 'support/parser.pegjs',
+        dest: 'support/parser.js'
+      }
+    },
+
+    amdconfig: {amber: {dest: 'config.js'}},
+
+    amberc: {
+      options: {
+        amber_dir: process.cwd(),
+        closure_jar: ''
+      },
+      amber: {
+        output_dir : 'src',
+        src: ['src/Kernel-Objects.st', 'src/Kernel-Classes.st', 'src/Kernel-Methods.st', 'src/Kernel-Collections.st',
+              'src/Kernel-Infrastructure.st', 'src/Kernel-Exceptions.st', 'src/Kernel-Transcript.st', 'src/Kernel-Announcements.st',
+              'src/Kernel-ImportExport.st', 'src/Compiler-Exceptions.st', 'src/Compiler-Core.st', 'src/Compiler-AST.st',
+              'src/Compiler-IR.st', 'src/Compiler-Inlining.st', 'src/Compiler-Semantic.st', 'src/Compiler-Interpreter.st',
+              'src/Web.st', 'src/SUnit.st', 'src/IDE.st',
+              'src/Kernel-Tests.st', 'src/Compiler-Tests.st', 'src/SUnit-Tests.st',
+              'src/Benchfib.st', 'src/Examples.st'
+              ],
+        jsGlobals: ['navigator']
+      },
+      cli: {
+        output_dir: 'external/amber-cli/src',
+        src: ['external/amber-cli/src/AmberCli.st'],
+        libraries: [
+          'Compiler-Exceptions', 'Compiler-Core', 'Compiler-AST',
+          'Compiler-IR', 'Compiler-Inlining', 'Compiler-Semantic', 'Compiler-Interpreter', 'parser',
+          'SUnit', 'Kernel-ImportExport',
+          'Kernel-Tests', 'Compiler-Tests', 'SUnit-Tests'
+        ],
+        main_class: 'AmberCli',
+        output_name: '../support/amber-cli',
+        amd_namespace: 'amber_cli'
+      },
+      dev: {
+        output_dir: 'external/amber-dev/lib',
+        src: ['external/amber-dev/lib/Test.st']
+      },
+      test_runner: {
+        src: ['node_modules/amber-dev/lib/Test.st'],
+        libraries: [
+        'Compiler-Exceptions', 'Compiler-Core', 'Compiler-AST',
+        'Compiler-IR', 'Compiler-Inlining', 'Compiler-Semantic', 'Compiler-Interpreter', 'parser',
+        'SUnit', 'Kernel-ImportExport',
+        'Kernel-Tests', 'Compiler-Tests', 'SUnit-Tests'],
+        main_class: 'NodeTestRunner',
+        output_name: 'test_runner'
+      }
+    },
+
+    execute: {
+      test_runner: {
+        src: ['test_runner.js']
+      }
+    },
+
+    clean: {
+      test_runner: ['test_runner.js']
+    },
+
+    jshint: {
+      amber: ['src/*.js', 'support/[^p]*.js'],
+      cli: ['external/amber-cli/src/*.js', 'external/amber-cli/support/*.js'],
+      dev: ['external/amber-dev/lib/*.js'],
+      grunt: ['Gruntfile.js', 'internal/grunt-tasks/*.js', 'external/amber-dev/tasks/*.js']
+    }
+  });
+};

+ 22 - 0
bower_components/amber/LICENSE

@@ -0,0 +1,22 @@
+Copyright (C) 2011-2014 Nicolas Petton <petton.nicolas@gmail.com>
+Copyright (C) 2011-2014 Amber contributors https://github.com/NicolasPetton/amber/contributors
+
+Parts of Amber take ideas from Clamato (http://clamato.net), written by Avi Bryant.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.

+ 89 - 0
bower_components/amber/README.md

@@ -0,0 +1,89 @@
+Amber [![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/amber-smalltalk/amber?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Travis CI Status](https://secure.travis-ci.org/amber-smalltalk/amber.png)](https://travis-ci.org/#!/amber-smalltalk/amber) [![devDependency status](https://david-dm.org/amber-smalltalk/amber/dev-status.svg?style=flat)](https://david-dm.org/amber-smalltalk/amber#info=devDependencies)
+=====
+
+
+By Nicolas Petton <petton.nicolas@gmail.com> and [Amber contributors](https://github.com/amber-smalltalk/amber/contributors)
+
+Amber is an implementation of the Smalltalk language that runs on top of the JavaScript runtime. It is designed to make client-side development faster and easier.
+
+> \o/ **Call for contributors!**  \o/
+>
+> The core project of Amber has enough resources, but:
+> - the Helios IDE (https://github.com/amber-smalltalk/helios), as well as
+> - examples (https://github.com/amber-smalltalk/amber-examples), and
+> - documentation (https://github.com/amber-smalltalk/amber-documentation)
+>
+> would need some of your care.
+>
+> Thank you very much!
+>
+> (see [CONTRIBUTING.md](CONTRIBUTING.md) for further details)
+
+
+Overview
+--------
+
+Amber is written in itself, including the parser and compiler. Amber compiles into efficient JavaScript, mapping one-to-one with the equivalent JavaScript. There is no interpretation at runtime.
+
+Some highlights:
+
+-    Amber features an IDE with a Class browser, Workspace, Transcript, a ReferencesBrowser supporting senders/implementors and class references, basic Inspector and even a beginning of a Debugger and a unit TestRunner.
+-    [Pharo Smalltalk](http://www.pharo-project.org) is considered as the reference implementation.
+-    Amber includes a canvas to generate HTML, like [Seaside](http://www.seaside.st)
+-    Amber can use Javascript libraries and the current IDE is built on [jQuery](http://www.jquery.com)
+-    You can inline Javascript code and there are many ways to interact between Amber and Javascript
+
+
+Getting Amber
+-------------
+
+Amber is shipped as a cli tool to create new projects and assist with development tasks in a [npm](http://npmjs.org) package  `amber-cli`
+and as a library to be used by projects in a [bower](https://github.com/bower/bower) package `amber`.
+
+Do this [1] to create an Amber project of your own and start working in it:
+
+    # Install the CLI tool `amber-cli`
+    npm install -g amber-cli
+    
+    # Initialize your project (directory must be empty)
+    cd /path/to/myproject
+    amber init
+
+    # Serve amber on localhost:4000
+    amber serve
+
+The [Getting started](https://github.com/amber-smalltalk/amber/wiki/Getting-started) page shows more details on ways to obtain Amber and start a project.
+
+[1] For installation to work, you need to install `node`, `npm` and `git` (in Windows, use Git for Windows and select "Run Git from Windows Command Prompt" and "Checkout Windows-style, commit Unix-style" installation options).
+
+
+Reporting issues
+--------------
+
+  - Report issues with the www.amber-lang.net website here: https://github.com/amber-smalltalk/amber-website/issues.
+  - Report issues with the docs.amber-lang.net website here: https://github.com/amber-smalltalk/documentation/issues.
+  - Report issues with Amber itself or `amber` / `amberc` cli tools here: https://github.com/amber-smalltalk/amber/issues.
+Issues related to questions during `amber init` and structure of project created should be reported
+to https://github.com/amber-smalltalk/grunt-init-amber/issues instead.
+  - Report issues with the Helios IDE here: https://github.com/amber-smalltalk/helios/issues.
+
+Please refer to [CONTRIBUTING.md](CONTRIBUTING.md) for further details.
+
+
+Developing Amber
+--------------
+
+Please refer to [CONTRIBUTING.md](CONTRIBUTING.md) for further details.
+It explains the Amber development setup and how to contribute.
+
+
+License
+-------
+
+Amber is released under the MIT license. All contributions made for inclusion are considered to be under MIT.
+
+
+More infos
+----------
+
+More on the [project page](http://amber-lang.net)

+ 27 - 0
bower_components/amber/bower.json

@@ -0,0 +1,27 @@
+{
+  "name": "amber",
+  "version": "0.13.3",
+  "main": "support/amber.js",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/external",
+    "/internal",
+    "/my",
+    "config.js",
+    "/test_runner.js",
+    "test",
+    "tests"
+  ],
+  "dependencies": {
+    "jquery": ">=1.7.0",
+    "jquery-ui": ">=1.9.2",
+    "es5-shim": "^4.0.3",
+    "require-css": "^0.1.2",
+    "codemirror": "^4.7.0"
+  },
+  "devDependencies": {
+    "jquery": ">=1.7.0 <2.1.0"
+  }
+}

+ 10 - 0
bower_components/amber/codemirror.amd.json

@@ -0,0 +1,10 @@
+{
+    "paths": {
+        "codemirror": "."
+    },
+    "shim": {
+        "codemirror/lib/codemirror": {
+            "deps": [ "css!codemirror/lib/codemirror" ]
+        }
+    }
+}

+ 5 - 0
bower_components/amber/es5-shim.amd.json

@@ -0,0 +1,5 @@
+{
+    "paths": {
+        "amber_lib/es5-shim": "."
+    }
+}

BIN
bower_components/amber/favicon.ico


+ 10 - 0
bower_components/amber/jquery-ui.amd.json

@@ -0,0 +1,10 @@
+{
+    "paths": {
+        "jquery-ui": ["jquery-ui", "ui/jquery-ui"]
+    },
+    "shim": {
+        "jquery-ui": {
+            "deps": [ "jquery" ]
+        }
+    }
+}

+ 5 - 0
bower_components/amber/jquery.amd.json

@@ -0,0 +1,5 @@
+{
+    "paths": {
+        "jquery": ["dist/jquery", "jquery"]
+    }
+}

+ 14 - 0
bower_components/amber/local.amd.json

@@ -0,0 +1,14 @@
+{
+    "paths": {
+        "amber": "support",
+        "amber_vm": "support/deprecated-vm-files",
+        "amber_vm/_st": "support/deprecated-vm-files/as-receiver",
+        "amber_css": "support/resources",
+        "amber_core": "src"
+    },
+    "shim": {
+        "ensure-console": {
+            "exports": "console"
+        }
+    }
+}

+ 40 - 0
bower_components/amber/package.json

@@ -0,0 +1,40 @@
+{
+  "name": "amber",
+  "version": "0.13.3",
+  "description": "An implementation of the Smalltalk language that runs on top of the JS runtime.",
+  "homepage": "http://amber-lang.net",
+  "keywords": [
+    "javascript",
+    "smalltalk",
+    "language",
+    "compiler",
+    "web"
+  ],
+  "author": {
+    "name": "Nicolas Petton",
+    "email": "petton.nicolas@gmail.com",
+    "url": "http://www.nicolas-petton.fr"
+  },
+  "license": {
+    "type": "MIT"
+  },
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/amber-smalltalk/amber.git#0.13.3"
+  },
+  "engines": {
+    "node": ">=0.8.0"
+  },
+  "scripts": {
+    "test": "grunt test && cd external && cd amber-cli && npm test && cd .. && cd .."
+  },
+  "devDependencies": {
+    "amber-dev": "^0.2.2",
+    "grunt": "^0.4.0",
+    "grunt-contrib-clean": "^0.6.0",
+    "grunt-contrib-jshint": "^0.10.0",
+    "grunt-execute": "^0.2.1",
+    "pegjs": "^0.8.0",
+    "requirejs": "^2.1.15"
+  }
+}

+ 10 - 0
bower_components/amber/require-css.amd.json

@@ -0,0 +1,10 @@
+{
+    "paths": {
+        "require-css": "."
+    },
+    "map": {
+        "*": {
+            "css": "require-css/css"
+        }
+    }
+}

+ 490 - 0
bower_components/amber/src/Benchfib.js

@@ -0,0 +1,490 @@
+define("amber_core/Benchfib", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Benchfib');
+$core.packages["Benchfib"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Benchfib', $globals.Object, [], 'Benchfib');
+
+$core.addMethod(
+$core.method({
+selector: "main",
+protocol: 'not yet classified',
+fn: function (){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+result=(0)._tinyBenchmarks();
+$recv(console)._log_("0 tinyBenchmarks => ".__comma(result));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"main",{result:result},$globals.Benchfib.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "main\x0a\x0a\x09| result |\x0a\x09result := 0 tinyBenchmarks.\x0a\x09console log: '0 tinyBenchmarks => ' , result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tinyBenchmarks", "log:", ","]
+}),
+$globals.Benchfib.klass);
+
+$core.addMethod(
+$core.method({
+selector: "benchFib",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$5,$4,$3,$1;
+$2=self.__lt((2));
+if($core.assert($2)){
+$1=(1);
+} else {
+$5=self.__minus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["-"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._benchFib();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["benchFib"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__plus($recv(self.__minus((2)))._benchFib());
+$1=$recv($3).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"benchFib",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "benchFib\x0a\x09\x22Handy send-heavy benchmark\x22\x0a\x09\x22(result // seconds to run) = approx calls per second\x22\x0a\x09\x22\x09| r t |\x0a\x09\x09t := Time millisecondsToRun: [r := 26 benchFib].\x0a\x09\x09(r * 1000) // t\x22\x0a\x09\x22138000 on a Mac 8100/100\x22\x0a\x09^ self < 2\x0a\x09\x09ifTrue: [1]\x0a\x09\x09ifFalse: [(self-1) benchFib + (self-2) benchFib + 1]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "<", "+", "benchFib", "-"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "benchmark",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+var size,flags,prime,k,count;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+size=(8190);
+(1)._to_do_(self,(function(iter){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+count=(0);
+count;
+flags=$recv($Array())._new();
+flags;
+$recv(size)._timesRepeat_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(flags)._add_(true);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+return (1)._to_do_(size,(function(i){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$1=$recv(flags)._at_(i);
+if($core.assert($1)){
+prime=$recv(i).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+prime;
+k=$recv(i).__plus(prime);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["+"]=2;
+//>>excludeEnd("ctx");
+k;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv(k).__lt_eq(size);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$recv(flags)._at_put_(k,false);
+k=$recv(k).__plus(prime);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["+"]=3;
+//>>excludeEnd("ctx");
+return k;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,6)});
+//>>excludeEnd("ctx");
+}));
+count=$recv(count).__plus((1));
+return count;
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({i:i},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({iter:iter},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["to:do:"]=1;
+//>>excludeEnd("ctx");
+$2=count;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"benchmark",{size:size,flags:flags,prime:prime,k:k,count:count},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "benchmark\x0a\x09\x22Handy bytecode-heavy benchmark\x22\x0a\x09\x22(500000 // time to run) = approx bytecodes per second\x22\x0a\x09\x225000000 // (Time millisecondsToRun: [10 benchmark]) * 1000\x22\x0a\x09\x223059000 on a Mac 8100/100\x22\x0a\x09| size flags prime k count |\x0a\x09size := 8190.\x0a\x091 to: self do:\x0a\x09\x09[:iter |\x0a\x09\x09count := 0.\x0a\x09\x09flags := Array new.\x0a\x09\x09size timesRepeat: [ flags add: true].\x0a\x09\x091 to: size do:\x0a\x09\x09\x09[:i | (flags at: i) ifTrue:\x0a\x09\x09\x09\x09[prime := i+1.\x0a\x09\x09\x09\x09k := i + prime.\x0a\x09\x09\x09\x09[k <= size] whileTrue:\x0a\x09\x09\x09\x09\x09[flags at: k put: false.\x0a\x09\x09\x09\x09\x09k := k + prime].\x0a\x09\x09\x09\x09count := count + 1]]].\x0a\x09^ count",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["to:do:", "new", "timesRepeat:", "add:", "ifTrue:", "at:", "+", "whileTrue:", "<=", "at:put:"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "jsbenchFib",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+if (this < 2) {
+return 1;
+} else {
+return (this-1)._jsbenchFib() + (this-2)._jsbenchFib() + 1;};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jsbenchFib",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "jsbenchFib\x0a\x0a\x09<if (this < 2) {\x0areturn 1;\x0a} else {\x0areturn (this-1)._jsbenchFib() + (this-2)._jsbenchFib() + 1;}>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "jsbenchmark",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+var size = 8190;
+var count;
+for (var z=0;z<this;z++) {
+	count = 0;
+	var flags = new Array();
+	for (var p=0; p<size; p++) {
+	flags[p] = true;
+	}
+	for (var i=1;i<=size;i++) {
+		if (flags[i-1]) {
+			var prime = i+1;
+			var k = i + prime;
+			while (k <= size) {
+				flags[k-1] = false;
+				k = k + prime;
+			}
+			count = count + 1;
+		}
+	}
+}
+return count;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jsbenchmark",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "jsbenchmark\x0a\x0a<\x0avar size = 8190;\x0avar count;\x0afor (var z=0;z<this;z++) {\x0a\x09count = 0;\x0a\x09var flags = new Array();\x0a\x09for (var p=0; p<size; p++) {\x0a\x09flags[p] = true;\x0a\x09}\x0a\x09for (var i=1;i<=size;i++) {\x0a\x09\x09if (flags[i-1]) {\x0a\x09\x09\x09var prime = i+1;\x0a\x09\x09\x09var k = i + prime;\x0a\x09\x09\x09while (k <= size) {\x0a\x09\x09\x09\x09flags[k-1] = false;\x0a\x09\x09\x09\x09k = k + prime;\x0a\x09\x09\x09}\x0a\x09\x09\x09count = count + 1;\x0a\x09\x09}\x0a\x09}\x0a}\x0areturn count>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "jstinyBenchmarks",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+var t1,t2,r,n1,n2;
+function $Date(){return $globals.Date||(typeof Date=="undefined"?nil:Date)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $7,$6,$5,$4,$3,$2,$1;
+n1=(1);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+t1=$recv($Date())._millisecondsToRun_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(n1)._jsbenchmark();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["millisecondsToRun:"]=1;
+//>>excludeEnd("ctx");
+t1;
+return $recv(t1).__lt((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["<"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+n1=$recv(n1).__star((2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["*"]=1;
+//>>excludeEnd("ctx");
+return n1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["whileTrue:"]=1;
+//>>excludeEnd("ctx");
+n2=(28);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+t2=$recv($Date())._millisecondsToRun_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+r=$recv(n2)._jsbenchFib();
+return r;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
+//>>excludeEnd("ctx");
+}));
+t2;
+return $recv(t2).__lt((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+n2=$recv(n2).__plus((1));
+return n2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
+//>>excludeEnd("ctx");
+}));
+$7=$recv(n1).__star((500000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=3;
+//>>excludeEnd("ctx");
+$6=$recv($7).__star((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6).__slash(t1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["/"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._printString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printString"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(" bytecodes/sec; ");
+$2=$recv($3).__comma($recv($recv($recv(r).__star((1000))).__slash(t2))._printString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma(" sends/sec");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jstinyBenchmarks",{t1:t1,t2:t2,r:r,n1:n1,n2:n2},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "jstinyBenchmarks\x0a\x09\x220 jstinyBenchmarks\x22\x0a\x0a\x09| t1 t2 r n1 n2 |\x0a\x09n1 := 1.\x0a\x09[t1 := Date millisecondsToRun: [n1 jsbenchmark].\x0a\x09t1 < 1000] whileTrue:[n1 := n1 * 2]. \x22Note: #benchmark's runtime is about O(n)\x22\x0a\x0a\x09n2 := 28.\x0a\x09[t2 := Date millisecondsToRun: [r := n2 jsbenchFib].\x0a\x09t2 < 1000] whileTrue:[n2 := n2 + 1].\x0a\x09\x22Note: #jsbenchFib's runtime is about O(k^n),\x0a\x09\x09where k is the golden number = (1 + 5 sqrt) / 2 = 1.618....\x22\x0a\x0a\x09^ ((n1 * 500000 * 1000) / t1) printString, ' bytecodes/sec; ',\x0a\x09\x09((r * 1000) / t2) printString, ' sends/sec'",
+referencedClasses: ["Date"],
+//>>excludeEnd("ide");
+messageSends: ["whileTrue:", "millisecondsToRun:", "jsbenchmark", "<", "*", "jsbenchFib", "+", ",", "printString", "/"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "tinyBenchmarks",
+protocol: '*Benchfib',
+fn: function (){
+var self=this;
+var t1,t2,r,n1,n2;
+function $Date(){return $globals.Date||(typeof Date=="undefined"?nil:Date)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $7,$6,$5,$4,$3,$2,$1;
+n1=(1);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+t1=$recv($Date())._millisecondsToRun_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(n1)._benchmark();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["millisecondsToRun:"]=1;
+//>>excludeEnd("ctx");
+t1;
+return $recv(t1).__lt((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["<"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+n1=$recv(n1).__star((2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["*"]=1;
+//>>excludeEnd("ctx");
+return n1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["whileTrue:"]=1;
+//>>excludeEnd("ctx");
+n2=(16);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+t2=$recv($Date())._millisecondsToRun_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+r=$recv(n2)._benchFib();
+return r;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
+//>>excludeEnd("ctx");
+}));
+t2;
+return $recv(t2).__lt((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+n2=$recv(n2).__plus((1));
+return n2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
+//>>excludeEnd("ctx");
+}));
+$7=$recv(n1).__star((500000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=3;
+//>>excludeEnd("ctx");
+$6=$recv($7).__star((1000));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6).__slash(t1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["/"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._printString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printString"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(" bytecodes/sec; ");
+$2=$recv($3).__comma($recv($recv($recv(r).__star((1000))).__slash(t2))._printString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma(" sends/sec");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tinyBenchmarks",{t1:t1,t2:t2,r:r,n1:n1,n2:n2},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tinyBenchmarks\x0a\x09\x22Report the results of running the two tiny Squeak benchmarks.\x0a\x09ar 9/10/1999: Adjusted to run at least 1 sec to get more stable results\x22\x0a\x09\x220 tinyBenchmarks\x22\x0a\x09\x22On a 292 MHz G3 Mac: 22727272 bytecodes/sec; 984169 sends/sec\x22\x0a\x09\x22On a 400 MHz PII/Win98: 18028169 bytecodes/sec; 1081272 sends/sec\x22\x0a\x09| t1 t2 r n1 n2 |\x0a\x09n1 := 1.\x0a\x09[t1 := Date millisecondsToRun: [n1 benchmark].\x0a\x09t1 < 1000] whileTrue:[n1 := n1 * 2]. \x22Note: #benchmark's runtime is about O(n)\x22\x0a\x0a\x09n2 := 16.\x0a\x09[t2 := Date millisecondsToRun: [r := n2 benchFib].\x0a\x09t2 < 1000] whileTrue:[n2 := n2 + 1].\x0a\x09\x22Note: #benchFib's runtime is about O(k^n),\x0a\x09\x09where k is the golden number = (1 + 5 sqrt) / 2 = 1.618....\x22\x0a\x0a\x09^ ((n1 * 500000 * 1000) / t1) printString, ' bytecodes/sec; ',\x0a\x09\x09((r * 1000) / t2) printString, ' sends/sec'",
+referencedClasses: ["Date"],
+//>>excludeEnd("ide");
+messageSends: ["whileTrue:", "millisecondsToRun:", "benchmark", "<", "*", "benchFib", "+", ",", "printString", "/"]
+}),
+$globals.Number);
+
+});

+ 124 - 0
bower_components/amber/src/Benchfib.st

@@ -0,0 +1,124 @@
+Smalltalk createPackage: 'Benchfib'!
+Object subclass: #Benchfib
+	instanceVariableNames: ''
+	package: 'Benchfib'!
+
+!Benchfib class methodsFor: 'not yet classified'!
+
+main
+
+	| result |
+	result := 0 tinyBenchmarks.
+	console log: '0 tinyBenchmarks => ' , result
+! !
+
+!Number methodsFor: '*Benchfib'!
+
+benchFib
+	"Handy send-heavy benchmark"
+	"(result // seconds to run) = approx calls per second"
+	"	| r t |
+		t := Time millisecondsToRun: [r := 26 benchFib].
+		(r * 1000) // t"
+	"138000 on a Mac 8100/100"
+	^ self < 2
+		ifTrue: [1]
+		ifFalse: [(self-1) benchFib + (self-2) benchFib + 1]
+!
+
+benchmark
+	"Handy bytecode-heavy benchmark"
+	"(500000 // time to run) = approx bytecodes per second"
+	"5000000 // (Time millisecondsToRun: [10 benchmark]) * 1000"
+	"3059000 on a Mac 8100/100"
+	| size flags prime k count |
+	size := 8190.
+	1 to: self do:
+		[:iter |
+		count := 0.
+		flags := Array new.
+		size timesRepeat: [ flags add: true].
+		1 to: size do:
+			[:i | (flags at: i) ifTrue:
+				[prime := i+1.
+				k := i + prime.
+				[k <= size] whileTrue:
+					[flags at: k put: false.
+					k := k + prime].
+				count := count + 1]]].
+	^ count
+!
+
+jsbenchFib
+
+	<if (this < 2) {
+return 1;
+} else {
+return (this-1)._jsbenchFib() + (this-2)._jsbenchFib() + 1;}>
+!
+
+jsbenchmark
+
+<
+var size = 8190;
+var count;
+for (var z=0;z<this;z++) {
+	count = 0;
+	var flags = new Array();
+	for (var p=0; p<size; p++) {
+	flags[p] = true;
+	}
+	for (var i=1;i<=size;i++) {
+		if (flags[i-1]) {
+			var prime = i+1;
+			var k = i + prime;
+			while (k <= size) {
+				flags[k-1] = false;
+				k = k + prime;
+			}
+			count = count + 1;
+		}
+	}
+}
+return count>
+!
+
+jstinyBenchmarks
+	"0 jstinyBenchmarks"
+
+	| t1 t2 r n1 n2 |
+	n1 := 1.
+	[t1 := Date millisecondsToRun: [n1 jsbenchmark].
+	t1 < 1000] whileTrue:[n1 := n1 * 2]. "Note: #benchmark's runtime is about O(n)"
+
+	n2 := 28.
+	[t2 := Date millisecondsToRun: [r := n2 jsbenchFib].
+	t2 < 1000] whileTrue:[n2 := n2 + 1].
+	"Note: #jsbenchFib's runtime is about O(k^n),
+		where k is the golden number = (1 + 5 sqrt) / 2 = 1.618...."
+
+	^ ((n1 * 500000 * 1000) / t1) printString, ' bytecodes/sec; ',
+		((r * 1000) / t2) printString, ' sends/sec'
+!
+
+tinyBenchmarks
+	"Report the results of running the two tiny Squeak benchmarks.
+	ar 9/10/1999: Adjusted to run at least 1 sec to get more stable results"
+	"0 tinyBenchmarks"
+	"On a 292 MHz G3 Mac: 22727272 bytecodes/sec; 984169 sends/sec"
+	"On a 400 MHz PII/Win98: 18028169 bytecodes/sec; 1081272 sends/sec"
+	| t1 t2 r n1 n2 |
+	n1 := 1.
+	[t1 := Date millisecondsToRun: [n1 benchmark].
+	t1 < 1000] whileTrue:[n1 := n1 * 2]. "Note: #benchmark's runtime is about O(n)"
+
+	n2 := 16.
+	[t2 := Date millisecondsToRun: [r := n2 benchFib].
+	t2 < 1000] whileTrue:[n2 := n2 + 1].
+	"Note: #benchFib's runtime is about O(k^n),
+		where k is the golden number = (1 + 5 sqrt) / 2 = 1.618...."
+
+	^ ((n1 * 500000 * 1000) / t1) printString, ' bytecodes/sec; ',
+		((r * 1000) / t2) printString, ' sends/sec'
+! !
+

+ 3593 - 0
bower_components/amber/src/Compiler-AST.js

@@ -0,0 +1,3593 @@
+define("amber_core/Compiler-AST", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Methods"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-AST');
+$core.packages["Compiler-AST"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Node', $globals.Object, ['parent', 'position', 'source', 'nodes', 'shouldBeInlined', 'shouldBeAliased'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Node.comment="I am the abstract root class of the abstract syntax tree.\x0a\x0aConcrete classes should implement `#accept:` to allow visiting.\x0a\x0a`position` holds a point containing line and column number of the symbol location in the original source file.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "addNode:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._nodes())._add_(aNode);
+$recv(aNode)._parent_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addNode:",{aNode:aNode},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "addNode: aNode\x0a\x09self nodes add: aNode.\x0a\x09aNode parent: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "nodes", "parent:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "allNodes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var allNodes;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+allNodes=$recv($1)._asSet();
+$recv(self._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(allNodes)._addAll_($recv(each)._allNodes());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=allNodes;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allNodes",{allNodes:allNodes},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allNodes\x0a\x09| allNodes |\x0a\x09\x0a\x09allNodes := self nodes asSet.\x0a\x09self nodes do: [ :each | \x0a\x09\x09allNodes addAll: each allNodes ].\x0a\x09\x0a\x09^ allNodes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asSet", "nodes", "do:", "addAll:", "allNodes"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "inPosition:",
+protocol: 'testing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._positionStart()).__lt_eq(aPoint))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._positionEnd()).__gt_eq(aPoint);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inPosition:",{aPoint:aPoint},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "inPosition: aPoint\x0a\x09^ (self positionStart <= aPoint and: [\x0a\x09\x09self positionEnd >= aPoint ])",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "<=", "positionStart", ">=", "positionEnd"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isAssignmentNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isAssignmentNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockSequenceNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockSequenceNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isCascadeNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCascadeNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isJSStatementNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isJSStatementNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isLastChild",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv(self._parent())._nodes())._last()).__eq(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isLastChild",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isLastChild\x0a\x09^ self parent nodes last = self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "last", "nodes", "parent"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isNavigationNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNavigationNode\x0a\x09\x22Answer true if the node can be navigated to\x22\x0a\x09\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isReferenced",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$4=self._parent();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["parent"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._isSequenceNode();
+$2=$recv($3)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._parent())._isAssignmentNode();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=$recv($2)._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isReferenced",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isReferenced\x0a\x09\x22Answer true if the receiver is referenced by other nodes.\x0a\x09Do not take sequences or assignments into account\x22\x0a\x09\x0a\x09^ (self parent isSequenceNode or: [\x0a\x09\x09self parent isAssignmentNode ]) not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "or:", "isSequenceNode", "parent", "isAssignmentNode"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isReturnNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isReturnNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isSendNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSendNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isSequenceNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSequenceNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isValueNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isValueNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isVariableNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isVariableNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._parent();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+var node;
+node=$receiver;
+$1=$recv(node)._method();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"method",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ self parent ifNotNil: [ :node | node method ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "parent", "method"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "navigationNodeAt:ifAbsent:",
+protocol: 'accessing',
+fn: function (aPoint,aBlock){
+var self=this;
+var children;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$4,$3,$2;
+var $early={};
+try {
+children=$recv(self._allNodes())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._isNavigationNode())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(each)._inPosition_(aPoint);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(children)._ifEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value();
+throw $early=[$1];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv($recv($recv(children)._asArray())._sort_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(a)._positionStart();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["positionStart"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._dist_(aPoint);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["dist:"]=1;
+//>>excludeEnd("ctx");
+return $recv($3).__lt_eq($recv($recv(b)._positionStart())._dist_(aPoint));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,4)});
+//>>excludeEnd("ctx");
+})))._first();
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"navigationNodeAt:ifAbsent:",{aPoint:aPoint,aBlock:aBlock,children:children},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint", "aBlock"],
+source: "navigationNodeAt: aPoint ifAbsent: aBlock\x0a\x09\x22Answer the navigation node in the receiver's tree at aPoint \x0a\x09or nil if no navigation node was found.\x0a\x09\x0a\x09See `node >> isNaviationNode`\x22\x0a\x09\x0a\x09| children |\x0a\x09\x0a\x09children := self allNodes select: [ :each | \x0a\x09\x09each isNavigationNode and: [ each inPosition: aPoint ] ].\x0a\x09\x0a\x09children ifEmpty: [ ^ aBlock value ].\x0a\x09\x0a\x09^ (children asArray sort: [ :a :b | \x0a\x09\x09(a positionStart dist: aPoint) <= \x0a\x09\x09(b positionStart dist: aPoint) ]) first",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["select:", "allNodes", "and:", "isNavigationNode", "inPosition:", "ifEmpty:", "value", "first", "sort:", "asArray", "<=", "dist:", "positionStart"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "nextChild",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=self._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._isEmpty();
+if($core.assert($2)){
+$1=self;
+} else {
+$1=$recv($recv(self._nodes())._first())._nextChild();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextChild",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextChild\x0a\x09\x22Answer the next node after aNode.\x0a\x09Recurse into the possible children of the receiver to answer the next node to be evaluated\x22\x0a\x09\x0a\x09^ self nodes isEmpty\x0a\x09\x09ifTrue: [ self ]\x0a\x09\x09ifFalse: [ self nodes first nextChild ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isEmpty", "nodes", "nextChild", "first"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "nextNode",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._parent();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+var node;
+node=$receiver;
+$1=$recv(node)._nextNode_(self);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextNode",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextNode\x0a\x09^ self parent ifNotNil: [ :node |\x0a\x09\x09node nextNode: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "parent", "nextNode:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "nextNode:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+var next;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+$1=self._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+next=$recv($1)._at_ifAbsent_($recv($recv(self._nodes())._indexOf_(aNode)).__plus((1)),(function(){
+throw $early=[self];
+
+}));
+$2=$recv(next)._nextChild();
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextNode:",{aNode:aNode,next:next},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "nextNode: aNode\x0a\x09\x22Answer the next node after aNode.\x0a\x09Recurse into the possible children of the next node to answer the next node to be evaluated\x22\x0a\x09\x0a\x09| next |\x0a\x09\x0a\x09next := self nodes \x0a\x09\x09at: (self nodes indexOf: aNode) + 1\x0a\x09\x09ifAbsent: [ ^ self ].\x0a\x09\x0a\x09^ next nextChild",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "nodes", "+", "indexOf:", "nextChild"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "nodes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@nodes"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@nodes"]=$recv($Array())._new();
+$1=self["@nodes"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nodes",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nodes\x0a\x09^ nodes ifNil: [ nodes := Array new ]",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "nodes:",
+protocol: 'building',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@nodes"]=aCollection;
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._parent_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nodes:",{aCollection:aCollection},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "nodes: aCollection\x0a\x09nodes := aCollection.\x0a\x09aCollection do: [ :each | each parent: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "parent:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "parent",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@parent"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "parent\x0a\x09^ parent",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "parent:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@parent"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "parent: aNode\x0a\x09parent := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "position",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$receiver;
+$2=self["@position"];
+if(($receiver = $2) == null || $receiver.isNil){
+$3=self._parent();
+if(($receiver = $3) == null || $receiver.isNil){
+$1=$3;
+} else {
+var node;
+node=$receiver;
+$1=$recv(node)._position();
+};
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"position",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "position\x0a\x09\x22answer the line and column of the receiver in the source code\x22\x0a\x09\x0a\x09^ position ifNil: [ \x0a\x09\x09self parent ifNotNil: [ :node | node position ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "ifNotNil:", "parent", "position"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "position:",
+protocol: 'accessing',
+fn: function (aPosition){
+var self=this;
+self["@position"]=aPosition;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPosition"],
+source: "position: aPosition\x0a\x09position := aPosition",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "positionEnd",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$7,$6,$5,$4,$3,$1;
+$2=self._positionStart();
+$7=self._source();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["source"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7)._lines();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lines"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__minus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["-"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__at($recv($recv($recv($recv(self._source())._lines())._last())._size()).__minus((1)));
+$1=$recv($2).__plus($3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"positionEnd",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "positionEnd\x0a\x09^ self positionStart + ((self source lines size - 1) @ (self source lines last size - 1))",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["+", "positionStart", "@", "-", "size", "lines", "source", "last"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "positionStart",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._position();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"positionStart",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "positionStart\x0a\x09^ self position",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["position"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "postCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Node.superclass.fn.prototype._postCopy.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(self._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._parent_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"postCopy",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "postCopy\x0a\x09super postCopy.\x0a\x09self nodes do: [ :each | each parent: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["postCopy", "do:", "nodes", "parent:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "requiresSmalltalkContext",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._nodes())._detect_ifNone_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._requiresSmalltalkContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+return nil;
+
+})))._notNil();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"requiresSmalltalkContext",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "requiresSmalltalkContext\x0a\x09\x22Answer true if the receiver requires a smalltalk context.\x0a\x09Only send nodes require a context.\x0a\x09\x0a\x09If no node requires a context, the method will be compiled without one.\x0a\x09See `IRJSTranslator` and `JSStream` for context creation\x22\x0a\x09\x0a\x09^ (self nodes \x0a\x09\x09detect: [ :each | each requiresSmalltalkContext ]\x0a\x09\x09ifNone: [ nil ]) notNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["notNil", "detect:ifNone:", "nodes", "requiresSmalltalkContext"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeAliased",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@shouldBeAliased"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldBeAliased",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldBeAliased\x0a\x09^ shouldBeAliased ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeAliased:",
+protocol: 'accessing',
+fn: function (aBoolean){
+var self=this;
+self["@shouldBeAliased"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "shouldBeAliased: aBoolean\x0a\x09shouldBeAliased := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeInlined",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@shouldBeInlined"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldBeInlined",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldBeInlined\x0a\x09^ shouldBeInlined ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeInlined:",
+protocol: 'accessing',
+fn: function (aBoolean){
+var self=this;
+self["@shouldBeInlined"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "shouldBeInlined: aBoolean\x0a\x09shouldBeInlined := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._source())._size();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09^ self source size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["size", "source"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@source"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1="";
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source ifNil: [ '' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "stopOnStepping",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stopOnStepping\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "subtreeNeedsAliasing",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._shouldBeAliased())._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._shouldBeInlined();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._nodes())._anySatisfy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(each)._subtreeNeedsAliasing();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["or:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subtreeNeedsAliasing",{},$globals.Node)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subtreeNeedsAliasing\x0a\x09^ (self shouldBeAliased or: [ self shouldBeInlined ]) or: [\x0a\x09\x09self nodes anySatisfy: [ :each | each subtreeNeedsAliasing ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["or:", "shouldBeAliased", "shouldBeInlined", "anySatisfy:", "nodes", "subtreeNeedsAliasing"]
+}),
+$globals.Node);
+
+
+
+$core.addClass('AssignmentNode', $globals.Node, ['left', 'right'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AssignmentNode.comment="I represent an assignment node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitAssignmentNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.AssignmentNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitAssignmentNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitAssignmentNode:"]
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "isAssignmentNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isAssignmentNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "left",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@left"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "left\x0a\x09^ left",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "left:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@left"]=aNode;
+$recv(aNode)._parent_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"left:",{aNode:aNode},$globals.AssignmentNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "left: aNode\x0a\x09left := aNode.\x0a\x09aNode parent: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parent:"]
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "nodes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Array())._with_with_(self._left(),self._right());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nodes",{},$globals.AssignmentNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nodes\x0a\x09^ Array with: self left with: self right",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["with:with:", "left", "right"]
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "right",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@right"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "right\x0a\x09^ right",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "right:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@right"]=aNode;
+$recv(aNode)._parent_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"right:",{aNode:aNode},$globals.AssignmentNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "right: aNode\x0a\x09right := aNode.\x0a\x09aNode parent: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parent:"]
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeAliased",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AssignmentNode.superclass.fn.prototype._shouldBeAliased.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($2)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._isReferenced();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldBeAliased",{},$globals.AssignmentNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldBeAliased\x0a\x09^ super shouldBeAliased or: [ self isReferenced ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["or:", "shouldBeAliased", "isReferenced"]
+}),
+$globals.AssignmentNode);
+
+
+
+$core.addClass('BlockNode', $globals.Node, ['parameters', 'scope'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.BlockNode.comment="I represent an block closure node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitBlockNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.BlockNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitBlockNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitBlockNode:"]
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "nextChild",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextChild\x0a\x09\x22Answer the receiver as we want to avoid eager evaluation\x22\x0a\x09\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "nextNode:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "nextNode: aNode\x0a\x09\x22Answer the receiver as we want to avoid eager evaluation\x22\x0a\x09\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "parameters",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@parameters"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@parameters"]=$recv($Array())._new();
+$1=self["@parameters"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parameters",{},$globals.BlockNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "parameters\x0a\x09^ parameters ifNil: [ parameters := Array new ]",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "parameters:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@parameters"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "parameters: aCollection\x0a\x09parameters := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aLexicalScope){
+var self=this;
+self["@scope"]=aLexicalScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aLexicalScope"],
+source: "scope: aLexicalScope\x0a\x09scope := aLexicalScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "subtreeNeedsAliasing",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._shouldBeAliased())._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._shouldBeInlined();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subtreeNeedsAliasing",{},$globals.BlockNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subtreeNeedsAliasing\x0a\x09^ self shouldBeAliased or: [ self shouldBeInlined ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["or:", "shouldBeAliased", "shouldBeInlined"]
+}),
+$globals.BlockNode);
+
+
+
+$core.addClass('CascadeNode', $globals.Node, ['receiver'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.CascadeNode.comment="I represent an cascade node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitCascadeNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.CascadeNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitCascadeNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitCascadeNode:"]
+}),
+$globals.CascadeNode);
+
+$core.addMethod(
+$core.method({
+selector: "isCascadeNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCascadeNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CascadeNode);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@receiver"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CascadeNode);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@receiver"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "receiver: aNode\x0a\x09receiver := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CascadeNode);
+
+
+
+$core.addClass('DynamicArrayNode', $globals.Node, [], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.DynamicArrayNode.comment="I represent an dynamic array node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitDynamicArrayNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.DynamicArrayNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitDynamicArrayNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitDynamicArrayNode:"]
+}),
+$globals.DynamicArrayNode);
+
+
+
+$core.addClass('DynamicDictionaryNode', $globals.Node, [], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.DynamicDictionaryNode.comment="I represent an dynamic dictionary node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitDynamicDictionaryNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.DynamicDictionaryNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitDynamicDictionaryNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitDynamicDictionaryNode:"]
+}),
+$globals.DynamicDictionaryNode);
+
+
+
+$core.addClass('JSStatementNode', $globals.Node, [], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.JSStatementNode.comment="I represent an JavaScript statement node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitJSStatementNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.JSStatementNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitJSStatementNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitJSStatementNode:"]
+}),
+$globals.JSStatementNode);
+
+$core.addMethod(
+$core.method({
+selector: "isJSStatementNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isJSStatementNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSStatementNode);
+
+$core.addMethod(
+$core.method({
+selector: "requiresSmalltalkContext",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "requiresSmalltalkContext\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSStatementNode);
+
+
+
+$core.addClass('MethodNode', $globals.Node, ['selector', 'arguments', 'source', 'scope', 'classReferences', 'sendIndexes', 'superSends'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodNode.comment="I represent an method node.\x0a\x0aA method node must be the root and only method node of a valid AST.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitMethodNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.MethodNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitMethodNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitMethodNode:"]
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@arguments"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=[];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.MethodNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ arguments ifNil: [ #() ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "arguments:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@arguments"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "arguments: aCollection\x0a\x09arguments := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "classReferences",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@classReferences"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classReferences\x0a\x09^ classReferences",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "classReferences:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@classReferences"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "classReferences: aCollection\x0a\x09classReferences := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "messageSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._sendIndexes())._keys();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageSends",{},$globals.MethodNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageSends\x0a\x09^ self sendIndexes keys",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keys", "sendIndexes"]
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aMethodScope){
+var self=this;
+self["@scope"]=aMethodScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethodScope"],
+source: "scope: aMethodScope\x0a\x09scope := aMethodScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@sendIndexes"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sendIndexes\x0a\x09^ sendIndexes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes:",
+protocol: 'accessing',
+fn: function (aDictionary){
+var self=this;
+self["@sendIndexes"]=aDictionary;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDictionary"],
+source: "sendIndexes: aDictionary\x0a\x09sendIndexes := aDictionary",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "sequenceNode",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+$recv(self._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(each)._isSequenceNode();
+if($core.assert($1)){
+throw $early=[each];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return nil;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sequenceNode",{},$globals.MethodNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sequenceNode\x0a\x09self nodes do: [ :each |\x0a\x09\x09each isSequenceNode ifTrue: [ ^ each ] ].\x0a\x09\x09\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "nodes", "ifTrue:", "isSequenceNode"]
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@source"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "superSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@superSends"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "superSends\x0a\x09^ superSends",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+$core.addMethod(
+$core.method({
+selector: "superSends:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@superSends"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "superSends: aCollection\x0a\x09superSends := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodNode);
+
+
+
+$core.addClass('ReturnNode', $globals.Node, ['scope'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ReturnNode.comment="I represent an return node. At the AST level, there is not difference between a local return or non-local return.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitReturnNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.ReturnNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitReturnNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitReturnNode:"]
+}),
+$globals.ReturnNode);
+
+$core.addMethod(
+$core.method({
+selector: "isReturnNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isReturnNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ReturnNode);
+
+$core.addMethod(
+$core.method({
+selector: "nonLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._scope())._isMethodScope())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nonLocalReturn",{},$globals.ReturnNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nonLocalReturn\x0a\x09^ self scope isMethodScope not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isMethodScope", "scope"]
+}),
+$globals.ReturnNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ReturnNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aLexicalScope){
+var self=this;
+self["@scope"]=aLexicalScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aLexicalScope"],
+source: "scope: aLexicalScope\x0a\x09scope := aLexicalScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ReturnNode);
+
+
+
+$core.addClass('SendNode', $globals.Node, ['selector', 'arguments', 'receiver', 'superSend', 'index'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SendNode.comment="I represent an message send node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitSendNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitSendNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitSendNode:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@arguments"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@arguments"]=[];
+$1=self["@arguments"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ arguments ifNil: [ arguments := #() ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "arguments:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@arguments"]=aCollection;
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._parent_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments:",{aCollection:aCollection},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "arguments: aCollection\x0a\x09arguments := aCollection.\x0a\x09aCollection do: [ :each | each parent: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "parent:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "cascadeNodeWithMessages:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+var first;
+function $SendNode(){return $globals.SendNode||(typeof SendNode=="undefined"?nil:SendNode)}
+function $CascadeNode(){return $globals.CascadeNode||(typeof CascadeNode=="undefined"?nil:CascadeNode)}
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$5,$3;
+$1=$recv($SendNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._selector_(self._selector());
+$recv($1)._arguments_(self._arguments());
+$2=$recv($1)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+first=$2;
+$4=$recv($CascadeNode())._new();
+$recv($4)._receiver_(self._receiver());
+$recv($4)._nodes_($recv($recv($Array())._with_(first)).__comma(aCollection));
+$5=$recv($4)._yourself();
+$3=$5;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cascadeNodeWithMessages:",{aCollection:aCollection,first:first},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "cascadeNodeWithMessages: aCollection\x0a\x09| first |\x0a\x09first := SendNode new\x0a\x09\x09selector: self selector;\x0a\x09\x09arguments: self arguments;\x0a\x09\x09yourself.\x0a\x09^ CascadeNode new\x0a\x09\x09receiver: self receiver;\x0a\x09\x09nodes: (Array with: first), aCollection;\x0a\x09\x09yourself",
+referencedClasses: ["SendNode", "CascadeNode", "Array"],
+//>>excludeEnd("ide");
+messageSends: ["selector:", "new", "selector", "arguments:", "arguments", "yourself", "receiver:", "receiver", "nodes:", ",", "with:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "index",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@index"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "index\x0a\x09^ index",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "index:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@index"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "index: anInteger\x0a\x09index := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "isCascadeSendNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._parent())._isCascadeNode();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isCascadeSendNode",{},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCascadeSendNode\x0a\x09^ self parent isCascadeNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isCascadeNode", "parent"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "isNavigationNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNavigationNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSendNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSendNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "navigationLink",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._selector();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"navigationLink",{},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "navigationLink\x0a\x09^ self selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["selector"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "nodes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$5,$6,$4,$receiver;
+$1=self._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$3=self._arguments();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["arguments"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._copy();
+return $2;
+} else {
+$1;
+};
+$5=$recv($Array())._with_(self._receiver());
+$recv($5)._addAll_(self._arguments());
+$6=$recv($5)._yourself();
+$4=$6;
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nodes",{},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nodes\x0a\x09self receiver ifNil: [ ^ self arguments copy ].\x0a\x09\x0a\x09^ (Array with: self receiver)\x0a\x09\x09addAll: self arguments;\x0a\x09\x09yourself",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "receiver", "copy", "arguments", "addAll:", "with:", "yourself"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@receiver"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self["@receiver"]=aNode;
+$1=$recv(aNode)._isNode();
+if($core.assert($1)){
+$recv(aNode)._parent_(self);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"receiver:",{aNode:aNode},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "receiver: aNode\x0a\x09receiver := aNode.\x0a\x09aNode isNode ifTrue: [\x0a\x09\x09aNode parent: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isNode", "parent:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "requiresSmalltalkContext",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "requiresSmalltalkContext\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "shouldBeAliased",
+protocol: 'testing',
+fn: function (){
+var self=this;
+var sends;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+sends=$recv($recv($recv(self._method())._sendIndexes())._at_(self._selector()))._size();
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SendNode.superclass.fn.prototype._shouldBeAliased.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($2)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._isReferenced())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv($recv(sends).__gt((1)))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv(self._index()).__lt(sends);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
+//>>excludeEnd("ctx");
+})))._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return self._superSend();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,4)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["and:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["or:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldBeAliased",{sends:sends},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldBeAliased\x0a\x09\x22Because we keep track of send indexes, some send nodes need additional care for aliasing. \x0a\x09See IRJSVisitor >> visitIRSend:\x22\x0a\x09\x0a\x09| sends |\x0a\x09\x0a\x09sends := (self method sendIndexes at: self selector) size.\x0a\x09\x0a\x09^ (super shouldBeAliased or: [\x0a\x09\x09self isReferenced and: [\x0a\x09\x09\x09(sends > 1 and: [ self index < sends ])\x0a\x09\x09\x09\x09or: [ self superSend ] ] ])",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["size", "at:", "sendIndexes", "method", "selector", "or:", "shouldBeAliased", "and:", "isReferenced", ">", "<", "index", "superSend"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "stopOnStepping",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stopOnStepping\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "superSend",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@superSend"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"superSend",{},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "superSend\x0a\x09^ superSend ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "superSend:",
+protocol: 'accessing',
+fn: function (aBoolean){
+var self=this;
+self["@superSend"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "superSend: aBoolean\x0a\x09superSend := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+$core.addMethod(
+$core.method({
+selector: "valueForReceiver:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+function $SendNode(){return $globals.SendNode||(typeof SendNode=="undefined"?nil:SendNode)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$5,$4,$6,$1,$receiver;
+$2=$recv($SendNode())._new();
+$recv($2)._position_(self._position());
+$recv($2)._source_(self._source());
+$3=$2;
+$5=self._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $5) == null || $receiver.isNil){
+$4=anObject;
+} else {
+$4=$recv(self._receiver())._valueForReceiver_(anObject);
+};
+$recv($3)._receiver_($4);
+$recv($2)._selector_(self._selector());
+$recv($2)._arguments_(self._arguments());
+$6=$recv($2)._yourself();
+$1=$6;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueForReceiver:",{anObject:anObject},$globals.SendNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "valueForReceiver: anObject\x0a\x09^ SendNode new\x0a\x09\x09position: self position;\x0a\x09\x09source: self source;\x0a\x09\x09receiver: (self receiver\x0a\x09\x09ifNil: [ anObject ] \x0a\x09\x09ifNotNil: [ self receiver valueForReceiver: anObject ]);\x0a\x09\x09selector: self selector;\x0a\x09\x09arguments: self arguments;\x0a\x09\x09yourself",
+referencedClasses: ["SendNode"],
+//>>excludeEnd("ide");
+messageSends: ["position:", "new", "position", "source:", "source", "receiver:", "ifNil:ifNotNil:", "receiver", "valueForReceiver:", "selector:", "selector", "arguments:", "arguments", "yourself"]
+}),
+$globals.SendNode);
+
+
+
+$core.addClass('SequenceNode', $globals.Node, ['temps', 'scope'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SequenceNode.comment="I represent an sequence node. A sequence represent a set of instructions inside the same scope (the method scope or a block scope).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitSequenceNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.SequenceNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitSequenceNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitSequenceNode:"]
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "asBlockSequenceNode",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $BlockSequenceNode(){return $globals.BlockSequenceNode||(typeof BlockSequenceNode=="undefined"?nil:BlockSequenceNode)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($BlockSequenceNode())._new();
+$recv($2)._position_(self._position());
+$recv($2)._source_(self._source());
+$recv($2)._nodes_(self._nodes());
+$recv($2)._temps_(self._temps());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asBlockSequenceNode",{},$globals.SequenceNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asBlockSequenceNode\x0a\x09^ BlockSequenceNode new\x0a\x09\x09position: self position;\x0a\x09\x09source: self source;\x0a\x09\x09nodes: self nodes;\x0a\x09\x09temps: self temps;\x0a\x09\x09yourself",
+referencedClasses: ["BlockSequenceNode"],
+//>>excludeEnd("ide");
+messageSends: ["position:", "new", "position", "source:", "source", "nodes:", "nodes", "temps:", "temps", "yourself"]
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSequenceNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSequenceNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aLexicalScope){
+var self=this;
+self["@scope"]=aLexicalScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aLexicalScope"],
+source: "scope: aLexicalScope\x0a\x09scope := aLexicalScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "temps",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@temps"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=[];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"temps",{},$globals.SequenceNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "temps\x0a\x09^ temps ifNil: [ #() ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.SequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "temps:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@temps"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "temps: aCollection\x0a\x09temps := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceNode);
+
+
+
+$core.addClass('BlockSequenceNode', $globals.SequenceNode, [], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.BlockSequenceNode.comment="I represent an special sequence node for block scopes.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitBlockSequenceNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.BlockSequenceNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitBlockSequenceNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitBlockSequenceNode:"]
+}),
+$globals.BlockSequenceNode);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockSequenceNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockSequenceNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockSequenceNode);
+
+
+
+$core.addClass('ValueNode', $globals.Node, ['value'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ValueNode.comment="I represent a value node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitValueNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.ValueNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitValueNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitValueNode:"]
+}),
+$globals.ValueNode);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._value())._isImmutable();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isImmutable",{},$globals.ValueNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ self value isImmutable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isImmutable", "value"]
+}),
+$globals.ValueNode);
+
+$core.addMethod(
+$core.method({
+selector: "isValueNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isValueNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ValueNode);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@value"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ValueNode);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@value"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "value: anObject\x0a\x09value := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ValueNode);
+
+
+
+$core.addClass('VariableNode', $globals.ValueNode, ['assigned', 'binding'], 'Compiler-AST');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.VariableNode.comment="I represent an variable node.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitVariableNode_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitVariableNode: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitVariableNode:"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._binding())._alias();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09^ self binding alias",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["alias", "binding"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "assigned",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@assigned"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assigned",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "assigned\x0a\x09^ assigned ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "assigned:",
+protocol: 'accessing',
+fn: function (aBoolean){
+var self=this;
+self["@assigned"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "assigned: aBoolean\x0a\x09assigned := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "beAssigned",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._binding())._validateAssignment();
+self["@assigned"]=true;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beAssigned",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "beAssigned\x0a\x09self binding validateAssignment.\x0a\x09assigned := true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["validateAssignment", "binding"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "binding",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@binding"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "binding\x0a\x09^ binding",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "binding:",
+protocol: 'accessing',
+fn: function (aScopeVar){
+var self=this;
+self["@binding"]=aScopeVar;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScopeVar"],
+source: "binding: aScopeVar\x0a\x09binding := aScopeVar",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "isArgument",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._binding())._isArgVar();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isArgument",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isArgument\x0a\x09^ self binding isArgVar",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isArgVar", "binding"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._binding())._isImmutable();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isImmutable",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ self binding isImmutable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isImmutable", "binding"]
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "isNavigationNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNavigationNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "isVariableNode",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isVariableNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.VariableNode);
+
+$core.addMethod(
+$core.method({
+selector: "navigationLink",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"navigationLink",{},$globals.VariableNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "navigationLink\x0a\x09^ self value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value"]
+}),
+$globals.VariableNode);
+
+
+$core.addMethod(
+$core.method({
+selector: "ast",
+protocol: '*Compiler-AST',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._source();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["source"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._ifEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Method source is empty");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv($Smalltalk())._parse_(self._source());
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ast",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ast\x0a\x09self source ifEmpty: [ self error: 'Method source is empty' ].\x0a\x09\x0a\x09^ Smalltalk parse: self source",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifEmpty:", "source", "error:", "parse:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "isNode",
+protocol: '*Compiler-AST',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+});

+ 842 - 0
bower_components/amber/src/Compiler-AST.st

@@ -0,0 +1,842 @@
+Smalltalk createPackage: 'Compiler-AST'!
+Object subclass: #Node
+	instanceVariableNames: 'parent position source nodes shouldBeInlined shouldBeAliased'
+	package: 'Compiler-AST'!
+!Node commentStamp!
+I am the abstract root class of the abstract syntax tree.
+
+Concrete classes should implement `#accept:` to allow visiting.
+
+`position` holds a point containing line and column number of the symbol location in the original source file.!
+
+!Node methodsFor: 'accessing'!
+
+addNode: aNode
+	self nodes add: aNode.
+	aNode parent: self
+!
+
+allNodes
+	| allNodes |
+	
+	allNodes := self nodes asSet.
+	self nodes do: [ :each | 
+		allNodes addAll: each allNodes ].
+	
+	^ allNodes
+!
+
+method
+	^ self parent ifNotNil: [ :node | node method ]
+!
+
+navigationNodeAt: aPoint ifAbsent: aBlock
+	"Answer the navigation node in the receiver's tree at aPoint 
+	or nil if no navigation node was found.
+	
+	See `node >> isNaviationNode`"
+	
+	| children |
+	
+	children := self allNodes select: [ :each | 
+		each isNavigationNode and: [ each inPosition: aPoint ] ].
+	
+	children ifEmpty: [ ^ aBlock value ].
+	
+	^ (children asArray sort: [ :a :b | 
+		(a positionStart dist: aPoint) <= 
+		(b positionStart dist: aPoint) ]) first
+!
+
+nextChild
+	"Answer the next node after aNode.
+	Recurse into the possible children of the receiver to answer the next node to be evaluated"
+	
+	^ self nodes isEmpty
+		ifTrue: [ self ]
+		ifFalse: [ self nodes first nextChild ]
+!
+
+nextNode
+	^ self parent ifNotNil: [ :node |
+		node nextNode: self ]
+!
+
+nextNode: aNode
+	"Answer the next node after aNode.
+	Recurse into the possible children of the next node to answer the next node to be evaluated"
+	
+	| next |
+	
+	next := self nodes 
+		at: (self nodes indexOf: aNode) + 1
+		ifAbsent: [ ^ self ].
+	
+	^ next nextChild
+!
+
+nodes
+	^ nodes ifNil: [ nodes := Array new ]
+!
+
+parent
+	^ parent
+!
+
+parent: aNode
+	parent := aNode
+!
+
+position
+	"answer the line and column of the receiver in the source code"
+	
+	^ position ifNil: [ 
+		self parent ifNotNil: [ :node | node position ] ]
+!
+
+position: aPosition
+	position := aPosition
+!
+
+positionEnd
+	^ self positionStart + ((self source lines size - 1) @ (self source lines last size - 1))
+!
+
+positionStart
+	^ self position
+!
+
+shouldBeAliased
+	^ shouldBeAliased ifNil: [ false ]
+!
+
+shouldBeAliased: aBoolean
+	shouldBeAliased := aBoolean
+!
+
+shouldBeInlined
+	^ shouldBeInlined ifNil: [ false ]
+!
+
+shouldBeInlined: aBoolean
+	shouldBeInlined := aBoolean
+!
+
+size
+	^ self source size
+!
+
+source
+	^ source ifNil: [ '' ]
+!
+
+source: aString
+	source := aString
+! !
+
+!Node methodsFor: 'building'!
+
+nodes: aCollection
+	nodes := aCollection.
+	aCollection do: [ :each | each parent: self ]
+! !
+
+!Node methodsFor: 'copying'!
+
+postCopy
+	super postCopy.
+	self nodes do: [ :each | each parent: self ]
+! !
+
+!Node methodsFor: 'testing'!
+
+inPosition: aPoint
+	^ (self positionStart <= aPoint and: [
+		self positionEnd >= aPoint ])
+!
+
+isAssignmentNode
+	^ false
+!
+
+isBlockNode
+	^ false
+!
+
+isBlockSequenceNode
+	^ false
+!
+
+isCascadeNode
+	^ false
+!
+
+isImmutable
+	^ false
+!
+
+isJSStatementNode
+	^ false
+!
+
+isLastChild
+	^ self parent nodes last = self
+!
+
+isNavigationNode
+	"Answer true if the node can be navigated to"
+	
+	^ false
+!
+
+isNode
+	^ true
+!
+
+isReferenced
+	"Answer true if the receiver is referenced by other nodes.
+	Do not take sequences or assignments into account"
+	
+	^ (self parent isSequenceNode or: [
+		self parent isAssignmentNode ]) not
+!
+
+isReturnNode
+	^ false
+!
+
+isSendNode
+	^ false
+!
+
+isSequenceNode
+	^ false
+!
+
+isValueNode
+	^ false
+!
+
+isVariableNode
+	^ false
+!
+
+requiresSmalltalkContext
+	"Answer true if the receiver requires a smalltalk context.
+	Only send nodes require a context.
+	
+	If no node requires a context, the method will be compiled without one.
+	See `IRJSTranslator` and `JSStream` for context creation"
+	
+	^ (self nodes 
+		detect: [ :each | each requiresSmalltalkContext ]
+		ifNone: [ nil ]) notNil
+!
+
+stopOnStepping
+	^ false
+!
+
+subtreeNeedsAliasing
+	^ (self shouldBeAliased or: [ self shouldBeInlined ]) or: [
+		self nodes anySatisfy: [ :each | each subtreeNeedsAliasing ] ]
+! !
+
+!Node methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitNode: self
+! !
+
+Node subclass: #AssignmentNode
+	instanceVariableNames: 'left right'
+	package: 'Compiler-AST'!
+!AssignmentNode commentStamp!
+I represent an assignment node.!
+
+!AssignmentNode methodsFor: 'accessing'!
+
+left
+	^ left
+!
+
+left: aNode
+	left := aNode.
+	aNode parent: self
+!
+
+nodes
+	^ Array with: self left with: self right
+!
+
+right
+	^ right
+!
+
+right: aNode
+	right := aNode.
+	aNode parent: self
+! !
+
+!AssignmentNode methodsFor: 'testing'!
+
+isAssignmentNode
+	^ true
+!
+
+shouldBeAliased
+	^ super shouldBeAliased or: [ self isReferenced ]
+! !
+
+!AssignmentNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitAssignmentNode: self
+! !
+
+Node subclass: #BlockNode
+	instanceVariableNames: 'parameters scope'
+	package: 'Compiler-AST'!
+!BlockNode commentStamp!
+I represent an block closure node.!
+
+!BlockNode methodsFor: 'accessing'!
+
+nextChild
+	"Answer the receiver as we want to avoid eager evaluation"
+	
+	^ self
+!
+
+nextNode: aNode
+	"Answer the receiver as we want to avoid eager evaluation"
+	
+	^ self
+!
+
+parameters
+	^ parameters ifNil: [ parameters := Array new ]
+!
+
+parameters: aCollection
+	parameters := aCollection
+!
+
+scope
+	^ scope
+!
+
+scope: aLexicalScope
+	scope := aLexicalScope
+! !
+
+!BlockNode methodsFor: 'testing'!
+
+isBlockNode
+	^ true
+!
+
+subtreeNeedsAliasing
+	^ self shouldBeAliased or: [ self shouldBeInlined ]
+! !
+
+!BlockNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitBlockNode: self
+! !
+
+Node subclass: #CascadeNode
+	instanceVariableNames: 'receiver'
+	package: 'Compiler-AST'!
+!CascadeNode commentStamp!
+I represent an cascade node.!
+
+!CascadeNode methodsFor: 'accessing'!
+
+receiver
+	^ receiver
+!
+
+receiver: aNode
+	receiver := aNode
+! !
+
+!CascadeNode methodsFor: 'testing'!
+
+isCascadeNode
+	^ true
+! !
+
+!CascadeNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitCascadeNode: self
+! !
+
+Node subclass: #DynamicArrayNode
+	instanceVariableNames: ''
+	package: 'Compiler-AST'!
+!DynamicArrayNode commentStamp!
+I represent an dynamic array node.!
+
+!DynamicArrayNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitDynamicArrayNode: self
+! !
+
+Node subclass: #DynamicDictionaryNode
+	instanceVariableNames: ''
+	package: 'Compiler-AST'!
+!DynamicDictionaryNode commentStamp!
+I represent an dynamic dictionary node.!
+
+!DynamicDictionaryNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitDynamicDictionaryNode: self
+! !
+
+Node subclass: #JSStatementNode
+	instanceVariableNames: ''
+	package: 'Compiler-AST'!
+!JSStatementNode commentStamp!
+I represent an JavaScript statement node.!
+
+!JSStatementNode methodsFor: 'testing'!
+
+isJSStatementNode
+	^ true
+!
+
+requiresSmalltalkContext
+	^ true
+! !
+
+!JSStatementNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitJSStatementNode: self
+! !
+
+Node subclass: #MethodNode
+	instanceVariableNames: 'selector arguments source scope classReferences sendIndexes superSends'
+	package: 'Compiler-AST'!
+!MethodNode commentStamp!
+I represent an method node.
+
+A method node must be the root and only method node of a valid AST.!
+
+!MethodNode methodsFor: 'accessing'!
+
+arguments
+	^ arguments ifNil: [ #() ]
+!
+
+arguments: aCollection
+	arguments := aCollection
+!
+
+classReferences
+	^ classReferences
+!
+
+classReferences: aCollection
+	classReferences := aCollection
+!
+
+messageSends
+	^ self sendIndexes keys
+!
+
+method
+	^ self
+!
+
+scope
+	^ scope
+!
+
+scope: aMethodScope
+	scope := aMethodScope
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+!
+
+sendIndexes
+	^ sendIndexes
+!
+
+sendIndexes: aDictionary
+	sendIndexes := aDictionary
+!
+
+sequenceNode
+	self nodes do: [ :each |
+		each isSequenceNode ifTrue: [ ^ each ] ].
+		
+	^ nil
+!
+
+source
+	^ source
+!
+
+source: aString
+	source := aString
+!
+
+superSends
+	^ superSends
+!
+
+superSends: aCollection
+	superSends := aCollection
+! !
+
+!MethodNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitMethodNode: self
+! !
+
+Node subclass: #ReturnNode
+	instanceVariableNames: 'scope'
+	package: 'Compiler-AST'!
+!ReturnNode commentStamp!
+I represent an return node. At the AST level, there is not difference between a local return or non-local return.!
+
+!ReturnNode methodsFor: 'accessing'!
+
+scope
+	^ scope
+!
+
+scope: aLexicalScope
+	scope := aLexicalScope
+! !
+
+!ReturnNode methodsFor: 'testing'!
+
+isReturnNode
+	^ true
+!
+
+nonLocalReturn
+	^ self scope isMethodScope not
+! !
+
+!ReturnNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitReturnNode: self
+! !
+
+Node subclass: #SendNode
+	instanceVariableNames: 'selector arguments receiver superSend index'
+	package: 'Compiler-AST'!
+!SendNode commentStamp!
+I represent an message send node.!
+
+!SendNode methodsFor: 'accessing'!
+
+arguments
+	^ arguments ifNil: [ arguments := #() ]
+!
+
+arguments: aCollection
+	arguments := aCollection.
+	aCollection do: [ :each | each parent: self ]
+!
+
+cascadeNodeWithMessages: aCollection
+	| first |
+	first := SendNode new
+		selector: self selector;
+		arguments: self arguments;
+		yourself.
+	^ CascadeNode new
+		receiver: self receiver;
+		nodes: (Array with: first), aCollection;
+		yourself
+!
+
+index
+	^ index
+!
+
+index: anInteger
+	index := anInteger
+!
+
+navigationLink
+	^ self selector
+!
+
+nodes
+	self receiver ifNil: [ ^ self arguments copy ].
+	
+	^ (Array with: self receiver)
+		addAll: self arguments;
+		yourself
+!
+
+receiver
+	^ receiver
+!
+
+receiver: aNode
+	receiver := aNode.
+	aNode isNode ifTrue: [
+		aNode parent: self ]
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+!
+
+superSend
+	^ superSend ifNil: [ false ]
+!
+
+superSend: aBoolean
+	superSend := aBoolean
+!
+
+valueForReceiver: anObject
+	^ SendNode new
+		position: self position;
+		source: self source;
+		receiver: (self receiver
+		ifNil: [ anObject ] 
+		ifNotNil: [ self receiver valueForReceiver: anObject ]);
+		selector: self selector;
+		arguments: self arguments;
+		yourself
+! !
+
+!SendNode methodsFor: 'testing'!
+
+isCascadeSendNode
+	^ self parent isCascadeNode
+!
+
+isNavigationNode
+	^ true
+!
+
+isSendNode
+	^ true
+!
+
+requiresSmalltalkContext
+	^ true
+!
+
+shouldBeAliased
+	"Because we keep track of send indexes, some send nodes need additional care for aliasing. 
+	See IRJSVisitor >> visitIRSend:"
+	
+	| sends |
+	
+	sends := (self method sendIndexes at: self selector) size.
+	
+	^ (super shouldBeAliased or: [
+		self isReferenced and: [
+			(sends > 1 and: [ self index < sends ])
+				or: [ self superSend ] ] ])
+!
+
+stopOnStepping
+	^ true
+! !
+
+!SendNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitSendNode: self
+! !
+
+Node subclass: #SequenceNode
+	instanceVariableNames: 'temps scope'
+	package: 'Compiler-AST'!
+!SequenceNode commentStamp!
+I represent an sequence node. A sequence represent a set of instructions inside the same scope (the method scope or a block scope).!
+
+!SequenceNode methodsFor: 'accessing'!
+
+scope
+	^ scope
+!
+
+scope: aLexicalScope
+	scope := aLexicalScope
+!
+
+temps
+	^ temps ifNil: [ #() ]
+!
+
+temps: aCollection
+	temps := aCollection
+! !
+
+!SequenceNode methodsFor: 'converting'!
+
+asBlockSequenceNode
+	^ BlockSequenceNode new
+		position: self position;
+		source: self source;
+		nodes: self nodes;
+		temps: self temps;
+		yourself
+! !
+
+!SequenceNode methodsFor: 'testing'!
+
+isSequenceNode
+	^ true
+! !
+
+!SequenceNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitSequenceNode: self
+! !
+
+SequenceNode subclass: #BlockSequenceNode
+	instanceVariableNames: ''
+	package: 'Compiler-AST'!
+!BlockSequenceNode commentStamp!
+I represent an special sequence node for block scopes.!
+
+!BlockSequenceNode methodsFor: 'testing'!
+
+isBlockSequenceNode
+	^ true
+! !
+
+!BlockSequenceNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitBlockSequenceNode: self
+! !
+
+Node subclass: #ValueNode
+	instanceVariableNames: 'value'
+	package: 'Compiler-AST'!
+!ValueNode commentStamp!
+I represent a value node.!
+
+!ValueNode methodsFor: 'accessing'!
+
+value
+	^ value
+!
+
+value: anObject
+	value := anObject
+! !
+
+!ValueNode methodsFor: 'testing'!
+
+isImmutable
+	^ self value isImmutable
+!
+
+isValueNode
+	^ true
+! !
+
+!ValueNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitValueNode: self
+! !
+
+ValueNode subclass: #VariableNode
+	instanceVariableNames: 'assigned binding'
+	package: 'Compiler-AST'!
+!VariableNode commentStamp!
+I represent an variable node.!
+
+!VariableNode methodsFor: 'accessing'!
+
+alias
+	^ self binding alias
+!
+
+assigned
+	^ assigned ifNil: [ false ]
+!
+
+assigned: aBoolean
+	assigned := aBoolean
+!
+
+beAssigned
+	self binding validateAssignment.
+	assigned := true
+!
+
+binding
+	^ binding
+!
+
+binding: aScopeVar
+	binding := aScopeVar
+!
+
+navigationLink
+	^ self value
+! !
+
+!VariableNode methodsFor: 'testing'!
+
+isArgument
+	^ self binding isArgVar
+!
+
+isImmutable
+	^ self binding isImmutable
+!
+
+isNavigationNode
+	^ true
+!
+
+isVariableNode
+	^ true
+! !
+
+!VariableNode methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitVariableNode: self
+! !
+
+!CompiledMethod methodsFor: '*Compiler-AST'!
+
+ast
+	self source ifEmpty: [ self error: 'Method source is empty' ].
+	
+	^ Smalltalk parse: self source
+! !
+
+!Object methodsFor: '*Compiler-AST'!
+
+isNode
+	^ false
+! !
+

+ 1552 - 0
bower_components/amber/src/Compiler-Core.js

@@ -0,0 +1,1552 @@
+define("amber_core/Compiler-Core", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Collections"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Core');
+$core.packages["Compiler-Core"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('AbstractCodeGenerator', $globals.Object, ['currentClass', 'source'], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AbstractCodeGenerator.comment="I am the abstract super class of all code generators and provide their common API.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "classNameFor:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$1;
+$2=$recv(aClass)._isMetaclass();
+if($core.assert($2)){
+$3=$recv($recv(aClass)._instanceClass())._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($3).__comma(".klass");
+} else {
+$4=$recv(aClass)._isNil();
+if($core.assert($4)){
+$1="nil";
+} else {
+$1=$recv(aClass)._name();
+};
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},$globals.AbstractCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "classNameFor: aClass\x0a\x09^ aClass isMetaclass\x0a\x09\x09ifTrue: [ aClass instanceClass name, '.klass' ]\x0a\x09\x09ifFalse: [\x0a\x09\x09aClass isNil\x0a\x09\x09\x09ifTrue: [ 'nil' ]\x0a\x09\x09\x09ifFalse: [ aClass name ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isMetaclass", ",", "name", "instanceClass", "isNil"]
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "compileNode:",
+protocol: 'compiling',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileNode:",{aNode:aNode},$globals.AbstractCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "compileNode: aNode\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@currentClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currentClass\x0a\x09^ currentClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@currentClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "currentClass: aClass\x0a\x09currentClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "pseudoVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._pseudoVariableNames();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pseudoVariables",{},$globals.AbstractCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pseudoVariables\x0a\x09^ Smalltalk pseudoVariableNames",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["pseudoVariableNames"]
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@source"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1="";
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source",{},$globals.AbstractCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source ifNil: [ '' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.AbstractCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AbstractCodeGenerator);
+
+
+
+$core.addClass('CodeGenerator', $globals.AbstractCodeGenerator, [], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.CodeGenerator.comment="I am a basic code generator. I generate a valid JavaScript output, but no not perform any inlining.\x0aSee `InliningCodeGenerator` for an optimized JavaScript code generation.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "compileNode:",
+protocol: 'compiling',
+fn: function (aNode){
+var self=this;
+var ir,stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$recv(self._semanticAnalyzer())._visit_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+ir=$recv(self._translator())._visit_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=2;
+//>>excludeEnd("ctx");
+$2=self._irTranslator();
+$recv($2)._currentClass_(self._currentClass());
+$recv($2)._visit_(ir);
+$3=$recv($2)._contents();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileNode:",{aNode:aNode,ir:ir,stream:stream},$globals.CodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "compileNode: aNode\x0a\x09| ir stream |\x0a\x09self semanticAnalyzer visit: aNode.\x0a\x09ir := self translator visit: aNode.\x0a\x09^ self irTranslator\x0a\x09\x09currentClass: self currentClass;\x0a\x09\x09visit: ir;\x0a\x09\x09contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "semanticAnalyzer", "translator", "currentClass:", "irTranslator", "currentClass", "contents"]
+}),
+$globals.CodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "irTranslator",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $IRJSTranslator(){return $globals.IRJSTranslator||(typeof IRJSTranslator=="undefined"?nil:IRJSTranslator)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRJSTranslator())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"irTranslator",{},$globals.CodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "irTranslator\x0a\x09^ IRJSTranslator new",
+referencedClasses: ["IRJSTranslator"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.CodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "semanticAnalyzer",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($SemanticAnalyzer())._on_(self._currentClass());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"semanticAnalyzer",{},$globals.CodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "semanticAnalyzer\x0a\x09^ SemanticAnalyzer on: self currentClass",
+referencedClasses: ["SemanticAnalyzer"],
+//>>excludeEnd("ide");
+messageSends: ["on:", "currentClass"]
+}),
+$globals.CodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "translator",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $IRASTTranslator(){return $globals.IRASTTranslator||(typeof IRASTTranslator=="undefined"?nil:IRASTTranslator)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRASTTranslator())._new();
+$recv($2)._source_(self._source());
+$recv($2)._theClass_(self._currentClass());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"translator",{},$globals.CodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "translator\x0a\x09^ IRASTTranslator new\x0a\x09\x09source: self source;\x0a\x09\x09theClass: self currentClass;\x0a\x09\x09yourself",
+referencedClasses: ["IRASTTranslator"],
+//>>excludeEnd("ide");
+messageSends: ["source:", "new", "source", "theClass:", "currentClass", "yourself"]
+}),
+$globals.CodeGenerator);
+
+
+
+$core.addClass('Compiler', $globals.Object, ['currentClass', 'source', 'unknownVariables', 'codeGeneratorClass'], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Compiler.comment="I provide the public interface for compiling Amber source code into JavaScript.\x0a\x0aThe code generator used to produce JavaScript can be plugged with `#codeGeneratorClass`.\x0aThe default code generator is an instance of `InlinedCodeGenerator`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "codeGeneratorClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $InliningCodeGenerator(){return $globals.InliningCodeGenerator||(typeof InliningCodeGenerator=="undefined"?nil:InliningCodeGenerator)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@codeGeneratorClass"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$InliningCodeGenerator();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"codeGeneratorClass",{},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "codeGeneratorClass\x0a\x09^ codeGeneratorClass ifNil: [ InliningCodeGenerator ]",
+referencedClasses: ["InliningCodeGenerator"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "codeGeneratorClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@codeGeneratorClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "codeGeneratorClass: aClass\x0a\x09codeGeneratorClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "compile:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._compileNode_(self._parse_(aString));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compile:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compile: aString\x0a\x09^ self compileNode: (self parse: aString)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["compileNode:", "parse:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "compile:forClass:",
+protocol: 'compiling',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._currentClass_(aClass);
+self._source_(aString);
+$1=self._compile_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compile:forClass:",{aString:aString,aClass:aClass},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "compile: aString forClass: aClass\x0a\x09self currentClass: aClass.\x0a\x09self source: aString.\x0a\x09^ self compile: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["currentClass:", "source:", "compile:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "compileExpression:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+function $DoIt(){return $globals.DoIt||(typeof DoIt=="undefined"?nil:DoIt)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._currentClass_($DoIt());
+$1=$recv("doIt ^ [ ".__comma(aString)).__comma(" ] value");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._source_($1);
+$2=self._compileNode_(self._parse_(self._source()));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileExpression:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compileExpression: aString\x0a\x09self currentClass: DoIt.\x0a\x09self source: 'doIt ^ [ ', aString, ' ] value'.\x0a\x09^ self compileNode: (self parse: self source)",
+referencedClasses: ["DoIt"],
+//>>excludeEnd("ide");
+messageSends: ["currentClass:", "source:", ",", "compileNode:", "parse:", "source"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "compileExpression:on:",
+protocol: 'compiling',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._currentClass_($recv(anObject)._class());
+$1=$recv("xxxDoIt ^ [ ".__comma(aString)).__comma(" ] value");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._source_($1);
+$2=self._compileNode_(self._parse_(self._source()));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileExpression:on:",{aString:aString,anObject:anObject},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "compileExpression: aString on: anObject\x0a\x09self currentClass: anObject class.\x0a\x09self source: 'xxxDoIt ^ [ ', aString, ' ] value'.\x0a\x09^ self compileNode: (self parse: self source)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["currentClass:", "class", "source:", ",", "compileNode:", "parse:", "source"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "compileNode:",
+protocol: 'compiling',
+fn: function (aNode){
+var self=this;
+var generator,result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+generator=$recv(self._codeGeneratorClass())._new();
+$1=generator;
+$recv($1)._source_(self._source());
+$2=$recv($1)._currentClass_(self._currentClass());
+result=$recv(generator)._compileNode_(aNode);
+self._unknownVariables_([]);
+$3=result;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileNode:",{aNode:aNode,generator:generator,result:result},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "compileNode: aNode\x0a\x09| generator result |\x0a\x09generator := self codeGeneratorClass new.\x0a\x09generator\x0a\x09\x09source: self source;\x0a\x09\x09currentClass: self currentClass.\x0a\x09result := generator compileNode: aNode.\x0a\x09self unknownVariables: #().\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "codeGeneratorClass", "source:", "source", "currentClass:", "currentClass", "compileNode:", "unknownVariables:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@currentClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currentClass\x0a\x09^ currentClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@currentClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "currentClass: aClass\x0a\x09currentClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "eval:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return eval(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"eval:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "eval: aString\x0a\x09<return eval(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "evaluateExpression:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+function $DoIt(){return $globals.DoIt||(typeof DoIt=="undefined"?nil:DoIt)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._evaluateExpression_on_(aString,$recv($DoIt())._new());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluateExpression:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "evaluateExpression: aString\x0a\x09\x22Unlike #eval: evaluate a Smalltalk expression and answer the returned object\x22\x0a\x09^ self evaluateExpression: aString on: DoIt new",
+referencedClasses: ["DoIt"],
+//>>excludeEnd("ide");
+messageSends: ["evaluateExpression:on:", "new"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "evaluateExpression:on:",
+protocol: 'compiling',
+fn: function (aString,anObject){
+var self=this;
+var result,method;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+method=self._eval_(self._compileExpression_on_(aString,anObject));
+$recv(method)._protocol_("**xxxDoIt");
+$1=$recv(anObject)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._addCompiledMethod_(method);
+result=$recv(anObject)._xxxDoIt();
+$recv($recv(anObject)._class())._removeCompiledMethod_(method);
+$2=result;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluateExpression:on:",{aString:aString,anObject:anObject,result:result,method:method},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "evaluateExpression: aString on: anObject\x0a\x09\x22Unlike #eval: evaluate a Smalltalk expression with anObject as the receiver and answer the returned object\x22\x0a\x09| result method |\x0a\x09method := self eval: (self compileExpression: aString on: anObject).\x0a\x09method protocol: '**xxxDoIt'.\x0a\x09anObject class addCompiledMethod: method.\x0a\x09result := anObject xxxDoIt.\x0a\x09anObject class removeCompiledMethod: method.\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["eval:", "compileExpression:on:", "protocol:", "addCompiledMethod:", "class", "xxxDoIt", "removeCompiledMethod:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "install:forClass:protocol:",
+protocol: 'compiling',
+fn: function (aString,aBehavior,anotherString){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($ClassBuilder())._new())._installMethod_forClass_protocol_(self._eval_(self._compile_forClass_(aString,aBehavior)),aBehavior,anotherString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"install:forClass:protocol:",{aString:aString,aBehavior:aBehavior,anotherString:anotherString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBehavior", "anotherString"],
+source: "install: aString forClass: aBehavior protocol: anotherString\x0a\x09^ ClassBuilder new\x0a\x09\x09installMethod: (self eval: (self compile: aString forClass: aBehavior))\x0a\x09\x09forClass: aBehavior\x0a\x09\x09protocol: anotherString",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["installMethod:forClass:protocol:", "new", "eval:", "compile:forClass:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "parse:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._parse_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "parse: aString\x0a\x09^ Smalltalk parse: aString",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "parseExpression:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv("doIt ^ [ ".__comma(aString)).__comma(" ] value");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$1=self._parse_($2);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parseExpression:",{aString:aString},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "parseExpression: aString\x0a\x09^ self parse: 'doIt ^ [ ', aString, ' ] value'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parse:", ","]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "recompile:",
+protocol: 'compiling',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv($recv($recv(aClass)._methodDictionary())._values())._do_displayingProgress_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._install_forClass_protocol_($recv(each)._source(),aClass,$recv(each)._protocol());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),"Recompiling ".__comma($recv(aClass)._name()));
+$1=$recv(aClass)._isMetaclass();
+if(!$core.assert($1)){
+self._recompile_($recv(aClass)._class());
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"recompile:",{aClass:aClass},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "recompile: aClass\x0a\x09aClass methodDictionary values\x0a\x09\x09do: [ :each | \x0a\x09\x09\x09self \x0a\x09\x09\x09\x09install: each source \x0a\x09\x09\x09\x09forClass: aClass \x0a\x09\x09\x09\x09protocol: each protocol ]\x0a\x09\x09displayingProgress: 'Recompiling ', aClass name.\x0a\x09aClass isMetaclass ifFalse: [ self recompile: aClass class ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:displayingProgress:", "values", "methodDictionary", "install:forClass:protocol:", "source", "protocol", ",", "name", "ifFalse:", "isMetaclass", "recompile:", "class"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "recompileAll",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($Smalltalk())._classes())._do_displayingProgress_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._recompile_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),"Compiling all classes...");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"recompileAll",{},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "recompileAll\x0a\x09Smalltalk classes \x0a\x09\x09do: [ :each | self recompile: each ]\x0a\x09\x09displayingProgress: 'Compiling all classes...'",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["do:displayingProgress:", "classes", "recompile:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@source"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1="";
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source",{},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source ifNil: [ '' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "unknownVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@unknownVariables"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "unknownVariables\x0a\x09^ unknownVariables",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+$core.addMethod(
+$core.method({
+selector: "unknownVariables:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@unknownVariables"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "unknownVariables: aCollection\x0a\x09unknownVariables := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
+
+$core.addMethod(
+$core.method({
+selector: "recompile:",
+protocol: 'compiling',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._new())._recompile_(aClass);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"recompile:",{aClass:aClass},$globals.Compiler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "recompile: aClass\x0a\x09self new recompile: aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["recompile:", "new"]
+}),
+$globals.Compiler.klass);
+
+$core.addMethod(
+$core.method({
+selector: "recompileAll",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($Smalltalk())._classes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._recompile_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"recompileAll",{},$globals.Compiler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "recompileAll\x0a\x09Smalltalk classes do: [ :each |\x0a\x09\x09self recompile: each ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["do:", "classes", "recompile:"]
+}),
+$globals.Compiler.klass);
+
+
+$core.addClass('DoIt', $globals.Object, [], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.DoIt.comment="`DoIt` is the class used to compile and evaluate expressions. See `Compiler >> evaluateExpression:`.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('Evaluator', $globals.InterfacingObject, [], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Evaluator.comment="I evaluate code against a receiver, dispatching #evaluate:on: to the receiver.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "evaluate:context:",
+protocol: 'evaluating',
+fn: function (aString,aContext){
+var self=this;
+var compiler,ast;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+function $AISemanticAnalyzer(){return $globals.AISemanticAnalyzer||(typeof AISemanticAnalyzer=="undefined"?nil:AISemanticAnalyzer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+var $early={};
+try {
+compiler=$recv($Compiler())._new();
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+ast=$recv(compiler)._parseExpression_(aString);
+return ast;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._alert_($recv(ex)._messageText());
+throw $early=[$1];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv($AISemanticAnalyzer())._on_($recv($recv(aContext)._receiver())._class());
+$recv($2)._context_(aContext);
+$3=$recv($2)._visit_(ast);
+$4=$recv(aContext)._evaluateNode_(ast);
+return $4;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:context:",{aString:aString,aContext:aContext,compiler:compiler,ast:ast},$globals.Evaluator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aContext"],
+source: "evaluate: aString context: aContext\x0a\x09\x22Similar to #evaluate:for:, with the following differences:\x0a\x09- instead of compiling and running `aString`, `aString` is interpreted using an `ASTInterpreter`\x0a\x09- instead of evaluating against a receiver, evaluate in the context of `aContext`\x22\x0a\x0a\x09| compiler ast |\x0a\x09\x0a\x09compiler := Compiler new.\x0a\x09[ ast := compiler parseExpression: aString ] \x0a\x09\x09on: Error \x0a\x09\x09do: [ :ex | ^ self alert: ex messageText ].\x0a\x09\x09\x0a\x09(AISemanticAnalyzer on: aContext receiver class)\x0a\x09\x09context: aContext;\x0a\x09\x09visit: ast.\x0a\x0a\x09^ aContext evaluateNode: ast",
+referencedClasses: ["Compiler", "Error", "AISemanticAnalyzer"],
+//>>excludeEnd("ide");
+messageSends: ["new", "on:do:", "parseExpression:", "alert:", "messageText", "context:", "on:", "class", "receiver", "visit:", "evaluateNode:"]
+}),
+$globals.Evaluator);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:for:",
+protocol: 'evaluating',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anObject)._evaluate_on_(aString,self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:for:",{aString:aString,anObject:anObject},$globals.Evaluator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "evaluate: aString for: anObject\x0a\x09^ anObject evaluate: aString on: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["evaluate:on:"]
+}),
+$globals.Evaluator);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:receiver:",
+protocol: 'evaluating',
+fn: function (aString,anObject){
+var self=this;
+var compiler;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+compiler=$recv($Compiler())._new();
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(compiler)._parseExpression_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._alert_($recv(ex)._messageText());
+throw $early=[$1];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv(compiler)._evaluateExpression_on_(aString,anObject);
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:receiver:",{aString:aString,anObject:anObject,compiler:compiler},$globals.Evaluator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "evaluate: aString receiver: anObject\x0a\x09| compiler |\x0a\x09\x0a\x09compiler := Compiler new.\x0a\x09[ compiler parseExpression: aString ] \x0a\x09\x09on: Error \x0a\x09\x09do: [ :ex | ^ self alert: ex messageText ].\x0a\x0a\x09^ compiler evaluateExpression: aString on: anObject",
+referencedClasses: ["Compiler", "Error"],
+//>>excludeEnd("ide");
+messageSends: ["new", "on:do:", "parseExpression:", "alert:", "messageText", "evaluateExpression:on:"]
+}),
+$globals.Evaluator);
+
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:for:",
+protocol: 'instance creation',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._new())._evaluate_for_(aString,anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:for:",{aString:aString,anObject:anObject},$globals.Evaluator.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "evaluate: aString for: anObject\x0a\x09^ self new evaluate: aString for: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["evaluate:for:", "new"]
+}),
+$globals.Evaluator.klass);
+
+
+$core.addClass('NodeVisitor', $globals.Object, [], 'Compiler-Core');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.NodeVisitor.comment="I am the abstract super class of all AST node visitors.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "visit:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aNode)._accept_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visit:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visit: aNode\x0a\x09^ aNode accept: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["accept:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitAll:",
+protocol: 'visiting',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aCollection)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitAll:",{aCollection:aCollection},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "visitAll: aCollection\x0a\x09^ aCollection collect: [ :each | self visit: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "visit:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitAssignmentNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitAssignmentNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitAssignmentNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitSequenceNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockSequenceNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockSequenceNode: aNode\x0a\x09^ self visitSequenceNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitSequenceNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitCascadeNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitCascadeNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitCascadeNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicArrayNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicArrayNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicArrayNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicDictionaryNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicDictionaryNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicDictionaryNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitJSStatementNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitJSStatementNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitJSStatementNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitMethodNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitMethodNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitMethodNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitAll_($recv(aNode)._nodes());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitNode: aNode\x0a\x09^ self visitAll: aNode nodes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitAll:", "nodes"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitReturnNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitReturnNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitReturnNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitSendNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSendNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSequenceNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSequenceNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitValueNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitValueNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitValueNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitVariableNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitNode_(aNode);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode},$globals.NodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitVariableNode: aNode\x0a\x09^ self visitNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitNode:"]
+}),
+$globals.NodeVisitor);
+
+
+$core.addMethod(
+$core.method({
+selector: "asVariableName",
+protocol: '*Compiler-Core',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv($recv($Smalltalk())._reservedWords())._includes_(self);
+if($core.assert($2)){
+$1=self.__comma("_");
+} else {
+$1=self;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asVariableName",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asVariableName\x0a\x09^ (Smalltalk reservedWords includes: self)\x0a\x09\x09ifTrue: [ self, '_' ]\x0a\x09\x09ifFalse: [ self ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "includes:", "reservedWords", ","]
+}),
+$globals.String);
+
+});

+ 353 - 0
bower_components/amber/src/Compiler-Core.st

@@ -0,0 +1,353 @@
+Smalltalk createPackage: 'Compiler-Core'!
+Object subclass: #AbstractCodeGenerator
+	instanceVariableNames: 'currentClass source'
+	package: 'Compiler-Core'!
+!AbstractCodeGenerator commentStamp!
+I am the abstract super class of all code generators and provide their common API.!
+
+!AbstractCodeGenerator methodsFor: 'accessing'!
+
+classNameFor: aClass
+	^ aClass isMetaclass
+		ifTrue: [ aClass instanceClass name, '.klass' ]
+		ifFalse: [
+		aClass isNil
+			ifTrue: [ 'nil' ]
+			ifFalse: [ aClass name ]]
+!
+
+currentClass
+	^ currentClass
+!
+
+currentClass: aClass
+	currentClass := aClass
+!
+
+pseudoVariables
+	^ Smalltalk pseudoVariableNames
+!
+
+source
+	^ source ifNil: [ '' ]
+!
+
+source: aString
+	source := aString
+! !
+
+!AbstractCodeGenerator methodsFor: 'compiling'!
+
+compileNode: aNode
+	self subclassResponsibility
+! !
+
+AbstractCodeGenerator subclass: #CodeGenerator
+	instanceVariableNames: ''
+	package: 'Compiler-Core'!
+!CodeGenerator commentStamp!
+I am a basic code generator. I generate a valid JavaScript output, but no not perform any inlining.
+See `InliningCodeGenerator` for an optimized JavaScript code generation.!
+
+!CodeGenerator methodsFor: 'compiling'!
+
+compileNode: aNode
+	| ir stream |
+	self semanticAnalyzer visit: aNode.
+	ir := self translator visit: aNode.
+	^ self irTranslator
+		currentClass: self currentClass;
+		visit: ir;
+		contents
+!
+
+irTranslator
+	^ IRJSTranslator new
+!
+
+semanticAnalyzer
+	^ SemanticAnalyzer on: self currentClass
+!
+
+translator
+	^ IRASTTranslator new
+		source: self source;
+		theClass: self currentClass;
+		yourself
+! !
+
+Object subclass: #Compiler
+	instanceVariableNames: 'currentClass source unknownVariables codeGeneratorClass'
+	package: 'Compiler-Core'!
+!Compiler commentStamp!
+I provide the public interface for compiling Amber source code into JavaScript.
+
+The code generator used to produce JavaScript can be plugged with `#codeGeneratorClass`.
+The default code generator is an instance of `InlinedCodeGenerator`!
+
+!Compiler methodsFor: 'accessing'!
+
+codeGeneratorClass
+	^ codeGeneratorClass ifNil: [ InliningCodeGenerator ]
+!
+
+codeGeneratorClass: aClass
+	codeGeneratorClass := aClass
+!
+
+currentClass
+	^ currentClass
+!
+
+currentClass: aClass
+	currentClass := aClass
+!
+
+source
+	^ source ifNil: [ '' ]
+!
+
+source: aString
+	source := aString
+!
+
+unknownVariables
+	^ unknownVariables
+!
+
+unknownVariables: aCollection
+	unknownVariables := aCollection
+! !
+
+!Compiler methodsFor: 'compiling'!
+
+compile: aString
+	^ self compileNode: (self parse: aString)
+!
+
+compile: aString forClass: aClass
+	self currentClass: aClass.
+	self source: aString.
+	^ self compile: aString
+!
+
+compileExpression: aString
+	self currentClass: DoIt.
+	self source: 'doIt ^ [ ', aString, ' ] value'.
+	^ self compileNode: (self parse: self source)
+!
+
+compileExpression: aString on: anObject
+	self currentClass: anObject class.
+	self source: 'xxxDoIt ^ [ ', aString, ' ] value'.
+	^ self compileNode: (self parse: self source)
+!
+
+compileNode: aNode
+	| generator result |
+	generator := self codeGeneratorClass new.
+	generator
+		source: self source;
+		currentClass: self currentClass.
+	result := generator compileNode: aNode.
+	self unknownVariables: #().
+	^ result
+!
+
+eval: aString
+	<return eval(aString)>
+!
+
+evaluateExpression: aString
+	"Unlike #eval: evaluate a Smalltalk expression and answer the returned object"
+	^ self evaluateExpression: aString on: DoIt new
+!
+
+evaluateExpression: aString on: anObject
+	"Unlike #eval: evaluate a Smalltalk expression with anObject as the receiver and answer the returned object"
+	| result method |
+	method := self eval: (self compileExpression: aString on: anObject).
+	method protocol: '**xxxDoIt'.
+	anObject class addCompiledMethod: method.
+	result := anObject xxxDoIt.
+	anObject class removeCompiledMethod: method.
+	^ result
+!
+
+install: aString forClass: aBehavior protocol: anotherString
+	^ ClassBuilder new
+		installMethod: (self eval: (self compile: aString forClass: aBehavior))
+		forClass: aBehavior
+		protocol: anotherString
+!
+
+parse: aString
+	^ Smalltalk parse: aString
+!
+
+parseExpression: aString
+	^ self parse: 'doIt ^ [ ', aString, ' ] value'
+!
+
+recompile: aClass
+	aClass methodDictionary values
+		do: [ :each | 
+			self 
+				install: each source 
+				forClass: aClass 
+				protocol: each protocol ]
+		displayingProgress: 'Recompiling ', aClass name.
+	aClass isMetaclass ifFalse: [ self recompile: aClass class ]
+!
+
+recompileAll
+	Smalltalk classes 
+		do: [ :each | self recompile: each ]
+		displayingProgress: 'Compiling all classes...'
+! !
+
+!Compiler class methodsFor: 'compiling'!
+
+recompile: aClass
+	self new recompile: aClass
+!
+
+recompileAll
+	Smalltalk classes do: [ :each |
+		self recompile: each ]
+! !
+
+Object subclass: #DoIt
+	instanceVariableNames: ''
+	package: 'Compiler-Core'!
+!DoIt commentStamp!
+`DoIt` is the class used to compile and evaluate expressions. See `Compiler >> evaluateExpression:`.!
+
+InterfacingObject subclass: #Evaluator
+	instanceVariableNames: ''
+	package: 'Compiler-Core'!
+!Evaluator commentStamp!
+I evaluate code against a receiver, dispatching #evaluate:on: to the receiver.!
+
+!Evaluator methodsFor: 'evaluating'!
+
+evaluate: aString context: aContext
+	"Similar to #evaluate:for:, with the following differences:
+	- instead of compiling and running `aString`, `aString` is interpreted using an `ASTInterpreter`
+	- instead of evaluating against a receiver, evaluate in the context of `aContext`"
+
+	| compiler ast |
+	
+	compiler := Compiler new.
+	[ ast := compiler parseExpression: aString ] 
+		on: Error 
+		do: [ :ex | ^ self alert: ex messageText ].
+		
+	(AISemanticAnalyzer on: aContext receiver class)
+		context: aContext;
+		visit: ast.
+
+	^ aContext evaluateNode: ast
+!
+
+evaluate: aString for: anObject
+	^ anObject evaluate: aString on: self
+!
+
+evaluate: aString receiver: anObject
+	| compiler |
+	
+	compiler := Compiler new.
+	[ compiler parseExpression: aString ] 
+		on: Error 
+		do: [ :ex | ^ self alert: ex messageText ].
+
+	^ compiler evaluateExpression: aString on: anObject
+! !
+
+!Evaluator class methodsFor: 'instance creation'!
+
+evaluate: aString for: anObject
+	^ self new evaluate: aString for: anObject
+! !
+
+Object subclass: #NodeVisitor
+	instanceVariableNames: ''
+	package: 'Compiler-Core'!
+!NodeVisitor commentStamp!
+I am the abstract super class of all AST node visitors.!
+
+!NodeVisitor methodsFor: 'visiting'!
+
+visit: aNode
+	^ aNode accept: self
+!
+
+visitAll: aCollection
+	^ aCollection collect: [ :each | self visit: each ]
+!
+
+visitAssignmentNode: aNode
+	^ self visitNode: aNode
+!
+
+visitBlockNode: aNode
+	^ self visitNode: aNode
+!
+
+visitBlockSequenceNode: aNode
+	^ self visitSequenceNode: aNode
+!
+
+visitCascadeNode: aNode
+	^ self visitNode: aNode
+!
+
+visitDynamicArrayNode: aNode
+	^ self visitNode: aNode
+!
+
+visitDynamicDictionaryNode: aNode
+	^ self visitNode: aNode
+!
+
+visitJSStatementNode: aNode
+	^ self visitNode: aNode
+!
+
+visitMethodNode: aNode
+	^ self visitNode: aNode
+!
+
+visitNode: aNode
+	^ self visitAll: aNode nodes
+!
+
+visitReturnNode: aNode
+	^ self visitNode: aNode
+!
+
+visitSendNode: aNode
+	^ self visitNode: aNode
+!
+
+visitSequenceNode: aNode
+	^ self visitNode: aNode
+!
+
+visitValueNode: aNode
+	^ self visitNode: aNode
+!
+
+visitVariableNode: aNode
+	^ self visitNode: aNode
+! !
+
+!String methodsFor: '*Compiler-Core'!
+
+asVariableName
+	^ (Smalltalk reservedWords includes: self)
+		ifTrue: [ self, '_' ]
+		ifFalse: [ self ]
+! !
+

+ 300 - 0
bower_components/amber/src/Compiler-Exceptions.js

@@ -0,0 +1,300 @@
+define("amber_core/Compiler-Exceptions", ["amber/boot", "amber_core/Kernel-Exceptions", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Exceptions');
+$core.packages["Compiler-Exceptions"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('CompilerError', $globals.Error, [], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.CompilerError.comment="I am the common superclass of all compiling errors.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ParseError', $globals.CompilerError, [], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ParseError.comment="Instance of ParseError are signaled on any parsing error.\x0aSee `Smalltalk >> #parse:`";
+//>>excludeEnd("ide");
+
+
+$core.addClass('SemanticError', $globals.CompilerError, [], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SemanticError.comment="I represent an abstract semantic error thrown by the SemanticAnalyzer.\x0aSemantic errors can be unknown variable errors, etc.\x0aSee my subclasses for concrete errors.\x0a\x0aThe IDE should catch instances of Semantic error to deal with them when compiling";
+//>>excludeEnd("ide");
+
+
+$core.addClass('InliningError', $globals.SemanticError, [], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.InliningError.comment="Instances of InliningError are signaled when using an `InliningCodeGenerator`in a `Compiler`.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('InvalidAssignmentError', $globals.SemanticError, ['variableName'], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.InvalidAssignmentError.comment="I get signaled when a pseudo variable gets assigned.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=" Invalid assignment to variable: ".__comma(self._variableName());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageText",{},$globals.InvalidAssignmentError)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ ' Invalid assignment to variable: ', self variableName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "variableName"]
+}),
+$globals.InvalidAssignmentError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@variableName"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "variableName\x0a\x09^ variableName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.InvalidAssignmentError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@variableName"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "variableName: aString\x0a\x09variableName := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.InvalidAssignmentError);
+
+
+
+$core.addClass('ShadowingVariableError', $globals.SemanticError, ['variableName'], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ShadowingVariableError.comment="I get signaled when a variable in a block or method scope shadows a variable of the same name in an outer scope.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("Variable shadowing error: ".__comma(self._variableName())).__comma(" is already defined");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageText",{},$globals.ShadowingVariableError)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ 'Variable shadowing error: ', self variableName, ' is already defined'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "variableName"]
+}),
+$globals.ShadowingVariableError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@variableName"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "variableName\x0a\x09^ variableName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ShadowingVariableError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@variableName"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "variableName: aString\x0a\x09variableName := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ShadowingVariableError);
+
+
+
+$core.addClass('UnknownVariableError', $globals.SemanticError, ['variableName'], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.UnknownVariableError.comment="I get signaled when a variable is not defined.\x0aThe default behavior is to allow it, as this is how Amber currently is able to seamlessly send messages to JavaScript objects.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("Unknown Variable error: ".__comma(self._variableName())).__comma(" is not defined");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageText",{},$globals.UnknownVariableError)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ 'Unknown Variable error: ', self variableName, ' is not defined'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "variableName"]
+}),
+$globals.UnknownVariableError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@variableName"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "variableName\x0a\x09^ variableName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UnknownVariableError);
+
+$core.addMethod(
+$core.method({
+selector: "variableName:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@variableName"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "variableName: aString\x0a\x09variableName := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UnknownVariableError);
+
+
+
+$core.addClass('RethrowErrorHandler', $globals.Object, [], 'Compiler-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.RethrowErrorHandler.comment="This class is used in the commandline version of the compiler.\x0aIt uses the handleError: message of ErrorHandler for printing the stacktrace and throws the error again as JS exception.\x0aAs a result Smalltalk errors are not swallowd by the Amber runtime and compilation can be aborted.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "basicSignal:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+throw anError;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicSignal:",{anError:anError},$globals.RethrowErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "basicSignal: anError\x0a        <throw anError>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.RethrowErrorHandler);
+
+$core.addMethod(
+$core.method({
+selector: "handleError:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicSignal_(anError);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"handleError:",{anError:anError},$globals.RethrowErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "handleError: anError\x0a        self basicSignal: anError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicSignal:"]
+}),
+$globals.RethrowErrorHandler);
+
+
+});

+ 109 - 0
bower_components/amber/src/Compiler-Exceptions.st

@@ -0,0 +1,109 @@
+Smalltalk createPackage: 'Compiler-Exceptions'!
+Error subclass: #CompilerError
+	instanceVariableNames: ''
+	package: 'Compiler-Exceptions'!
+!CompilerError commentStamp!
+I am the common superclass of all compiling errors.!
+
+CompilerError subclass: #ParseError
+	instanceVariableNames: ''
+	package: 'Compiler-Exceptions'!
+!ParseError commentStamp!
+Instance of ParseError are signaled on any parsing error.
+See `Smalltalk >> #parse:`!
+
+CompilerError subclass: #SemanticError
+	instanceVariableNames: ''
+	package: 'Compiler-Exceptions'!
+!SemanticError commentStamp!
+I represent an abstract semantic error thrown by the SemanticAnalyzer.
+Semantic errors can be unknown variable errors, etc.
+See my subclasses for concrete errors.
+
+The IDE should catch instances of Semantic error to deal with them when compiling!
+
+SemanticError subclass: #InliningError
+	instanceVariableNames: ''
+	package: 'Compiler-Exceptions'!
+!InliningError commentStamp!
+Instances of InliningError are signaled when using an `InliningCodeGenerator`in a `Compiler`.!
+
+SemanticError subclass: #InvalidAssignmentError
+	instanceVariableNames: 'variableName'
+	package: 'Compiler-Exceptions'!
+!InvalidAssignmentError commentStamp!
+I get signaled when a pseudo variable gets assigned.!
+
+!InvalidAssignmentError methodsFor: 'accessing'!
+
+messageText
+	^ ' Invalid assignment to variable: ', self variableName
+!
+
+variableName
+	^ variableName
+!
+
+variableName: aString
+	variableName := aString
+! !
+
+SemanticError subclass: #ShadowingVariableError
+	instanceVariableNames: 'variableName'
+	package: 'Compiler-Exceptions'!
+!ShadowingVariableError commentStamp!
+I get signaled when a variable in a block or method scope shadows a variable of the same name in an outer scope.!
+
+!ShadowingVariableError methodsFor: 'accessing'!
+
+messageText
+	^ 'Variable shadowing error: ', self variableName, ' is already defined'
+!
+
+variableName
+	^ variableName
+!
+
+variableName: aString
+	variableName := aString
+! !
+
+SemanticError subclass: #UnknownVariableError
+	instanceVariableNames: 'variableName'
+	package: 'Compiler-Exceptions'!
+!UnknownVariableError commentStamp!
+I get signaled when a variable is not defined.
+The default behavior is to allow it, as this is how Amber currently is able to seamlessly send messages to JavaScript objects.!
+
+!UnknownVariableError methodsFor: 'accessing'!
+
+messageText
+	^ 'Unknown Variable error: ', self variableName, ' is not defined'
+!
+
+variableName
+	^ variableName
+!
+
+variableName: aString
+	variableName := aString
+! !
+
+Object subclass: #RethrowErrorHandler
+	instanceVariableNames: ''
+	package: 'Compiler-Exceptions'!
+!RethrowErrorHandler commentStamp!
+This class is used in the commandline version of the compiler.
+It uses the handleError: message of ErrorHandler for printing the stacktrace and throws the error again as JS exception.
+As a result Smalltalk errors are not swallowd by the Amber runtime and compilation can be aborted.!
+
+!RethrowErrorHandler methodsFor: 'error handling'!
+
+basicSignal: anError
+        <throw anError>
+!
+
+handleError: anError
+        self basicSignal: anError
+! !
+

+ 6152 - 0
bower_components/amber/src/Compiler-IR.js

@@ -0,0 +1,6152 @@
+define("amber_core/Compiler-IR", ["amber/boot", "amber_core/Compiler-Core", "amber_core/Kernel-Objects", "amber_core/Kernel-Methods"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-IR');
+$core.packages["Compiler-IR"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('IRASTTranslator', $globals.NodeVisitor, ['source', 'theClass', 'method', 'sequence', 'nextAlias'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRASTTranslator.comment="I am the AST (abstract syntax tree) visitor responsible for building the intermediate representation graph.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "alias:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var variable;
+function $IRVariable(){return $globals.IRVariable||(typeof IRVariable=="undefined"?nil:IRVariable)}
+function $AliasVar(){return $globals.AliasVar||(typeof AliasVar=="undefined"?nil:AliasVar)}
+function $IRAssignment(){return $globals.IRAssignment||(typeof IRAssignment=="undefined"?nil:IRAssignment)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$6,$5,$7,$8,$10,$11,$9,$12;
+$1=$recv(aNode)._isImmutable();
+if($core.assert($1)){
+$2=self._visit_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $2;
+};
+$3=$recv($IRVariable())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$4=$3;
+$6=$recv($AliasVar())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._name_("$".__comma(self._nextAlias()));
+$recv($4)._variable_($5);
+$7=$recv($3)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+variable=$7;
+$8=self._sequence();
+$10=$recv($IRAssignment())._new();
+$recv($10)._add_(variable);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+$recv($10)._add_(self._visit_(aNode));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=3;
+//>>excludeEnd("ctx");
+$11=$recv($10)._yourself();
+$9=$11;
+$recv($8)._add_($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(self._method())._internalVariables())._add_(variable);
+$12=variable;
+return $12;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias:",{aNode:aNode,variable:variable},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "alias: aNode\x0a\x09| variable |\x0a\x0a\x09aNode isImmutable ifTrue: [ ^ self visit: aNode ].\x0a\x0a\x09variable := IRVariable new\x0a\x09\x09variable: (AliasVar new name: '$', self nextAlias);\x0a\x09\x09yourself.\x0a\x0a\x09self sequence add: (IRAssignment new\x0a\x09\x09add: variable;\x0a\x09\x09add: (self visit: aNode);\x0a\x09\x09yourself).\x0a\x0a\x09self method internalVariables add: variable.\x0a\x0a\x09^ variable",
+referencedClasses: ["IRVariable", "AliasVar", "IRAssignment"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isImmutable", "visit:", "variable:", "new", "name:", ",", "nextAlias", "yourself", "add:", "sequence", "internalVariables", "method"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "aliasTemporally:",
+protocol: 'visiting',
+fn: function (aCollection){
+var self=this;
+var threshold,result;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3,$5;
+threshold=(0);
+$recv(aCollection)._withIndexDo_((function(each,i){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(each)._subtreeNeedsAliasing();
+if($core.assert($1)){
+threshold=i;
+return threshold;
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,i:i},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["withIndexDo:"]=1;
+//>>excludeEnd("ctx");
+result=$recv($OrderedCollection())._new();
+$recv(aCollection)._withIndexDo_((function(each,i){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=result;
+$4=$recv(i).__lt_eq(threshold);
+if($core.assert($4)){
+$3=self._alias_(each);
+} else {
+$3=self._visit_(each);
+};
+return $recv($2)._add_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,i:i},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$5=result;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"aliasTemporally:",{aCollection:aCollection,threshold:threshold,result:result},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "aliasTemporally: aCollection\x0a\x09\x22https://github.com/NicolasPetton/amber/issues/296\x0a\x09\x0a\x09If a node is aliased, all preceding ones are aliased as well.\x0a\x09The tree is iterated twice. First we get the aliasing dependency,\x0a\x09then the aliasing itself is done\x22\x0a\x0a\x09| threshold result |\x0a\x09threshold := 0.\x0a\x09\x0a\x09aCollection withIndexDo: [ :each :i |\x0a\x09\x09each subtreeNeedsAliasing\x0a\x09\x09\x09ifTrue: [ threshold := i ] ].\x0a\x0a\x09result := OrderedCollection new.\x0a\x09aCollection withIndexDo: [ :each :i |\x0a\x09\x09result add: (i <= threshold\x0a\x09\x09\x09ifTrue: [ self alias: each ]\x0a\x09\x09\x09ifFalse: [ self visit: each ]) ].\x0a\x0a\x09^ result",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["withIndexDo:", "ifTrue:", "subtreeNeedsAliasing", "new", "add:", "ifTrue:ifFalse:", "<=", "alias:", "visit:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@method"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ method",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "method:",
+protocol: 'accessing',
+fn: function (anIRMethod){
+var self=this;
+self["@method"]=anIRMethod;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRMethod"],
+source: "method: anIRMethod\x0a\x09method := anIRMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "nextAlias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=self["@nextAlias"];
+if(($receiver = $1) == null || $receiver.isNil){
+self["@nextAlias"]=(0);
+self["@nextAlias"];
+} else {
+$1;
+};
+self["@nextAlias"]=$recv(self["@nextAlias"]).__plus((1));
+$2=$recv(self["@nextAlias"])._asString();
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextAlias",{},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextAlias\x0a\x09nextAlias ifNil: [ nextAlias := 0 ].\x0a\x09nextAlias := nextAlias + 1.\x0a\x09^ nextAlias asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "+", "asString"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "sequence",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@sequence"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sequence\x0a\x09^ sequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "sequence:",
+protocol: 'accessing',
+fn: function (anIRSequence){
+var self=this;
+self["@sequence"]=anIRSequence;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSequence"],
+source: "sequence: anIRSequence\x0a\x09sequence := anIRSequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@source"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitAssignmentNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var left,right,assignment;
+function $IRAssignment(){return $globals.IRAssignment||(typeof IRAssignment=="undefined"?nil:IRAssignment)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$4,$2,$5;
+right=self._visit_($recv(aNode)._right());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+left=self._visit_($recv(aNode)._left());
+$1=self._sequence();
+$3=$recv($IRAssignment())._new();
+$recv($3)._add_(left);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+$recv($3)._add_(right);
+$4=$recv($3)._yourself();
+$2=$4;
+$recv($1)._add_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$5=left;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitAssignmentNode:",{aNode:aNode,left:left,right:right,assignment:assignment},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitAssignmentNode: aNode\x0a\x09| left right assignment |\x0a\x09right := self visit: aNode right.\x0a\x09left := self visit: aNode left.\x0a\x09self sequence add: (IRAssignment new\x0a\x09\x09add: left;\x0a\x09\x09add: right;\x0a\x09\x09yourself).\x0a\x09^ left",
+referencedClasses: ["IRAssignment"],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "right", "left", "add:", "sequence", "new", "yourself"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var closure;
+function $IRClosure(){return $globals.IRClosure||(typeof IRClosure=="undefined"?nil:IRClosure)}
+function $IRTempDeclaration(){return $globals.IRTempDeclaration||(typeof IRTempDeclaration=="undefined"?nil:IRTempDeclaration)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$6,$5,$7,$8,$9;
+$1=$recv($IRClosure())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._arguments_($recv(aNode)._parameters());
+$recv($1)._requiresSmalltalkContext_($recv(aNode)._requiresSmalltalkContext());
+$2=$1;
+$3=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._scope_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($1)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+closure=$4;
+$6=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._temps();
+$recv($5)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$7=$recv($IRTempDeclaration())._new();
+$recv($7)._name_($recv(each)._name());
+$recv($7)._scope_($recv(aNode)._scope());
+$8=$recv($7)._yourself();
+return $recv(closure)._add_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(closure)._add_(self._visit_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$9=closure;
+return $9;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode,closure:closure},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockNode: aNode\x0a\x09| closure |\x0a\x09closure := IRClosure new\x0a\x09\x09arguments: aNode parameters;\x0a\x09\x09requiresSmalltalkContext: aNode requiresSmalltalkContext;\x0a\x09\x09scope: aNode scope;\x0a\x09\x09yourself.\x0a\x09aNode scope temps do: [ :each |\x0a\x09\x09closure add: (IRTempDeclaration new\x0a\x09\x09\x09name: each name;\x0a\x09\x09\x09scope: aNode scope;\x0a\x09\x09\x09yourself) ].\x0a\x09aNode nodes do: [ :each | closure add: (self visit: each) ].\x0a\x09^ closure",
+referencedClasses: ["IRClosure", "IRTempDeclaration"],
+//>>excludeEnd("ide");
+messageSends: ["arguments:", "new", "parameters", "requiresSmalltalkContext:", "requiresSmalltalkContext", "scope:", "scope", "yourself", "do:", "temps", "add:", "name:", "name", "nodes", "visit:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRBlockSequence(){return $globals.IRBlockSequence||(typeof IRBlockSequence=="undefined"?nil:IRBlockSequence)}
+function $IRBlockReturn(){return $globals.IRBlockReturn||(typeof IRBlockReturn=="undefined"?nil:IRBlockReturn)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$5,$4,$6,$7,$10,$9,$8,$11,$13,$14,$17,$16,$15,$18,$12,$1;
+$2=$recv($IRBlockSequence())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$1=self._withSequence_do_($2,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+return $recv($3)._ifNotEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$5=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nodes"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($5)._allButLast();
+$recv($4)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$6=self._sequence();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["sequence"]=1;
+//>>excludeEnd("ctx");
+$7=self._visitOrAlias_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["visitOrAlias:"]=1;
+//>>excludeEnd("ctx");
+return $recv($6)._add_($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({each:each},$ctx3,3)});
+//>>excludeEnd("ctx");
+}));
+$10=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nodes"]=3;
+//>>excludeEnd("ctx");
+$9=$recv($10)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+$8=$recv($9)._isReturnNode();
+if($core.assert($8)){
+return $recv(self._sequence())._add_(self._visitOrAlias_($recv($recv(aNode)._nodes())._last()));
+} else {
+$11=self._sequence();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["sequence"]=2;
+//>>excludeEnd("ctx");
+$13=$recv($IRBlockReturn())._new();
+$14=$13;
+$17=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nodes"]=4;
+//>>excludeEnd("ctx");
+$16=$recv($17)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["last"]=2;
+//>>excludeEnd("ctx");
+$15=self._visitOrAlias_($16);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["visitOrAlias:"]=2;
+//>>excludeEnd("ctx");
+$recv($14)._add_($15);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["add:"]=3;
+//>>excludeEnd("ctx");
+$18=$recv($13)._yourself();
+$12=$18;
+return $recv($11)._add_($12);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockSequenceNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockSequenceNode: aNode\x0a\x09^ self\x0a\x09\x09withSequence: IRBlockSequence new\x0a\x09\x09do: [\x0a\x09\x09\x09aNode nodes ifNotEmpty: [\x0a\x09\x09\x09\x09aNode nodes allButLast do: [ :each |\x0a\x09\x09\x09\x09\x09self sequence add: (self visitOrAlias: each) ].\x0a\x09\x09\x09\x09aNode nodes last isReturnNode\x0a\x09\x09\x09\x09\x09ifFalse: [ self sequence add: (IRBlockReturn new add: (self visitOrAlias: aNode nodes last); yourself) ]\x0a\x09\x09\x09\x09\x09ifTrue: [ self sequence add: (self visitOrAlias: aNode nodes last) ] ]]",
+referencedClasses: ["IRBlockSequence", "IRBlockReturn"],
+//>>excludeEnd("ide");
+messageSends: ["withSequence:do:", "new", "ifNotEmpty:", "nodes", "do:", "allButLast", "add:", "sequence", "visitOrAlias:", "ifFalse:ifTrue:", "isReturnNode", "last", "yourself"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitCascadeNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var alias,receiver;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$5,$4,$6;
+$2=$recv(aNode)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isImmutable();
+if($core.assert($1)){
+receiver=$recv(aNode)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=2;
+//>>excludeEnd("ctx");
+receiver;
+} else {
+alias=self._alias_($recv(aNode)._receiver());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias:"]=1;
+//>>excludeEnd("ctx");
+alias;
+receiver=$recv($recv($VariableNode())._new())._binding_($recv(alias)._variable());
+receiver;
+};
+$3=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._receiver_(receiver);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($5)._allButLast();
+$recv($4)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._sequence())._add_(self._visit_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+$6=self._alias_($recv($recv(aNode)._nodes())._last());
+return $6;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitCascadeNode:",{aNode:aNode,alias:alias,receiver:receiver},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitCascadeNode: aNode\x0a\x09| alias receiver |\x0a\x0a\x09aNode receiver isImmutable \x0a\x09\x09ifTrue: [ receiver := aNode receiver ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09alias := self alias: aNode receiver.\x0a\x09\x09\x09receiver := VariableNode new binding: alias variable ].\x0a\x09\x0a\x09aNode nodes do: [ :each |\x0a\x09\x09\x09each receiver: receiver ].\x0a\x0a\x09aNode nodes allButLast do: [ :each |\x0a\x09\x09self sequence add: (self visit: each) ].\x0a\x0a\x09^ self alias: aNode nodes last",
+referencedClasses: ["VariableNode"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isImmutable", "receiver", "alias:", "binding:", "new", "variable", "do:", "nodes", "receiver:", "allButLast", "add:", "sequence", "visit:", "last"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicArrayNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var array;
+function $IRDynamicArray(){return $globals.IRDynamicArray||(typeof IRDynamicArray=="undefined"?nil:IRDynamicArray)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+array=$recv($IRDynamicArray())._new();
+$recv(self._aliasTemporally_($recv(aNode)._nodes()))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(array)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=array;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicArrayNode:",{aNode:aNode,array:array},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicArrayNode: aNode\x0a\x09| array |\x0a\x09array := IRDynamicArray new.\x0a\x09(self aliasTemporally: aNode nodes) do: [ :each | array add: each ].\x0a\x09^ array",
+referencedClasses: ["IRDynamicArray"],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "aliasTemporally:", "nodes", "add:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicDictionaryNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var dictionary;
+function $IRDynamicDictionary(){return $globals.IRDynamicDictionary||(typeof IRDynamicDictionary=="undefined"?nil:IRDynamicDictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+dictionary=$recv($IRDynamicDictionary())._new();
+$recv(self._aliasTemporally_($recv(aNode)._nodes()))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(dictionary)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=dictionary;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicDictionaryNode:",{aNode:aNode,dictionary:dictionary},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicDictionaryNode: aNode\x0a\x09| dictionary |\x0a\x09dictionary := IRDynamicDictionary new.\x0a\x09(self aliasTemporally: aNode nodes) do: [ :each | dictionary add: each ].\x0a\x09^ dictionary",
+referencedClasses: ["IRDynamicDictionary"],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "aliasTemporally:", "nodes", "add:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitJSStatementNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRVerbatim(){return $globals.IRVerbatim||(typeof IRVerbatim=="undefined"?nil:IRVerbatim)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRVerbatim())._new();
+$recv($2)._source_($recv($recv(aNode)._source())._crlfSanitized());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitJSStatementNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitJSStatementNode: aNode\x0a\x09^ IRVerbatim new\x0a\x09\x09source: aNode source crlfSanitized;\x0a\x09\x09yourself",
+referencedClasses: ["IRVerbatim"],
+//>>excludeEnd("ide");
+messageSends: ["source:", "new", "crlfSanitized", "source", "yourself"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitMethodNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRMethod(){return $globals.IRMethod||(typeof IRMethod=="undefined"?nil:IRMethod)}
+function $IRTempDeclaration(){return $globals.IRTempDeclaration||(typeof IRTempDeclaration=="undefined"?nil:IRTempDeclaration)}
+function $IRReturn(){return $globals.IRReturn||(typeof IRReturn=="undefined"?nil:IRReturn)}
+function $IRVariable(){return $globals.IRVariable||(typeof IRVariable=="undefined"?nil:IRVariable)}
+function $IRVerbatim(){return $globals.IRVerbatim||(typeof IRVerbatim=="undefined"?nil:IRVerbatim)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$5,$1,$7,$6,$8,$10,$11,$12,$13,$9,$14,$16,$15,$17,$18,$20,$21,$23,$24,$22,$25,$19,$27,$28,$26,$29;
+$2=$recv($IRMethod())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._source_($recv(self._source())._crlfSanitized());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["source:"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._theClass_(self._theClass());
+$recv($2)._arguments_($recv(aNode)._arguments());
+$recv($2)._selector_($recv(aNode)._selector());
+$recv($2)._sendIndexes_($recv(aNode)._sendIndexes());
+$recv($2)._superSends_($recv(aNode)._superSends());
+$recv($2)._requiresSmalltalkContext_($recv(aNode)._requiresSmalltalkContext());
+$recv($2)._classReferences_($recv(aNode)._classReferences());
+$3=$2;
+$4=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._scope_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope:"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($2)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$1=$5;
+self._method_($1);
+$7=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._temps();
+$recv($6)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$8=self._method();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["method"]=1;
+//>>excludeEnd("ctx");
+$10=$recv($IRTempDeclaration())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$recv($10)._name_($recv(each)._name());
+$11=$10;
+$12=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["scope"]=3;
+//>>excludeEnd("ctx");
+$recv($11)._scope_($12);
+$13=$recv($10)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["yourself"]=2;
+//>>excludeEnd("ctx");
+$9=$13;
+return $recv($8)._add_($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$14=self._method();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["method"]=2;
+//>>excludeEnd("ctx");
+return $recv($14)._add_(self._visit_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$16=$recv(aNode)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=4;
+//>>excludeEnd("ctx");
+$15=$recv($16)._hasLocalReturn();
+if(!$core.assert($15)){
+$17=self._method();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["method"]=3;
+//>>excludeEnd("ctx");
+$18=$17;
+$20=$recv($IRReturn())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=3;
+//>>excludeEnd("ctx");
+$21=$20;
+$23=$recv($IRVariable())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=4;
+//>>excludeEnd("ctx");
+$recv($23)._variable_($recv($recv($recv(aNode)._scope())._pseudoVars())._at_("self"));
+$24=$recv($23)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=3;
+//>>excludeEnd("ctx");
+$22=$24;
+$recv($21)._add_($22);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=4;
+//>>excludeEnd("ctx");
+$25=$recv($20)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=4;
+//>>excludeEnd("ctx");
+$19=$25;
+$recv($18)._add_($19);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=3;
+//>>excludeEnd("ctx");
+$27=$recv($IRVerbatim())._new();
+$recv($27)._source_("");
+$28=$recv($27)._yourself();
+$26=$recv($17)._add_($28);
+$26;
+};
+$29=self._method();
+return $29;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitMethodNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitMethodNode: aNode\x0a\x0a\x09self method: (IRMethod new\x0a\x09\x09source: self source crlfSanitized;\x0a\x09\x09theClass: self theClass;\x0a\x09\x09arguments: aNode arguments;\x0a\x09\x09selector: aNode selector;\x0a\x09\x09sendIndexes: aNode sendIndexes;\x0a\x09\x09superSends: aNode superSends;\x0a\x09\x09requiresSmalltalkContext: aNode requiresSmalltalkContext;\x0a\x09\x09classReferences: aNode classReferences;\x0a\x09\x09scope: aNode scope;\x0a\x09\x09yourself).\x0a\x0a\x09aNode scope temps do: [ :each |\x0a\x09\x09self method add: (IRTempDeclaration new\x0a\x09\x09\x09name: each name;\x0a\x09\x09\x09scope: aNode scope;\x0a\x09\x09\x09yourself) ].\x0a\x0a\x09aNode nodes do: [ :each | self method add: (self visit: each) ].\x0a\x0a\x09aNode scope hasLocalReturn ifFalse: [self method\x0a\x09\x09add: (IRReturn new\x0a\x09\x09\x09add: (IRVariable new\x0a\x09\x09\x09\x09variable: (aNode scope pseudoVars at: 'self');\x0a\x09\x09\x09\x09yourself);\x0a\x09\x09\x09yourself);\x0a\x09\x09add: (IRVerbatim new source: ''; yourself) ].\x0a\x0a\x09^ self method",
+referencedClasses: ["IRMethod", "IRTempDeclaration", "IRReturn", "IRVariable", "IRVerbatim"],
+//>>excludeEnd("ide");
+messageSends: ["method:", "source:", "new", "crlfSanitized", "source", "theClass:", "theClass", "arguments:", "arguments", "selector:", "selector", "sendIndexes:", "sendIndexes", "superSends:", "superSends", "requiresSmalltalkContext:", "requiresSmalltalkContext", "classReferences:", "classReferences", "scope:", "scope", "yourself", "do:", "temps", "add:", "method", "name:", "name", "nodes", "visit:", "ifFalse:", "hasLocalReturn", "variable:", "at:", "pseudoVars"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitOrAlias:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(aNode)._shouldBeAliased();
+if($core.assert($2)){
+$1=self._alias_(aNode);
+} else {
+$1=self._visit_(aNode);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitOrAlias:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitOrAlias: aNode\x0a\x09^ aNode shouldBeAliased\x0a\x09\x09ifTrue: [ self alias: aNode ]\x0a\x09\x09ifFalse: [ self visit: aNode ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "shouldBeAliased", "alias:", "visit:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitReturnNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var return_;
+function $IRNonLocalReturn(){return $globals.IRNonLocalReturn||(typeof IRNonLocalReturn=="undefined"?nil:IRNonLocalReturn)}
+function $IRReturn(){return $globals.IRReturn||(typeof IRReturn=="undefined"?nil:IRReturn)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(aNode)._nonLocalReturn();
+if($core.assert($1)){
+return_=$recv($IRNonLocalReturn())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+} else {
+return_=$recv($IRReturn())._new();
+};
+$recv(return_)._scope_($recv(aNode)._scope());
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(return_)._add_(self._alias_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$2=return_;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitReturnNode:",{aNode:aNode,return_:return_},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitReturnNode: aNode\x0a\x09| return |\x0a\x09return := aNode nonLocalReturn\x0a\x09\x09ifTrue: [ IRNonLocalReturn new ]\x0a\x09\x09ifFalse: [ IRReturn new ].\x0a\x09return scope: aNode scope.\x0a\x09aNode nodes do: [ :each |\x0a\x09\x09return add: (self alias: each) ].\x0a\x09^ return",
+referencedClasses: ["IRNonLocalReturn", "IRReturn"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "nonLocalReturn", "new", "scope:", "scope", "do:", "nodes", "add:", "alias:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitSendNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var send,all,receiver,arguments_;
+function $IRSend(){return $globals.IRSend||(typeof IRSend=="undefined"?nil:IRSend)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+send=$recv($IRSend())._new();
+$1=send;
+$recv($1)._selector_($recv(aNode)._selector());
+$2=$recv($1)._index_($recv(aNode)._index());
+$3=$recv(aNode)._superSend();
+if($core.assert($3)){
+$recv(send)._classSend_($recv(self._theClass())._superclass());
+};
+all=self._aliasTemporally_($recv([$recv(aNode)._receiver()]).__comma($recv(aNode)._arguments()));
+receiver=$recv(all)._first();
+arguments_=$recv(all)._allButFirst();
+$recv(send)._add_(receiver);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv(arguments_)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(send)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$4=send;
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode,send:send,all:all,receiver:receiver,arguments_:arguments_},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSendNode: aNode\x0a\x09| send all receiver arguments |\x0a\x09send := IRSend new.\x0a\x09send\x0a\x09\x09selector: aNode selector;\x0a\x09\x09index: aNode index.\x0a\x09aNode superSend ifTrue: [ send classSend: self theClass superclass ].\x0a\x09\x0a\x09all := self aliasTemporally: { aNode receiver }, aNode arguments.\x0a\x09receiver := all first.\x0a\x09arguments := all allButFirst.\x0a\x0a\x09send add: receiver.\x0a\x09arguments do: [ :each | send add: each ].\x0a\x0a\x09^ send",
+referencedClasses: ["IRSend"],
+//>>excludeEnd("ide");
+messageSends: ["new", "selector:", "selector", "index:", "index", "ifTrue:", "superSend", "classSend:", "superclass", "theClass", "aliasTemporally:", ",", "receiver", "arguments", "first", "allButFirst", "add:", "do:"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRSequence(){return $globals.IRSequence||(typeof IRSequence=="undefined"?nil:IRSequence)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=self._withSequence_do_($recv($IRSequence())._new(),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(aNode)._nodes())._do_((function(each){
+var instruction;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+instruction=self._visitOrAlias_(each);
+instruction;
+$2=$recv(instruction)._isVariable();
+if(!$core.assert($2)){
+return $recv(self._sequence())._add_(instruction);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each,instruction:instruction},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSequenceNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSequenceNode: aNode\x0a\x09^ self\x0a\x09\x09withSequence: IRSequence new\x0a\x09\x09do: [\x0a\x09\x09\x09aNode nodes do: [ :each | | instruction |\x0a\x09\x09\x09\x09instruction := self visitOrAlias: each.\x0a\x09\x09\x09\x09instruction isVariable ifFalse: [\x0a\x09\x09\x09\x09\x09self sequence add: instruction ] ]]",
+referencedClasses: ["IRSequence"],
+//>>excludeEnd("ide");
+messageSends: ["withSequence:do:", "new", "do:", "nodes", "visitOrAlias:", "ifFalse:", "isVariable", "add:", "sequence"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitValueNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRValue(){return $globals.IRValue||(typeof IRValue=="undefined"?nil:IRValue)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRValue())._new();
+$recv($2)._value_($recv(aNode)._value());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitValueNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitValueNode: aNode\x0a\x09^ IRValue new\x0a\x09\x09value: aNode value;\x0a\x09\x09yourself",
+referencedClasses: ["IRValue"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "new", "value", "yourself"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitVariableNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $IRVariable(){return $globals.IRVariable||(typeof IRVariable=="undefined"?nil:IRVariable)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRVariable())._new();
+$recv($2)._variable_($recv(aNode)._binding());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitVariableNode: aNode\x0a\x09^ IRVariable new\x0a\x09\x09variable: aNode binding;\x0a\x09\x09yourself",
+referencedClasses: ["IRVariable"],
+//>>excludeEnd("ide");
+messageSends: ["variable:", "new", "binding", "yourself"]
+}),
+$globals.IRASTTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "withSequence:do:",
+protocol: 'accessing',
+fn: function (aSequence,aBlock){
+var self=this;
+var outerSequence;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+outerSequence=self._sequence();
+self._sequence_(aSequence);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["sequence:"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+self._sequence_(outerSequence);
+return aSequence;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withSequence:do:",{aSequence:aSequence,aBlock:aBlock,outerSequence:outerSequence},$globals.IRASTTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSequence", "aBlock"],
+source: "withSequence: aSequence do: aBlock\x0a\x09| outerSequence |\x0a\x09outerSequence := self sequence.\x0a\x09self sequence: aSequence.\x0a\x09aBlock value.\x0a\x09self sequence: outerSequence.\x0a\x09^ aSequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sequence", "sequence:", "value"]
+}),
+$globals.IRASTTranslator);
+
+
+
+$core.addClass('IRInstruction', $globals.Object, ['parent', 'instructions'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInstruction.comment="I am the abstract root class of the IR (intermediate representation) instructions class hierarchy.\x0aThe IR graph is used to emit JavaScript code using a JSStream.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRInstruction_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRInstruction: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'building',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(anObject)._parent_(self);
+$1=$recv(self._instructions())._add_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anObject:anObject},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "add: anObject\x0a\x09anObject parent: self.\x0a\x09^ self instructions add: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parent:", "add:", "instructions"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "canBeAssigned",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "canBeAssigned\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "instructions",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@instructions"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@instructions"]=$recv($OrderedCollection())._new();
+$1=self["@instructions"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instructions",{},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "instructions\x0a\x09^ instructions ifNil: [ instructions := OrderedCollection new ]",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isClosure",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClosure\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isLocalReturn\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isMethod",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMethod\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isReturn\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isSend",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSend\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isSequence",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSequence\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isTempDeclaration",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTempDeclaration\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "isVariable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isVariable\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._parent())._method();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"method",{},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ self parent method",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["method", "parent"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "needsBoxingAsReceiver",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "needsBoxingAsReceiver\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "parent",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@parent"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "parent\x0a\x09^ parent",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "parent:",
+protocol: 'accessing',
+fn: function (anIRInstruction){
+var self=this;
+self["@parent"]=anIRInstruction;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "parent: anIRInstruction\x0a\x09parent := anIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "remove",
+protocol: 'building',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._parent())._remove_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove",{},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "remove\x0a\x09self parent remove: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:", "parent"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "remove:",
+protocol: 'building',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._instructions())._remove_(anIRInstruction);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:",{anIRInstruction:anIRInstruction},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "remove: anIRInstruction\x0a\x09self instructions remove: anIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:", "instructions"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "replace:with:",
+protocol: 'building',
+fn: function (anIRInstruction,anotherIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(anotherIRInstruction)._parent_(self);
+$1=self._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._at_put_($recv(self._instructions())._indexOf_(anIRInstruction),anotherIRInstruction);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"replace:with:",{anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction", "anotherIRInstruction"],
+source: "replace: anIRInstruction with: anotherIRInstruction\x0a\x09anotherIRInstruction parent: self.\x0a\x09self instructions\x0a\x09\x09at: (self instructions indexOf: anIRInstruction)\x0a\x09\x09put: anotherIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parent:", "at:put:", "instructions", "indexOf:"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "replaceWith:",
+protocol: 'building',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._parent())._replace_with_(self,anIRInstruction);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"replaceWith:",{anIRInstruction:anIRInstruction},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "replaceWith: anIRInstruction\x0a\x09self parent replace: self with: anIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["replace:with:", "parent"]
+}),
+$globals.IRInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._parent();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+var node;
+node=$receiver;
+$1=$recv(node)._scope();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scope",{},$globals.IRInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ self parent ifNotNil: [ :node | \x0a\x09\x09node scope ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "parent", "scope"]
+}),
+$globals.IRInstruction);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aBuilder){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._builder_(aBuilder);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aBuilder:aBuilder},$globals.IRInstruction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBuilder"],
+source: "on: aBuilder\x0a\x09^ self new\x0a\x09\x09builder: aBuilder;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["builder:", "new", "yourself"]
+}),
+$globals.IRInstruction.klass);
+
+
+$core.addClass('IRAssignment', $globals.IRInstruction, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRAssignment_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRAssignment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRAssignment: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRAssignment:"]
+}),
+$globals.IRAssignment);
+
+
+
+$core.addClass('IRDynamicArray', $globals.IRInstruction, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRDynamicArray_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRDynamicArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRDynamicArray: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRDynamicArray:"]
+}),
+$globals.IRDynamicArray);
+
+
+
+$core.addClass('IRDynamicDictionary', $globals.IRInstruction, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRDynamicDictionary_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRDynamicDictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRDynamicDictionary: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRDynamicDictionary:"]
+}),
+$globals.IRDynamicDictionary);
+
+
+
+$core.addClass('IRScopedInstruction', $globals.IRInstruction, ['scope'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRScopedInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aScope){
+var self=this;
+self["@scope"]=aScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "scope: aScope\x0a\x09scope := aScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRScopedInstruction);
+
+
+
+$core.addClass('IRClosureInstruction', $globals.IRScopedInstruction, ['arguments', 'requiresSmalltalkContext'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@arguments"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=[];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.IRClosureInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ arguments ifNil: [ #() ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "arguments:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@arguments"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "arguments: aCollection\x0a\x09arguments := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "locals",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv(self._arguments())._copy();
+$recv($2)._addAll_($recv(self._tempDeclarations())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})));
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"locals",{},$globals.IRClosureInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "locals\x0a\x09^ self arguments copy\x0a\x09\x09addAll: (self tempDeclarations collect: [ :each | each name ]);\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "copy", "arguments", "collect:", "tempDeclarations", "name", "yourself"]
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "requiresSmalltalkContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@requiresSmalltalkContext"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"requiresSmalltalkContext",{},$globals.IRClosureInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "requiresSmalltalkContext\x0a\x09^ requiresSmalltalkContext ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "requiresSmalltalkContext:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@requiresSmalltalkContext"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "requiresSmalltalkContext: anObject\x0a\x09requiresSmalltalkContext := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aScope){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRClosureInstruction.superclass.fn.prototype._scope_.apply($recv(self), [aScope]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aScope)._instruction_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scope:",{aScope:aScope},$globals.IRClosureInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "scope: aScope\x0a\x09super scope: aScope.\x0a\x09aScope instruction: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["scope:", "instruction:"]
+}),
+$globals.IRClosureInstruction);
+
+$core.addMethod(
+$core.method({
+selector: "tempDeclarations",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._instructions())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._isTempDeclaration();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tempDeclarations",{},$globals.IRClosureInstruction)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tempDeclarations\x0a\x09^ self instructions select: [ :each |\x0a\x09\x09each isTempDeclaration ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["select:", "instructions", "isTempDeclaration"]
+}),
+$globals.IRClosureInstruction);
+
+
+
+$core.addClass('IRClosure', $globals.IRClosureInstruction, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRClosure_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRClosure: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRClosure:"]
+}),
+$globals.IRClosure);
+
+$core.addMethod(
+$core.method({
+selector: "isClosure",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClosure\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRClosure);
+
+$core.addMethod(
+$core.method({
+selector: "sequence",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._instructions())._last();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sequence",{},$globals.IRClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sequence\x0a\x09^ self instructions last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["last", "instructions"]
+}),
+$globals.IRClosure);
+
+
+
+$core.addClass('IRMethod', $globals.IRClosureInstruction, ['theClass', 'source', 'selector', 'classReferences', 'sendIndexes', 'superSends', 'requiresSmalltalkContext', 'internalVariables'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRMethod.comment="I am a method instruction";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRMethod_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRMethod: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRMethod:"]
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "classReferences",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@classReferences"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classReferences\x0a\x09^ classReferences",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "classReferences:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@classReferences"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "classReferences: aCollection\x0a\x09classReferences := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "internalVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@internalVariables"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@internalVariables"]=$recv($Set())._new();
+$1=self["@internalVariables"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"internalVariables",{},$globals.IRMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "internalVariables\x0a\x09^ internalVariables ifNil: [ internalVariables := Set new ]",
+referencedClasses: ["Set"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "isMethod",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMethod\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "messageSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._sendIndexes())._keys();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageSends",{},$globals.IRMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageSends\x0a\x09^ self sendIndexes keys",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keys", "sendIndexes"]
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@sendIndexes"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sendIndexes\x0a\x09^ sendIndexes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes:",
+protocol: 'accessing',
+fn: function (aDictionary){
+var self=this;
+self["@sendIndexes"]=aDictionary;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDictionary"],
+source: "sendIndexes: aDictionary\x0a\x09sendIndexes := aDictionary",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@source"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "superSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@superSends"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "superSends\x0a\x09^ superSends",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "superSends:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@superSends"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "superSends: aCollection\x0a\x09superSends := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRMethod);
+
+
+
+$core.addClass('IRReturn', $globals.IRScopedInstruction, [], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRReturn.comment="I am a local return instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRReturn_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRReturn: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRReturn:"]
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "canBeAssigned",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "canBeAssigned\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockReturn\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isLocalReturn\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isNonLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._isLocalReturn())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isNonLocalReturn",{},$globals.IRReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNonLocalReturn\x0a\x09^ self isLocalReturn not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isLocalReturn"]
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isReturn\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRReturn);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@scope"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$recv(self._parent())._scope();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scope",{},$globals.IRReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope ifNil: [ self parent scope ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "scope", "parent"]
+}),
+$globals.IRReturn);
+
+
+
+$core.addClass('IRBlockReturn', $globals.IRReturn, [], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRBlockReturn.comment="Smalltalk blocks return their last statement. I am a implicit block return instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRBlockReturn_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRBlockReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRBlockReturn: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRBlockReturn:"]
+}),
+$globals.IRBlockReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockReturn\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRBlockReturn);
+
+
+
+$core.addClass('IRNonLocalReturn', $globals.IRReturn, [], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRNonLocalReturn.comment="I am a non local return instruction.\x0aNon local returns are handled using a try/catch JavaScript statement.\x0a\x0aSee `IRNonLocalReturnHandling` class.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRNonLocalReturn_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRNonLocalReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRNonLocalReturn: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRNonLocalReturn:"]
+}),
+$globals.IRNonLocalReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isLocalReturn\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRNonLocalReturn);
+
+
+
+$core.addClass('IRTempDeclaration', $globals.IRScopedInstruction, ['name'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRTempDeclaration_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRTempDeclaration)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRTempDeclaration: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRTempDeclaration:"]
+}),
+$globals.IRTempDeclaration);
+
+$core.addMethod(
+$core.method({
+selector: "isTempDeclaration",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTempDeclaration\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRTempDeclaration);
+
+$core.addMethod(
+$core.method({
+selector: "name",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@name"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "name\x0a\x09^ name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRTempDeclaration);
+
+$core.addMethod(
+$core.method({
+selector: "name:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@name"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "name: aString\x0a\x09name := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRTempDeclaration);
+
+
+
+$core.addClass('IRSend', $globals.IRInstruction, ['selector', 'classSend', 'index'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRSend.comment="I am a message send instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRSend_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRSend: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRSend:"]
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "classSend",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@classSend"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classSend\x0a\x09^ classSend",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "classSend:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@classSend"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "classSend: aClass\x0a\x09classSend := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "index",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@index"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "index\x0a\x09^ index",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "index:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@index"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "index: anInteger\x0a\x09index := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "isSend",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSend\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSend);
+
+
+
+$core.addClass('IRSequence', $globals.IRInstruction, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRSequence_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRSequence)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRSequence: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRSequence:"]
+}),
+$globals.IRSequence);
+
+$core.addMethod(
+$core.method({
+selector: "isSequence",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSequence\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSequence);
+
+
+
+$core.addClass('IRBlockSequence', $globals.IRSequence, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRBlockSequence_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRBlockSequence)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRBlockSequence: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRBlockSequence:"]
+}),
+$globals.IRBlockSequence);
+
+
+
+$core.addClass('IRValue', $globals.IRInstruction, ['value'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRValue.comment="I am the simplest possible instruction. I represent a value.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRValue_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRValue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRValue: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRValue:"]
+}),
+$globals.IRValue);
+
+$core.addMethod(
+$core.method({
+selector: "needsBoxingAsReceiver",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "needsBoxingAsReceiver\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRValue);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@value"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRValue);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@value"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "value: aString\x0a\x09value := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRValue);
+
+
+
+$core.addClass('IRVariable', $globals.IRInstruction, ['variable'], 'Compiler-IR');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRVariable.comment="I am a variable instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRVariable_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRVariable)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRVariable: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRVariable:"]
+}),
+$globals.IRVariable);
+
+$core.addMethod(
+$core.method({
+selector: "isVariable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isVariable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRVariable);
+
+$core.addMethod(
+$core.method({
+selector: "needsBoxingAsReceiver",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._variable())._isPseudoVar())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"needsBoxingAsReceiver",{},$globals.IRVariable)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "needsBoxingAsReceiver\x0a\x09^ self variable isPseudoVar not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isPseudoVar", "variable"]
+}),
+$globals.IRVariable);
+
+$core.addMethod(
+$core.method({
+selector: "variable",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@variable"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "variable\x0a\x09^ variable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRVariable);
+
+$core.addMethod(
+$core.method({
+selector: "variable:",
+protocol: 'accessing',
+fn: function (aScopeVariable){
+var self=this;
+self["@variable"]=aScopeVariable;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScopeVariable"],
+source: "variable: aScopeVariable\x0a\x09variable := aScopeVariable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRVariable);
+
+
+
+$core.addClass('IRVerbatim', $globals.IRInstruction, ['source'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRVerbatim_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRVerbatim)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRVerbatim: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRVerbatim:"]
+}),
+$globals.IRVerbatim);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@source"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ source",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRVerbatim);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@source"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09source := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRVerbatim);
+
+
+
+$core.addClass('IRVisitor', $globals.Object, [], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "visit:",
+protocol: 'visiting',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anIRInstruction)._accept_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visit:",{anIRInstruction:anIRInstruction},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "visit: anIRInstruction\x0a\x09^ anIRInstruction accept: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["accept:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRAssignment:",
+protocol: 'visiting',
+fn: function (anIRAssignment){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRAssignment);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRAssignment:",{anIRAssignment:anIRAssignment},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRAssignment"],
+source: "visitIRAssignment: anIRAssignment\x0a\x09^ self visitIRInstruction: anIRAssignment",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRBlockReturn:",
+protocol: 'visiting',
+fn: function (anIRBlockReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRReturn_(anIRBlockReturn);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRBlockReturn:",{anIRBlockReturn:anIRBlockReturn},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRBlockReturn"],
+source: "visitIRBlockReturn: anIRBlockReturn\x0a\x09^ self visitIRReturn: anIRBlockReturn",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRReturn:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRBlockSequence:",
+protocol: 'visiting',
+fn: function (anIRBlockSequence){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRSequence_(anIRBlockSequence);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRBlockSequence:",{anIRBlockSequence:anIRBlockSequence},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRBlockSequence"],
+source: "visitIRBlockSequence: anIRBlockSequence\x0a\x09^ self visitIRSequence: anIRBlockSequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRSequence:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRClosure:",
+protocol: 'visiting',
+fn: function (anIRClosure){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRClosure);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRClosure:",{anIRClosure:anIRClosure},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure"],
+source: "visitIRClosure: anIRClosure\x0a\x09^ self visitIRInstruction: anIRClosure",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRDynamicArray:",
+protocol: 'visiting',
+fn: function (anIRDynamicArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRDynamicArray);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRDynamicArray:",{anIRDynamicArray:anIRDynamicArray},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRDynamicArray"],
+source: "visitIRDynamicArray: anIRDynamicArray\x0a\x09^ self visitIRInstruction: anIRDynamicArray",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRDynamicDictionary:",
+protocol: 'visiting',
+fn: function (anIRDynamicDictionary){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRDynamicDictionary);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRDynamicDictionary:",{anIRDynamicDictionary:anIRDynamicDictionary},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRDynamicDictionary"],
+source: "visitIRDynamicDictionary: anIRDynamicDictionary\x0a\x09^ self visitIRInstruction: anIRDynamicDictionary",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedClosure:",
+protocol: 'visiting',
+fn: function (anIRInlinedClosure){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRClosure_(anIRInlinedClosure);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedClosure:",{anIRInlinedClosure:anIRInlinedClosure},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedClosure"],
+source: "visitIRInlinedClosure: anIRInlinedClosure\x0a\x09^ self visitIRClosure: anIRInlinedClosure",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRClosure:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedSequence:",
+protocol: 'visiting',
+fn: function (anIRInlinedSequence){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRSequence_(anIRInlinedSequence);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedSequence:",{anIRInlinedSequence:anIRInlinedSequence},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedSequence"],
+source: "visitIRInlinedSequence: anIRInlinedSequence\x0a\x09^ self visitIRSequence: anIRInlinedSequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRSequence:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInstruction:",
+protocol: 'visiting',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(anIRInstruction)._instructions())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return anIRInstruction;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInstruction:",{anIRInstruction:anIRInstruction},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "visitIRInstruction: anIRInstruction\x0a\x09anIRInstruction instructions do: [ :each | self visit: each ].\x0a\x09^ anIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "instructions", "visit:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRMethod:",
+protocol: 'visiting',
+fn: function (anIRMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRMethod);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRMethod:",{anIRMethod:anIRMethod},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRMethod"],
+source: "visitIRMethod: anIRMethod\x0a\x09^ self visitIRInstruction: anIRMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRNonLocalReturn:",
+protocol: 'visiting',
+fn: function (anIRNonLocalReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRNonLocalReturn);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRNonLocalReturn:",{anIRNonLocalReturn:anIRNonLocalReturn},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRNonLocalReturn"],
+source: "visitIRNonLocalReturn: anIRNonLocalReturn\x0a\x09^ self visitIRInstruction: anIRNonLocalReturn",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRNonLocalReturnHandling:",
+protocol: 'visiting',
+fn: function (anIRNonLocalReturnHandling){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRNonLocalReturnHandling);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRNonLocalReturnHandling:",{anIRNonLocalReturnHandling:anIRNonLocalReturnHandling},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRNonLocalReturnHandling"],
+source: "visitIRNonLocalReturnHandling: anIRNonLocalReturnHandling\x0a\x09^ self visitIRInstruction: anIRNonLocalReturnHandling",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRReturn:",
+protocol: 'visiting',
+fn: function (anIRReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRReturn);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRReturn:",{anIRReturn:anIRReturn},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRReturn"],
+source: "visitIRReturn: anIRReturn\x0a\x09^ self visitIRInstruction: anIRReturn",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRSend:",
+protocol: 'visiting',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRSend);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRSend:",{anIRSend:anIRSend},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "visitIRSend: anIRSend\x0a\x09^ self visitIRInstruction: anIRSend",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRSequence:",
+protocol: 'visiting',
+fn: function (anIRSequence){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRSequence);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRSequence:",{anIRSequence:anIRSequence},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSequence"],
+source: "visitIRSequence: anIRSequence\x0a\x09^ self visitIRInstruction: anIRSequence",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRTempDeclaration:",
+protocol: 'visiting',
+fn: function (anIRTempDeclaration){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRTempDeclaration);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRTempDeclaration:",{anIRTempDeclaration:anIRTempDeclaration},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRTempDeclaration"],
+source: "visitIRTempDeclaration: anIRTempDeclaration\x0a\x09^ self visitIRInstruction: anIRTempDeclaration",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRValue:",
+protocol: 'visiting',
+fn: function (anIRValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRValue);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRValue:",{anIRValue:anIRValue},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRValue"],
+source: "visitIRValue: anIRValue\x0a\x09^ self visitIRInstruction: anIRValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRVariable:",
+protocol: 'visiting',
+fn: function (anIRVariable){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRVariable);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRVariable:",{anIRVariable:anIRVariable},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRVariable"],
+source: "visitIRVariable: anIRVariable\x0a\x09^ self visitIRInstruction: anIRVariable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRVerbatim:",
+protocol: 'visiting',
+fn: function (anIRVerbatim){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._visitIRInstruction_(anIRVerbatim);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRVerbatim:",{anIRVerbatim:anIRVerbatim},$globals.IRVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRVerbatim"],
+source: "visitIRVerbatim: anIRVerbatim\x0a\x09^ self visitIRInstruction: anIRVerbatim",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInstruction:"]
+}),
+$globals.IRVisitor);
+
+
+
+$core.addClass('IRJSTranslator', $globals.IRVisitor, ['stream', 'currentClass'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "contents",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._stream())._contents();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contents",{},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "contents\x0a\x09^ self stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["contents", "stream"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@currentClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currentClass\x0a\x09^ currentClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "currentClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@currentClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "currentClass: aClass\x0a\x09currentClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $JSStream(){return $globals.JSStream||(typeof JSStream=="undefined"?nil:JSStream)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@stream"]=$recv($JSStream())._new();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09stream := JSStream new.",
+referencedClasses: ["JSStream"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "stream",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@stream"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stream\x0a\x09^ stream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "stream:",
+protocol: 'accessing',
+fn: function (aStream){
+var self=this;
+self["@stream"]=aStream;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "stream: aStream\x0a\x09stream := aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRAssignment:",
+protocol: 'visiting',
+fn: function (anIRAssignment){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(anIRAssignment)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._first();
+self._visit_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+$recv(self._stream())._nextPutAssignment();
+self._visit_($recv($recv(anIRAssignment)._instructions())._last());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRAssignment:",{anIRAssignment:anIRAssignment},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRAssignment"],
+source: "visitIRAssignment: anIRAssignment\x0a\x09self visit: anIRAssignment instructions first.\x0a\x09self stream nextPutAssignment.\x0a\x09self visit: anIRAssignment instructions last.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "first", "instructions", "nextPutAssignment", "stream", "last"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRClosure:",
+protocol: 'visiting',
+fn: function (anIRClosure){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutClosureWith_arguments_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutVars_($recv($recv(anIRClosure)._tempDeclarations())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._name())._asVariableName();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+})));
+return $recv(self._stream())._nextPutBlockContextFor_during_(anIRClosure,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._visitIRClosure_.apply($recv(self), [anIRClosure]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$recv(anIRClosure)._arguments());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRClosure:",{anIRClosure:anIRClosure},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure"],
+source: "visitIRClosure: anIRClosure\x0a\x09self stream\x0a\x09\x09nextPutClosureWith: [\x0a\x09\x09\x09self stream nextPutVars: (anIRClosure tempDeclarations collect: [ :each |\x0a\x09\x09\x09\x09\x09each name asVariableName ]).\x0a\x09\x09\x09self stream\x0a\x09\x09\x09\x09nextPutBlockContextFor: anIRClosure\x0a\x09\x09\x09\x09during: [ super visitIRClosure: anIRClosure ] ]\x0a\x09\x09arguments: anIRClosure arguments",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutClosureWith:arguments:", "stream", "nextPutVars:", "collect:", "tempDeclarations", "asVariableName", "name", "nextPutBlockContextFor:during:", "visitIRClosure:", "arguments"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRDynamicArray:",
+protocol: 'visiting',
+fn: function (anIRDynamicArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("[");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(anIRDynamicArray)._instructions())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(self["@stream"])._nextPutAll_("]");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRDynamicArray:",{anIRDynamicArray:anIRDynamicArray},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRDynamicArray"],
+source: "visitIRDynamicArray: anIRDynamicArray\x0a\x09self stream nextPutAll: '['.\x0a\x09anIRDynamicArray instructions\x0a\x09\x09do: [ :each | self visit: each ]\x0a\x09\x09separatedBy: [ self stream nextPutAll: ',' ].\x0a\x09stream nextPutAll: ']'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "stream", "do:separatedBy:", "instructions", "visit:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRDynamicDictionary:",
+protocol: 'visiting',
+fn: function (anIRDynamicDictionary){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("$globals.HashedCollection._newFromPairs_([");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(anIRDynamicDictionary)._instructions())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+return $recv($2)._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(self._stream())._nextPutAll_("])");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRDynamicDictionary:",{anIRDynamicDictionary:anIRDynamicDictionary},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRDynamicDictionary"],
+source: "visitIRDynamicDictionary: anIRDynamicDictionary\x0a\x09self stream nextPutAll: '$globals.HashedCollection._newFromPairs_(['.\x0a\x09\x09anIRDynamicDictionary instructions\x0a\x09\x09\x09do: [ :each | self visit: each ]\x0a\x09\x09\x09separatedBy: [ self stream nextPutAll: ',' ].\x0a\x09self stream nextPutAll: '])'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "stream", "do:separatedBy:", "instructions", "visit:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRMethod:",
+protocol: 'visiting',
+fn: function (anIRMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$6,$8,$7,$9,$10;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutMethodDeclaration_with_(anIRMethod,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+return $recv($2)._nextPutFunctionWith_arguments_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$3=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["stream"]=3;
+//>>excludeEnd("ctx");
+$4=$recv($recv(anIRMethod)._tempDeclarations())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._name())._asVariableName();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({each:each},$ctx3,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["collect:"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._nextPutVars_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutVars:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(anIRMethod)._classReferences())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$5=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["stream"]=4;
+//>>excludeEnd("ctx");
+return $recv($5)._nextPutClassRefFunction_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({each:each},$ctx3,4)});
+//>>excludeEnd("ctx");
+}));
+$6=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["stream"]=5;
+//>>excludeEnd("ctx");
+return $recv($6)._nextPutContextFor_during_(anIRMethod,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$8=$recv(anIRMethod)._internalVariables();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["internalVariables"]=1;
+//>>excludeEnd("ctx");
+$7=$recv($8)._notEmpty();
+if($core.assert($7)){
+$9=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["stream"]=6;
+//>>excludeEnd("ctx");
+$recv($9)._nextPutVars_($recv($recv($recv(anIRMethod)._internalVariables())._asSet())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx5) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._variable())._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx5) {$ctx5.fillBlock({each:each},$ctx4,7)});
+//>>excludeEnd("ctx");
+})));
+};
+$10=$recv($recv(anIRMethod)._scope())._hasNonLocalReturn();
+if($core.assert($10)){
+return $recv(self._stream())._nextPutNonLocalReturnHandlingWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx5) {
+//>>excludeEnd("ctx");
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx5.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._visitIRMethod_.apply($recv(self), [anIRMethod]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx5.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx5.sendIdx["visitIRMethod:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx5) {$ctx5.fillBlock({},$ctx4,9)});
+//>>excludeEnd("ctx");
+}));
+} else {
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._visitIRMethod_.apply($recv(self), [anIRMethod]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.supercall = false;
+//>>excludeEnd("ctx");;
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,5)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),$recv(anIRMethod)._arguments());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRMethod:",{anIRMethod:anIRMethod},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRMethod"],
+source: "visitIRMethod: anIRMethod\x0a\x0a\x09self stream\x0a\x09\x09nextPutMethodDeclaration: anIRMethod\x0a\x09\x09with: [ self stream\x0a\x09\x09\x09nextPutFunctionWith: [\x0a\x09\x09\x09\x09self stream nextPutVars: (anIRMethod tempDeclarations collect: [ :each |\x0a\x09\x09\x09\x09\x09each name asVariableName ]).\x0a\x09\x09\x09\x09anIRMethod classReferences do: [ :each | self stream nextPutClassRefFunction: each ].\x0a\x09\x09\x09\x09self stream nextPutContextFor: anIRMethod during: [\x0a\x09\x09\x09\x09anIRMethod internalVariables notEmpty ifTrue: [\x0a\x09\x09\x09\x09\x09self stream nextPutVars: (anIRMethod internalVariables asSet collect: [ :each |\x0a\x09\x09\x09\x09\x09\x09each variable alias ]) ].\x0a\x09\x09\x09\x09anIRMethod scope hasNonLocalReturn\x0a\x09\x09\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09\x09\x09self stream nextPutNonLocalReturnHandlingWith: [\x0a\x09\x09\x09\x09\x09\x09\x09super visitIRMethod: anIRMethod ] ]\x0a\x09\x09\x09\x09\x09ifFalse: [ super visitIRMethod: anIRMethod ] ]]\x0a\x09\x09\x09arguments: anIRMethod arguments ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutMethodDeclaration:with:", "stream", "nextPutFunctionWith:arguments:", "nextPutVars:", "collect:", "tempDeclarations", "asVariableName", "name", "do:", "classReferences", "nextPutClassRefFunction:", "nextPutContextFor:during:", "ifTrue:", "notEmpty", "internalVariables", "asSet", "alias", "variable", "ifTrue:ifFalse:", "hasNonLocalReturn", "scope", "nextPutNonLocalReturnHandlingWith:", "visitIRMethod:", "arguments"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRNonLocalReturn:",
+protocol: 'visiting',
+fn: function (anIRNonLocalReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._stream())._nextPutNonLocalReturnWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._visitIRNonLocalReturn_.apply($recv(self), [anIRNonLocalReturn]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRNonLocalReturn:",{anIRNonLocalReturn:anIRNonLocalReturn},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRNonLocalReturn"],
+source: "visitIRNonLocalReturn: anIRNonLocalReturn\x0a\x09self stream nextPutNonLocalReturnWith: [\x0a\x09\x09super visitIRNonLocalReturn: anIRNonLocalReturn ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutNonLocalReturnWith:", "stream", "visitIRNonLocalReturn:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRReturn:",
+protocol: 'visiting',
+fn: function (anIRReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._stream())._nextPutReturnWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRJSTranslator.superclass.fn.prototype._visitIRReturn_.apply($recv(self), [anIRReturn]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRReturn:",{anIRReturn:anIRReturn},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRReturn"],
+source: "visitIRReturn: anIRReturn\x0a\x09self stream nextPutReturnWith: [\x0a\x09\x09super visitIRReturn: anIRReturn ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutReturnWith:", "stream", "visitIRReturn:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRSend:",
+protocol: 'visiting',
+fn: function (anIRSend){
+var self=this;
+var sends;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+sends=$recv($recv($recv($recv(anIRSend)._method())._sendIndexes())._at_($recv(anIRSend)._selector()))._size();
+$1=$recv(anIRSend)._classSend();
+if(($receiver = $1) == null || $receiver.isNil){
+self._visitSend_(anIRSend);
+} else {
+self._visitSuperSend_(anIRSend);
+};
+$2=$recv($recv(sends).__gt((1)))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(anIRSend)._index()).__lt(sends);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($2)){
+$recv(self._stream())._nextPutSendIndexFor_(anIRSend);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRSend:",{anIRSend:anIRSend,sends:sends},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "visitIRSend: anIRSend\x0a\x09| sends |\x0a\x09sends := (anIRSend method sendIndexes at: anIRSend selector) size.\x0a\x09\x0a\x09anIRSend classSend\x0a\x09\x09ifNil: [ self visitSend: anIRSend ]\x0a\x09\x09ifNotNil: [ self visitSuperSend: anIRSend ].\x0a\x09\x09\x0a\x09(sends > 1 and: [ anIRSend index < sends ])\x0a\x09\x09ifTrue: [ self stream nextPutSendIndexFor: anIRSend ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["size", "at:", "sendIndexes", "method", "selector", "ifNil:ifNotNil:", "classSend", "visitSend:", "visitSuperSend:", "ifTrue:", "and:", ">", "<", "index", "nextPutSendIndexFor:", "stream"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRSequence:",
+protocol: 'visiting',
+fn: function (anIRSequence){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutSequenceWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(anIRSequence)._instructions())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutStatementWith_(self._visit_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRSequence:",{anIRSequence:anIRSequence},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSequence"],
+source: "visitIRSequence: anIRSequence\x0a\x09self stream nextPutSequenceWith: [\x0a\x09\x09anIRSequence instructions do: [ :each |\x0a\x09\x09\x09self stream nextPutStatementWith: (self visit: each) ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutSequenceWith:", "stream", "do:", "instructions", "nextPutStatementWith:", "visit:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRTempDeclaration:",
+protocol: 'visiting',
+fn: function (anIRTempDeclaration){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRTempDeclaration"],
+source: "visitIRTempDeclaration: anIRTempDeclaration\x0a\x09\x22self stream\x0a\x09\x09nextPutAll: 'var ', anIRTempDeclaration name asVariableName, ';';\x0a\x09\x09lf\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRValue:",
+protocol: 'visiting',
+fn: function (anIRValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._stream())._nextPutAll_($recv($recv(anIRValue)._value())._asJavascript());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRValue:",{anIRValue:anIRValue},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRValue"],
+source: "visitIRValue: anIRValue\x0a\x09self stream nextPutAll: anIRValue value asJavascript",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "stream", "asJavascript", "value"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRVariable:",
+protocol: 'visiting',
+fn: function (anIRVariable){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$4;
+$3=$recv(anIRVariable)._variable();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["variable"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._name();
+$1=$recv($2).__eq("thisContext");
+if($core.assert($1)){
+$4=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($4)._nextPutAll_("$core.getThisContext()");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$recv(self._stream())._nextPutAll_($recv($recv(anIRVariable)._variable())._alias());
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRVariable:",{anIRVariable:anIRVariable},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRVariable"],
+source: "visitIRVariable: anIRVariable\x0a\x09anIRVariable variable name = 'thisContext'\x0a\x09\x09ifTrue: [ self stream nextPutAll: '$core.getThisContext()' ]\x0a\x09\x09ifFalse: [ self stream nextPutAll: anIRVariable variable alias ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "=", "name", "variable", "nextPutAll:", "stream", "alias"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRVerbatim:",
+protocol: 'visiting',
+fn: function (anIRVerbatim){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutStatementWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_($recv(anIRVerbatim)._source());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRVerbatim:",{anIRVerbatim:anIRVerbatim},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRVerbatim"],
+source: "visitIRVerbatim: anIRVerbatim\x0a\x09self stream nextPutStatementWith: [\x0a\x09\x09self stream nextPutAll: anIRVerbatim source ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutStatementWith:", "stream", "nextPutAll:", "source"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitReceiver:",
+protocol: 'visiting',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+$1=$recv(anIRInstruction)._needsBoxingAsReceiver();
+if(!$core.assert($1)){
+$2=self._visit_(anIRInstruction);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $2;
+};
+$3=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._nextPutAll_("$recv(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._visit_(anIRInstruction);
+$recv(self._stream())._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitReceiver:",{anIRInstruction:anIRInstruction},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "visitReceiver: anIRInstruction\x0a\x09anIRInstruction needsBoxingAsReceiver ifFalse: [ ^ self visit: anIRInstruction ].\x0a\x09\x0a\x09self stream nextPutAll: '$recv('.\x0a\x09self visit: anIRInstruction.\x0a\x09self stream nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "needsBoxingAsReceiver", "visit:", "nextPutAll:", "stream"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitSend:",
+protocol: 'visiting',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4,$5;
+$2=$recv(anIRSend)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._first();
+self._visitReceiver_($1);
+$3=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(".".__comma($recv($recv(anIRSend)._selector())._asJavaScriptMethodName())).__comma("(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($3)._nextPutAll_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv($recv(anIRSend)._instructions())._allButFirst())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+return $recv($5)._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(self._stream())._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSend:",{anIRSend:anIRSend},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "visitSend: anIRSend\x0a\x09self visitReceiver: anIRSend instructions first.\x0a\x09self stream nextPutAll: '.', anIRSend selector asJavaScriptMethodName, '('.\x0a\x09anIRSend instructions allButFirst\x0a\x09\x09do: [ :each | self visit: each ]\x0a\x09\x09separatedBy: [ self stream nextPutAll: ',' ].\x0a\x09self stream nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitReceiver:", "first", "instructions", "nextPutAll:", "stream", ",", "asJavaScriptMethodName", "selector", "do:separatedBy:", "allButFirst", "visit:"]
+}),
+$globals.IRJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitSuperSend:",
+protocol: 'visiting',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$5,$4,$3,$6,$7,$8,$10,$9,$11,$12,$13,$14;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$2=$1;
+$5=$recv(anIRSend)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(".supercall = true, ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_($recv(self._currentClass())._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(".superclass.fn.prototype.");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$6=$1;
+$7=$recv($recv($recv(anIRSend)._selector())._asJavaScriptMethodName()).__comma(".apply(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv($6)._nextPutAll_($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$8=$recv($1)._nextPutAll_("$recv(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$10=$recv(anIRSend)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$9=$recv($10)._first();
+self._visit_($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+$11=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$recv($11)._nextPutAll_("), [");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+$recv($recv($recv(anIRSend)._instructions())._allButFirst())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$12=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=3;
+//>>excludeEnd("ctx");
+return $recv($12)._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$13=self._stream();
+$recv($13)._nextPutAll_("]));");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=11;
+//>>excludeEnd("ctx");
+$recv($13)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=5;
+//>>excludeEnd("ctx");
+$recv($13)._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=12;
+//>>excludeEnd("ctx");
+$recv($13)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=6;
+//>>excludeEnd("ctx");
+$recv($13)._nextPutAll_($recv($recv($recv(anIRSend)._scope())._alias()).__comma(".supercall = false;"));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=13;
+//>>excludeEnd("ctx");
+$recv($13)._lf();
+$14=$recv($13)._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSuperSend:",{anIRSend:anIRSend},$globals.IRJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "visitSuperSend: anIRSend\x0a\x09self stream\x0a\x09\x09nextPutAll: '('; lf;\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);'; lf;\x0a\x09\x09nextPutAll: anIRSend scope alias, '.supercall = true, '; lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);'; lf;\x0a\x09\x09nextPutAll: self currentClass asJavascript;\x0a\x09\x09nextPutAll: '.superclass.fn.prototype.';\x0a\x09\x09nextPutAll: anIRSend selector asJavaScriptMethodName, '.apply(';\x0a\x09\x09nextPutAll: '$recv('.\x0a\x09self visit: anIRSend instructions first.\x0a\x09self stream nextPutAll: '), ['.\x0a\x09anIRSend instructions allButFirst\x0a\x09\x09do: [ :each | self visit: each ]\x0a\x09\x09separatedBy: [ self stream nextPutAll: ',' ].\x0a\x09self stream \x0a\x09\x09nextPutAll: ']));'; lf;\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);'; lf;\x0a\x09\x09nextPutAll: anIRSend scope alias, '.supercall = false;'; lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "stream", "lf", ",", "alias", "scope", "asJavascript", "currentClass", "asJavaScriptMethodName", "selector", "visit:", "first", "instructions", "do:separatedBy:", "allButFirst"]
+}),
+$globals.IRJSTranslator);
+
+
+
+$core.addClass('JSStream', $globals.Object, ['stream'], 'Compiler-IR');
+$core.addMethod(
+$core.method({
+selector: "contents",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@stream"])._contents();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contents",{},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "contents\x0a\x09^ stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["contents"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.JSStream.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@stream"]=""._writeStream();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09stream := '' writeStream.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "writeStream"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "lf",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lf",{},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lf\x0a\x09stream lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lf"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPut:",
+protocol: 'streaming',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._nextPut_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPut:",{aString:aString},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPut: aString\x0a\x09stream nextPut: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPut:"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutAll:",
+protocol: 'streaming',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._nextPutAll_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutAll:",{aString:aString},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPutAll: aString\x0a\x09stream nextPutAll: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutAssignment",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._nextPutAll_("=");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutAssignment",{},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextPutAssignment\x0a\x09stream nextPutAll: '='",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutBlockContextFor:during:",
+protocol: 'streaming',
+fn: function (anIRClosure,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$6,$5,$4,$3,$7,$11,$10,$9,$8,$15,$14,$13,$12,$16,$17,$23,$22,$21,$20,$19,$18,$24;
+$1=$recv(anIRClosure)._requiresSmalltalkContext();
+if(!$core.assert($1)){
+$2=$recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+return $2;
+};
+self._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(anIRClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=1;
+//>>excludeEnd("ctx");
+$4="return $core.withContext(function(".__comma($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(") {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+self._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$7=self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+self._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$11=$recv(anIRClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$10=$recv($11)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=2;
+//>>excludeEnd("ctx");
+$9="}, function(".__comma($10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$8=$recv($9).__comma(") {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+self._nextPutAll_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$15=$recv(anIRClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=3;
+//>>excludeEnd("ctx");
+$14=$recv($15)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=3;
+//>>excludeEnd("ctx");
+$13=$recv($14).__comma(".fillBlock({");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$12=self._nextPutAll_($13);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv($recv(anIRClosure)._locals())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$16=$recv(each)._asVariableName();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["asVariableName"]=1;
+//>>excludeEnd("ctx");
+self._nextPutAll_($16);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+self._nextPutAll_(":");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$17=self._nextPutAll_($recv(each)._asVariableName());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+return $17;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+self._nextPutAll_("},");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=11;
+//>>excludeEnd("ctx");
+$23=$recv(anIRClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=4;
+//>>excludeEnd("ctx");
+$22=$recv($23)._outerScope();
+$21=$recv($22)._alias();
+$20=$recv($21).__comma(",");
+$19=$recv($20).__comma($recv($recv($recv(anIRClosure)._scope())._blockIndex())._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=7;
+//>>excludeEnd("ctx");
+$18=$recv($19).__comma(")});");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=6;
+//>>excludeEnd("ctx");
+self._nextPutAll_($18);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=12;
+//>>excludeEnd("ctx");
+self._lf();
+$24=self._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutBlockContextFor:during:",{anIRClosure:anIRClosure,aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure", "aBlock"],
+source: "nextPutBlockContextFor: anIRClosure during: aBlock\x0a\x09anIRClosure requiresSmalltalkContext ifFalse: [ ^ aBlock value ].\x0a\x09self\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: 'return $core.withContext(function(', anIRClosure scope alias, ') {';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);';\x0a\x09\x09lf.\x0a\x09\x0a\x09aBlock value.\x0a\x09\x0a\x09self\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '}, function(', anIRClosure scope alias, ') {';\x0a\x09\x09nextPutAll: anIRClosure scope alias, '.fillBlock({'.\x0a\x09\x0a\x09anIRClosure locals\x0a\x09\x09do: [ :each |\x0a\x09\x09\x09self\x0a\x09\x09\x09\x09nextPutAll: each asVariableName;\x0a\x09\x09\x09\x09nextPutAll: ':';\x0a\x09\x09\x09\x09nextPutAll: each asVariableName ]\x0a\x09\x09separatedBy: [ self nextPutAll: ',' ].\x0a\x09\x0a\x09self\x0a\x09\x09nextPutAll: '},';\x0a\x09\x09nextPutAll: anIRClosure scope outerScope alias, ',', anIRClosure scope blockIndex asString, ')});';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "requiresSmalltalkContext", "value", "nextPutAll:", "lf", ",", "alias", "scope", "do:separatedBy:", "locals", "asVariableName", "outerScope", "asString", "blockIndex"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutClassRefFunction:",
+protocol: 'streaming',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self["@stream"];
+$recv($1)._nextPutAll_("function $");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("(){return $globals.");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("||(typeof ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("==\x22undefined\x22?nil:");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_(")}");
+$2=$recv($1)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutClassRefFunction:",{aString:aString},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPutClassRefFunction: aString\x0a\x09\x22Creates an inner function $aString into method and called as `$Foo()`whenever the global is accessed.\x0a\x09This ensures that undefined global access will answer `nil`\x22\x0a\x09\x0a\x09stream\x0a\x09\x09nextPutAll: 'function $';\x0a\x09\x09nextPutAll: aString;\x0a\x09\x09nextPutAll: '(){return $globals.';\x0a\x09\x09nextPutAll: aString;\x0a\x09\x09nextPutAll: '||(typeof ';\x0a\x09\x09nextPutAll: aString;\x0a\x09\x09nextPutAll: '==\x22undefined\x22?nil:';\x0a\x09\x09nextPutAll: aString;\x0a\x09\x09nextPutAll: ')}';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutClosureWith:arguments:",
+protocol: 'streaming',
+fn: function (aBlock,anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$recv(self["@stream"])._nextPutAll_("(function(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(anArray)._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_($recv(each)._asVariableName());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPut_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$1=self["@stream"];
+$recv($1)._nextPutAll_("){");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$2=$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+$3=self["@stream"];
+$recv($3)._lf();
+$4=$recv($3)._nextPutAll_("})");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutClosureWith:arguments:",{aBlock:aBlock,anArray:anArray},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anArray"],
+source: "nextPutClosureWith: aBlock arguments: anArray\x0a\x09stream nextPutAll: '(function('.\x0a\x09anArray\x0a\x09\x09do: [ :each | stream nextPutAll: each asVariableName ]\x0a\x09\x09separatedBy: [ stream nextPut: ',' ].\x0a\x09stream nextPutAll: '){'; lf.\x0a\x09aBlock value.\x0a\x09stream lf; nextPutAll: '})'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "do:separatedBy:", "asVariableName", "nextPut:", "lf", "value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutContextFor:during:",
+protocol: 'streaming',
+fn: function (aMethod,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$6,$5,$4,$3,$7,$12,$11,$10,$9,$8,$16,$15,$14,$13,$17,$18,$19;
+$1=$recv(aMethod)._requiresSmalltalkContext();
+if(!$core.assert($1)){
+$2=$recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+return $2;
+};
+self._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(aMethod)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=1;
+//>>excludeEnd("ctx");
+$4="return $core.withContext(function(".__comma($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(") {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+self._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$7=self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+self._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$12=$recv(aMethod)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$11=$recv($12)._alias();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["alias"]=2;
+//>>excludeEnd("ctx");
+$10="}, function(".__comma($11);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$9=$recv($10).__comma(") {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$8=$recv($9).__comma($recv($recv(aMethod)._scope())._alias());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+self._nextPutAll_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$16=$recv($recv(aMethod)._selector())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=1;
+//>>excludeEnd("ctx");
+$15=".fill(self,".__comma($16);
+$14=$recv($15).__comma(",{");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=6;
+//>>excludeEnd("ctx");
+$13=self._nextPutAll_($14);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv($recv(aMethod)._locals())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$17=$recv(each)._asVariableName();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["asVariableName"]=1;
+//>>excludeEnd("ctx");
+self._nextPutAll_($17);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+self._nextPutAll_(":");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$18=self._nextPutAll_($recv(each)._asVariableName());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+return $18;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+self._nextPutAll_("},");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=11;
+//>>excludeEnd("ctx");
+self._nextPutAll_($recv($recv(aMethod)._theClass())._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=12;
+//>>excludeEnd("ctx");
+self._nextPutAll_(")});");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=13;
+//>>excludeEnd("ctx");
+self._lf();
+$19=self._nextPutAll_("//>>excludeEnd(\x22ctx\x22);");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutContextFor:during:",{aMethod:aMethod,aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aBlock"],
+source: "nextPutContextFor: aMethod during: aBlock\x0a\x09aMethod requiresSmalltalkContext ifFalse: [ ^ aBlock value ].\x0a\x09\x0a\x09self\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: 'return $core.withContext(function(', aMethod scope alias, ') {';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);';\x0a\x09\x09lf.\x0a\x0a\x09aBlock value.\x0a\x09\x0a\x09self\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '}, function(', aMethod scope alias, ') {', aMethod scope alias;\x0a\x09\x09nextPutAll: '.fill(self,', aMethod selector asJavascript, ',{'.\x0a\x0a\x09aMethod locals\x0a\x09\x09do: [ :each |\x0a\x09\x09\x09self\x0a\x09\x09\x09\x09nextPutAll: each asVariableName;\x0a\x09\x09\x09\x09nextPutAll: ':';\x0a\x09\x09\x09\x09nextPutAll: each asVariableName ]\x0a\x09\x09separatedBy: [ self nextPutAll: ',' ].\x0a\x09\x0a\x09self\x0a\x09\x09nextPutAll: '},';\x0a\x09\x09nextPutAll: aMethod theClass asJavascript;\x0a\x09\x09nextPutAll: ')});';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22);'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "requiresSmalltalkContext", "value", "nextPutAll:", "lf", ",", "alias", "scope", "asJavascript", "selector", "do:separatedBy:", "locals", "asVariableName", "theClass"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutFunctionWith:arguments:",
+protocol: 'streaming',
+fn: function (aBlock,anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$6;
+$recv(self["@stream"])._nextPutAll_("fn: function(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(anArray)._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_($recv(each)._asVariableName());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPut_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$1=self["@stream"];
+$recv($1)._nextPutAll_("){");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$2=$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$3=self["@stream"];
+$recv($3)._nextPutAll_("var self=this;");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$4=$recv($3)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+$5=self["@stream"];
+$recv($5)._lf();
+$6=$recv($5)._nextPutAll_("}");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutFunctionWith:arguments:",{aBlock:aBlock,anArray:anArray},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anArray"],
+source: "nextPutFunctionWith: aBlock arguments: anArray\x0a\x09stream nextPutAll: 'fn: function('.\x0a\x09anArray\x0a\x09\x09do: [ :each | stream nextPutAll: each asVariableName ]\x0a\x09\x09separatedBy: [ stream nextPut: ',' ].\x0a\x09stream nextPutAll: '){'; lf.\x0a\x09stream nextPutAll: 'var self=this;'; lf.\x0a\x09aBlock value.\x0a\x09stream lf; nextPutAll: '}'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "do:separatedBy:", "asVariableName", "nextPut:", "lf", "value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutIf:with:",
+protocol: 'streaming',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$recv(self["@stream"])._nextPutAll_("if(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$1=self["@stream"];
+$recv($1)._nextPutAll_("){");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($1)._lf();
+$recv(anotherBlock)._value();
+$recv(self["@stream"])._nextPutAll_("}");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutIf:with:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "nextPutIf: aBlock with: anotherBlock\x0a\x09stream nextPutAll: 'if('.\x0a\x09aBlock value.\x0a\x09stream nextPutAll: '){'; lf.\x0a\x09anotherBlock value.\x0a\x09stream nextPutAll: '}'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "value", "lf"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutIfElse:with:with:",
+protocol: 'streaming',
+fn: function (aBlock,ifBlock,elseBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$recv(self["@stream"])._nextPutAll_("if(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$1=self["@stream"];
+$recv($1)._nextPutAll_("){");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(ifBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=2;
+//>>excludeEnd("ctx");
+$3=self["@stream"];
+$recv($3)._nextPutAll_("} else {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$4=$recv($3)._lf();
+$recv(elseBlock)._value();
+$recv(self["@stream"])._nextPutAll_("}");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutIfElse:with:with:",{aBlock:aBlock,ifBlock:ifBlock,elseBlock:elseBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "ifBlock", "elseBlock"],
+source: "nextPutIfElse: aBlock with: ifBlock with: elseBlock\x0a\x09stream nextPutAll: 'if('.\x0a\x09aBlock value.\x0a\x09stream nextPutAll: '){'; lf.\x0a\x09ifBlock value.\x0a\x09stream nextPutAll: '} else {'; lf.\x0a\x09elseBlock value.\x0a\x09stream nextPutAll: '}'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "value", "lf"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutMethodDeclaration:with:",
+protocol: 'streaming',
+fn: function (aMethod,aBlock){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$5,$4,$3,$6,$9,$8,$7,$10,$11,$12,$15,$14,$13,$16,$19,$18,$17,$20,$23,$22,$21,$24,$25,$26;
+$1=self["@stream"];
+$recv($1)._nextPutAll_("$core.method({");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$2=$1;
+$5=$recv($recv(aMethod)._selector())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=1;
+//>>excludeEnd("ctx");
+$4="selector: ".__comma($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$6=$1;
+$9=$recv($recv(aMethod)._source())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=2;
+//>>excludeEnd("ctx");
+$8="source: ".__comma($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$7=$recv($8).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$recv($6)._nextPutAll_($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$10=$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$11=self["@stream"];
+$12=$11;
+$15=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$14=",".__comma($15);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=6;
+//>>excludeEnd("ctx");
+$13=$recv($14).__comma("messageSends: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$recv($12)._nextPutAll_($13);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$16=$11;
+$19=$recv($recv(aMethod)._messageSends())._asArray();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asArray"]=1;
+//>>excludeEnd("ctx");
+$18=$recv($19)._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=3;
+//>>excludeEnd("ctx");
+$17=$recv($18).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=7;
+//>>excludeEnd("ctx");
+$recv($16)._nextPutAll_($17);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv($11)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=5;
+//>>excludeEnd("ctx");
+$20=$11;
+$23=$recv($recv($recv($recv(aMethod)._arguments())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._asArray())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=4;
+//>>excludeEnd("ctx");
+$22="args: ".__comma($23);
+$21=$recv($22).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=8;
+//>>excludeEnd("ctx");
+$recv($20)._nextPutAll_($21);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv($11)._lf();
+$24=$recv($11)._nextPutAll_("referencedClasses: [");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$recv($recv(aMethod)._classReferences())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_($recv(each)._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$25=self["@stream"];
+$recv($25)._nextPutAll_("]");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+$26=$recv($25)._nextPutAll_("})");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutMethodDeclaration:with:",{aMethod:aMethod,aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aBlock"],
+source: "nextPutMethodDeclaration: aMethod with: aBlock\x0a\x09stream\x0a\x09\x09nextPutAll: '$core.method({'; lf;\x0a\x09\x09nextPutAll: 'selector: ', aMethod selector asJavascript, ','; lf;\x0a\x09\x09nextPutAll: 'source: ', aMethod source asJavascript, ',';lf.\x0a\x09aBlock value.\x0a\x09stream\x0a\x09\x09nextPutAll: ',', String lf, 'messageSends: ';\x0a\x09\x09nextPutAll: aMethod messageSends asArray asJavascript, ','; lf;\x0a\x09\x09nextPutAll: 'args: ', (aMethod arguments collect: [ :each | each value ]) asArray asJavascript, ','; lf;\x0a\x09\x09nextPutAll: 'referencedClasses: ['.\x0a\x09aMethod classReferences\x0a\x09\x09do: [ :each | stream nextPutAll: each asJavascript ]\x0a\x09\x09separatedBy: [ stream nextPutAll: ',' ].\x0a\x09stream\x0a\x09\x09nextPutAll: ']';\x0a\x09\x09nextPutAll: '})'",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "source", "value", "asArray", "messageSends", "collect:", "arguments", "do:separatedBy:", "classReferences"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutNonLocalReturnHandlingWith:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$1=self["@stream"];
+$recv($1)._nextPutAll_("var $early={};");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutAll_("try {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($1)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+$3=self["@stream"];
+$recv($3)._nextPutAll_("}");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv($3)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv($3)._nextPutAll_("catch(e) {if(e===$early)return e[0]; throw e}");
+$4=$recv($3)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutNonLocalReturnHandlingWith:",{aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextPutNonLocalReturnHandlingWith: aBlock\x0a\x09stream\x0a\x09\x09nextPutAll: 'var $early={};'; lf;\x0a\x09\x09nextPutAll: 'try {'; lf.\x0a\x09aBlock value.\x0a\x09stream\x0a\x09\x09nextPutAll: '}'; lf;\x0a\x09\x09nextPutAll: 'catch(e) {if(e===$early)return e[0]; throw e}'; lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf", "value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutNonLocalReturnWith:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._nextPutAll_("throw $early=[");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+$recv(self["@stream"])._nextPutAll_("]");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutNonLocalReturnWith:",{aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextPutNonLocalReturnWith: aBlock\x0a\x09stream nextPutAll: 'throw $early=['.\x0a\x09aBlock value.\x0a\x09stream nextPutAll: ']'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutReturn",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@stream"])._nextPutAll_("return ");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutReturn",{},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextPutReturn\x0a\x09stream nextPutAll: 'return '",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutReturnWith:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._nextPutReturn();
+$recv(aBlock)._value();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutReturnWith:",{aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextPutReturnWith: aBlock\x0a\x09self nextPutReturn.\x0a\x09aBlock value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutReturn", "value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutSendIndexFor:",
+protocol: 'streaming',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._nextPutAll_(";");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+self._nextPutAll_("//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+self._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+self._nextPutAll_($recv($recv(anIRSend)._scope())._alias());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+self._nextPutAll_(".sendIdx[");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+self._nextPutAll_($recv($recv(anIRSend)._selector())._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+self._nextPutAll_("]=");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+self._nextPutAll_($recv($recv(anIRSend)._index())._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+self._nextPutAll_(";");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+self._lf();
+$1=self._nextPutAll_("//>>excludeEnd(\x22ctx\x22)");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutSendIndexFor:",{anIRSend:anIRSend},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "nextPutSendIndexFor: anIRSend\x0a\x09self \x0a\x09\x09nextPutAll: ';'; lf;\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ctx\x22, pragmas.excludeDebugContexts);'; lf;\x0a\x09\x09nextPutAll: anIRSend scope alias;\x0a\x09\x09nextPutAll: '.sendIdx[';\x0a\x09\x09nextPutAll: anIRSend selector asJavascript;\x0a\x09\x09nextPutAll: ']=';\x0a\x09\x09nextPutAll: anIRSend index asString;\x0a\x09\x09nextPutAll: ';'; lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ctx\x22)'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf", "alias", "scope", "asJavascript", "selector", "asString", "index"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutSequenceWith:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutSequenceWith:",{aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextPutSequenceWith: aBlock\x0a\x09\x22stream\x0a\x09\x09nextPutAll: 'switch($core.thisContext.pc){'; lf.\x22\x0a\x09aBlock value.\x0a\x09\x22stream\x0a\x09\x09nextPutAll: '};'; lf\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutStatementWith:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$recv(aBlock)._value();
+$1=self["@stream"];
+$recv($1)._nextPutAll_(";");
+$2=$recv($1)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutStatementWith:",{aBlock:aBlock},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextPutStatementWith: aBlock\x0a\x09aBlock value.\x0a\x09stream nextPutAll: ';'; lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value", "nextPutAll:", "lf"]
+}),
+$globals.JSStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutVars:",
+protocol: 'streaming',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+$recv(aCollection)._ifEmpty_((function(){
+throw $early=[self];
+
+}));
+$recv(self["@stream"])._nextPutAll_("var ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aCollection)._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@stream"])._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$1=self["@stream"];
+$recv($1)._nextPutAll_(";");
+$2=$recv($1)._lf();
+return self;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutVars:",{aCollection:aCollection},$globals.JSStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "nextPutVars: aCollection\x0a\x09aCollection ifEmpty: [ ^ self ].\x0a\x09\x0a\x09stream nextPutAll: 'var '.\x0a\x09aCollection\x0a\x09\x09do: [ :each | stream nextPutAll: each ]\x0a\x09\x09separatedBy: [ stream nextPutAll: ',' ].\x0a\x09stream nextPutAll: ';'; lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifEmpty:", "nextPutAll:", "do:separatedBy:", "lf"]
+}),
+$globals.JSStream);
+
+
+$core.addMethod(
+$core.method({
+selector: "appendToInstruction:",
+protocol: '*Compiler-IR',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(anIRInstruction)._appendBlock_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToInstruction:",{anIRInstruction:anIRInstruction},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "appendToInstruction: anIRInstruction\x0a\x09anIRInstruction appendBlock: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendBlock:"]
+}),
+$globals.BlockClosure);
+
+});

+ 1329 - 0
bower_components/amber/src/Compiler-IR.st

@@ -0,0 +1,1329 @@
+Smalltalk createPackage: 'Compiler-IR'!
+NodeVisitor subclass: #IRASTTranslator
+	instanceVariableNames: 'source theClass method sequence nextAlias'
+	package: 'Compiler-IR'!
+!IRASTTranslator commentStamp!
+I am the AST (abstract syntax tree) visitor responsible for building the intermediate representation graph.!
+
+!IRASTTranslator methodsFor: 'accessing'!
+
+method
+	^ method
+!
+
+method: anIRMethod
+	method := anIRMethod
+!
+
+nextAlias
+	nextAlias ifNil: [ nextAlias := 0 ].
+	nextAlias := nextAlias + 1.
+	^ nextAlias asString
+!
+
+sequence
+	^ sequence
+!
+
+sequence: anIRSequence
+	sequence := anIRSequence
+!
+
+source
+	^ source
+!
+
+source: aString
+	source := aString
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+!
+
+withSequence: aSequence do: aBlock
+	| outerSequence |
+	outerSequence := self sequence.
+	self sequence: aSequence.
+	aBlock value.
+	self sequence: outerSequence.
+	^ aSequence
+! !
+
+!IRASTTranslator methodsFor: 'visiting'!
+
+alias: aNode
+	| variable |
+
+	aNode isImmutable ifTrue: [ ^ self visit: aNode ].
+
+	variable := IRVariable new
+		variable: (AliasVar new name: '$', self nextAlias);
+		yourself.
+
+	self sequence add: (IRAssignment new
+		add: variable;
+		add: (self visit: aNode);
+		yourself).
+
+	self method internalVariables add: variable.
+
+	^ variable
+!
+
+aliasTemporally: aCollection
+	"https://github.com/NicolasPetton/amber/issues/296
+	
+	If a node is aliased, all preceding ones are aliased as well.
+	The tree is iterated twice. First we get the aliasing dependency,
+	then the aliasing itself is done"
+
+	| threshold result |
+	threshold := 0.
+	
+	aCollection withIndexDo: [ :each :i |
+		each subtreeNeedsAliasing
+			ifTrue: [ threshold := i ] ].
+
+	result := OrderedCollection new.
+	aCollection withIndexDo: [ :each :i |
+		result add: (i <= threshold
+			ifTrue: [ self alias: each ]
+			ifFalse: [ self visit: each ]) ].
+
+	^ result
+!
+
+visitAssignmentNode: aNode
+	| left right assignment |
+	right := self visit: aNode right.
+	left := self visit: aNode left.
+	self sequence add: (IRAssignment new
+		add: left;
+		add: right;
+		yourself).
+	^ left
+!
+
+visitBlockNode: aNode
+	| closure |
+	closure := IRClosure new
+		arguments: aNode parameters;
+		requiresSmalltalkContext: aNode requiresSmalltalkContext;
+		scope: aNode scope;
+		yourself.
+	aNode scope temps do: [ :each |
+		closure add: (IRTempDeclaration new
+			name: each name;
+			scope: aNode scope;
+			yourself) ].
+	aNode nodes do: [ :each | closure add: (self visit: each) ].
+	^ closure
+!
+
+visitBlockSequenceNode: aNode
+	^ self
+		withSequence: IRBlockSequence new
+		do: [
+			aNode nodes ifNotEmpty: [
+				aNode nodes allButLast do: [ :each |
+					self sequence add: (self visitOrAlias: each) ].
+				aNode nodes last isReturnNode
+					ifFalse: [ self sequence add: (IRBlockReturn new add: (self visitOrAlias: aNode nodes last); yourself) ]
+					ifTrue: [ self sequence add: (self visitOrAlias: aNode nodes last) ] ]]
+!
+
+visitCascadeNode: aNode
+	| alias receiver |
+
+	aNode receiver isImmutable 
+		ifTrue: [ receiver := aNode receiver ]
+		ifFalse: [
+			alias := self alias: aNode receiver.
+			receiver := VariableNode new binding: alias variable ].
+	
+	aNode nodes do: [ :each |
+			each receiver: receiver ].
+
+	aNode nodes allButLast do: [ :each |
+		self sequence add: (self visit: each) ].
+
+	^ self alias: aNode nodes last
+!
+
+visitDynamicArrayNode: aNode
+	| array |
+	array := IRDynamicArray new.
+	(self aliasTemporally: aNode nodes) do: [ :each | array add: each ].
+	^ array
+!
+
+visitDynamicDictionaryNode: aNode
+	| dictionary |
+	dictionary := IRDynamicDictionary new.
+	(self aliasTemporally: aNode nodes) do: [ :each | dictionary add: each ].
+	^ dictionary
+!
+
+visitJSStatementNode: aNode
+	^ IRVerbatim new
+		source: aNode source crlfSanitized;
+		yourself
+!
+
+visitMethodNode: aNode
+
+	self method: (IRMethod new
+		source: self source crlfSanitized;
+		theClass: self theClass;
+		arguments: aNode arguments;
+		selector: aNode selector;
+		sendIndexes: aNode sendIndexes;
+		superSends: aNode superSends;
+		requiresSmalltalkContext: aNode requiresSmalltalkContext;
+		classReferences: aNode classReferences;
+		scope: aNode scope;
+		yourself).
+
+	aNode scope temps do: [ :each |
+		self method add: (IRTempDeclaration new
+			name: each name;
+			scope: aNode scope;
+			yourself) ].
+
+	aNode nodes do: [ :each | self method add: (self visit: each) ].
+
+	aNode scope hasLocalReturn ifFalse: [self method
+		add: (IRReturn new
+			add: (IRVariable new
+				variable: (aNode scope pseudoVars at: 'self');
+				yourself);
+			yourself);
+		add: (IRVerbatim new source: ''; yourself) ].
+
+	^ self method
+!
+
+visitOrAlias: aNode
+	^ aNode shouldBeAliased
+		ifTrue: [ self alias: aNode ]
+		ifFalse: [ self visit: aNode ]
+!
+
+visitReturnNode: aNode
+	| return |
+	return := aNode nonLocalReturn
+		ifTrue: [ IRNonLocalReturn new ]
+		ifFalse: [ IRReturn new ].
+	return scope: aNode scope.
+	aNode nodes do: [ :each |
+		return add: (self alias: each) ].
+	^ return
+!
+
+visitSendNode: aNode
+	| send all receiver arguments |
+	send := IRSend new.
+	send
+		selector: aNode selector;
+		index: aNode index.
+	aNode superSend ifTrue: [ send classSend: self theClass superclass ].
+	
+	all := self aliasTemporally: { aNode receiver }, aNode arguments.
+	receiver := all first.
+	arguments := all allButFirst.
+
+	send add: receiver.
+	arguments do: [ :each | send add: each ].
+
+	^ send
+!
+
+visitSequenceNode: aNode
+	^ self
+		withSequence: IRSequence new
+		do: [
+			aNode nodes do: [ :each | | instruction |
+				instruction := self visitOrAlias: each.
+				instruction isVariable ifFalse: [
+					self sequence add: instruction ] ]]
+!
+
+visitValueNode: aNode
+	^ IRValue new
+		value: aNode value;
+		yourself
+!
+
+visitVariableNode: aNode
+	^ IRVariable new
+		variable: aNode binding;
+		yourself
+! !
+
+Object subclass: #IRInstruction
+	instanceVariableNames: 'parent instructions'
+	package: 'Compiler-IR'!
+!IRInstruction commentStamp!
+I am the abstract root class of the IR (intermediate representation) instructions class hierarchy.
+The IR graph is used to emit JavaScript code using a JSStream.!
+
+!IRInstruction methodsFor: 'accessing'!
+
+instructions
+	^ instructions ifNil: [ instructions := OrderedCollection new ]
+!
+
+method
+	^ self parent method
+!
+
+parent
+	^ parent
+!
+
+parent: anIRInstruction
+	parent := anIRInstruction
+!
+
+scope
+	^ self parent ifNotNil: [ :node | 
+		node scope ]
+! !
+
+!IRInstruction methodsFor: 'building'!
+
+add: anObject
+	anObject parent: self.
+	^ self instructions add: anObject
+!
+
+remove
+	self parent remove: self
+!
+
+remove: anIRInstruction
+	self instructions remove: anIRInstruction
+!
+
+replace: anIRInstruction with: anotherIRInstruction
+	anotherIRInstruction parent: self.
+	self instructions
+		at: (self instructions indexOf: anIRInstruction)
+		put: anotherIRInstruction
+!
+
+replaceWith: anIRInstruction
+	self parent replace: self with: anIRInstruction
+! !
+
+!IRInstruction methodsFor: 'testing'!
+
+canBeAssigned
+	^ true
+!
+
+isClosure
+	^ false
+!
+
+isInlined
+	^ false
+!
+
+isLocalReturn
+	^ false
+!
+
+isMethod
+	^ false
+!
+
+isReturn
+	^ false
+!
+
+isSend
+	^ false
+!
+
+isSequence
+	^ false
+!
+
+isTempDeclaration
+	^ false
+!
+
+isVariable
+	^ false
+!
+
+needsBoxingAsReceiver
+	^ true
+! !
+
+!IRInstruction methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRInstruction: self
+! !
+
+!IRInstruction class methodsFor: 'instance creation'!
+
+on: aBuilder
+	^ self new
+		builder: aBuilder;
+		yourself
+! !
+
+IRInstruction subclass: #IRAssignment
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRAssignment methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRAssignment: self
+! !
+
+IRInstruction subclass: #IRDynamicArray
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRDynamicArray methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRDynamicArray: self
+! !
+
+IRInstruction subclass: #IRDynamicDictionary
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRDynamicDictionary methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRDynamicDictionary: self
+! !
+
+IRInstruction subclass: #IRScopedInstruction
+	instanceVariableNames: 'scope'
+	package: 'Compiler-IR'!
+
+!IRScopedInstruction methodsFor: 'accessing'!
+
+scope
+	^ scope
+!
+
+scope: aScope
+	scope := aScope
+! !
+
+IRScopedInstruction subclass: #IRClosureInstruction
+	instanceVariableNames: 'arguments requiresSmalltalkContext'
+	package: 'Compiler-IR'!
+
+!IRClosureInstruction methodsFor: 'accessing'!
+
+arguments
+	^ arguments ifNil: [ #() ]
+!
+
+arguments: aCollection
+	arguments := aCollection
+!
+
+locals
+	^ self arguments copy
+		addAll: (self tempDeclarations collect: [ :each | each name ]);
+		yourself
+!
+
+requiresSmalltalkContext
+	^ requiresSmalltalkContext ifNil: [ false ]
+!
+
+requiresSmalltalkContext: anObject
+	requiresSmalltalkContext := anObject
+!
+
+scope: aScope
+	super scope: aScope.
+	aScope instruction: self
+!
+
+tempDeclarations
+	^ self instructions select: [ :each |
+		each isTempDeclaration ]
+! !
+
+IRClosureInstruction subclass: #IRClosure
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRClosure methodsFor: 'accessing'!
+
+sequence
+	^ self instructions last
+! !
+
+!IRClosure methodsFor: 'testing'!
+
+isClosure
+	^ true
+! !
+
+!IRClosure methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRClosure: self
+! !
+
+IRClosureInstruction subclass: #IRMethod
+	instanceVariableNames: 'theClass source selector classReferences sendIndexes superSends requiresSmalltalkContext internalVariables'
+	package: 'Compiler-IR'!
+!IRMethod commentStamp!
+I am a method instruction!
+
+!IRMethod methodsFor: 'accessing'!
+
+classReferences
+	^ classReferences
+!
+
+classReferences: aCollection
+	classReferences := aCollection
+!
+
+internalVariables
+	^ internalVariables ifNil: [ internalVariables := Set new ]
+!
+
+isMethod
+	^ true
+!
+
+messageSends
+	^ self sendIndexes keys
+!
+
+method
+	^ self
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+!
+
+sendIndexes
+	^ sendIndexes
+!
+
+sendIndexes: aDictionary
+	sendIndexes := aDictionary
+!
+
+source
+	^ source
+!
+
+source: aString
+	source := aString
+!
+
+superSends
+	^ superSends
+!
+
+superSends: aCollection
+	superSends := aCollection
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+!IRMethod methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRMethod: self
+! !
+
+IRScopedInstruction subclass: #IRReturn
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+!IRReturn commentStamp!
+I am a local return instruction.!
+
+!IRReturn methodsFor: 'accessing'!
+
+scope
+	^ scope ifNil: [ self parent scope ]
+! !
+
+!IRReturn methodsFor: 'testing'!
+
+canBeAssigned
+	^ false
+!
+
+isBlockReturn
+	^ false
+!
+
+isLocalReturn
+	^ true
+!
+
+isNonLocalReturn
+	^ self isLocalReturn not
+!
+
+isReturn
+	^ true
+! !
+
+!IRReturn methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRReturn: self
+! !
+
+IRReturn subclass: #IRBlockReturn
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+!IRBlockReturn commentStamp!
+Smalltalk blocks return their last statement. I am a implicit block return instruction.!
+
+!IRBlockReturn methodsFor: 'testing'!
+
+isBlockReturn
+	^ true
+! !
+
+!IRBlockReturn methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRBlockReturn: self
+! !
+
+IRReturn subclass: #IRNonLocalReturn
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+!IRNonLocalReturn commentStamp!
+I am a non local return instruction.
+Non local returns are handled using a try/catch JavaScript statement.
+
+See `IRNonLocalReturnHandling` class.!
+
+!IRNonLocalReturn methodsFor: 'testing'!
+
+isLocalReturn
+	^ false
+! !
+
+!IRNonLocalReturn methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRNonLocalReturn: self
+! !
+
+IRScopedInstruction subclass: #IRTempDeclaration
+	instanceVariableNames: 'name'
+	package: 'Compiler-IR'!
+
+!IRTempDeclaration methodsFor: 'accessing'!
+
+name
+	^ name
+!
+
+name: aString
+	name := aString
+! !
+
+!IRTempDeclaration methodsFor: 'testing'!
+
+isTempDeclaration
+	^ true
+! !
+
+!IRTempDeclaration methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRTempDeclaration: self
+! !
+
+IRInstruction subclass: #IRSend
+	instanceVariableNames: 'selector classSend index'
+	package: 'Compiler-IR'!
+!IRSend commentStamp!
+I am a message send instruction.!
+
+!IRSend methodsFor: 'accessing'!
+
+classSend
+	^ classSend
+!
+
+classSend: aClass
+	classSend := aClass
+!
+
+index
+	^ index
+!
+
+index: anInteger
+	index := anInteger
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+! !
+
+!IRSend methodsFor: 'testing'!
+
+isSend
+	^ true
+! !
+
+!IRSend methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRSend: self
+! !
+
+IRInstruction subclass: #IRSequence
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRSequence methodsFor: 'testing'!
+
+isSequence
+	^ true
+! !
+
+!IRSequence methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRSequence: self
+! !
+
+IRSequence subclass: #IRBlockSequence
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRBlockSequence methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRBlockSequence: self
+! !
+
+IRInstruction subclass: #IRValue
+	instanceVariableNames: 'value'
+	package: 'Compiler-IR'!
+!IRValue commentStamp!
+I am the simplest possible instruction. I represent a value.!
+
+!IRValue methodsFor: 'accessing'!
+
+value
+	^ value
+!
+
+value: aString
+	value := aString
+! !
+
+!IRValue methodsFor: 'testing'!
+
+needsBoxingAsReceiver
+	^ false
+! !
+
+!IRValue methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRValue: self
+! !
+
+IRInstruction subclass: #IRVariable
+	instanceVariableNames: 'variable'
+	package: 'Compiler-IR'!
+!IRVariable commentStamp!
+I am a variable instruction.!
+
+!IRVariable methodsFor: 'accessing'!
+
+variable
+	^ variable
+!
+
+variable: aScopeVariable
+	variable := aScopeVariable
+! !
+
+!IRVariable methodsFor: 'testing'!
+
+isVariable
+	^ true
+!
+
+needsBoxingAsReceiver
+	^ self variable isPseudoVar not
+! !
+
+!IRVariable methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRVariable: self
+! !
+
+IRInstruction subclass: #IRVerbatim
+	instanceVariableNames: 'source'
+	package: 'Compiler-IR'!
+
+!IRVerbatim methodsFor: 'accessing'!
+
+source
+	^ source
+!
+
+source: aString
+	source := aString
+! !
+
+!IRVerbatim methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRVerbatim: self
+! !
+
+Object subclass: #IRVisitor
+	instanceVariableNames: ''
+	package: 'Compiler-IR'!
+
+!IRVisitor methodsFor: 'visiting'!
+
+visit: anIRInstruction
+	^ anIRInstruction accept: self
+!
+
+visitIRAssignment: anIRAssignment
+	^ self visitIRInstruction: anIRAssignment
+!
+
+visitIRBlockReturn: anIRBlockReturn
+	^ self visitIRReturn: anIRBlockReturn
+!
+
+visitIRBlockSequence: anIRBlockSequence
+	^ self visitIRSequence: anIRBlockSequence
+!
+
+visitIRClosure: anIRClosure
+	^ self visitIRInstruction: anIRClosure
+!
+
+visitIRDynamicArray: anIRDynamicArray
+	^ self visitIRInstruction: anIRDynamicArray
+!
+
+visitIRDynamicDictionary: anIRDynamicDictionary
+	^ self visitIRInstruction: anIRDynamicDictionary
+!
+
+visitIRInlinedClosure: anIRInlinedClosure
+	^ self visitIRClosure: anIRInlinedClosure
+!
+
+visitIRInlinedSequence: anIRInlinedSequence
+	^ self visitIRSequence: anIRInlinedSequence
+!
+
+visitIRInstruction: anIRInstruction
+	anIRInstruction instructions do: [ :each | self visit: each ].
+	^ anIRInstruction
+!
+
+visitIRMethod: anIRMethod
+	^ self visitIRInstruction: anIRMethod
+!
+
+visitIRNonLocalReturn: anIRNonLocalReturn
+	^ self visitIRInstruction: anIRNonLocalReturn
+!
+
+visitIRNonLocalReturnHandling: anIRNonLocalReturnHandling
+	^ self visitIRInstruction: anIRNonLocalReturnHandling
+!
+
+visitIRReturn: anIRReturn
+	^ self visitIRInstruction: anIRReturn
+!
+
+visitIRSend: anIRSend
+	^ self visitIRInstruction: anIRSend
+!
+
+visitIRSequence: anIRSequence
+	^ self visitIRInstruction: anIRSequence
+!
+
+visitIRTempDeclaration: anIRTempDeclaration
+	^ self visitIRInstruction: anIRTempDeclaration
+!
+
+visitIRValue: anIRValue
+	^ self visitIRInstruction: anIRValue
+!
+
+visitIRVariable: anIRVariable
+	^ self visitIRInstruction: anIRVariable
+!
+
+visitIRVerbatim: anIRVerbatim
+	^ self visitIRInstruction: anIRVerbatim
+! !
+
+IRVisitor subclass: #IRJSTranslator
+	instanceVariableNames: 'stream currentClass'
+	package: 'Compiler-IR'!
+
+!IRJSTranslator methodsFor: 'accessing'!
+
+contents
+	^ self stream contents
+!
+
+currentClass
+	^ currentClass
+!
+
+currentClass: aClass
+	currentClass := aClass
+!
+
+stream
+	^ stream
+!
+
+stream: aStream
+	stream := aStream
+! !
+
+!IRJSTranslator methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	stream := JSStream new.
+! !
+
+!IRJSTranslator methodsFor: 'visiting'!
+
+visitIRAssignment: anIRAssignment
+	self visit: anIRAssignment instructions first.
+	self stream nextPutAssignment.
+	self visit: anIRAssignment instructions last.
+!
+
+visitIRClosure: anIRClosure
+	self stream
+		nextPutClosureWith: [
+			self stream nextPutVars: (anIRClosure tempDeclarations collect: [ :each |
+					each name asVariableName ]).
+			self stream
+				nextPutBlockContextFor: anIRClosure
+				during: [ super visitIRClosure: anIRClosure ] ]
+		arguments: anIRClosure arguments
+!
+
+visitIRDynamicArray: anIRDynamicArray
+	self stream nextPutAll: '['.
+	anIRDynamicArray instructions
+		do: [ :each | self visit: each ]
+		separatedBy: [ self stream nextPutAll: ',' ].
+	stream nextPutAll: ']'
+!
+
+visitIRDynamicDictionary: anIRDynamicDictionary
+	self stream nextPutAll: '$globals.HashedCollection._newFromPairs_(['.
+		anIRDynamicDictionary instructions
+			do: [ :each | self visit: each ]
+			separatedBy: [ self stream nextPutAll: ',' ].
+	self stream nextPutAll: '])'
+!
+
+visitIRMethod: anIRMethod
+
+	self stream
+		nextPutMethodDeclaration: anIRMethod
+		with: [ self stream
+			nextPutFunctionWith: [
+				self stream nextPutVars: (anIRMethod tempDeclarations collect: [ :each |
+					each name asVariableName ]).
+				anIRMethod classReferences do: [ :each | self stream nextPutClassRefFunction: each ].
+				self stream nextPutContextFor: anIRMethod during: [
+				anIRMethod internalVariables notEmpty ifTrue: [
+					self stream nextPutVars: (anIRMethod internalVariables asSet collect: [ :each |
+						each variable alias ]) ].
+				anIRMethod scope hasNonLocalReturn
+					ifTrue: [
+						self stream nextPutNonLocalReturnHandlingWith: [
+							super visitIRMethod: anIRMethod ] ]
+					ifFalse: [ super visitIRMethod: anIRMethod ] ]]
+			arguments: anIRMethod arguments ]
+!
+
+visitIRNonLocalReturn: anIRNonLocalReturn
+	self stream nextPutNonLocalReturnWith: [
+		super visitIRNonLocalReturn: anIRNonLocalReturn ]
+!
+
+visitIRReturn: anIRReturn
+	self stream nextPutReturnWith: [
+		super visitIRReturn: anIRReturn ]
+!
+
+visitIRSend: anIRSend
+	| sends |
+	sends := (anIRSend method sendIndexes at: anIRSend selector) size.
+	
+	anIRSend classSend
+		ifNil: [ self visitSend: anIRSend ]
+		ifNotNil: [ self visitSuperSend: anIRSend ].
+		
+	(sends > 1 and: [ anIRSend index < sends ])
+		ifTrue: [ self stream nextPutSendIndexFor: anIRSend ]
+!
+
+visitIRSequence: anIRSequence
+	self stream nextPutSequenceWith: [
+		anIRSequence instructions do: [ :each |
+			self stream nextPutStatementWith: (self visit: each) ] ]
+!
+
+visitIRTempDeclaration: anIRTempDeclaration
+	"self stream
+		nextPutAll: 'var ', anIRTempDeclaration name asVariableName, ';';
+		lf"
+!
+
+visitIRValue: anIRValue
+	self stream nextPutAll: anIRValue value asJavascript
+!
+
+visitIRVariable: anIRVariable
+	anIRVariable variable name = 'thisContext'
+		ifTrue: [ self stream nextPutAll: '$core.getThisContext()' ]
+		ifFalse: [ self stream nextPutAll: anIRVariable variable alias ]
+!
+
+visitIRVerbatim: anIRVerbatim
+	self stream nextPutStatementWith: [
+		self stream nextPutAll: anIRVerbatim source ]
+!
+
+visitReceiver: anIRInstruction
+	anIRInstruction needsBoxingAsReceiver ifFalse: [ ^ self visit: anIRInstruction ].
+	
+	self stream nextPutAll: '$recv('.
+	self visit: anIRInstruction.
+	self stream nextPutAll: ')'
+!
+
+visitSend: anIRSend
+	self visitReceiver: anIRSend instructions first.
+	self stream nextPutAll: '.', anIRSend selector asJavaScriptMethodName, '('.
+	anIRSend instructions allButFirst
+		do: [ :each | self visit: each ]
+		separatedBy: [ self stream nextPutAll: ',' ].
+	self stream nextPutAll: ')'
+!
+
+visitSuperSend: anIRSend
+	self stream
+		nextPutAll: '('; lf;
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);'; lf;
+		nextPutAll: anIRSend scope alias, '.supercall = true, '; lf;
+		nextPutAll: '//>>excludeEnd("ctx");'; lf;
+		nextPutAll: self currentClass asJavascript;
+		nextPutAll: '.superclass.fn.prototype.';
+		nextPutAll: anIRSend selector asJavaScriptMethodName, '.apply(';
+		nextPutAll: '$recv('.
+	self visit: anIRSend instructions first.
+	self stream nextPutAll: '), ['.
+	anIRSend instructions allButFirst
+		do: [ :each | self visit: each ]
+		separatedBy: [ self stream nextPutAll: ',' ].
+	self stream 
+		nextPutAll: ']));'; lf;
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);'; lf;
+		nextPutAll: anIRSend scope alias, '.supercall = false;'; lf;
+		nextPutAll: '//>>excludeEnd("ctx");'
+! !
+
+Object subclass: #JSStream
+	instanceVariableNames: 'stream'
+	package: 'Compiler-IR'!
+
+!JSStream methodsFor: 'accessing'!
+
+contents
+	^ stream contents
+! !
+
+!JSStream methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	stream := '' writeStream.
+! !
+
+!JSStream methodsFor: 'streaming'!
+
+lf
+	stream lf
+!
+
+nextPut: aString
+	stream nextPut: aString
+!
+
+nextPutAll: aString
+	stream nextPutAll: aString
+!
+
+nextPutAssignment
+	stream nextPutAll: '='
+!
+
+nextPutBlockContextFor: anIRClosure during: aBlock
+	anIRClosure requiresSmalltalkContext ifFalse: [ ^ aBlock value ].
+	self
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);';
+		lf;
+		nextPutAll: 'return $core.withContext(function(', anIRClosure scope alias, ') {';
+		lf;
+		nextPutAll: '//>>excludeEnd("ctx");';
+		lf.
+	
+	aBlock value.
+	
+	self
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);';
+		lf;
+		nextPutAll: '}, function(', anIRClosure scope alias, ') {';
+		nextPutAll: anIRClosure scope alias, '.fillBlock({'.
+	
+	anIRClosure locals
+		do: [ :each |
+			self
+				nextPutAll: each asVariableName;
+				nextPutAll: ':';
+				nextPutAll: each asVariableName ]
+		separatedBy: [ self nextPutAll: ',' ].
+	
+	self
+		nextPutAll: '},';
+		nextPutAll: anIRClosure scope outerScope alias, ',', anIRClosure scope blockIndex asString, ')});';
+		lf;
+		nextPutAll: '//>>excludeEnd("ctx");'
+!
+
+nextPutClassRefFunction: aString
+	"Creates an inner function $aString into method and called as `$Foo()`whenever the global is accessed.
+	This ensures that undefined global access will answer `nil`"
+	
+	stream
+		nextPutAll: 'function $';
+		nextPutAll: aString;
+		nextPutAll: '(){return $globals.';
+		nextPutAll: aString;
+		nextPutAll: '||(typeof ';
+		nextPutAll: aString;
+		nextPutAll: '=="undefined"?nil:';
+		nextPutAll: aString;
+		nextPutAll: ')}';
+		lf
+!
+
+nextPutClosureWith: aBlock arguments: anArray
+	stream nextPutAll: '(function('.
+	anArray
+		do: [ :each | stream nextPutAll: each asVariableName ]
+		separatedBy: [ stream nextPut: ',' ].
+	stream nextPutAll: '){'; lf.
+	aBlock value.
+	stream lf; nextPutAll: '})'
+!
+
+nextPutContextFor: aMethod during: aBlock
+	aMethod requiresSmalltalkContext ifFalse: [ ^ aBlock value ].
+	
+	self
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);';
+		lf;
+		nextPutAll: 'return $core.withContext(function(', aMethod scope alias, ') {';
+		lf;
+		nextPutAll: '//>>excludeEnd("ctx");';
+		lf.
+
+	aBlock value.
+	
+	self
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);';
+		lf;
+		nextPutAll: '}, function(', aMethod scope alias, ') {', aMethod scope alias;
+		nextPutAll: '.fill(self,', aMethod selector asJavascript, ',{'.
+
+	aMethod locals
+		do: [ :each |
+			self
+				nextPutAll: each asVariableName;
+				nextPutAll: ':';
+				nextPutAll: each asVariableName ]
+		separatedBy: [ self nextPutAll: ',' ].
+	
+	self
+		nextPutAll: '},';
+		nextPutAll: aMethod theClass asJavascript;
+		nextPutAll: ')});';
+		lf;
+		nextPutAll: '//>>excludeEnd("ctx");'
+!
+
+nextPutFunctionWith: aBlock arguments: anArray
+	stream nextPutAll: 'fn: function('.
+	anArray
+		do: [ :each | stream nextPutAll: each asVariableName ]
+		separatedBy: [ stream nextPut: ',' ].
+	stream nextPutAll: '){'; lf.
+	stream nextPutAll: 'var self=this;'; lf.
+	aBlock value.
+	stream lf; nextPutAll: '}'
+!
+
+nextPutIf: aBlock with: anotherBlock
+	stream nextPutAll: 'if('.
+	aBlock value.
+	stream nextPutAll: '){'; lf.
+	anotherBlock value.
+	stream nextPutAll: '}'
+!
+
+nextPutIfElse: aBlock with: ifBlock with: elseBlock
+	stream nextPutAll: 'if('.
+	aBlock value.
+	stream nextPutAll: '){'; lf.
+	ifBlock value.
+	stream nextPutAll: '} else {'; lf.
+	elseBlock value.
+	stream nextPutAll: '}'
+!
+
+nextPutMethodDeclaration: aMethod with: aBlock
+	stream
+		nextPutAll: '$core.method({'; lf;
+		nextPutAll: 'selector: ', aMethod selector asJavascript, ','; lf;
+		nextPutAll: 'source: ', aMethod source asJavascript, ',';lf.
+	aBlock value.
+	stream
+		nextPutAll: ',', String lf, 'messageSends: ';
+		nextPutAll: aMethod messageSends asArray asJavascript, ','; lf;
+		nextPutAll: 'args: ', (aMethod arguments collect: [ :each | each value ]) asArray asJavascript, ','; lf;
+		nextPutAll: 'referencedClasses: ['.
+	aMethod classReferences
+		do: [ :each | stream nextPutAll: each asJavascript ]
+		separatedBy: [ stream nextPutAll: ',' ].
+	stream
+		nextPutAll: ']';
+		nextPutAll: '})'
+!
+
+nextPutNonLocalReturnHandlingWith: aBlock
+	stream
+		nextPutAll: 'var $early={};'; lf;
+		nextPutAll: 'try {'; lf.
+	aBlock value.
+	stream
+		nextPutAll: '}'; lf;
+		nextPutAll: 'catch(e) {if(e===$early)return e[0]; throw e}'; lf
+!
+
+nextPutNonLocalReturnWith: aBlock
+	stream nextPutAll: 'throw $early=['.
+	aBlock value.
+	stream nextPutAll: ']'
+!
+
+nextPutReturn
+	stream nextPutAll: 'return '
+!
+
+nextPutReturnWith: aBlock
+	self nextPutReturn.
+	aBlock value
+!
+
+nextPutSendIndexFor: anIRSend
+	self 
+		nextPutAll: ';'; lf;
+		nextPutAll: '//>>excludeStart("ctx", pragmas.excludeDebugContexts);'; lf;
+		nextPutAll: anIRSend scope alias;
+		nextPutAll: '.sendIdx[';
+		nextPutAll: anIRSend selector asJavascript;
+		nextPutAll: ']=';
+		nextPutAll: anIRSend index asString;
+		nextPutAll: ';'; lf;
+		nextPutAll: '//>>excludeEnd("ctx")'
+!
+
+nextPutSequenceWith: aBlock
+	"stream
+		nextPutAll: 'switch($core.thisContext.pc){'; lf."
+	aBlock value.
+	"stream
+		nextPutAll: '};'; lf"
+!
+
+nextPutStatementWith: aBlock
+	aBlock value.
+	stream nextPutAll: ';'; lf
+!
+
+nextPutVars: aCollection
+	aCollection ifEmpty: [ ^ self ].
+	
+	stream nextPutAll: 'var '.
+	aCollection
+		do: [ :each | stream nextPutAll: each ]
+		separatedBy: [ stream nextPutAll: ',' ].
+	stream nextPutAll: ';'; lf
+! !
+
+!BlockClosure methodsFor: '*Compiler-IR'!
+
+appendToInstruction: anIRInstruction
+	anIRInstruction appendBlock: self
+! !
+

+ 2625 - 0
bower_components/amber/src/Compiler-Inlining.js

@@ -0,0 +1,2625 @@
+define("amber_core/Compiler-Inlining", ["amber/boot", "amber_core/Compiler-IR", "amber_core/Kernel-Objects", "amber_core/Compiler-Core"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Inlining');
+$core.packages["Compiler-Inlining"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('IRInlinedAssignment', $globals.IRAssignment, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedAssignment.comment="I represent an inlined assignment instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRInlinedAssignment_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedAssignment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRInlinedAssignment: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedAssignment:"]
+}),
+$globals.IRInlinedAssignment);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedAssignment);
+
+
+
+$core.addClass('IRInlinedClosure', $globals.IRClosure, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedClosure.comment="I represent an inlined closure instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedClosure_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedClosure: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedClosure:"]
+}),
+$globals.IRInlinedClosure);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedClosure);
+
+
+
+$core.addClass('IRInlinedReturn', $globals.IRReturn, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedReturn.comment="I represent an inlined local return instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aVisitor)._visitIRInlinedReturn_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedReturn)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09^ aVisitor visitIRInlinedReturn: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedReturn:"]
+}),
+$globals.IRInlinedReturn);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedReturn);
+
+
+
+$core.addClass('IRInlinedSend', $globals.IRSend, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedSend.comment="I am the abstract super class of inlined message send instructions.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitInlinedSend_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitInlinedSend: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitInlinedSend:"]
+}),
+$globals.IRInlinedSend);
+
+$core.addMethod(
+$core.method({
+selector: "internalVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=[];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "internalVariables\x0a\x09\x22Answer a collection of internal variables required \x0a\x09to perform the inlining\x22\x0a\x09\x0a\x09^ #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedSend);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedSend);
+
+
+
+$core.addClass('IRInlinedIfFalse', $globals.IRInlinedSend, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedIfFalse.comment="I represent an inlined `#ifFalse:` message send instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedIfFalse_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedIfFalse)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedIfFalse: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedIfFalse:"]
+}),
+$globals.IRInlinedIfFalse);
+
+
+
+$core.addClass('IRInlinedIfNilIfNotNil', $globals.IRInlinedSend, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedIfNilIfNotNil.comment="I represent an inlined `#ifNil:ifNotNil:` message send instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedIfNilIfNotNil_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedIfNilIfNotNil)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedIfNilIfNotNil: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedIfNilIfNotNil:"]
+}),
+$globals.IRInlinedIfNilIfNotNil);
+
+$core.addMethod(
+$core.method({
+selector: "internalVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Array())._with_(self._receiverInternalVariable());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"internalVariables",{},$globals.IRInlinedIfNilIfNotNil)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "internalVariables\x0a\x09^ Array with: self receiverInternalVariable",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["with:", "receiverInternalVariable"]
+}),
+$globals.IRInlinedIfNilIfNotNil);
+
+$core.addMethod(
+$core.method({
+selector: "receiverInternalVariable",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $IRVariable(){return $globals.IRVariable||(typeof IRVariable=="undefined"?nil:IRVariable)}
+function $AliasVar(){return $globals.AliasVar||(typeof AliasVar=="undefined"?nil:AliasVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRVariable())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._variable_($recv($recv($AliasVar())._new())._name_(self._receiverInternalVariableName()));
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"receiverInternalVariable",{},$globals.IRInlinedIfNilIfNotNil)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiverInternalVariable\x0a\x09^ IRVariable new\x0a\x09\x09variable: (AliasVar new name: self receiverInternalVariableName);\x0a\x09\x09yourself.",
+referencedClasses: ["IRVariable", "AliasVar"],
+//>>excludeEnd("ide");
+messageSends: ["variable:", "new", "name:", "receiverInternalVariableName", "yourself"]
+}),
+$globals.IRInlinedIfNilIfNotNil);
+
+$core.addMethod(
+$core.method({
+selector: "receiverInternalVariableName",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "$receiver";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiverInternalVariableName\x0a\x09^ '$receiver'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedIfNilIfNotNil);
+
+
+
+$core.addClass('IRInlinedIfTrue', $globals.IRInlinedSend, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedIfTrue.comment="I represent an inlined `#ifTrue:` message send instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedIfTrue_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedIfTrue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedIfTrue: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedIfTrue:"]
+}),
+$globals.IRInlinedIfTrue);
+
+
+
+$core.addClass('IRInlinedIfTrueIfFalse', $globals.IRInlinedSend, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedIfTrueIfFalse.comment="I represent an inlined `#ifTrue:ifFalse:` message send instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedIfTrueIfFalse_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedIfTrueIfFalse)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedIfTrueIfFalse: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedIfTrueIfFalse:"]
+}),
+$globals.IRInlinedIfTrueIfFalse);
+
+
+
+$core.addClass('IRInlinedSequence', $globals.IRBlockSequence, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInlinedSequence.comment="I represent a (block) sequence inside an inlined closure instruction (instance of `IRInlinedClosure`).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accept:",
+protocol: 'visiting',
+fn: function (aVisitor){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aVisitor)._visitIRInlinedSequence_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accept:",{aVisitor:aVisitor},$globals.IRInlinedSequence)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aVisitor"],
+source: "accept: aVisitor\x0a\x09aVisitor visitIRInlinedSequence: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitIRInlinedSequence:"]
+}),
+$globals.IRInlinedSequence);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRInlinedSequence);
+
+
+
+$core.addClass('IRInliner', $globals.IRVisitor, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInliner.comment="I visit an IR tree, inlining message sends and block closures.\x0a\x0aMessage selectors that can be inlined are answered by `IRSendInliner >> #inlinedSelectors`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "assignmentInliner",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRAssignmentInliner(){return $globals.IRAssignmentInliner||(typeof IRAssignmentInliner=="undefined"?nil:IRAssignmentInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRAssignmentInliner())._new();
+$recv($2)._translator_(self);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assignmentInliner",{},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "assignmentInliner\x0a\x09^ IRAssignmentInliner new\x0a\x09\x09translator: self;\x0a\x09\x09yourself",
+referencedClasses: ["IRAssignmentInliner"],
+//>>excludeEnd("ide");
+messageSends: ["translator:", "new", "yourself"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "returnInliner",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRReturnInliner(){return $globals.IRReturnInliner||(typeof IRReturnInliner=="undefined"?nil:IRReturnInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRReturnInliner())._new();
+$recv($2)._translator_(self);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"returnInliner",{},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "returnInliner\x0a\x09^ IRReturnInliner new\x0a\x09\x09translator: self;\x0a\x09\x09yourself",
+referencedClasses: ["IRReturnInliner"],
+//>>excludeEnd("ide");
+messageSends: ["translator:", "new", "yourself"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "sendInliner",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRSendInliner(){return $globals.IRSendInliner||(typeof IRSendInliner=="undefined"?nil:IRSendInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($IRSendInliner())._new();
+$recv($2)._translator_(self);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendInliner",{},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sendInliner\x0a\x09^ IRSendInliner new\x0a\x09\x09translator: self;\x0a\x09\x09yourself",
+referencedClasses: ["IRSendInliner"],
+//>>excludeEnd("ide");
+messageSends: ["translator:", "new", "yourself"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "shouldInlineAssignment:",
+protocol: 'testing',
+fn: function (anIRAssignment){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$1=$recv($recv($recv(anIRAssignment)._isInlined())._not())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(anIRAssignment)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._isSend();
+return $recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._shouldInlineSend_($recv($recv(anIRAssignment)._instructions())._last());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["and:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldInlineAssignment:",{anIRAssignment:anIRAssignment},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRAssignment"],
+source: "shouldInlineAssignment: anIRAssignment\x0a\x09^ anIRAssignment isInlined not and: [\x0a\x09\x09anIRAssignment instructions last isSend and: [\x0a\x09\x09\x09self shouldInlineSend: (anIRAssignment instructions last) ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "not", "isInlined", "isSend", "last", "instructions", "shouldInlineSend:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "shouldInlineReturn:",
+protocol: 'testing',
+fn: function (anIRReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$1=$recv($recv($recv(anIRReturn)._isInlined())._not())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(anIRReturn)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._isSend();
+return $recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._shouldInlineSend_($recv($recv(anIRReturn)._instructions())._first());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["and:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldInlineReturn:",{anIRReturn:anIRReturn},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRReturn"],
+source: "shouldInlineReturn: anIRReturn\x0a\x09^ anIRReturn isInlined not and: [\x0a\x09\x09anIRReturn instructions first isSend and: [\x0a\x09\x09\x09self shouldInlineSend: (anIRReturn instructions first) ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "not", "isInlined", "isSend", "first", "instructions", "shouldInlineSend:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "shouldInlineSend:",
+protocol: 'testing',
+fn: function (anIRSend){
+var self=this;
+function $IRSendInliner(){return $globals.IRSendInliner||(typeof IRSendInliner=="undefined"?nil:IRSendInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv(anIRSend)._isInlined())._not())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($IRSendInliner())._shouldInline_(anIRSend);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldInlineSend:",{anIRSend:anIRSend},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "shouldInlineSend: anIRSend\x0a\x09^ anIRSend isInlined not and: [\x0a\x09\x09IRSendInliner shouldInline: anIRSend ]",
+referencedClasses: ["IRSendInliner"],
+//>>excludeEnd("ide");
+messageSends: ["and:", "not", "isInlined", "shouldInline:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "transformNonLocalReturn:",
+protocol: 'visiting',
+fn: function (anIRNonLocalReturn){
+var self=this;
+var localReturn;
+function $IRReturn(){return $globals.IRReturn||(typeof IRReturn=="undefined"?nil:IRReturn)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$4,$3,$5,$6,$7,$8,$9;
+$2=$recv(anIRNonLocalReturn)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._canInlineNonLocalReturns();
+if($core.assert($1)){
+$4=$recv(anIRNonLocalReturn)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4)._methodScope();
+$5=$recv(anIRNonLocalReturn)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=3;
+//>>excludeEnd("ctx");
+$recv($3)._removeNonLocalReturn_($5);
+$6=$recv($IRReturn())._new();
+$recv($6)._scope_($recv(anIRNonLocalReturn)._scope());
+$7=$recv($6)._yourself();
+localReturn=$7;
+localReturn;
+$recv($recv(anIRNonLocalReturn)._instructions())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(localReturn)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(anIRNonLocalReturn)._replaceWith_(localReturn);
+$8=localReturn;
+return $8;
+};
+$9=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRInliner.superclass.fn.prototype._visitIRNonLocalReturn_.apply($recv(self), [anIRNonLocalReturn]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return $9;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"transformNonLocalReturn:",{anIRNonLocalReturn:anIRNonLocalReturn,localReturn:localReturn},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRNonLocalReturn"],
+source: "transformNonLocalReturn: anIRNonLocalReturn\x0a\x09\x22Replace a non local return into a local return\x22\x0a\x0a\x09| localReturn |\x0a\x09anIRNonLocalReturn scope canInlineNonLocalReturns ifTrue: [\x0a\x09\x09anIRNonLocalReturn scope methodScope removeNonLocalReturn: anIRNonLocalReturn scope.\x0a\x09\x09localReturn := IRReturn new\x0a\x09\x09\x09scope: anIRNonLocalReturn scope;\x0a\x09\x09\x09yourself.\x0a\x09\x09anIRNonLocalReturn instructions do: [ :each |\x0a\x09\x09\x09localReturn add: each ].\x0a\x09\x09anIRNonLocalReturn replaceWith: localReturn.\x0a\x09\x09^ localReturn ].\x0a\x09^ super visitIRNonLocalReturn: anIRNonLocalReturn",
+referencedClasses: ["IRReturn"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "canInlineNonLocalReturns", "scope", "removeNonLocalReturn:", "methodScope", "scope:", "new", "yourself", "do:", "instructions", "add:", "replaceWith:", "visitIRNonLocalReturn:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRAssignment:",
+protocol: 'visiting',
+fn: function (anIRAssignment){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._shouldInlineAssignment_(anIRAssignment);
+if($core.assert($2)){
+$1=$recv(self._assignmentInliner())._inlineAssignment_(anIRAssignment);
+} else {
+$1=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRInliner.superclass.fn.prototype._visitIRAssignment_.apply($recv(self), [anIRAssignment]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRAssignment:",{anIRAssignment:anIRAssignment},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRAssignment"],
+source: "visitIRAssignment: anIRAssignment\x0a\x09^ (self shouldInlineAssignment: anIRAssignment)\x0a\x09\x09ifTrue: [ self assignmentInliner inlineAssignment: anIRAssignment ]\x0a\x09\x09ifFalse: [ super visitIRAssignment: anIRAssignment ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "shouldInlineAssignment:", "inlineAssignment:", "assignmentInliner", "visitIRAssignment:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRNonLocalReturn:",
+protocol: 'visiting',
+fn: function (anIRNonLocalReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._transformNonLocalReturn_(anIRNonLocalReturn);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRNonLocalReturn:",{anIRNonLocalReturn:anIRNonLocalReturn},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRNonLocalReturn"],
+source: "visitIRNonLocalReturn: anIRNonLocalReturn\x0a\x09^ self transformNonLocalReturn: anIRNonLocalReturn",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["transformNonLocalReturn:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRReturn:",
+protocol: 'visiting',
+fn: function (anIRReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._shouldInlineReturn_(anIRReturn);
+if($core.assert($2)){
+$1=$recv(self._returnInliner())._inlineReturn_(anIRReturn);
+} else {
+$1=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRInliner.superclass.fn.prototype._visitIRReturn_.apply($recv(self), [anIRReturn]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRReturn:",{anIRReturn:anIRReturn},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRReturn"],
+source: "visitIRReturn: anIRReturn\x0a\x09^ (self shouldInlineReturn: anIRReturn)\x0a\x09\x09ifTrue: [ self returnInliner inlineReturn: anIRReturn ]\x0a\x09\x09ifFalse: [ super visitIRReturn: anIRReturn ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "shouldInlineReturn:", "inlineReturn:", "returnInliner", "visitIRReturn:"]
+}),
+$globals.IRInliner);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRSend:",
+protocol: 'visiting',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._shouldInlineSend_(anIRSend);
+if($core.assert($2)){
+$1=$recv(self._sendInliner())._inlineSend_(anIRSend);
+} else {
+$1=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRInliner.superclass.fn.prototype._visitIRSend_.apply($recv(self), [anIRSend]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRSend:",{anIRSend:anIRSend},$globals.IRInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "visitIRSend: anIRSend\x0a\x09^ (self shouldInlineSend: anIRSend)\x0a\x09\x09ifTrue: [ self sendInliner inlineSend: anIRSend ]\x0a\x09\x09ifFalse: [ super visitIRSend: anIRSend ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "shouldInlineSend:", "inlineSend:", "sendInliner", "visitIRSend:"]
+}),
+$globals.IRInliner);
+
+
+
+$core.addClass('IRInliningJSTranslator', $globals.IRJSTranslator, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRInliningJSTranslator.comment="I am a specialized JavaScript translator able to write inlined IR instructions to JavaScript stream (`JSStream` instance).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedAssignment:",
+protocol: 'visiting',
+fn: function (anIRInlinedAssignment){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._visit_($recv($recv(anIRInlinedAssignment)._instructions())._last());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedAssignment:",{anIRInlinedAssignment:anIRInlinedAssignment},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedAssignment"],
+source: "visitIRInlinedAssignment: anIRInlinedAssignment\x0a\x09self visit: anIRInlinedAssignment instructions last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "last", "instructions"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedClosure:",
+protocol: 'visiting',
+fn: function (anIRInlinedClosure){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._stream())._nextPutVars_($recv($recv(anIRInlinedClosure)._tempDeclarations())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._name())._asVariableName();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})));
+$recv($recv(anIRInlinedClosure)._instructions())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedClosure:",{anIRInlinedClosure:anIRInlinedClosure},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedClosure"],
+source: "visitIRInlinedClosure: anIRInlinedClosure\x0a\x09self stream nextPutVars: (anIRInlinedClosure tempDeclarations collect: [ :each |\x0a\x09\x09each name asVariableName ]).\x0a\x09anIRInlinedClosure instructions do: [ :each |\x0a\x09\x09self visit: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutVars:", "stream", "collect:", "tempDeclarations", "asVariableName", "name", "do:", "instructions", "visit:"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedIfFalse:",
+protocol: 'visiting',
+fn: function (anIRInlinedIfFalse){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutIf_with_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_("!$core.assert(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(anIRInlinedIfFalse)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+self._visit_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_($recv($recv(anIRInlinedIfFalse)._instructions())._last());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedIfFalse:",{anIRInlinedIfFalse:anIRInlinedIfFalse},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedIfFalse"],
+source: "visitIRInlinedIfFalse: anIRInlinedIfFalse\x0a\x09self stream nextPutIf: [\x0a\x09\x09self stream nextPutAll: '!$core.assert('.\x0a\x09\x09self visit: anIRInlinedIfFalse instructions first.\x0a\x09\x09self stream nextPutAll: ')' ]\x0a\x09\x09with: [ self visit: anIRInlinedIfFalse instructions last ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutIf:with:", "stream", "nextPutAll:", "visit:", "first", "instructions", "last"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedIfNilIfNotNil:",
+protocol: 'visiting',
+fn: function (anIRInlinedIfNilIfNotNil){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$5,$4,$7,$6;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutIfElse_with_with_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$3=$recv("(".__comma($recv(anIRInlinedIfNilIfNotNil)._receiverInternalVariableName())).__comma(" = ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(anIRInlinedIfNilIfNotNil)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._first();
+self._visit_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_(") == null || $receiver.isNil");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$7=$recv(anIRInlinedIfNilIfNotNil)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._second();
+return self._visit_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_($recv($recv(anIRInlinedIfNilIfNotNil)._instructions())._third());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedIfNilIfNotNil:",{anIRInlinedIfNilIfNotNil:anIRInlinedIfNilIfNotNil},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedIfNilIfNotNil"],
+source: "visitIRInlinedIfNilIfNotNil: anIRInlinedIfNilIfNotNil\x0a\x09self stream\x0a\x09\x09nextPutIfElse: [\x0a\x09\x09\x09self stream nextPutAll: '(', anIRInlinedIfNilIfNotNil receiverInternalVariableName, ' = '.\x0a\x09\x09\x09self visit: anIRInlinedIfNilIfNotNil instructions first.\x0a\x09\x09\x09self stream nextPutAll: ') == null || $receiver.isNil' ]\x0a\x09\x09with: [ self visit: anIRInlinedIfNilIfNotNil instructions second ]\x0a\x09\x09with: [ self visit: anIRInlinedIfNilIfNotNil instructions third ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutIfElse:with:with:", "stream", "nextPutAll:", ",", "receiverInternalVariableName", "visit:", "first", "instructions", "second", "third"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedIfTrue:",
+protocol: 'visiting',
+fn: function (anIRInlinedIfTrue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutIf_with_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_("$core.assert(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(anIRInlinedIfTrue)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+self._visit_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_($recv($recv(anIRInlinedIfTrue)._instructions())._last());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedIfTrue:",{anIRInlinedIfTrue:anIRInlinedIfTrue},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedIfTrue"],
+source: "visitIRInlinedIfTrue: anIRInlinedIfTrue\x0a\x09self stream nextPutIf: [\x0a\x09\x09self stream nextPutAll: '$core.assert('.\x0a\x09\x09self visit: anIRInlinedIfTrue instructions first.\x0a\x09\x09self stream nextPutAll: ')' ]\x0a\x09\x09with: [ self visit: anIRInlinedIfTrue instructions last ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutIf:with:", "stream", "nextPutAll:", "visit:", "first", "instructions", "last"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedIfTrueIfFalse:",
+protocol: 'visiting',
+fn: function (anIRInlinedIfTrueIfFalse){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3,$6,$5;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutIfElse_with_with_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["stream"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._nextPutAll_("$core.assert(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(anIRInlinedIfTrueIfFalse)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+self._visit_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutAll_(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$6=$recv(anIRInlinedIfTrueIfFalse)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["instructions"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._second();
+return self._visit_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["visit:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_($recv($recv(anIRInlinedIfTrueIfFalse)._instructions())._third());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedIfTrueIfFalse:",{anIRInlinedIfTrueIfFalse:anIRInlinedIfTrueIfFalse},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedIfTrueIfFalse"],
+source: "visitIRInlinedIfTrueIfFalse: anIRInlinedIfTrueIfFalse\x0a\x09self stream\x0a\x09\x09nextPutIfElse: [\x0a\x09\x09\x09self stream nextPutAll: '$core.assert('.\x0a\x09\x09\x09self visit: anIRInlinedIfTrueIfFalse instructions first.\x0a\x09\x09\x09self stream nextPutAll: ')' ]\x0a\x09\x09with: [ self visit: anIRInlinedIfTrueIfFalse instructions second ]\x0a\x09\x09with: [ self visit: anIRInlinedIfTrueIfFalse instructions third ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutIfElse:with:with:", "stream", "nextPutAll:", "visit:", "first", "instructions", "second", "third"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedNonLocalReturn:",
+protocol: 'visiting',
+fn: function (anIRInlinedReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stream"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._nextPutStatementWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._visit_($recv($recv(anIRInlinedReturn)._instructions())._last());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(self._stream())._nextPutNonLocalReturnWith_((function(){
+
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedNonLocalReturn:",{anIRInlinedReturn:anIRInlinedReturn},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedReturn"],
+source: "visitIRInlinedNonLocalReturn: anIRInlinedReturn\x0a\x09self stream nextPutStatementWith: [\x0a\x09\x09self visit: anIRInlinedReturn instructions last ].\x0a\x09self stream nextPutNonLocalReturnWith: [ ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutStatementWith:", "stream", "visit:", "last", "instructions", "nextPutNonLocalReturnWith:"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedReturn:",
+protocol: 'visiting',
+fn: function (anIRInlinedReturn){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._visit_($recv($recv(anIRInlinedReturn)._instructions())._last());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedReturn:",{anIRInlinedReturn:anIRInlinedReturn},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedReturn"],
+source: "visitIRInlinedReturn: anIRInlinedReturn\x0a\x09self visit: anIRInlinedReturn instructions last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "last", "instructions"]
+}),
+$globals.IRInliningJSTranslator);
+
+$core.addMethod(
+$core.method({
+selector: "visitIRInlinedSequence:",
+protocol: 'visiting',
+fn: function (anIRInlinedSequence){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(anIRInlinedSequence)._instructions())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._stream())._nextPutStatementWith_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._visit_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitIRInlinedSequence:",{anIRInlinedSequence:anIRInlinedSequence},$globals.IRInliningJSTranslator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInlinedSequence"],
+source: "visitIRInlinedSequence: anIRInlinedSequence\x0a\x09anIRInlinedSequence instructions do: [ :each |\x0a\x09\x09self stream nextPutStatementWith: [ self visit: each ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "instructions", "nextPutStatementWith:", "stream", "visit:"]
+}),
+$globals.IRInliningJSTranslator);
+
+
+
+$core.addClass('IRSendInliner', $globals.Object, ['send', 'translator'], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRSendInliner.comment="I inline some message sends and block closure arguments. I heavily rely on #perform: to dispatch inlining methods.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "ifFalse:",
+protocol: 'inlining',
+fn: function (anIRInstruction){
+var self=this;
+function $IRInlinedIfFalse(){return $globals.IRInlinedIfFalse||(typeof IRInlinedIfFalse=="undefined"?nil:IRInlinedIfFalse)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._inlinedSend_with_($recv($IRInlinedIfFalse())._new(),anIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifFalse:",{anIRInstruction:anIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "ifFalse: anIRInstruction\x0a\x09^ self inlinedSend: IRInlinedIfFalse new with: anIRInstruction",
+referencedClasses: ["IRInlinedIfFalse"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:", "new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifFalse:ifTrue:",
+protocol: 'inlining',
+fn: function (anIRInstruction,anotherIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._perform_withArguments_("ifTrue:ifFalse:",[anotherIRInstruction,anIRInstruction]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifFalse:ifTrue:",{anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction", "anotherIRInstruction"],
+source: "ifFalse: anIRInstruction ifTrue: anotherIRInstruction\x0a\x09^ self perform: #ifTrue:ifFalse: withArguments: { anotherIRInstruction. anIRInstruction }",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["perform:withArguments:"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:",
+protocol: 'inlining',
+fn: function (anIRInstruction){
+var self=this;
+function $IRInlinedIfNilIfNotNil(){return $globals.IRInlinedIfNilIfNotNil||(typeof IRInlinedIfNilIfNotNil=="undefined"?nil:IRInlinedIfNilIfNotNil)}
+function $IRClosure(){return $globals.IRClosure||(typeof IRClosure=="undefined"?nil:IRClosure)}
+function $IRBlockSequence(){return $globals.IRBlockSequence||(typeof IRBlockSequence=="undefined"?nil:IRBlockSequence)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$4,$5,$7,$8,$6,$9,$3,$1;
+$2=$recv($IRInlinedIfNilIfNotNil())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($IRClosure())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$recv($4)._scope_($recv($recv(anIRInstruction)._scope())._copy());
+$5=$4;
+$7=$recv($IRBlockSequence())._new();
+$recv($7)._add_($recv($recv(self._send())._instructions())._first());
+$8=$recv($7)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$6=$8;
+$recv($5)._add_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$9=$recv($4)._yourself();
+$3=$9;
+$1=self._inlinedSend_with_with_($2,anIRInstruction,$3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNil:",{anIRInstruction:anIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "ifNil: anIRInstruction\x0a\x09^ self\x0a\x09\x09inlinedSend: IRInlinedIfNilIfNotNil new\x0a\x09\x09with: anIRInstruction\x0a\x09\x09with: (IRClosure new\x0a\x09\x09\x09scope: anIRInstruction scope copy;\x0a\x09\x09\x09add: (IRBlockSequence new\x0a\x09\x09\x09\x09add: self send instructions first;\x0a\x09\x09\x09\x09yourself);\x0a\x09\x09\x09yourself)",
+referencedClasses: ["IRInlinedIfNilIfNotNil", "IRClosure", "IRBlockSequence"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:with:", "new", "scope:", "copy", "scope", "add:", "first", "instructions", "send", "yourself"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:ifNotNil:",
+protocol: 'inlining',
+fn: function (anIRInstruction,anotherIRInstruction){
+var self=this;
+function $IRInlinedIfNilIfNotNil(){return $globals.IRInlinedIfNilIfNotNil||(typeof IRInlinedIfNilIfNotNil=="undefined"?nil:IRInlinedIfNilIfNotNil)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._inlinedSend_with_with_($recv($IRInlinedIfNilIfNotNil())._new(),anIRInstruction,anotherIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNil:ifNotNil:",{anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction", "anotherIRInstruction"],
+source: "ifNil: anIRInstruction ifNotNil: anotherIRInstruction\x0a\x09^ self inlinedSend: IRInlinedIfNilIfNotNil new with: anIRInstruction with: anotherIRInstruction",
+referencedClasses: ["IRInlinedIfNilIfNotNil"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:with:", "new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:",
+protocol: 'inlining',
+fn: function (anIRInstruction){
+var self=this;
+function $IRInlinedIfNilIfNotNil(){return $globals.IRInlinedIfNilIfNotNil||(typeof IRInlinedIfNilIfNotNil=="undefined"?nil:IRInlinedIfNilIfNotNil)}
+function $IRClosure(){return $globals.IRClosure||(typeof IRClosure=="undefined"?nil:IRClosure)}
+function $IRBlockSequence(){return $globals.IRBlockSequence||(typeof IRBlockSequence=="undefined"?nil:IRBlockSequence)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$4,$5,$7,$8,$6,$9,$3,$1;
+$2=$recv($IRInlinedIfNilIfNotNil())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($IRClosure())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$recv($4)._scope_($recv($recv(anIRInstruction)._scope())._copy());
+$5=$4;
+$7=$recv($IRBlockSequence())._new();
+$recv($7)._add_($recv($recv(self._send())._instructions())._first());
+$8=$recv($7)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$6=$8;
+$recv($5)._add_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$9=$recv($4)._yourself();
+$3=$9;
+$1=self._inlinedSend_with_with_($2,$3,anIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotNil:",{anIRInstruction:anIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "ifNotNil: anIRInstruction\x0a\x09^ self\x0a\x09\x09inlinedSend: IRInlinedIfNilIfNotNil new\x0a\x09\x09with: (IRClosure new\x0a\x09\x09\x09scope: anIRInstruction scope copy;\x0a\x09\x09\x09add: (IRBlockSequence new\x0a\x09\x09\x09\x09add: self send instructions first;\x0a\x09\x09\x09\x09yourself);\x0a\x09\x09\x09yourself)\x0a\x09\x09with: anIRInstruction",
+referencedClasses: ["IRInlinedIfNilIfNotNil", "IRClosure", "IRBlockSequence"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:with:", "new", "scope:", "copy", "scope", "add:", "first", "instructions", "send", "yourself"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:ifNil:",
+protocol: 'inlining',
+fn: function (anIRInstruction,anotherIRInstruction){
+var self=this;
+function $IRInlinedIfNilIfNotNil(){return $globals.IRInlinedIfNilIfNotNil||(typeof IRInlinedIfNilIfNotNil=="undefined"?nil:IRInlinedIfNilIfNotNil)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._inlinedSend_with_with_($recv($IRInlinedIfNilIfNotNil())._new(),anotherIRInstruction,anIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotNil:ifNil:",{anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction", "anotherIRInstruction"],
+source: "ifNotNil: anIRInstruction ifNil: anotherIRInstruction\x0a\x09^ self inlinedSend: IRInlinedIfNilIfNotNil new with: anotherIRInstruction with: anIRInstruction",
+referencedClasses: ["IRInlinedIfNilIfNotNil"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:with:", "new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifTrue:",
+protocol: 'inlining',
+fn: function (anIRInstruction){
+var self=this;
+function $IRInlinedIfTrue(){return $globals.IRInlinedIfTrue||(typeof IRInlinedIfTrue=="undefined"?nil:IRInlinedIfTrue)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._inlinedSend_with_($recv($IRInlinedIfTrue())._new(),anIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifTrue:",{anIRInstruction:anIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "ifTrue: anIRInstruction\x0a\x09^ self inlinedSend: IRInlinedIfTrue new with: anIRInstruction",
+referencedClasses: ["IRInlinedIfTrue"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:", "new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "ifTrue:ifFalse:",
+protocol: 'inlining',
+fn: function (anIRInstruction,anotherIRInstruction){
+var self=this;
+function $IRInlinedIfTrueIfFalse(){return $globals.IRInlinedIfTrueIfFalse||(typeof IRInlinedIfTrueIfFalse=="undefined"?nil:IRInlinedIfTrueIfFalse)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._inlinedSend_with_with_($recv($IRInlinedIfTrueIfFalse())._new(),anIRInstruction,anotherIRInstruction);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifTrue:ifFalse:",{anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction", "anotherIRInstruction"],
+source: "ifTrue: anIRInstruction ifFalse: anotherIRInstruction\x0a\x09^ self inlinedSend: IRInlinedIfTrueIfFalse new with: anIRInstruction with: anotherIRInstruction",
+referencedClasses: ["IRInlinedIfTrueIfFalse"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedSend:with:with:", "new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlineClosure:",
+protocol: 'inlining',
+fn: function (anIRClosure){
+var self=this;
+var inlinedClosure,sequence,statements;
+function $IRTempDeclaration(){return $globals.IRTempDeclaration||(typeof IRTempDeclaration=="undefined"?nil:IRTempDeclaration)}
+function $IRAssignment(){return $globals.IRAssignment||(typeof IRAssignment=="undefined"?nil:IRAssignment)}
+function $IRVariable(){return $globals.IRVariable||(typeof IRVariable=="undefined"?nil:IRVariable)}
+function $AliasVar(){return $globals.AliasVar||(typeof AliasVar=="undefined"?nil:AliasVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$7,$8,$6,$9,$11,$12,$14,$16,$17,$18,$19,$15,$13,$20,$22,$24,$25,$23,$21,$26,$10,$28,$27,$31,$30,$32,$29,$33,$36,$35,$34,$37;
+inlinedClosure=self._inlinedClosure();
+$1=inlinedClosure;
+$2=$1;
+$3=$recv(anIRClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._scope_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($1)._parent_($recv(anIRClosure)._parent());
+$recv($recv(anIRClosure)._tempDeclarations())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(inlinedClosure)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+sequence=self._inlinedSequence();
+$recv($recv(anIRClosure)._arguments())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=inlinedClosure;
+$7=$recv($IRTempDeclaration())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($7)._name_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name:"]=1;
+//>>excludeEnd("ctx");
+$8=$recv($7)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$6=$8;
+$recv($5)._add_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+$9=sequence;
+$11=$recv($IRAssignment())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$12=$11;
+$14=$recv($IRVariable())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=3;
+//>>excludeEnd("ctx");
+$16=$recv($AliasVar())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=4;
+//>>excludeEnd("ctx");
+$17=$16;
+$18=$recv(inlinedClosure)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$recv($17)._scope_($18);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["scope:"]=2;
+//>>excludeEnd("ctx");
+$recv($16)._name_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name:"]=2;
+//>>excludeEnd("ctx");
+$19=$recv($16)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["yourself"]=2;
+//>>excludeEnd("ctx");
+$15=$19;
+$13=$recv($14)._variable_($15);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["variable:"]=1;
+//>>excludeEnd("ctx");
+$recv($12)._add_($13);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=4;
+//>>excludeEnd("ctx");
+$20=$11;
+$22=$recv($IRVariable())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=5;
+//>>excludeEnd("ctx");
+$24=$recv($AliasVar())._new();
+$recv($24)._scope_($recv(inlinedClosure)._scope());
+$recv($24)._name_("$receiver");
+$25=$recv($24)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["yourself"]=3;
+//>>excludeEnd("ctx");
+$23=$25;
+$21=$recv($22)._variable_($23);
+$recv($20)._add_($21);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=5;
+//>>excludeEnd("ctx");
+$26=$recv($11)._yourself();
+$10=$26;
+return $recv($9)._add_($10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=2;
+//>>excludeEnd("ctx");
+$recv(inlinedClosure)._add_(sequence);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=6;
+//>>excludeEnd("ctx");
+$28=$recv(anIRClosure)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=2;
+//>>excludeEnd("ctx");
+$27=$recv($28)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+statements=$recv($27)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv(statements)._ifNotEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv($recv(statements)._allButLast())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(sequence)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["add:"]=7;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,4)});
+//>>excludeEnd("ctx");
+}));
+$31=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=2;
+//>>excludeEnd("ctx");
+$30=$recv($31)._isReturn();
+$29=$recv($30)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$32=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["last"]=3;
+//>>excludeEnd("ctx");
+return $recv($32)._isBlockReturn();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($29)){
+$33=sequence;
+$36=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=4;
+//>>excludeEnd("ctx");
+$35=$recv($36)._instructions();
+$34=$recv($35)._first();
+return $recv($33)._add_($34);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=8;
+//>>excludeEnd("ctx");
+} else {
+return $recv(sequence)._add_($recv(statements)._last());
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$37=inlinedClosure;
+return $37;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineClosure:",{anIRClosure:anIRClosure,inlinedClosure:inlinedClosure,sequence:sequence,statements:statements},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure"],
+source: "inlineClosure: anIRClosure\x0a\x09| inlinedClosure sequence statements |\x0a\x0a\x09inlinedClosure := self inlinedClosure.\x0a\x09inlinedClosure \x0a\x09\x09scope: anIRClosure scope;\x0a\x09\x09parent: anIRClosure parent.\x0a\x0a\x09\x22Add the possible temp declarations\x22\x0a\x09anIRClosure tempDeclarations do: [ :each |\x0a\x09\x09\x09inlinedClosure add: each ].\x0a\x0a\x09\x22Add a block sequence\x22\x0a\x09sequence := self inlinedSequence.\x0a\x0a\x09\x22Map the closure arguments to the receiver of the message send\x22\x0a\x09anIRClosure arguments do: [ :each |\x0a\x09\x09inlinedClosure add: (IRTempDeclaration new name: each; yourself).\x0a\x09\x09sequence add: (IRAssignment new\x0a\x09\x09\x09add: (IRVariable new variable: (AliasVar new scope: inlinedClosure scope; name: each; yourself));\x0a\x09\x09\x09add: (IRVariable new variable: (AliasVar new scope: inlinedClosure scope; name: '$receiver'; yourself));\x0a\x09\x09\x09yourself) ].\x0a\x09\x09\x09\x0a\x09\x22To ensure the correct order of the closure instructions: first the temps then the sequence\x22\x0a\x09inlinedClosure add: sequence.\x0a\x0a\x09\x22Get all the statements\x22\x0a\x09statements := anIRClosure instructions last instructions.\x0a\x09\x0a\x09statements ifNotEmpty: [\x0a\x09\x09statements allButLast do: [ :each | sequence add: each ].\x0a\x0a\x09\x09\x22Inlined closures don't have implicit local returns\x22\x0a\x09\x09(statements last isReturn and: [ statements last isBlockReturn ])\x0a\x09\x09\x09ifTrue: [ sequence add: statements last instructions first ]\x0a\x09\x09\x09ifFalse: [ sequence add: statements last ] ].\x0a\x0a\x09^ inlinedClosure",
+referencedClasses: ["IRTempDeclaration", "IRAssignment", "IRVariable", "AliasVar"],
+//>>excludeEnd("ide");
+messageSends: ["inlinedClosure", "scope:", "scope", "parent:", "parent", "do:", "tempDeclarations", "add:", "inlinedSequence", "arguments", "name:", "new", "yourself", "variable:", "instructions", "last", "ifNotEmpty:", "allButLast", "ifTrue:ifFalse:", "and:", "isReturn", "isBlockReturn", "first"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlineSend:",
+protocol: 'inlining',
+fn: function (anIRSend){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+self._send_(anIRSend);
+$3=self._send();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["send"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._selector();
+$1=self._perform_withArguments_($2,$recv($recv(self._send())._instructions())._allButFirst());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineSend:",{anIRSend:anIRSend},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "inlineSend: anIRSend\x0a\x09self send: anIRSend.\x0a\x09^ self\x0a\x09\x09perform: self send selector\x0a\x09\x09withArguments: self send instructions allButFirst",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["send:", "perform:withArguments:", "selector", "send", "allButFirst", "instructions"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlinedClosure",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRInlinedClosure(){return $globals.IRInlinedClosure||(typeof IRInlinedClosure=="undefined"?nil:IRInlinedClosure)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRInlinedClosure())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlinedClosure",{},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inlinedClosure\x0a\x09^ IRInlinedClosure new",
+referencedClasses: ["IRInlinedClosure"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlinedSend:with:",
+protocol: 'inlining',
+fn: function (inlinedSend,anIRInstruction){
+var self=this;
+var inlinedClosure;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$5,$4,$3,$6,$7;
+$1=$recv(anIRInstruction)._isClosure();
+if(!$core.assert($1)){
+self._inliningError_("Message argument should be a block");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["inliningError:"]=1;
+//>>excludeEnd("ctx");
+};
+$2=$recv($recv($recv(anIRInstruction)._arguments())._size()).__eq((0));
+if(!$core.assert($2)){
+self._inliningError_("Inlined block should have zero argument");
+};
+inlinedClosure=$recv(self._translator())._visit_(self._inlineClosure_(anIRInstruction));
+$5=self._send();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["send"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._instructions();
+$3=$recv($4)._first();
+$recv(inlinedSend)._add_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(inlinedSend)._add_(inlinedClosure);
+$recv(self._send())._replaceWith_(inlinedSend);
+$7=$recv($recv(inlinedSend)._method())._internalVariables();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["internalVariables"]=1;
+//>>excludeEnd("ctx");
+$recv($7)._addAll_($recv(inlinedSend)._internalVariables());
+return inlinedSend;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlinedSend:with:",{inlinedSend:inlinedSend,anIRInstruction:anIRInstruction,inlinedClosure:inlinedClosure},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["inlinedSend", "anIRInstruction"],
+source: "inlinedSend: inlinedSend with: anIRInstruction\x0a\x09| inlinedClosure |\x0a\x0a\x09anIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].\x0a\x09anIRInstruction arguments size = 0 ifFalse: [ self inliningError: 'Inlined block should have zero argument' ].\x0a\x0a\x09inlinedClosure := self translator visit: (self inlineClosure: anIRInstruction).\x0a\x0a\x09inlinedSend\x0a\x09\x09add: self send instructions first;\x0a\x09\x09add: inlinedClosure.\x0a\x0a\x09self send replaceWith: inlinedSend.\x0a\x09inlinedSend method internalVariables \x0a\x09\x09addAll: inlinedSend internalVariables.\x0a\x0a\x09^ inlinedSend",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isClosure", "inliningError:", "=", "size", "arguments", "visit:", "translator", "inlineClosure:", "add:", "first", "instructions", "send", "replaceWith:", "addAll:", "internalVariables", "method"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlinedSend:with:with:",
+protocol: 'inlining',
+fn: function (inlinedSend,anIRInstruction,anotherIRInstruction){
+var self=this;
+var inlinedClosure1,inlinedClosure2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$7,$6,$5,$8,$9;
+$1=$recv(anIRInstruction)._isClosure();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["isClosure"]=1;
+//>>excludeEnd("ctx");
+if(!$core.assert($1)){
+self._inliningError_("Message argument should be a block");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["inliningError:"]=1;
+//>>excludeEnd("ctx");
+};
+$2=$recv(anotherIRInstruction)._isClosure();
+if(!$core.assert($2)){
+self._inliningError_("Message argument should be a block");
+};
+$3=self._translator();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["translator"]=1;
+//>>excludeEnd("ctx");
+$4=self._inlineClosure_(anIRInstruction);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["inlineClosure:"]=1;
+//>>excludeEnd("ctx");
+inlinedClosure1=$recv($3)._visit_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+inlinedClosure2=$recv(self._translator())._visit_(self._inlineClosure_(anotherIRInstruction));
+$7=self._send();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["send"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7)._instructions();
+$5=$recv($6)._first();
+$recv(inlinedSend)._add_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv(inlinedSend)._add_(inlinedClosure1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+$8=$recv(inlinedSend)._add_(inlinedClosure2);
+$recv(self._send())._replaceWith_(inlinedSend);
+$9=$recv($recv(inlinedSend)._method())._internalVariables();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["internalVariables"]=1;
+//>>excludeEnd("ctx");
+$recv($9)._addAll_($recv(inlinedSend)._internalVariables());
+return inlinedSend;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlinedSend:with:with:",{inlinedSend:inlinedSend,anIRInstruction:anIRInstruction,anotherIRInstruction:anotherIRInstruction,inlinedClosure1:inlinedClosure1,inlinedClosure2:inlinedClosure2},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["inlinedSend", "anIRInstruction", "anotherIRInstruction"],
+source: "inlinedSend: inlinedSend with: anIRInstruction with: anotherIRInstruction\x0a\x09| inlinedClosure1 inlinedClosure2 |\x0a\x0a\x09anIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].\x0a\x09anotherIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].\x0a\x0a\x09inlinedClosure1 := self translator visit: (self inlineClosure: anIRInstruction).\x0a\x09inlinedClosure2 := self translator visit: (self inlineClosure: anotherIRInstruction).\x0a\x0a\x09inlinedSend\x0a\x09\x09add: self send instructions first;\x0a\x09\x09add: inlinedClosure1;\x0a\x09\x09add: inlinedClosure2.\x0a\x0a\x09self send replaceWith: inlinedSend.\x0a\x09inlinedSend method internalVariables \x0a\x09\x09addAll: inlinedSend internalVariables.\x0a\x09\x09\x0a\x09^ inlinedSend",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isClosure", "inliningError:", "visit:", "translator", "inlineClosure:", "add:", "first", "instructions", "send", "replaceWith:", "addAll:", "internalVariables", "method"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlinedSequence",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRInlinedSequence(){return $globals.IRInlinedSequence||(typeof IRInlinedSequence=="undefined"?nil:IRInlinedSequence)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRInlinedSequence())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlinedSequence",{},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inlinedSequence\x0a\x09^ IRInlinedSequence new",
+referencedClasses: ["IRInlinedSequence"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inliningError:",
+protocol: 'error handling',
+fn: function (aString){
+var self=this;
+function $InliningError(){return $globals.InliningError||(typeof InliningError=="undefined"?nil:InliningError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($InliningError())._signal_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inliningError:",{aString:aString},$globals.IRSendInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "inliningError: aString\x0a\x09InliningError signal: aString",
+referencedClasses: ["InliningError"],
+//>>excludeEnd("ide");
+messageSends: ["signal:"]
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "send",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@send"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "send\x0a\x09^ send",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "send:",
+protocol: 'accessing',
+fn: function (anIRSend){
+var self=this;
+self["@send"]=anIRSend;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRSend"],
+source: "send: anIRSend\x0a\x09send := anIRSend",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "translator",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@translator"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "translator\x0a\x09^ translator",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSendInliner);
+
+$core.addMethod(
+$core.method({
+selector: "translator:",
+protocol: 'accessing',
+fn: function (anASTTranslator){
+var self=this;
+self["@translator"]=anASTTranslator;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anASTTranslator"],
+source: "translator: anASTTranslator\x0a\x09translator := anASTTranslator",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSendInliner);
+
+
+$core.addMethod(
+$core.method({
+selector: "inlinedSelectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=["ifTrue:", "ifFalse:", "ifTrue:ifFalse:", "ifFalse:ifTrue:", "ifNil:", "ifNotNil:", "ifNil:ifNotNil:", "ifNotNil:ifNil:"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inlinedSelectors\x0a\x09^ #('ifTrue:' 'ifFalse:' 'ifTrue:ifFalse:' 'ifFalse:ifTrue:' 'ifNil:' 'ifNotNil:' 'ifNil:ifNotNil:' 'ifNotNil:ifNil:')",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRSendInliner.klass);
+
+$core.addMethod(
+$core.method({
+selector: "shouldInline:",
+protocol: 'accessing',
+fn: function (anIRInstruction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+$1=$recv(self._inlinedSelectors())._includes_($recv(anIRInstruction)._selector());
+if(!$core.assert($1)){
+return false;
+};
+$recv($recv($recv(anIRInstruction)._instructions())._allButFirst())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(each)._isClosure();
+if(!$core.assert($2)){
+throw $early=[false];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return true;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldInline:",{anIRInstruction:anIRInstruction},$globals.IRSendInliner.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "shouldInline: anIRInstruction\x0a\x09(self inlinedSelectors includes: anIRInstruction selector) ifFalse: [ ^ false ].\x0a\x09anIRInstruction instructions allButFirst do: [ :each |\x0a\x09\x09each isClosure ifFalse: [ ^ false ]].\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "includes:", "inlinedSelectors", "selector", "do:", "allButFirst", "instructions", "isClosure"]
+}),
+$globals.IRSendInliner.klass);
+
+
+$core.addClass('IRAssignmentInliner', $globals.IRSendInliner, ['assignment'], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRAssignmentInliner.comment="I inline message sends together with assignments by moving them around into the inline closure instructions.\x0a\x0a##Example\x0a\x0a\x09foo\x0a\x09\x09| a |\x0a\x09\x09a := true ifTrue: [ 1 ]\x0a\x0aWill produce:\x0a\x0a\x09if($core.assert(true) {\x0a\x09\x09a = 1;\x0a\x09};";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "assignment",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@assignment"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "assignment\x0a\x09^ assignment",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRAssignmentInliner);
+
+$core.addMethod(
+$core.method({
+selector: "assignment:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@assignment"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "assignment: aNode\x0a\x09assignment := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.IRAssignmentInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlineAssignment:",
+protocol: 'inlining',
+fn: function (anIRAssignment){
+var self=this;
+var inlinedAssignment;
+function $IRInlinedAssignment(){return $globals.IRInlinedAssignment||(typeof IRInlinedAssignment=="undefined"?nil:IRInlinedAssignment)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._assignment_(anIRAssignment);
+inlinedAssignment=$recv($IRInlinedAssignment())._new();
+$1=$recv(anIRAssignment)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(inlinedAssignment)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(anIRAssignment)._replaceWith_(inlinedAssignment);
+self._inlineSend_($recv($recv(inlinedAssignment)._instructions())._last());
+$2=inlinedAssignment;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineAssignment:",{anIRAssignment:anIRAssignment,inlinedAssignment:inlinedAssignment},$globals.IRAssignmentInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRAssignment"],
+source: "inlineAssignment: anIRAssignment\x0a\x09| inlinedAssignment |\x0a\x09self assignment: anIRAssignment.\x0a\x09inlinedAssignment := IRInlinedAssignment new.\x0a\x09anIRAssignment instructions do: [ :each |\x0a\x09\x09inlinedAssignment add: each ].\x0a\x09anIRAssignment replaceWith: inlinedAssignment.\x0a\x09self inlineSend: inlinedAssignment instructions last.\x0a\x09^ inlinedAssignment",
+referencedClasses: ["IRInlinedAssignment"],
+//>>excludeEnd("ide");
+messageSends: ["assignment:", "new", "do:", "instructions", "add:", "replaceWith:", "inlineSend:", "last"]
+}),
+$globals.IRAssignmentInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlineClosure:",
+protocol: 'inlining',
+fn: function (anIRClosure){
+var self=this;
+var inlinedClosure,statements;
+function $IRAssignment(){return $globals.IRAssignment||(typeof IRAssignment=="undefined"?nil:IRAssignment)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$4,$3,$5,$7,$8,$6,$9;
+inlinedClosure=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRAssignmentInliner.superclass.fn.prototype._inlineClosure_.apply($recv(self), [anIRClosure]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$2=$recv(inlinedClosure)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+statements=$recv($1)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv(statements)._ifNotEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4)._canBeAssigned();
+if($core.assert($3)){
+$5=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=3;
+//>>excludeEnd("ctx");
+$7=$recv($IRAssignment())._new();
+$recv($7)._add_($recv($recv(self._assignment())._instructions())._first());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv($7)._add_($recv($recv(statements)._last())._copy());
+$8=$recv($7)._yourself();
+$6=$8;
+return $recv($5)._replaceWith_($6);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$9=inlinedClosure;
+return $9;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineClosure:",{anIRClosure:anIRClosure,inlinedClosure:inlinedClosure,statements:statements},$globals.IRAssignmentInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure"],
+source: "inlineClosure: anIRClosure\x0a\x09| inlinedClosure statements |\x0a\x0a\x09inlinedClosure := super inlineClosure: anIRClosure.\x0a\x09statements := inlinedClosure instructions last instructions.\x0a\x09\x0a\x09statements ifNotEmpty: [\x0a\x09\x09statements last canBeAssigned ifTrue: [\x0a\x09\x09\x09statements last replaceWith: (IRAssignment new\x0a\x09\x09\x09\x09add: self assignment instructions first;\x0a\x09\x09\x09\x09add: statements last copy;\x0a\x09\x09\x09\x09yourself) ] ].\x0a\x0a\x09^ inlinedClosure",
+referencedClasses: ["IRAssignment"],
+//>>excludeEnd("ide");
+messageSends: ["inlineClosure:", "instructions", "last", "ifNotEmpty:", "ifTrue:", "canBeAssigned", "replaceWith:", "add:", "new", "first", "assignment", "copy", "yourself"]
+}),
+$globals.IRAssignmentInliner);
+
+
+
+$core.addClass('IRReturnInliner', $globals.IRSendInliner, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IRReturnInliner.comment="I inline message sends with inlined closure together with a return instruction.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "inlineClosure:",
+protocol: 'inlining',
+fn: function (anIRClosure){
+var self=this;
+var closure,statements;
+function $IRReturn(){return $globals.IRReturn||(typeof IRReturn=="undefined"?nil:IRReturn)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$6,$7;
+closure=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.IRReturnInliner.superclass.fn.prototype._inlineClosure_.apply($recv(self), [anIRClosure]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($recv(closure)._instructions())._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+statements=$recv($1)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv(statements)._ifNotEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3)._isReturn();
+if(!$core.assert($2)){
+$4=$recv(statements)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["last"]=3;
+//>>excludeEnd("ctx");
+$5=$recv($IRReturn())._new();
+$recv($5)._add_($recv($recv(statements)._last())._copy());
+$6=$recv($5)._yourself();
+return $recv($4)._replaceWith_($6);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$7=closure;
+return $7;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineClosure:",{anIRClosure:anIRClosure,closure:closure,statements:statements},$globals.IRReturnInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRClosure"],
+source: "inlineClosure: anIRClosure\x0a\x09| closure statements |\x0a\x0a\x09closure := super inlineClosure: anIRClosure.\x0a\x09statements := closure instructions last instructions.\x0a\x09\x0a\x09statements ifNotEmpty: [\x0a\x09\x09statements last isReturn\x0a\x09\x09\x09ifFalse: [ statements last replaceWith: (IRReturn new\x0a\x09\x09\x09\x09add: statements last copy;\x0a\x09\x09\x09\x09yourself)] ].\x0a\x0a\x09^ closure",
+referencedClasses: ["IRReturn"],
+//>>excludeEnd("ide");
+messageSends: ["inlineClosure:", "instructions", "last", "ifNotEmpty:", "ifFalse:", "isReturn", "replaceWith:", "add:", "new", "copy", "yourself"]
+}),
+$globals.IRReturnInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlineReturn:",
+protocol: 'inlining',
+fn: function (anIRReturn){
+var self=this;
+var return_;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+return_=self._inlinedReturn();
+$1=$recv(anIRReturn)._instructions();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instructions"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(return_)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(anIRReturn)._replaceWith_(return_);
+self._inlineSend_($recv($recv(return_)._instructions())._last());
+$2=return_;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlineReturn:",{anIRReturn:anIRReturn,return_:return_},$globals.IRReturnInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRReturn"],
+source: "inlineReturn: anIRReturn\x0a\x09| return |\x0a\x09return := self inlinedReturn.\x0a\x09anIRReturn instructions do: [ :each |\x0a\x09\x09return add: each ].\x0a\x09anIRReturn replaceWith: return.\x0a\x09self inlineSend: return instructions last.\x0a\x09^ return",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["inlinedReturn", "do:", "instructions", "add:", "replaceWith:", "inlineSend:", "last"]
+}),
+$globals.IRReturnInliner);
+
+$core.addMethod(
+$core.method({
+selector: "inlinedReturn",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $IRInlinedReturn(){return $globals.IRInlinedReturn||(typeof IRInlinedReturn=="undefined"?nil:IRInlinedReturn)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRInlinedReturn())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inlinedReturn",{},$globals.IRReturnInliner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inlinedReturn\x0a\x09^ IRInlinedReturn new",
+referencedClasses: ["IRInlinedReturn"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.IRReturnInliner);
+
+
+
+$core.addClass('InliningCodeGenerator', $globals.CodeGenerator, [], 'Compiler-Inlining');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.InliningCodeGenerator.comment="I am a specialized code generator that uses inlining to produce more optimized JavaScript output";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "compileNode:",
+protocol: 'compiling',
+fn: function (aNode){
+var self=this;
+var ir,stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$recv(self._semanticAnalyzer())._visit_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+ir=$recv(self._translator())._visit_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=2;
+//>>excludeEnd("ctx");
+$recv(self._inliner())._visit_(ir);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=3;
+//>>excludeEnd("ctx");
+$2=self._irTranslator();
+$recv($2)._currentClass_(self._currentClass());
+$recv($2)._visit_(ir);
+$3=$recv($2)._contents();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileNode:",{aNode:aNode,ir:ir,stream:stream},$globals.InliningCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "compileNode: aNode\x0a\x09| ir stream |\x0a\x0a\x09self semanticAnalyzer visit: aNode.\x0a\x09ir := self translator visit: aNode.\x0a\x09self inliner visit: ir.\x0a\x0a\x09^ self irTranslator\x0a\x09\x09currentClass: self currentClass;\x0a\x09\x09visit: ir;\x0a\x09\x09contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "semanticAnalyzer", "translator", "inliner", "currentClass:", "irTranslator", "currentClass", "contents"]
+}),
+$globals.InliningCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "inliner",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $IRInliner(){return $globals.IRInliner||(typeof IRInliner=="undefined"?nil:IRInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRInliner())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inliner",{},$globals.InliningCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inliner\x0a\x09^ IRInliner new",
+referencedClasses: ["IRInliner"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.InliningCodeGenerator);
+
+$core.addMethod(
+$core.method({
+selector: "irTranslator",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $IRInliningJSTranslator(){return $globals.IRInliningJSTranslator||(typeof IRInliningJSTranslator=="undefined"?nil:IRInliningJSTranslator)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($IRInliningJSTranslator())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"irTranslator",{},$globals.InliningCodeGenerator)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "irTranslator\x0a\x09^ IRInliningJSTranslator new",
+referencedClasses: ["IRInliningJSTranslator"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.InliningCodeGenerator);
+
+
+});

+ 636 - 0
bower_components/amber/src/Compiler-Inlining.st

@@ -0,0 +1,636 @@
+Smalltalk createPackage: 'Compiler-Inlining'!
+IRAssignment subclass: #IRInlinedAssignment
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedAssignment commentStamp!
+I represent an inlined assignment instruction.!
+
+!IRInlinedAssignment methodsFor: 'testing'!
+
+isInlined
+	^ true
+! !
+
+!IRInlinedAssignment methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRInlinedAssignment: self
+! !
+
+IRClosure subclass: #IRInlinedClosure
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedClosure commentStamp!
+I represent an inlined closure instruction.!
+
+!IRInlinedClosure methodsFor: 'testing'!
+
+isInlined
+	^ true
+! !
+
+!IRInlinedClosure methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedClosure: self
+! !
+
+IRReturn subclass: #IRInlinedReturn
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedReturn commentStamp!
+I represent an inlined local return instruction.!
+
+!IRInlinedReturn methodsFor: 'testing'!
+
+isInlined
+	^ true
+! !
+
+!IRInlinedReturn methodsFor: 'visiting'!
+
+accept: aVisitor
+	^ aVisitor visitIRInlinedReturn: self
+! !
+
+IRSend subclass: #IRInlinedSend
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedSend commentStamp!
+I am the abstract super class of inlined message send instructions.!
+
+!IRInlinedSend methodsFor: 'accessing'!
+
+internalVariables
+	"Answer a collection of internal variables required 
+	to perform the inlining"
+	
+	^ #()
+! !
+
+!IRInlinedSend methodsFor: 'testing'!
+
+isInlined
+	^ true
+! !
+
+!IRInlinedSend methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitInlinedSend: self
+! !
+
+IRInlinedSend subclass: #IRInlinedIfFalse
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedIfFalse commentStamp!
+I represent an inlined `#ifFalse:` message send instruction.!
+
+!IRInlinedIfFalse methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedIfFalse: self
+! !
+
+IRInlinedSend subclass: #IRInlinedIfNilIfNotNil
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedIfNilIfNotNil commentStamp!
+I represent an inlined `#ifNil:ifNotNil:` message send instruction.!
+
+!IRInlinedIfNilIfNotNil methodsFor: 'accessing'!
+
+internalVariables
+	^ Array with: self receiverInternalVariable
+!
+
+receiverInternalVariable
+	^ IRVariable new
+		variable: (AliasVar new name: self receiverInternalVariableName);
+		yourself.
+!
+
+receiverInternalVariableName
+	^ '$receiver'
+! !
+
+!IRInlinedIfNilIfNotNil methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedIfNilIfNotNil: self
+! !
+
+IRInlinedSend subclass: #IRInlinedIfTrue
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedIfTrue commentStamp!
+I represent an inlined `#ifTrue:` message send instruction.!
+
+!IRInlinedIfTrue methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedIfTrue: self
+! !
+
+IRInlinedSend subclass: #IRInlinedIfTrueIfFalse
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedIfTrueIfFalse commentStamp!
+I represent an inlined `#ifTrue:ifFalse:` message send instruction.!
+
+!IRInlinedIfTrueIfFalse methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedIfTrueIfFalse: self
+! !
+
+IRBlockSequence subclass: #IRInlinedSequence
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInlinedSequence commentStamp!
+I represent a (block) sequence inside an inlined closure instruction (instance of `IRInlinedClosure`).!
+
+!IRInlinedSequence methodsFor: 'testing'!
+
+isInlined
+	^ true
+! !
+
+!IRInlinedSequence methodsFor: 'visiting'!
+
+accept: aVisitor
+	aVisitor visitIRInlinedSequence: self
+! !
+
+IRVisitor subclass: #IRInliner
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInliner commentStamp!
+I visit an IR tree, inlining message sends and block closures.
+
+Message selectors that can be inlined are answered by `IRSendInliner >> #inlinedSelectors`!
+
+!IRInliner methodsFor: 'factory'!
+
+assignmentInliner
+	^ IRAssignmentInliner new
+		translator: self;
+		yourself
+!
+
+returnInliner
+	^ IRReturnInliner new
+		translator: self;
+		yourself
+!
+
+sendInliner
+	^ IRSendInliner new
+		translator: self;
+		yourself
+! !
+
+!IRInliner methodsFor: 'testing'!
+
+shouldInlineAssignment: anIRAssignment
+	^ anIRAssignment isInlined not and: [
+		anIRAssignment instructions last isSend and: [
+			self shouldInlineSend: (anIRAssignment instructions last) ]]
+!
+
+shouldInlineReturn: anIRReturn
+	^ anIRReturn isInlined not and: [
+		anIRReturn instructions first isSend and: [
+			self shouldInlineSend: (anIRReturn instructions first) ]]
+!
+
+shouldInlineSend: anIRSend
+	^ anIRSend isInlined not and: [
+		IRSendInliner shouldInline: anIRSend ]
+! !
+
+!IRInliner methodsFor: 'visiting'!
+
+transformNonLocalReturn: anIRNonLocalReturn
+	"Replace a non local return into a local return"
+
+	| localReturn |
+	anIRNonLocalReturn scope canInlineNonLocalReturns ifTrue: [
+		anIRNonLocalReturn scope methodScope removeNonLocalReturn: anIRNonLocalReturn scope.
+		localReturn := IRReturn new
+			scope: anIRNonLocalReturn scope;
+			yourself.
+		anIRNonLocalReturn instructions do: [ :each |
+			localReturn add: each ].
+		anIRNonLocalReturn replaceWith: localReturn.
+		^ localReturn ].
+	^ super visitIRNonLocalReturn: anIRNonLocalReturn
+!
+
+visitIRAssignment: anIRAssignment
+	^ (self shouldInlineAssignment: anIRAssignment)
+		ifTrue: [ self assignmentInliner inlineAssignment: anIRAssignment ]
+		ifFalse: [ super visitIRAssignment: anIRAssignment ]
+!
+
+visitIRNonLocalReturn: anIRNonLocalReturn
+	^ self transformNonLocalReturn: anIRNonLocalReturn
+!
+
+visitIRReturn: anIRReturn
+	^ (self shouldInlineReturn: anIRReturn)
+		ifTrue: [ self returnInliner inlineReturn: anIRReturn ]
+		ifFalse: [ super visitIRReturn: anIRReturn ]
+!
+
+visitIRSend: anIRSend
+	^ (self shouldInlineSend: anIRSend)
+		ifTrue: [ self sendInliner inlineSend: anIRSend ]
+		ifFalse: [ super visitIRSend: anIRSend ]
+! !
+
+IRJSTranslator subclass: #IRInliningJSTranslator
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRInliningJSTranslator commentStamp!
+I am a specialized JavaScript translator able to write inlined IR instructions to JavaScript stream (`JSStream` instance).!
+
+!IRInliningJSTranslator methodsFor: 'visiting'!
+
+visitIRInlinedAssignment: anIRInlinedAssignment
+	self visit: anIRInlinedAssignment instructions last
+!
+
+visitIRInlinedClosure: anIRInlinedClosure
+	self stream nextPutVars: (anIRInlinedClosure tempDeclarations collect: [ :each |
+		each name asVariableName ]).
+	anIRInlinedClosure instructions do: [ :each |
+		self visit: each ]
+!
+
+visitIRInlinedIfFalse: anIRInlinedIfFalse
+	self stream nextPutIf: [
+		self stream nextPutAll: '!!$core.assert('.
+		self visit: anIRInlinedIfFalse instructions first.
+		self stream nextPutAll: ')' ]
+		with: [ self visit: anIRInlinedIfFalse instructions last ]
+!
+
+visitIRInlinedIfNilIfNotNil: anIRInlinedIfNilIfNotNil
+	self stream
+		nextPutIfElse: [
+			self stream nextPutAll: '(', anIRInlinedIfNilIfNotNil receiverInternalVariableName, ' = '.
+			self visit: anIRInlinedIfNilIfNotNil instructions first.
+			self stream nextPutAll: ') == null || $receiver.isNil' ]
+		with: [ self visit: anIRInlinedIfNilIfNotNil instructions second ]
+		with: [ self visit: anIRInlinedIfNilIfNotNil instructions third ]
+!
+
+visitIRInlinedIfTrue: anIRInlinedIfTrue
+	self stream nextPutIf: [
+		self stream nextPutAll: '$core.assert('.
+		self visit: anIRInlinedIfTrue instructions first.
+		self stream nextPutAll: ')' ]
+		with: [ self visit: anIRInlinedIfTrue instructions last ]
+!
+
+visitIRInlinedIfTrueIfFalse: anIRInlinedIfTrueIfFalse
+	self stream
+		nextPutIfElse: [
+			self stream nextPutAll: '$core.assert('.
+			self visit: anIRInlinedIfTrueIfFalse instructions first.
+			self stream nextPutAll: ')' ]
+		with: [ self visit: anIRInlinedIfTrueIfFalse instructions second ]
+		with: [ self visit: anIRInlinedIfTrueIfFalse instructions third ]
+!
+
+visitIRInlinedNonLocalReturn: anIRInlinedReturn
+	self stream nextPutStatementWith: [
+		self visit: anIRInlinedReturn instructions last ].
+	self stream nextPutNonLocalReturnWith: [ ]
+!
+
+visitIRInlinedReturn: anIRInlinedReturn
+	self visit: anIRInlinedReturn instructions last
+!
+
+visitIRInlinedSequence: anIRInlinedSequence
+	anIRInlinedSequence instructions do: [ :each |
+		self stream nextPutStatementWith: [ self visit: each ]]
+! !
+
+Object subclass: #IRSendInliner
+	instanceVariableNames: 'send translator'
+	package: 'Compiler-Inlining'!
+!IRSendInliner commentStamp!
+I inline some message sends and block closure arguments. I heavily rely on #perform: to dispatch inlining methods.!
+
+!IRSendInliner methodsFor: 'accessing'!
+
+send
+	^ send
+!
+
+send: anIRSend
+	send := anIRSend
+!
+
+translator
+	^ translator
+!
+
+translator: anASTTranslator
+	translator := anASTTranslator
+! !
+
+!IRSendInliner methodsFor: 'error handling'!
+
+inliningError: aString
+	InliningError signal: aString
+! !
+
+!IRSendInliner methodsFor: 'factory'!
+
+inlinedClosure
+	^ IRInlinedClosure new
+!
+
+inlinedSequence
+	^ IRInlinedSequence new
+! !
+
+!IRSendInliner methodsFor: 'inlining'!
+
+ifFalse: anIRInstruction
+	^ self inlinedSend: IRInlinedIfFalse new with: anIRInstruction
+!
+
+ifFalse: anIRInstruction ifTrue: anotherIRInstruction
+	^ self perform: #ifTrue:ifFalse: withArguments: { anotherIRInstruction. anIRInstruction }
+!
+
+ifNil: anIRInstruction
+	^ self
+		inlinedSend: IRInlinedIfNilIfNotNil new
+		with: anIRInstruction
+		with: (IRClosure new
+			scope: anIRInstruction scope copy;
+			add: (IRBlockSequence new
+				add: self send instructions first;
+				yourself);
+			yourself)
+!
+
+ifNil: anIRInstruction ifNotNil: anotherIRInstruction
+	^ self inlinedSend: IRInlinedIfNilIfNotNil new with: anIRInstruction with: anotherIRInstruction
+!
+
+ifNotNil: anIRInstruction
+	^ self
+		inlinedSend: IRInlinedIfNilIfNotNil new
+		with: (IRClosure new
+			scope: anIRInstruction scope copy;
+			add: (IRBlockSequence new
+				add: self send instructions first;
+				yourself);
+			yourself)
+		with: anIRInstruction
+!
+
+ifNotNil: anIRInstruction ifNil: anotherIRInstruction
+	^ self inlinedSend: IRInlinedIfNilIfNotNil new with: anotherIRInstruction with: anIRInstruction
+!
+
+ifTrue: anIRInstruction
+	^ self inlinedSend: IRInlinedIfTrue new with: anIRInstruction
+!
+
+ifTrue: anIRInstruction ifFalse: anotherIRInstruction
+	^ self inlinedSend: IRInlinedIfTrueIfFalse new with: anIRInstruction with: anotherIRInstruction
+!
+
+inlineClosure: anIRClosure
+	| inlinedClosure sequence statements |
+
+	inlinedClosure := self inlinedClosure.
+	inlinedClosure 
+		scope: anIRClosure scope;
+		parent: anIRClosure parent.
+
+	"Add the possible temp declarations"
+	anIRClosure tempDeclarations do: [ :each |
+			inlinedClosure add: each ].
+
+	"Add a block sequence"
+	sequence := self inlinedSequence.
+
+	"Map the closure arguments to the receiver of the message send"
+	anIRClosure arguments do: [ :each |
+		inlinedClosure add: (IRTempDeclaration new name: each; yourself).
+		sequence add: (IRAssignment new
+			add: (IRVariable new variable: (AliasVar new scope: inlinedClosure scope; name: each; yourself));
+			add: (IRVariable new variable: (AliasVar new scope: inlinedClosure scope; name: '$receiver'; yourself));
+			yourself) ].
+			
+	"To ensure the correct order of the closure instructions: first the temps then the sequence"
+	inlinedClosure add: sequence.
+
+	"Get all the statements"
+	statements := anIRClosure instructions last instructions.
+	
+	statements ifNotEmpty: [
+		statements allButLast do: [ :each | sequence add: each ].
+
+		"Inlined closures don't have implicit local returns"
+		(statements last isReturn and: [ statements last isBlockReturn ])
+			ifTrue: [ sequence add: statements last instructions first ]
+			ifFalse: [ sequence add: statements last ] ].
+
+	^ inlinedClosure
+!
+
+inlineSend: anIRSend
+	self send: anIRSend.
+	^ self
+		perform: self send selector
+		withArguments: self send instructions allButFirst
+!
+
+inlinedSend: inlinedSend with: anIRInstruction
+	| inlinedClosure |
+
+	anIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].
+	anIRInstruction arguments size = 0 ifFalse: [ self inliningError: 'Inlined block should have zero argument' ].
+
+	inlinedClosure := self translator visit: (self inlineClosure: anIRInstruction).
+
+	inlinedSend
+		add: self send instructions first;
+		add: inlinedClosure.
+
+	self send replaceWith: inlinedSend.
+	inlinedSend method internalVariables 
+		addAll: inlinedSend internalVariables.
+
+	^ inlinedSend
+!
+
+inlinedSend: inlinedSend with: anIRInstruction with: anotherIRInstruction
+	| inlinedClosure1 inlinedClosure2 |
+
+	anIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].
+	anotherIRInstruction isClosure ifFalse: [ self inliningError: 'Message argument should be a block' ].
+
+	inlinedClosure1 := self translator visit: (self inlineClosure: anIRInstruction).
+	inlinedClosure2 := self translator visit: (self inlineClosure: anotherIRInstruction).
+
+	inlinedSend
+		add: self send instructions first;
+		add: inlinedClosure1;
+		add: inlinedClosure2.
+
+	self send replaceWith: inlinedSend.
+	inlinedSend method internalVariables 
+		addAll: inlinedSend internalVariables.
+		
+	^ inlinedSend
+! !
+
+!IRSendInliner class methodsFor: 'accessing'!
+
+inlinedSelectors
+	^ #('ifTrue:' 'ifFalse:' 'ifTrue:ifFalse:' 'ifFalse:ifTrue:' 'ifNil:' 'ifNotNil:' 'ifNil:ifNotNil:' 'ifNotNil:ifNil:')
+!
+
+shouldInline: anIRInstruction
+	(self inlinedSelectors includes: anIRInstruction selector) ifFalse: [ ^ false ].
+	anIRInstruction instructions allButFirst do: [ :each |
+		each isClosure ifFalse: [ ^ false ]].
+	^ true
+! !
+
+IRSendInliner subclass: #IRAssignmentInliner
+	instanceVariableNames: 'assignment'
+	package: 'Compiler-Inlining'!
+!IRAssignmentInliner commentStamp!
+I inline message sends together with assignments by moving them around into the inline closure instructions.
+
+##Example
+
+	foo
+		| a |
+		a := true ifTrue: [ 1 ]
+
+Will produce:
+
+	if($core.assert(true) {
+		a = 1;
+	};!
+
+!IRAssignmentInliner methodsFor: 'accessing'!
+
+assignment
+	^ assignment
+!
+
+assignment: aNode
+	assignment := aNode
+! !
+
+!IRAssignmentInliner methodsFor: 'inlining'!
+
+inlineAssignment: anIRAssignment
+	| inlinedAssignment |
+	self assignment: anIRAssignment.
+	inlinedAssignment := IRInlinedAssignment new.
+	anIRAssignment instructions do: [ :each |
+		inlinedAssignment add: each ].
+	anIRAssignment replaceWith: inlinedAssignment.
+	self inlineSend: inlinedAssignment instructions last.
+	^ inlinedAssignment
+!
+
+inlineClosure: anIRClosure
+	| inlinedClosure statements |
+
+	inlinedClosure := super inlineClosure: anIRClosure.
+	statements := inlinedClosure instructions last instructions.
+	
+	statements ifNotEmpty: [
+		statements last canBeAssigned ifTrue: [
+			statements last replaceWith: (IRAssignment new
+				add: self assignment instructions first;
+				add: statements last copy;
+				yourself) ] ].
+
+	^ inlinedClosure
+! !
+
+IRSendInliner subclass: #IRReturnInliner
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!IRReturnInliner commentStamp!
+I inline message sends with inlined closure together with a return instruction.!
+
+!IRReturnInliner methodsFor: 'factory'!
+
+inlinedReturn
+	^ IRInlinedReturn new
+! !
+
+!IRReturnInliner methodsFor: 'inlining'!
+
+inlineClosure: anIRClosure
+	| closure statements |
+
+	closure := super inlineClosure: anIRClosure.
+	statements := closure instructions last instructions.
+	
+	statements ifNotEmpty: [
+		statements last isReturn
+			ifFalse: [ statements last replaceWith: (IRReturn new
+				add: statements last copy;
+				yourself)] ].
+
+	^ closure
+!
+
+inlineReturn: anIRReturn
+	| return |
+	return := self inlinedReturn.
+	anIRReturn instructions do: [ :each |
+		return add: each ].
+	anIRReturn replaceWith: return.
+	self inlineSend: return instructions last.
+	^ return
+! !
+
+CodeGenerator subclass: #InliningCodeGenerator
+	instanceVariableNames: ''
+	package: 'Compiler-Inlining'!
+!InliningCodeGenerator commentStamp!
+I am a specialized code generator that uses inlining to produce more optimized JavaScript output!
+
+!InliningCodeGenerator methodsFor: 'compiling'!
+
+compileNode: aNode
+	| ir stream |
+
+	self semanticAnalyzer visit: aNode.
+	ir := self translator visit: aNode.
+	self inliner visit: ir.
+
+	^ self irTranslator
+		currentClass: self currentClass;
+		visit: ir;
+		contents
+!
+
+inliner
+	^ IRInliner new
+!
+
+irTranslator
+	^ IRInliningJSTranslator new
+! !
+

+ 3863 - 0
bower_components/amber/src/Compiler-Interpreter.js

@@ -0,0 +1,3863 @@
+define("amber_core/Compiler-Interpreter", ["amber/boot", "amber_core/Kernel-Methods", "amber_core/Compiler-Semantic", "amber_core/Kernel-Objects", "amber_core/Compiler-Core", "amber_core/Kernel-Exceptions", "amber_core/Compiler-AST"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Interpreter');
+$core.packages["Compiler-Interpreter"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('AIBlockClosure', $globals.BlockClosure, ['node', 'outerContext'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AIBlockClosure.comment="I am a special `BlockClosure` subclass used by an interpreter to interpret a block node.\x0a\x0aWhile I am polymorphic with `BlockClosure`, some methods such as `#new` will raise interpretation errors. Unlike a `BlockClosure`, my instance are not JavaScript functions.\x0a\x0aEvaluating an instance will result in interpreting the `node` instance variable (instance of `BlockNode`).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "applyTo:arguments:",
+protocol: 'evaluating',
+fn: function (anObject,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._interpreterError();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"applyTo:arguments:",{anObject:anObject,aCollection:aCollection},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aCollection"],
+source: "applyTo: anObject arguments: aCollection\x0a\x09self interpreterError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["interpreterError"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "compiledSource",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "[ AST Block closure ]";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "compiledSource\x0a\x09\x22Unlike blocks, the receiver doesn't represent a JS function\x22\x0a\x09\x0a\x09^ '[ AST Block closure ]'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "currySelf",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._interpreterError();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"currySelf",{},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currySelf\x0a\x09self interpreterError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["interpreterError"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "initializeWithContext:node:",
+protocol: 'initialization',
+fn: function (aContext,aNode){
+var self=this;
+self["@node"]=aNode;
+self["@outerContext"]=aContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext", "aNode"],
+source: "initializeWithContext: aContext node: aNode\x0a\x09node := aNode.\x0a\x09outerContext := aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "interpreterError",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+function $ASTInterpreterError(){return $globals.ASTInterpreterError||(typeof ASTInterpreterError=="undefined"?nil:ASTInterpreterError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ASTInterpreterError())._signal_("Method cannot be interpreted by the interpreter.");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpreterError",{},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "interpreterError\x0a\x09ASTInterpreterError signal: 'Method cannot be interpreted by the interpreter.'",
+referencedClasses: ["ASTInterpreterError"],
+//>>excludeEnd("ide");
+messageSends: ["signal:"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "numArgs",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self["@node"])._temps())._size();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"numArgs",{},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "numArgs\x0a\x09^ node temps size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["size", "temps"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._valueWithPossibleArguments_([]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ self valueWithPossibleArguments: #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valueWithPossibleArguments:"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'evaluating',
+fn: function (anArgument){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._valueWithPossibleArguments_([anArgument]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{anArgument:anArgument},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArgument"],
+source: "value: anArgument\x0a\x09^ self valueWithPossibleArguments: {anArgument}",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valueWithPossibleArguments:"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:",
+protocol: 'evaluating',
+fn: function (firstArgument,secondArgument){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._valueWithPossibleArguments_([firstArgument,secondArgument]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:",{firstArgument:firstArgument,secondArgument:secondArgument},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArgument", "secondArgument"],
+source: "value: firstArgument value: secondArgument\x0a\x09^ self valueWithPossibleArguments: {firstArgument . secondArgument}",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valueWithPossibleArguments:"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:value:",
+protocol: 'evaluating',
+fn: function (firstArgument,secondArgument,thirdArgument){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._valueWithPossibleArguments_([firstArgument,secondArgument,thirdArgument]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:value:",{firstArgument:firstArgument,secondArgument:secondArgument,thirdArgument:thirdArgument},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArgument", "secondArgument", "thirdArgument"],
+source: "value: firstArgument value: secondArgument value: thirdArgument\x0a\x09^ self valueWithPossibleArguments: {firstArgument . secondArgument . thirdArgument}",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valueWithPossibleArguments:"]
+}),
+$globals.AIBlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "valueWithPossibleArguments:",
+protocol: 'evaluating',
+fn: function (aCollection){
+var self=this;
+var context,sequenceNode;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$6;
+context=$recv(self["@outerContext"])._newInnerContext();
+$1=$recv($recv($recv(self["@node"])._nodes())._first())._copy();
+$recv($1)._parent_(nil);
+$2=$recv($1)._yourself();
+sequenceNode=$2;
+$recv($recv(sequenceNode)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(context)._defineLocal_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["defineLocal:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv($recv(self["@node"])._parameters())._withIndexDo_((function(each,index){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(context)._defineLocal_(each);
+return $recv(context)._localAt_put_(each,$recv(aCollection)._at_ifAbsent_(index,(function(){
+return nil;
+
+})));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,index:index},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$3=$recv(context)._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._node_($recv(sequenceNode)._nextChild());
+$4=$recv($3)._proceed();
+$5=$recv(self["@outerContext"])._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=2;
+//>>excludeEnd("ctx");
+$recv($5)._setNonLocalReturnFromContext_(context);
+$6=$recv($recv(context)._interpreter())._pop();
+return $6;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueWithPossibleArguments:",{aCollection:aCollection,context:context,sequenceNode:sequenceNode},$globals.AIBlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "valueWithPossibleArguments: aCollection\x0a\x09| context sequenceNode |\x0a\x09context := outerContext newInnerContext.\x0a\x0a\x09\x22Interpret a copy of the sequence node to avoid creating a new AIBlockClosure\x22\x0a\x09sequenceNode := node nodes first copy\x0a\x09\x09parent: nil;\x0a\x09\x09yourself.\x0a\x09\x09\x0a\x09\x22Define locals in the context\x22\x0a\x09sequenceNode temps do: [ :each |\x0a\x09\x09context defineLocal: each ].\x0a\x09\x09\x0a\x09\x22Populate the arguments into the context locals\x22\x09\x0a\x09node parameters withIndexDo: [ :each :index |\x0a\x09\x09context defineLocal: each.\x0a\x09\x09context localAt: each put: (aCollection at: index ifAbsent: [ nil ]) ].\x0a\x0a\x09\x22Interpret the first node of the BlockSequenceNode\x22\x0a\x09context interpreter\x0a\x09\x09node: sequenceNode nextChild;\x0a\x09\x09proceed.\x0a\x09\x09\x0a\x09outerContext interpreter\x0a\x09\x09setNonLocalReturnFromContext: context.\x0a\x09\x09\x0a\x09^ context interpreter pop",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["newInnerContext", "parent:", "copy", "first", "nodes", "yourself", "do:", "temps", "defineLocal:", "withIndexDo:", "parameters", "localAt:put:", "at:ifAbsent:", "node:", "interpreter", "nextChild", "proceed", "setNonLocalReturnFromContext:", "pop"]
+}),
+$globals.AIBlockClosure);
+
+
+$core.addMethod(
+$core.method({
+selector: "forContext:node:",
+protocol: 'instance creation',
+fn: function (aContext,aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._initializeWithContext_node_(aContext,aNode);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"forContext:node:",{aContext:aContext,aNode:aNode},$globals.AIBlockClosure.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext", "aNode"],
+source: "forContext: aContext node: aNode\x0a\x09^ self new\x0a\x09\x09initializeWithContext: aContext node: aNode;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeWithContext:node:", "new", "yourself"]
+}),
+$globals.AIBlockClosure.klass);
+
+
+$core.addClass('AIContext', $globals.MethodContext, ['outerContext', 'innerContext', 'pc', 'locals', 'selector', 'index', 'sendIndexes', 'evaluatedSelector', 'ast', 'interpreter', 'supercall'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AIContext.comment="I am like a `MethodContext`, used by the `ASTInterpreter`.\x0aUnlike a `MethodContext`, my instances are not read-only.\x0a\x0aWhen debugging, my instances are created by copying the current `MethodContext` (thisContext)";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._ast())._arguments())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._localAt_ifAbsent_(each,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._error_("Argument not in context");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ self ast arguments collect: [ :each |\x0a\x09\x09self localAt: each ifAbsent: [ self error: 'Argument not in context' ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "arguments", "ast", "localAt:ifAbsent:", "error:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "ast",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$receiver;
+$1=self._isBlockContext();
+if($core.assert($1)){
+$3=self._outerContext();
+if(($receiver = $3) == null || $receiver.isNil){
+$2=$3;
+} else {
+var context;
+context=$receiver;
+$2=$recv(context)._ast();
+};
+return $2;
+};
+$4=self["@ast"];
+if(($receiver = $4) == null || $receiver.isNil){
+self._initializeAST();
+} else {
+$4;
+};
+$5=self["@ast"];
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ast",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ast\x0a\x09self isBlockContext ifTrue: [ \x0a\x09\x09^ self outerContext ifNotNil: [ :context | context ast ] ].\x0a\x0a\x09ast ifNil: [ self initializeAST ].\x0a\x09^ ast",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isBlockContext", "ifNotNil:", "outerContext", "ast", "ifNil:", "initializeAST"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "basicLocalAt:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._locals())._at_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicLocalAt:",{aString:aString},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicLocalAt: aString\x0a\x09^ self locals at: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "locals"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "basicLocalAt:put:",
+protocol: 'private',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._locals())._at_put_(aString,anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicLocalAt:put:",{aString:aString,anObject:anObject},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "basicLocalAt: aString put: anObject\x0a\x09self locals at: aString put: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "locals"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "basicReceiver",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._localAt_("self");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicReceiver",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "basicReceiver\x0a\x09^ self localAt: 'self'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["localAt:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "defineLocal:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._locals())._at_put_(aString,nil);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defineLocal:",{aString:aString},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "defineLocal: aString\x0a\x09self locals at: aString put: nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "locals"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:on:",
+protocol: 'evaluating',
+fn: function (aString,anEvaluator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anEvaluator)._evaluate_context_(aString,self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:on:",{aString:aString,anEvaluator:anEvaluator},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anEvaluator"],
+source: "evaluate: aString on: anEvaluator\x0a\x09^ anEvaluator evaluate: aString context: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["evaluate:context:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "evaluateNode:",
+protocol: 'evaluating',
+fn: function (aNode){
+var self=this;
+function $ASTInterpreter(){return $globals.ASTInterpreter||(typeof ASTInterpreter=="undefined"?nil:ASTInterpreter)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($ASTInterpreter())._new();
+$recv($2)._context_(self);
+$recv($2)._node_($recv(aNode)._nextChild());
+$recv($2)._proceed();
+$3=$recv($2)._result();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluateNode:",{aNode:aNode},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "evaluateNode: aNode\x0a\x09^ ASTInterpreter new\x0a\x09\x09context: self;\x0a\x09\x09node: aNode nextChild;\x0a\x09\x09proceed;\x0a\x09\x09result",
+referencedClasses: ["ASTInterpreter"],
+//>>excludeEnd("ide");
+messageSends: ["context:", "new", "node:", "nextChild", "proceed", "result"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "evaluatedSelector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@evaluatedSelector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "evaluatedSelector\x0a\x09^ evaluatedSelector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "evaluatedSelector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@evaluatedSelector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "evaluatedSelector: aString\x0a\x09evaluatedSelector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "index",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@index"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=(0);
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"index",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "index\x0a\x09^ index ifNil: [ 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "index:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@index"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "index: anInteger\x0a\x09index := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "initializeAST",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._method();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["method"]=1;
+//>>excludeEnd("ctx");
+self["@ast"]=$recv($1)._ast();
+$recv($recv($SemanticAnalyzer())._on_($recv(self._method())._methodClass()))._visit_(self["@ast"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeAST",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initializeAST\x0a\x09ast := self method ast.\x0a\x09(SemanticAnalyzer on: self method methodClass)\x0a\x09\x09visit: ast",
+referencedClasses: ["SemanticAnalyzer"],
+//>>excludeEnd("ide");
+messageSends: ["ast", "method", "visit:", "on:", "methodClass"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "initializeFromMethodContext:",
+protocol: 'initialization',
+fn: function (aMethodContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$receiver;
+self._evaluatedSelector_($recv(aMethodContext)._evaluatedSelector());
+self._index_($recv(aMethodContext)._index());
+self._sendIndexes_($recv(aMethodContext)._sendIndexes());
+self._receiver_($recv(aMethodContext)._receiver());
+self._supercall_($recv(aMethodContext)._supercall());
+$1=self._selector_($recv(aMethodContext)._selector());
+$2=$recv(aMethodContext)._outerContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["outerContext"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+$2;
+} else {
+var outer;
+outer=$receiver;
+$3=$recv(outer)._methodContext();
+if(($receiver = $3) == null || $receiver.isNil){
+$3;
+} else {
+self._outerContext_($recv(self._class())._fromMethodContext_($recv(aMethodContext)._outerContext()));
+};
+$4=$recv(aMethodContext)._locals();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["locals"]=1;
+//>>excludeEnd("ctx");
+$recv($4)._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._locals())._at_put_(key,value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeFromMethodContext:",{aMethodContext:aMethodContext},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethodContext"],
+source: "initializeFromMethodContext: aMethodContext\x0a\x0a\x09self\x0a\x09\x09evaluatedSelector: aMethodContext evaluatedSelector;\x0a\x09\x09index: aMethodContext index;\x0a\x09\x09sendIndexes: aMethodContext sendIndexes;\x0a\x09\x09receiver: aMethodContext receiver;\x0a\x09\x09supercall: aMethodContext supercall;\x0a\x09\x09selector: aMethodContext selector.\x0a\x09\x09\x0a\x09aMethodContext outerContext ifNotNil: [ :outer |\x0a\x09\x09\x22If the method context is nil, the block was defined in JS, so ignore it\x22\x0a\x09\x09outer methodContext ifNotNil: [\x0a\x09\x09\x09self outerContext: (self class fromMethodContext: aMethodContext outerContext) ].\x0a\x09\x09\x09aMethodContext locals keysAndValuesDo: [ :key :value |\x0a\x09\x09\x09\x09self locals at: key put: value ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["evaluatedSelector:", "evaluatedSelector", "index:", "index", "sendIndexes:", "sendIndexes", "receiver:", "receiver", "supercall:", "supercall", "selector:", "selector", "ifNotNil:", "outerContext", "methodContext", "outerContext:", "fromMethodContext:", "class", "keysAndValuesDo:", "locals", "at:put:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "initializeInterpreter",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $ASTInterpreter(){return $globals.ASTInterpreter||(typeof ASTInterpreter=="undefined"?nil:ASTInterpreter)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$receiver;
+$1=$recv($ASTInterpreter())._new();
+$recv($1)._context_(self);
+$2=$recv($1)._yourself();
+self["@interpreter"]=$2;
+$3=self._innerContext();
+if(($receiver = $3) == null || $receiver.isNil){
+$3;
+} else {
+self._setupInterpreter_(self["@interpreter"]);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeInterpreter",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initializeInterpreter\x0a\x09interpreter := ASTInterpreter new\x0a\x09\x09context: self;\x0a\x09\x09yourself.\x0a\x09\x0a\x09self innerContext ifNotNil: [\x0a\x09\x09self setupInterpreter: interpreter ]",
+referencedClasses: ["ASTInterpreter"],
+//>>excludeEnd("ide");
+messageSends: ["context:", "new", "yourself", "ifNotNil:", "innerContext", "setupInterpreter:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "initializeLocals",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@locals"]=$recv($Dictionary())._new();
+$recv(self["@locals"])._at_put_("thisContext",self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeLocals",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initializeLocals\x0a\x09locals := Dictionary new.\x0a\x09locals at: 'thisContext' put: self.",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["new", "at:put:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "innerContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@innerContext"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "innerContext\x0a\x09^ innerContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "innerContext:",
+protocol: 'accessing',
+fn: function (anAIContext){
+var self=this;
+self["@innerContext"]=anAIContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAIContext"],
+source: "innerContext: anAIContext\x0a\x09innerContext := anAIContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "interpreter",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=self["@interpreter"];
+if(($receiver = $1) == null || $receiver.isNil){
+self._initializeInterpreter();
+} else {
+$1;
+};
+$2=self["@interpreter"];
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpreter",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "interpreter\x0a\x09interpreter ifNil: [ self initializeInterpreter ].\x0a\x09^ interpreter",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "initializeInterpreter"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "interpreter:",
+protocol: 'interpreting',
+fn: function (anInterpreter){
+var self=this;
+self["@interpreter"]=anInterpreter;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInterpreter"],
+source: "interpreter: anInterpreter\x0a\x09interpreter := anInterpreter",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "isTopContext",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._innerContext())._isNil();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isTopContext",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTopContext\x0a\x09^ self innerContext isNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isNil", "innerContext"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "localAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+var context;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+context=self._lookupContextForLocal_(aString);
+$1=$recv(context)._basicLocalAt_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"localAt:",{aString:aString,context:context},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "localAt: aString\x0a\x09\x22Lookup the local value up to the method context\x22\x0a\x0a\x09| context |\x0a\x09\x0a\x09context := self lookupContextForLocal: aString.\x0a\x09^ context basicLocalAt: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lookupContextForLocal:", "basicLocalAt:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "localAt:ifAbsent:",
+protocol: 'accessing',
+fn: function (aString,aBlock){
+var self=this;
+var context;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+context=self._lookupContextForLocal_ifNone_(aString,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value();
+throw $early=[$1];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv(context)._basicLocalAt_(aString);
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"localAt:ifAbsent:",{aString:aString,aBlock:aBlock,context:context},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock"],
+source: "localAt: aString ifAbsent: aBlock\x0a\x09\x22Lookup the local value up to the method context\x22\x0a\x0a\x09| context |\x0a\x09\x0a\x09context := self \x09\x0a\x09\x09lookupContextForLocal: aString \x0a\x09\x09ifNone: [ ^ aBlock value ].\x0a\x09\x0a\x09^ context basicLocalAt: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lookupContextForLocal:ifNone:", "value", "basicLocalAt:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "localAt:put:",
+protocol: 'accessing',
+fn: function (aString,anObject){
+var self=this;
+var context;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+context=self._lookupContextForLocal_(aString);
+$recv(context)._basicLocalAt_put_(aString,anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"localAt:put:",{aString:aString,anObject:anObject,context:context},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "localAt: aString put: anObject\x0a\x09| context |\x0a\x09\x0a\x09context := self lookupContextForLocal: aString.\x0a\x09context basicLocalAt: aString put: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lookupContextForLocal:", "basicLocalAt:put:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "locals",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=self["@locals"];
+if(($receiver = $1) == null || $receiver.isNil){
+self._initializeLocals();
+} else {
+$1;
+};
+$2=self["@locals"];
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"locals",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "locals\x0a\x09locals ifNil: [ self initializeLocals ].\x0a\x09\x0a\x09^ locals",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "initializeLocals"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "lookupContextForLocal:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._lookupContextForLocal_ifNone_(aString,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._variableNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lookupContextForLocal:",{aString:aString},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "lookupContextForLocal: aString\x0a\x09\x22Lookup the context defining the local named `aString` \x0a\x09up to the method context\x22\x0a\x0a\x09^ self \x0a\x09\x09lookupContextForLocal: aString \x0a\x09\x09ifNone: [ self variableNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lookupContextForLocal:ifNone:", "variableNotFound"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "lookupContextForLocal:ifNone:",
+protocol: 'private',
+fn: function (aString,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv(self._locals())._at_ifPresent_ifAbsent_(aString,(function(){
+return self;
+
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._outerContext();
+return $recv($2)._ifNil_ifNotNil_(aBlock,(function(context){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(context)._lookupContextForLocal_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({context:context},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lookupContextForLocal:ifNone:",{aString:aString,aBlock:aBlock},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock"],
+source: "lookupContextForLocal: aString ifNone: aBlock\x0a\x09\x22Lookup the context defining the local named `aString` \x0a\x09up to the method context\x22\x0a\x0a\x09^ self locals \x0a\x09\x09at: aString\x0a\x09\x09ifPresent: [ self ]\x0a\x09\x09ifAbsent: [ \x0a\x09\x09\x09self outerContext \x0a\x09\x09\x09\x09ifNil: aBlock\x0a\x09\x09\x09\x09ifNotNil: [ :context | \x0a\x09\x09\x09\x09\x09context lookupContextForLocal: aString ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifPresent:ifAbsent:", "locals", "ifNil:ifNotNil:", "outerContext", "lookupContextForLocal:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "newInnerContext",
+protocol: 'factory',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv(self._class())._new();
+$recv($2)._outerContext_(self);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newInnerContext",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newInnerContext\x0a\x09^ self class new\x0a\x09\x09outerContext: self;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["outerContext:", "new", "class", "yourself"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "outerContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@outerContext"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "outerContext\x0a\x09^ outerContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "outerContext:",
+protocol: 'accessing',
+fn: function (anAIContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+self["@outerContext"]=anAIContext;
+$1=self["@outerContext"];
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+var context;
+context=$receiver;
+$recv(context)._innerContext_(self);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"outerContext:",{anAIContext:anAIContext},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAIContext"],
+source: "outerContext: anAIContext\x0a\x09outerContext := anAIContext.\x0a\x09outerContext ifNotNil: [ :context | \x0a\x09\x09context innerContext: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "innerContext:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'interpreting',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._locals())._at_put_("self",anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"receiver:",{anObject:anObject},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "receiver: anObject\x0a\x09self locals at: 'self' put: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "locals"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._sendIndexes())._at_ifAbsent_(aString,(function(){
+return (0);
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendIndexAt:",{aString:aString},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "sendIndexAt: aString\x0a\x09^ self sendIndexes at: aString ifAbsent: [ 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "sendIndexes"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@sendIndexes"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$recv($Dictionary())._new();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendIndexes",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sendIndexes\x0a\x09^ sendIndexes ifNil: [ Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes:",
+protocol: 'accessing',
+fn: function (aDictionary){
+var self=this;
+self["@sendIndexes"]=aDictionary;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDictionary"],
+source: "sendIndexes: aDictionary\x0a\x09sendIndexes := aDictionary",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "setupInterpreter:",
+protocol: 'interpreting',
+fn: function (anInterpreter){
+var self=this;
+var currentNode;
+function $ASTPCNodeVisitor(){return $globals.ASTPCNodeVisitor||(typeof ASTPCNodeVisitor=="undefined"?nil:ASTPCNodeVisitor)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$8,$7,$6,$receiver;
+$1=$recv($ASTPCNodeVisitor())._new();
+$recv($1)._selector_(self._evaluatedSelector());
+$recv($1)._context_(self);
+$2=$1;
+$3=self._ast();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["ast"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._visit_($3);
+$4=$recv($1)._currentNode();
+currentNode=$4;
+$5=$recv(self._ast())._sequenceNode();
+if(($receiver = $5) == null || $receiver.isNil){
+$5;
+} else {
+var sequence;
+sequence=$receiver;
+$recv($recv(sequence)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._defineLocal_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+};
+$recv(anInterpreter)._node_(currentNode);
+$8=self._innerContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["innerContext"]=1;
+//>>excludeEnd("ctx");
+$7=$recv($8)._arguments();
+$6=$recv($7)._reversed();
+$recv($6)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(anInterpreter)._push_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["push:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(anInterpreter)._push_($recv(self._innerContext())._receiver());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setupInterpreter:",{anInterpreter:anInterpreter,currentNode:currentNode},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInterpreter"],
+source: "setupInterpreter: anInterpreter\x0a\x09| currentNode |\x0a\x09\x0a\x09\x22Retrieve the current node\x22\x0a\x09currentNode := ASTPCNodeVisitor new\x0a\x09\x09\x09selector: self evaluatedSelector;\x0a\x09\x09\x09context: self;\x0a\x09\x09\x09visit: self ast;\x0a\x09\x09\x09currentNode.\x0a\x09\x0a\x09\x22Define locals for the context\x22\x0a\x09self ast sequenceNode ifNotNil: [ :sequence |\x0a\x09\x09sequence temps do: [ :each |\x0a\x09\x09\x09self defineLocal: each ] ].\x0a\x09\x0a\x09anInterpreter node: currentNode.\x0a\x0a\x09\x22Push the send args and receiver to the interpreter stack\x22\x09\x0a\x09self innerContext arguments reversed do: [ :each | \x0a\x09\x09anInterpreter push: each ].\x0a\x09\x09\x0a\x09anInterpreter push: (self innerContext receiver)",
+referencedClasses: ["ASTPCNodeVisitor"],
+//>>excludeEnd("ide");
+messageSends: ["selector:", "new", "evaluatedSelector", "context:", "visit:", "ast", "currentNode", "ifNotNil:", "sequenceNode", "do:", "temps", "defineLocal:", "node:", "reversed", "arguments", "innerContext", "push:", "receiver"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "supercall",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@supercall"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"supercall",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "supercall\x0a\x09^ supercall ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "supercall:",
+protocol: 'interpreting',
+fn: function (aBoolean){
+var self=this;
+self["@supercall"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "supercall: aBoolean\x0a\x09supercall := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AIContext);
+
+$core.addMethod(
+$core.method({
+selector: "variableNotFound",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("Variable missing");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"variableNotFound",{},$globals.AIContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "variableNotFound\x0a\x09\x22Error thrown whenever a variable lookup fails\x22\x0a\x09\x0a\x09self error: 'Variable missing'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.AIContext);
+
+
+$core.addMethod(
+$core.method({
+selector: "fromMethodContext:",
+protocol: 'instance creation',
+fn: function (aMethodContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._initializeFromMethodContext_(aMethodContext);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromMethodContext:",{aMethodContext:aMethodContext},$globals.AIContext.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethodContext"],
+source: "fromMethodContext: aMethodContext\x0a\x09^ self new\x0a\x09\x09initializeFromMethodContext: aMethodContext;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeFromMethodContext:", "new", "yourself"]
+}),
+$globals.AIContext.klass);
+
+
+$core.addClass('AISemanticAnalyzer', $globals.SemanticAnalyzer, ['context'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AISemanticAnalyzer.comment="I perform the same semantic analysis than `SemanticAnalyzer`, with the difference that provided an `AIContext` context, variables are bound with the context variables.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@context"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09^ context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AISemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (anAIContext){
+var self=this;
+self["@context"]=anAIContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAIContext"],
+source: "context: anAIContext\x0a\x09context := anAIContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AISemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitVariableNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $ASTContextVar(){return $globals.ASTContextVar||(typeof ASTContextVar=="undefined"?nil:ASTContextVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+$recv(self._context())._localAt_ifAbsent_($recv(aNode)._value(),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AISemanticAnalyzer.superclass.fn.prototype._visitVariableNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.supercall = false;
+//>>excludeEnd("ctx");;
+throw $early=[$1];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(aNode)._binding_($recv($ASTContextVar())._new());
+return self;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode},$globals.AISemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitVariableNode: aNode\x0a\x09self context \x0a\x09\x09localAt: aNode value \x0a\x09\x09ifAbsent: [ ^ super visitVariableNode: aNode ].\x0a\x0a\x09aNode binding: ASTContextVar new",
+referencedClasses: ["ASTContextVar"],
+//>>excludeEnd("ide");
+messageSends: ["localAt:ifAbsent:", "context", "value", "visitVariableNode:", "binding:", "new"]
+}),
+$globals.AISemanticAnalyzer);
+
+
+
+$core.addClass('ASTContextVar', $globals.ScopeVar, ['context'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ASTContextVar.comment="I am a variable defined in a `context`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@context"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09^ context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTContextVar);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@context"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "context: anObject\x0a\x09context := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTContextVar);
+
+
+
+$core.addClass('ASTDebugger', $globals.Object, ['interpreter', 'context', 'result'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ASTDebugger.comment="I am a stepping debugger interface for Amber code.\x0aI internally use an instance of `ASTInterpreter` to actually step through node and interpret them.\x0a\x0aMy instances are created from an `AIContext` with `ASTDebugger class >> context:`.\x0aThey hold an `AIContext` instance internally, recursive copy of the `MethodContext`.\x0a\x0a## API\x0a\x0aUse the methods of the `'stepping'` protocol to do stepping.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "atEnd",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=self._context();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+return true;
+} else {
+$1;
+};
+$2=$recv($recv(self._interpreter())._atEnd())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._context())._isTopContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atEnd",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atEnd\x09\x0a\x09self context ifNil: [ ^ true ].\x0a\x09\x0a\x09^ self interpreter atEnd and: [ \x0a\x09\x09self context isTopContext ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "context", "and:", "atEnd", "interpreter", "isTopContext"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@context"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09^ context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (aContext){
+var self=this;
+self["@context"]=aContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "context: aContext\x0a\x09context := aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "flushInnerContexts",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=self._context();
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+var cxt;
+cxt=$receiver;
+$recv(cxt)._innerContext_(nil);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"flushInnerContexts",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "flushInnerContexts\x0a\x09\x22When stepping, the inner contexts are not relevent anymore,\x0a\x09and can be flushed\x22\x0a\x09\x0a\x09self context ifNotNil: [ :cxt | \x0a\x09\x09cxt innerContext: nil ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "context", "innerContext:"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "interpreter",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._context();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+var ctx;
+ctx=$receiver;
+$1=$recv(ctx)._interpreter();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpreter",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "interpreter\x0a\x09^ self context ifNotNil: [ :ctx | \x0a\x09\x09ctx interpreter ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "context", "interpreter"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._context())._method();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"method",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ self context method",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["method", "context"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "node",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+$1=$recv(self._interpreter())._node();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"node",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "node\x0a\x09^ self interpreter ifNotNil: [\x0a\x09\x09self interpreter node ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "interpreter", "node"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "onStep",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$6,$5,$receiver;
+$1=self._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+self["@result"]=$recv($1)._result();
+$3=self._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3)._atEnd();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["atEnd"]=1;
+//>>excludeEnd("ctx");
+if($core.assert($2)){
+$4=$recv(self._context())._outerContext();
+if(($receiver = $4) == null || $receiver.isNil){
+$4;
+} else {
+var outerContext;
+outerContext=$receiver;
+self._context_(outerContext);
+};
+$6=self._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=3;
+//>>excludeEnd("ctx");
+$5=$recv($6)._atEnd();
+if(!$core.assert($5)){
+$recv(self._interpreter())._skip();
+};
+};
+self._flushInnerContexts();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onStep",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "onStep\x0a\x09\x22After each step, check if the interpreter is at the end,\x0a\x09and if it is move to its outer context if any, skipping its \x0a\x09current node (which was just evaluated by the current \x0a\x09interpreter).\x0a\x09\x0a\x09After each step we also flush inner contexts.\x22\x0a\x09\x0a\x09result := self interpreter result.\x0a\x09\x0a\x09self interpreter atEnd ifTrue: [\x0a\x09\x09self context outerContext ifNotNil: [ :outerContext | \x0a\x09\x09\x09self context: outerContext ].\x0a\x09\x09self interpreter atEnd ifFalse: [ self interpreter skip ] ].\x0a\x09\x09\x0a\x09self flushInnerContexts",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["result", "interpreter", "ifTrue:", "atEnd", "ifNotNil:", "outerContext", "context", "context:", "ifFalse:", "skip", "flushInnerContexts"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "proceed",
+protocol: 'stepping',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._atEnd();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._stepOver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"proceed",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "proceed\x0a\x09[ self atEnd ] whileFalse: [ self stepOver ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "atEnd", "stepOver"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "restart",
+protocol: 'stepping',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._interpreter())._restart();
+self._flushInnerContexts();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"restart",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "restart\x0a\x09self interpreter restart.\x0a\x09self flushInnerContexts",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["restart", "interpreter", "flushInnerContexts"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "result",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@result"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "result\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "stepInto",
+protocol: 'stepping',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldBeImplemented();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"stepInto",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stepInto\x0a\x09self shouldBeImplemented",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldBeImplemented"]
+}),
+$globals.ASTDebugger);
+
+$core.addMethod(
+$core.method({
+selector: "stepOver",
+protocol: 'stepping',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(self._context())._isTopContext();
+if($core.assert($1)){
+$recv(self._interpreter())._stepOver();
+} else {
+$2=self._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._skip();
+};
+self._onStep();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"stepOver",{},$globals.ASTDebugger)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stepOver\x0a\x09self context isTopContext \x0a\x09\x09ifFalse: [ self interpreter skip ]\x0a\x09\x09ifTrue: [ self interpreter stepOver ].\x0a\x09self onStep",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:ifTrue:", "isTopContext", "context", "skip", "interpreter", "stepOver", "onStep"]
+}),
+$globals.ASTDebugger);
+
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'instance creation',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._context_(aContext);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"context:",{aContext:aContext},$globals.ASTDebugger.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "context: aContext\x0a\x09^ self new\x0a\x09\x09context: aContext;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["context:", "new", "yourself"]
+}),
+$globals.ASTDebugger.klass);
+
+
+$core.addClass('ASTInterpreter', $globals.NodeVisitor, ['node', 'context', 'stack', 'returnValue', 'returned', 'forceAtEnd'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ASTInterpreter.comment="I visit an AST, interpreting (evaluating) nodes one after the other, using a small stack machine.\x0a\x0a## API\x0a\x0aWhile my instances should be used from within an `ASTDebugger`, which provides a more high level interface,\x0ayou can use methods from the `interpreting` protocol:\x0a\x0a- `#step` evaluates the current `node` only\x0a- `#stepOver` evaluates the AST from the current `node` up to the next stepping node (most likely the next send node)\x0a- `#proceed` evaluates eagerly the AST\x0a- `#restart` select the first node of the AST\x0a- `#skip` skips the current node, moving to the next one if any";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "assign:to:",
+protocol: 'private',
+fn: function (aNode,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4;
+$1=$recv($recv(aNode)._binding())._isInstanceVar();
+if($core.assert($1)){
+$3=self._context();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._receiver();
+$4=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._instVarAt_put_($4,anObject);
+} else {
+$recv(self._context())._localAt_put_($recv(aNode)._value(),anObject);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assign:to:",{aNode:aNode,anObject:anObject},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode", "anObject"],
+source: "assign: aNode to: anObject\x0a\x09aNode binding isInstanceVar\x0a\x09\x09ifTrue: [ self context receiver instVarAt: aNode value put: anObject ]\x0a\x09\x09ifFalse: [ self context localAt: aNode value put: anObject ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isInstanceVar", "binding", "instVarAt:put:", "receiver", "context", "value", "localAt:put:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "atEnd",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self["@forceAtEnd"];
+if($core.assert($1)){
+return true;
+};
+$2=$recv(self._hasReturned())._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._node())._isNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atEnd",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atEnd\x0a\x09forceAtEnd ifTrue: [ ^ true ].\x0a\x09\x0a\x09^ self hasReturned or: [ self node isNil ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "or:", "hasReturned", "isNil", "node"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@context"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09^ context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (aContext){
+var self=this;
+self["@context"]=aContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "context: aContext\x0a\x09context := aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "eval:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+var source,function_;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$4,$5;
+source=$recv($String())._streamContents_((function(str){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(str)._nextPutAll_("0,(function(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$3=self._context();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["context"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._locals();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["locals"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._keys();
+$recv($1)._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(str)._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(str)._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(str)._nextPutAll_("){ return (function() {");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(str)._nextPutAll_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$4=$recv(str)._nextPutAll_("})()})");
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+function_=$recv($recv($Compiler())._new())._eval_(source);
+$5=$recv(function_)._valueWithPossibleArguments_($recv($recv(self._context())._locals())._values());
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"eval:",{aString:aString,source:source,function_:function_},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "eval: aString\x0a\x09\x22Evaluate aString as JS source inside an JS function.\x0a\x09aString is not sandboxed.\x22\x0a\x09\x0a\x09| source function |\x0a\x09\x0a\x09source := String streamContents: [ :str |\x0a\x09\x09str nextPutAll: '0,(function('.\x0a\x09\x09self context locals keys\x0a\x09\x09\x09do: [ :each | str nextPutAll: each ]\x0a\x09\x09\x09separatedBy: [ str nextPutAll: ',' ].\x0a\x09\x09str\x0a\x09\x09\x09nextPutAll: '){ return (function() {';\x0a\x09\x09\x09nextPutAll: aString;\x0a\x09\x09\x09nextPutAll: '})()})' ].\x0a\x09\x09\x09\x0a\x09function := Compiler new eval: source.\x0a\x09\x0a\x09^ function valueWithPossibleArguments: self context locals values",
+referencedClasses: ["String", "Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", "do:separatedBy:", "keys", "locals", "context", "eval:", "new", "valueWithPossibleArguments:", "values"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "hasReturned",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@returned"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hasReturned",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hasReturned\x0a\x09^ returned ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ASTInterpreter.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@forceAtEnd"]=false;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x0a\x09forceAtEnd := false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "interpret",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._visit_(self._node());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpret",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "interpret\x0a\x09\x22Interpret the next node to be evaluated\x22\x0a\x09\x0a\x09self visit: self node",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "node"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "interpret:",
+protocol: 'interpreting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._node_(aNode);
+self._interpret();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpret:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "interpret: aNode\x0a\x09self node: aNode.\x0a\x09self interpret",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["node:", "interpret"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "messageFromSendNode:arguments:",
+protocol: 'private',
+fn: function (aSendNode,aCollection){
+var self=this;
+function $Message(){return $globals.Message||(typeof Message=="undefined"?nil:Message)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($Message())._new();
+$recv($2)._selector_($recv(aSendNode)._selector());
+$recv($2)._arguments_(aCollection);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageFromSendNode:arguments:",{aSendNode:aSendNode,aCollection:aCollection},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSendNode", "aCollection"],
+source: "messageFromSendNode: aSendNode arguments: aCollection\x0a\x09^ Message new\x0a\x09\x09selector: aSendNode selector;\x0a\x09\x09arguments: aCollection;\x0a\x09\x09yourself",
+referencedClasses: ["Message"],
+//>>excludeEnd("ide");
+messageSends: ["selector:", "new", "selector", "arguments:", "yourself"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "messageNotUnderstood:receiver:",
+protocol: 'private',
+fn: function (aMessage,anObject){
+var self=this;
+function $MessageNotUnderstood(){return $globals.MessageNotUnderstood||(typeof MessageNotUnderstood=="undefined"?nil:MessageNotUnderstood)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($MessageNotUnderstood())._new();
+$recv($1)._meesage_(aMessage);
+$recv($1)._receiver_(anObject);
+$2=$recv($1)._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageNotUnderstood:receiver:",{aMessage:aMessage,anObject:anObject},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMessage", "anObject"],
+source: "messageNotUnderstood: aMessage receiver: anObject\x0a\x09MessageNotUnderstood new\x0a\x09\x09meesage: aMessage;\x0a\x09\x09receiver: anObject;\x0a\x09\x09signal",
+referencedClasses: ["MessageNotUnderstood"],
+//>>excludeEnd("ide");
+messageSends: ["meesage:", "new", "receiver:", "signal"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "next",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._node_($recv(self._node())._nextNode());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "next\x0a\x09self node: self node nextNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["node:", "nextNode", "node"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "node",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@node"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "node\x0a\x09\x22Answer the next node, ie the node to be evaluated in the next step\x22\x0a\x09\x0a\x09^ node",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "node:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@node"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "node: aNode\x0a\x09node := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "peek",
+protocol: 'stack',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+$1=self._stack();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["stack"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._ifEmpty_((function(){
+throw $early=[nil];
+
+}));
+$2=$recv(self._stack())._last();
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"peek",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "peek\x0a\x09\x22Peek the top object of the context stack\x22\x0a\x09\x0a\x09self stack ifEmpty: [ ^ nil ].\x0a\x09\x0a\x09^ self stack last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifEmpty:", "stack", "last"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "pop",
+protocol: 'stack',
+fn: function (){
+var self=this;
+var peekedValue;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+peekedValue=self._peek();
+$recv(self._stack())._removeLast();
+$1=peekedValue;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pop",{peekedValue:peekedValue},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pop\x0a\x09\x22Pop an object from the context stack\x22\x0a\x09\x0a\x09| peekedValue |\x0a\x09\x0a\x09peekedValue := self peek.\x0a\x09self stack removeLast.\x0a\x09^ peekedValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["peek", "removeLast", "stack"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "proceed",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._atEnd();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._step();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"proceed",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "proceed\x0a\x09\x22Eagerly evaluate the ast\x22\x0a\x09\x0a\x09[ self atEnd ] \x0a\x09\x09whileFalse: [ self step ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "atEnd", "step"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "push:",
+protocol: 'stack',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._stack())._add_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"push:",{anObject:anObject},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "push: anObject\x0a\x09\x22Push an object to the context stack\x22\x0a\x09\x0a\x09^ self stack add: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "stack"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "restart",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._node_($recv($recv(self._context())._ast())._nextChild());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"restart",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "restart\x0a\x09self node: self context ast nextChild",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["node:", "nextChild", "ast", "context"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "result",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._hasReturned();
+if($core.assert($2)){
+$1=self._returnValue();
+} else {
+$1=$recv(self._context())._receiver();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"result",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "result\x0a\x09^ self hasReturned \x0a\x09\x09ifTrue: [ self returnValue ] \x0a\x09\x09ifFalse: [ self context receiver ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "hasReturned", "returnValue", "receiver", "context"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "returnValue",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@returnValue"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "returnValue\x0a\x09^ returnValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "returnValue:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@returnValue"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "returnValue: anObject\x0a\x09returnValue := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "sendMessage:to:superSend:",
+protocol: 'private',
+fn: function (aMessage,anObject,aBoolean){
+var self=this;
+var method;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$6,$receiver;
+var $early={};
+try {
+if(!$core.assert(aBoolean)){
+$1=$recv(aMessage)._sendTo_(anObject);
+return $1;
+};
+$3=$recv(anObject)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+$4=self._messageNotUnderstood_receiver_(aMessage,anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["messageNotUnderstood:receiver:"]=1;
+//>>excludeEnd("ctx");
+return $4;
+} else {
+$2;
+};
+method=$recv($recv($recv($recv(anObject)._class())._superclass())._methodDictionary())._at_ifAbsent_($recv(aMessage)._selector(),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=self._messageNotUnderstood_receiver_(aMessage,anObject);
+throw $early=[$5];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$6=$recv(method)._sendTo_arguments_(anObject,$recv(aMessage)._arguments());
+return $6;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendMessage:to:superSend:",{aMessage:aMessage,anObject:anObject,aBoolean:aBoolean,method:method},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMessage", "anObject", "aBoolean"],
+source: "sendMessage: aMessage to: anObject superSend: aBoolean\x0a\x09| method |\x0a\x09\x0a\x09aBoolean ifFalse: [ ^ aMessage sendTo: anObject ].\x0a\x09anObject class superclass ifNil: [ ^ self messageNotUnderstood: aMessage receiver: anObject ].\x0a\x09\x0a\x09method := anObject class superclass methodDictionary\x0a\x09\x09at: aMessage selector\x0a\x09\x09ifAbsent: [ ^ self messageNotUnderstood: aMessage receiver: anObject ].\x0a\x09\x09\x0a\x09^ method sendTo: anObject arguments: aMessage arguments",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "sendTo:", "ifNil:", "superclass", "class", "messageNotUnderstood:receiver:", "at:ifAbsent:", "methodDictionary", "selector", "sendTo:arguments:", "arguments"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "setNonLocalReturnFromContext:",
+protocol: 'interpreting',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(aContext)._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._hasReturned();
+if($core.assert($1)){
+self["@returned"]=true;
+self["@returned"];
+self._returnValue_($recv($recv(aContext)._interpreter())._returnValue());
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setNonLocalReturnFromContext:",{aContext:aContext},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "setNonLocalReturnFromContext: aContext\x0a\x09aContext interpreter hasReturned ifTrue: [\x0a\x09\x09returned := true.\x0a\x09\x09self returnValue: aContext interpreter returnValue ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "hasReturned", "interpreter", "returnValue:", "returnValue"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "skip",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._next();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"skip",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "skip\x0a\x09self next",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["next"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "stack",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@stack"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@stack"]=$recv($OrderedCollection())._new();
+$1=self["@stack"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"stack",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stack\x0a\x09^ stack ifNil: [ stack := OrderedCollection new ]",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "step",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._interpret();
+$1=self._next();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"step",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "step\x0a\x09self \x0a\x09\x09interpret; \x0a\x09\x09next",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["interpret", "next"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "stepOver",
+protocol: 'interpreting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+self._step();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["step"]=1;
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._node();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["node"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isNil();
+return $recv($1)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self._node())._isSteppingNode();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._step();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"stepOver",{},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stepOver\x0a\x09self step.\x0a\x09\x0a\x09[ self node isNil or: [ self node isSteppingNode ] ] whileFalse: [ \x0a\x09\x09self step ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["step", "whileFalse:", "or:", "isNil", "node", "isSteppingNode"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visit:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._hasReturned();
+if(!$core.assert($1)){
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ASTInterpreter.superclass.fn.prototype._visit_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visit:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visit: aNode\x0a\x09self hasReturned ifFalse: [ super visit: aNode ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "hasReturned", "visit:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitAssignmentNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var poppedValue;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+poppedValue=self._pop();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["pop"]=1;
+//>>excludeEnd("ctx");
+self._pop();
+self._push_(poppedValue);
+self._assign_to_($recv(aNode)._left(),poppedValue);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitAssignmentNode:",{aNode:aNode,poppedValue:poppedValue},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitAssignmentNode: aNode\x0a\x09| poppedValue |\x0a\x09\x0a\x09poppedValue := self pop.\x0a\x09\x0a\x09\x22Pop the left side of the assignment.\x0a\x09It already has been visited, and we don't need its value.\x22\x0a\x09self pop.\x0a\x09\x0a\x09self push: poppedValue.\x0a\x09self assign: aNode left to: poppedValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["pop", "push:", "assign:to:", "left"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var block;
+function $AIBlockClosure(){return $globals.AIBlockClosure||(typeof AIBlockClosure=="undefined"?nil:AIBlockClosure)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+block=$recv($AIBlockClosure())._forContext_node_(self._context(),aNode);
+self._push_(block);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode,block:block},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockNode: aNode\x0a\x09\x22Do not evaluate the block node.\x0a\x09Instead, put all instructions into a block that we push to the stack for later evaluation\x22\x0a\x09\x0a\x09| block |\x0a\x09\x0a\x09block := AIBlockClosure forContext: self context node: aNode.\x0a\x09\x0a\x09self push: block",
+referencedClasses: ["AIBlockClosure"],
+//>>excludeEnd("ide");
+messageSends: ["forContext:node:", "context", "push:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ASTInterpreter.superclass.fn.prototype._visitBlockSequenceNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@forceAtEnd"]=true;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockSequenceNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockSequenceNode: aNode\x0a\x09\x22If the receiver is actually visiting a BlockSequenceNode,\x0a\x09it means the the context is a block context. Evaluation should \x0a\x09stop right after evaluating the block sequence and the outer\x0a\x09context's interpreter should take over. \x0a\x09Therefore we force #atEnd.\x22\x0a\x09\x0a\x09super visitBlockSequenceNode: aNode.\x0a\x09forceAtEnd := true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitBlockSequenceNode:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicArrayNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var array;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+array=[];
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(array)._addFirst_(self._pop());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self._push_(array);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicArrayNode:",{aNode:aNode,array:array},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicArrayNode: aNode\x0a\x09| array |\x0a\x09\x0a\x09array := #().\x0a\x09aNode nodes do: [ :each |\x0a\x09\x09array addFirst: self pop ].\x0a\x09\x0a\x09self push: array",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "nodes", "addFirst:", "pop", "push:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitDynamicDictionaryNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var keyValueList;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+keyValueList=$recv($OrderedCollection())._new();
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(keyValueList)._add_(self._pop());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self._push_($recv($HashedCollection())._newFromPairs_($recv(keyValueList)._reversed()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitDynamicDictionaryNode:",{aNode:aNode,keyValueList:keyValueList},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitDynamicDictionaryNode: aNode\x0a\x09| keyValueList |\x0a\x09\x0a\x09keyValueList := OrderedCollection new.\x0a\x09\x0a\x09aNode nodes do: [ :each | \x0a\x09\x09keyValueList add: self pop ].\x0a\x09\x0a\x09self push: (HashedCollection newFromPairs: keyValueList reversed)",
+referencedClasses: ["OrderedCollection", "HashedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "nodes", "add:", "pop", "push:", "newFromPairs:", "reversed"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitJSStatementNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@returned"]=true;
+self._returnValue_(self._eval_($recv(aNode)._source()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitJSStatementNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitJSStatementNode: aNode\x0a\x09returned := true.\x0a\x09self returnValue: (self eval: aNode source)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["returnValue:", "eval:", "source"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitNode: aNode\x0a\x09\x22Do nothing by default. Especially, do not visit children recursively.\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitReturnNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@returned"]=true;
+self._returnValue_(self._pop());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitReturnNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitReturnNode: aNode\x0a\x09returned := true.\x0a\x09self returnValue: self pop",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["returnValue:", "pop"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitSendNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var receiver,args,message,result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+args=$recv($recv(aNode)._arguments())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._pop();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["pop"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+receiver=self._pop();
+message=self._messageFromSendNode_arguments_(aNode,$recv(args)._reversed());
+result=self._sendMessage_to_superSend_(message,receiver,$recv(aNode)._superSend());
+$1=$recv($recv(aNode)._isCascadeSendNode())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(aNode)._isLastChild())._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+self._push_(receiver);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["push:"]=1;
+//>>excludeEnd("ctx");
+} else {
+self._push_(result);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode,receiver:receiver,args:args,message:message,result:result},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSendNode: aNode\x0a\x09| receiver args message result |\x0a\x09\x0a\x09args := aNode arguments collect: [ :each | self pop ].\x0a\x09receiver := self pop.\x0a\x09\x0a\x09message := self\x0a\x09\x09messageFromSendNode: aNode\x0a\x09\x09arguments: args reversed.\x0a\x09\x0a\x09result := self sendMessage: message to: receiver superSend: aNode superSend.\x0a\x09\x0a\x09\x22For cascade sends, push the reciever if the send is not the last one\x22\x0a\x09(aNode isCascadeSendNode and: [ aNode isLastChild not ])\x0a\x09\x09ifTrue: [ self push: receiver ]\x0a\x09\x09ifFalse: [ self push: result ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "arguments", "pop", "messageFromSendNode:arguments:", "reversed", "sendMessage:to:superSend:", "superSend", "ifTrue:ifFalse:", "and:", "isCascadeSendNode", "not", "isLastChild", "push:"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aNode)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._context())._defineLocal_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSequenceNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSequenceNode: aNode\x0a\x09aNode temps do: [ :each |\x0a\x09\x09self context defineLocal: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "temps", "defineLocal:", "context"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitValueNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._push_($recv(aNode)._value());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitValueNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitValueNode: aNode\x0a\x09self push: aNode value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["push:", "value"]
+}),
+$globals.ASTInterpreter);
+
+$core.addMethod(
+$core.method({
+selector: "visitVariableNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$5,$6,$4,$3,$8,$10,$9,$11,$12,$13,$15,$14,$16,$17,$7;
+$2=$recv(aNode)._binding();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["binding"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isUnknownVar();
+if($core.assert($1)){
+$5=$recv($PlatformInterface())._globals();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["globals"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._at_ifAbsent_($6,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Unknown variable");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:ifAbsent:"]=1;
+//>>excludeEnd("ctx");
+$3=self._push_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["push:"]=1;
+//>>excludeEnd("ctx");
+return $3;
+};
+$8=$recv($recv(aNode)._binding())._isInstanceVar();
+if($core.assert($8)){
+$10=self._context();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context"]=1;
+//>>excludeEnd("ctx");
+$9=$recv($10)._receiver();
+$11=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=2;
+//>>excludeEnd("ctx");
+$7=$recv($9)._instVarAt_($11);
+} else {
+$12=self._context();
+$13=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=3;
+//>>excludeEnd("ctx");
+$7=$recv($12)._localAt_ifAbsent_($13,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$15=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value"]=4;
+//>>excludeEnd("ctx");
+$14=$recv($15)._isCapitalized();
+if($core.assert($14)){
+$16=$recv($Smalltalk())._globals();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["globals"]=2;
+//>>excludeEnd("ctx");
+$17=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value"]=5;
+//>>excludeEnd("ctx");
+return $recv($16)._at_ifAbsent_($17,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv($PlatformInterface())._globals())._at_($recv(aNode)._value());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,7)});
+//>>excludeEnd("ctx");
+}));
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,5)});
+//>>excludeEnd("ctx");
+}));
+};
+self._push_($7);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode},$globals.ASTInterpreter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitVariableNode: aNode\x0a\x09aNode binding isUnknownVar ifTrue: [\x0a\x09\x09^ self push: (PlatformInterface globals at: aNode value ifAbsent: [ self error: 'Unknown variable' ]) ].\x0a\x09\x09\x0a\x09self push: (aNode binding isInstanceVar\x0a\x09\x09ifTrue: [ self context receiver instVarAt: aNode value ]\x0a\x09\x09ifFalse: [ self context \x0a\x09\x09\x09localAt: aNode value\x0a\x09\x09\x09ifAbsent: [\x0a\x09\x09\x09\x09aNode value isCapitalized\x0a\x09\x09\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09\x09\x09Smalltalk globals \x0a\x09\x09\x09\x09\x09\x09\x09at: aNode value \x0a\x09\x09\x09\x09\x09\x09\x09ifAbsent: [ PlatformInterface globals at: aNode value ] ] ] ])",
+referencedClasses: ["PlatformInterface", "Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isUnknownVar", "binding", "push:", "at:ifAbsent:", "globals", "value", "error:", "ifTrue:ifFalse:", "isInstanceVar", "instVarAt:", "receiver", "context", "localAt:ifAbsent:", "isCapitalized", "at:"]
+}),
+$globals.ASTInterpreter);
+
+
+
+$core.addClass('ASTInterpreterError', $globals.Error, [], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ASTInterpreterError.comment="I get signaled when an AST interpreter is unable to interpret a node.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ASTPCNodeVisitor', $globals.NodeVisitor, ['context', 'index', 'selector', 'currentNode'], 'Compiler-Interpreter');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ASTPCNodeVisitor.comment="I visit an AST until I get to the current node for the `context` and answer it.\x0a\x0a## API\x0a\x0aMy instances must be filled with a context object using `#context:`.\x0a\x0aAfter visiting the AST the current node is answered by `#currentNode`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@context"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09^ context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (aContext){
+var self=this;
+self["@context"]=aContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "context: aContext\x0a\x09context := aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "currentNode",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@currentNode"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currentNode\x0a\x09^ currentNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "increaseIndex",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@index"]=$recv(self._index()).__plus((1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"increaseIndex",{},$globals.ASTPCNodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "increaseIndex\x0a\x09index := self index + 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["+", "index"]
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "index",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@index"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@index"]=(0);
+$1=self["@index"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"index",{},$globals.ASTPCNodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "index\x0a\x09^ index ifNil: [ index := 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitJSStatementNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+self["@currentNode"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitJSStatementNode: aNode\x0a\x09\x22If a JSStatementNode is encountered, it always is the current node.\x0a\x09Stop visiting the AST there\x22\x0a\x09\x0a\x09currentNode := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ASTPCNodeVisitor);
+
+$core.addMethod(
+$core.method({
+selector: "visitSendNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var sendIndex;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3,$5;
+$1=self._context();
+$2=self._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+sendIndex=$recv($1)._sendIndexAt_($2);
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ASTPCNodeVisitor.superclass.fn.prototype._visitSendNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$4=self._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__eq($recv(aNode)._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+if($core.assert($3)){
+$5=$recv(self._index()).__eq(sendIndex);
+if($core.assert($5)){
+self["@currentNode"]=aNode;
+self["@currentNode"];
+};
+self._increaseIndex();
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode,sendIndex:sendIndex},$globals.ASTPCNodeVisitor)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSendNode: aNode\x0a\x09| sendIndex |\x0a\x09sendIndex := self context sendIndexAt: self selector.\x0a\x09\x0a\x09super visitSendNode: aNode.\x0a\x09\x0a\x09self selector = aNode selector ifTrue: [\x0a\x09\x09self index = sendIndex ifTrue: [ currentNode := aNode ].\x0a\x09\x09self increaseIndex ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sendIndexAt:", "context", "selector", "visitSendNode:", "ifTrue:", "=", "index", "increaseIndex"]
+}),
+$globals.ASTPCNodeVisitor);
+
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AssignmentNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.DynamicArrayNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.DynamicDictionaryNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSStatementNode);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Node);
+
+$core.addMethod(
+$core.method({
+selector: "isSteppingNode",
+protocol: '*Compiler-Interpreter',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSteppingNode\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SendNode);
+
+});

+ 975 - 0
bower_components/amber/src/Compiler-Interpreter.st

@@ -0,0 +1,975 @@
+Smalltalk createPackage: 'Compiler-Interpreter'!
+BlockClosure subclass: #AIBlockClosure
+	instanceVariableNames: 'node outerContext'
+	package: 'Compiler-Interpreter'!
+!AIBlockClosure commentStamp!
+I am a special `BlockClosure` subclass used by an interpreter to interpret a block node.
+
+While I am polymorphic with `BlockClosure`, some methods such as `#new` will raise interpretation errors. Unlike a `BlockClosure`, my instance are not JavaScript functions.
+
+Evaluating an instance will result in interpreting the `node` instance variable (instance of `BlockNode`).!
+
+!AIBlockClosure methodsFor: 'accessing'!
+
+compiledSource
+	"Unlike blocks, the receiver doesn't represent a JS function"
+	
+	^ '[ AST Block closure ]'
+!
+
+numArgs
+	^ node temps size
+! !
+
+!AIBlockClosure methodsFor: 'converting'!
+
+currySelf
+	self interpreterError
+! !
+
+!AIBlockClosure methodsFor: 'error handling'!
+
+interpreterError
+	ASTInterpreterError signal: 'Method cannot be interpreted by the interpreter.'
+! !
+
+!AIBlockClosure methodsFor: 'evaluating'!
+
+applyTo: anObject arguments: aCollection
+	self interpreterError
+!
+
+value
+	^ self valueWithPossibleArguments: #()
+!
+
+value: anArgument
+	^ self valueWithPossibleArguments: {anArgument}
+!
+
+value: firstArgument value: secondArgument
+	^ self valueWithPossibleArguments: {firstArgument . secondArgument}
+!
+
+value: firstArgument value: secondArgument value: thirdArgument
+	^ self valueWithPossibleArguments: {firstArgument . secondArgument . thirdArgument}
+!
+
+valueWithPossibleArguments: aCollection
+	| context sequenceNode |
+	context := outerContext newInnerContext.
+
+	"Interpret a copy of the sequence node to avoid creating a new AIBlockClosure"
+	sequenceNode := node nodes first copy
+		parent: nil;
+		yourself.
+		
+	"Define locals in the context"
+	sequenceNode temps do: [ :each |
+		context defineLocal: each ].
+		
+	"Populate the arguments into the context locals"	
+	node parameters withIndexDo: [ :each :index |
+		context defineLocal: each.
+		context localAt: each put: (aCollection at: index ifAbsent: [ nil ]) ].
+
+	"Interpret the first node of the BlockSequenceNode"
+	context interpreter
+		node: sequenceNode nextChild;
+		proceed.
+		
+	outerContext interpreter
+		setNonLocalReturnFromContext: context.
+		
+	^ context interpreter pop
+! !
+
+!AIBlockClosure methodsFor: 'initialization'!
+
+initializeWithContext: aContext node: aNode
+	node := aNode.
+	outerContext := aContext
+! !
+
+!AIBlockClosure class methodsFor: 'instance creation'!
+
+forContext: aContext node: aNode
+	^ self new
+		initializeWithContext: aContext node: aNode;
+		yourself
+! !
+
+MethodContext subclass: #AIContext
+	instanceVariableNames: 'outerContext innerContext pc locals selector index sendIndexes evaluatedSelector ast interpreter supercall'
+	package: 'Compiler-Interpreter'!
+!AIContext commentStamp!
+I am like a `MethodContext`, used by the `ASTInterpreter`.
+Unlike a `MethodContext`, my instances are not read-only.
+
+When debugging, my instances are created by copying the current `MethodContext` (thisContext)!
+
+!AIContext methodsFor: 'accessing'!
+
+defineLocal: aString
+	self locals at: aString put: nil
+!
+
+evaluatedSelector
+	^ evaluatedSelector
+!
+
+evaluatedSelector: aString
+	evaluatedSelector := aString
+!
+
+index
+	^ index ifNil: [ 0 ]
+!
+
+index: anInteger
+	index := anInteger
+!
+
+innerContext
+	^ innerContext
+!
+
+innerContext: anAIContext
+	innerContext := anAIContext
+!
+
+localAt: aString
+	"Lookup the local value up to the method context"
+
+	| context |
+	
+	context := self lookupContextForLocal: aString.
+	^ context basicLocalAt: aString
+!
+
+localAt: aString ifAbsent: aBlock
+	"Lookup the local value up to the method context"
+
+	| context |
+	
+	context := self 	
+		lookupContextForLocal: aString 
+		ifNone: [ ^ aBlock value ].
+	
+	^ context basicLocalAt: aString
+!
+
+localAt: aString put: anObject
+	| context |
+	
+	context := self lookupContextForLocal: aString.
+	context basicLocalAt: aString put: anObject
+!
+
+locals
+	locals ifNil: [ self initializeLocals ].
+	
+	^ locals
+!
+
+outerContext
+	^ outerContext
+!
+
+outerContext: anAIContext
+	outerContext := anAIContext.
+	outerContext ifNotNil: [ :context | 
+		context innerContext: self ]
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+!
+
+sendIndexAt: aString
+	^ self sendIndexes at: aString ifAbsent: [ 0 ]
+!
+
+sendIndexes
+	^ sendIndexes ifNil: [ Dictionary new ]
+!
+
+sendIndexes: aDictionary
+	sendIndexes := aDictionary
+! !
+
+!AIContext methodsFor: 'error handling'!
+
+variableNotFound
+	"Error thrown whenever a variable lookup fails"
+	
+	self error: 'Variable missing'
+! !
+
+!AIContext methodsFor: 'evaluating'!
+
+evaluate: aString on: anEvaluator
+	^ anEvaluator evaluate: aString context: self
+!
+
+evaluateNode: aNode
+	^ ASTInterpreter new
+		context: self;
+		node: aNode nextChild;
+		proceed;
+		result
+! !
+
+!AIContext methodsFor: 'factory'!
+
+newInnerContext
+	^ self class new
+		outerContext: self;
+		yourself
+! !
+
+!AIContext methodsFor: 'initialization'!
+
+initializeAST
+	ast := self method ast.
+	(SemanticAnalyzer on: self method methodClass)
+		visit: ast
+!
+
+initializeFromMethodContext: aMethodContext
+
+	self
+		evaluatedSelector: aMethodContext evaluatedSelector;
+		index: aMethodContext index;
+		sendIndexes: aMethodContext sendIndexes;
+		receiver: aMethodContext receiver;
+		supercall: aMethodContext supercall;
+		selector: aMethodContext selector.
+		
+	aMethodContext outerContext ifNotNil: [ :outer |
+		"If the method context is nil, the block was defined in JS, so ignore it"
+		outer methodContext ifNotNil: [
+			self outerContext: (self class fromMethodContext: aMethodContext outerContext) ].
+			aMethodContext locals keysAndValuesDo: [ :key :value |
+				self locals at: key put: value ] ]
+!
+
+initializeInterpreter
+	interpreter := ASTInterpreter new
+		context: self;
+		yourself.
+	
+	self innerContext ifNotNil: [
+		self setupInterpreter: interpreter ]
+!
+
+initializeLocals
+	locals := Dictionary new.
+	locals at: 'thisContext' put: self.
+! !
+
+!AIContext methodsFor: 'interpreting'!
+
+arguments
+	^ self ast arguments collect: [ :each |
+		self localAt: each ifAbsent: [ self error: 'Argument not in context' ] ]
+!
+
+ast
+	self isBlockContext ifTrue: [ 
+		^ self outerContext ifNotNil: [ :context | context ast ] ].
+
+	ast ifNil: [ self initializeAST ].
+	^ ast
+!
+
+basicReceiver
+	^ self localAt: 'self'
+!
+
+interpreter
+	interpreter ifNil: [ self initializeInterpreter ].
+	^ interpreter
+!
+
+interpreter: anInterpreter
+	interpreter := anInterpreter
+!
+
+receiver: anObject
+	self locals at: 'self' put: anObject
+!
+
+setupInterpreter: anInterpreter
+	| currentNode |
+	
+	"Retrieve the current node"
+	currentNode := ASTPCNodeVisitor new
+			selector: self evaluatedSelector;
+			context: self;
+			visit: self ast;
+			currentNode.
+	
+	"Define locals for the context"
+	self ast sequenceNode ifNotNil: [ :sequence |
+		sequence temps do: [ :each |
+			self defineLocal: each ] ].
+	
+	anInterpreter node: currentNode.
+
+	"Push the send args and receiver to the interpreter stack"	
+	self innerContext arguments reversed do: [ :each | 
+		anInterpreter push: each ].
+		
+	anInterpreter push: (self innerContext receiver)
+!
+
+supercall
+	^ supercall ifNil: [ false ]
+!
+
+supercall: aBoolean
+	supercall := aBoolean
+! !
+
+!AIContext methodsFor: 'private'!
+
+basicLocalAt: aString
+	^ self locals at: aString
+!
+
+basicLocalAt: aString put: anObject
+	self locals at: aString put: anObject
+!
+
+lookupContextForLocal: aString
+	"Lookup the context defining the local named `aString` 
+	up to the method context"
+
+	^ self 
+		lookupContextForLocal: aString 
+		ifNone: [ self variableNotFound ]
+!
+
+lookupContextForLocal: aString ifNone: aBlock
+	"Lookup the context defining the local named `aString` 
+	up to the method context"
+
+	^ self locals 
+		at: aString
+		ifPresent: [ self ]
+		ifAbsent: [ 
+			self outerContext 
+				ifNil: aBlock
+				ifNotNil: [ :context | 
+					context lookupContextForLocal: aString ] ]
+! !
+
+!AIContext methodsFor: 'testing'!
+
+isTopContext
+	^ self innerContext isNil
+! !
+
+!AIContext class methodsFor: 'instance creation'!
+
+fromMethodContext: aMethodContext
+	^ self new
+		initializeFromMethodContext: aMethodContext;
+		yourself
+! !
+
+SemanticAnalyzer subclass: #AISemanticAnalyzer
+	instanceVariableNames: 'context'
+	package: 'Compiler-Interpreter'!
+!AISemanticAnalyzer commentStamp!
+I perform the same semantic analysis than `SemanticAnalyzer`, with the difference that provided an `AIContext` context, variables are bound with the context variables.!
+
+!AISemanticAnalyzer methodsFor: 'accessing'!
+
+context
+	^ context
+!
+
+context: anAIContext
+	context := anAIContext
+! !
+
+!AISemanticAnalyzer methodsFor: 'visiting'!
+
+visitVariableNode: aNode
+	self context 
+		localAt: aNode value 
+		ifAbsent: [ ^ super visitVariableNode: aNode ].
+
+	aNode binding: ASTContextVar new
+! !
+
+ScopeVar subclass: #ASTContextVar
+	instanceVariableNames: 'context'
+	package: 'Compiler-Interpreter'!
+!ASTContextVar commentStamp!
+I am a variable defined in a `context`.!
+
+!ASTContextVar methodsFor: 'accessing'!
+
+context
+	^ context
+!
+
+context: anObject
+	context := anObject
+! !
+
+Object subclass: #ASTDebugger
+	instanceVariableNames: 'interpreter context result'
+	package: 'Compiler-Interpreter'!
+!ASTDebugger commentStamp!
+I am a stepping debugger interface for Amber code.
+I internally use an instance of `ASTInterpreter` to actually step through node and interpret them.
+
+My instances are created from an `AIContext` with `ASTDebugger class >> context:`.
+They hold an `AIContext` instance internally, recursive copy of the `MethodContext`.
+
+## API
+
+Use the methods of the `'stepping'` protocol to do stepping.!
+
+!ASTDebugger methodsFor: 'accessing'!
+
+context
+	^ context
+!
+
+context: aContext
+	context := aContext
+!
+
+interpreter
+	^ self context ifNotNil: [ :ctx | 
+		ctx interpreter ]
+!
+
+method
+	^ self context method
+!
+
+node
+	^ self interpreter ifNotNil: [
+		self interpreter node ]
+!
+
+result
+	^ result
+! !
+
+!ASTDebugger methodsFor: 'actions'!
+
+flushInnerContexts
+	"When stepping, the inner contexts are not relevent anymore,
+	and can be flushed"
+	
+	self context ifNotNil: [ :cxt | 
+		cxt innerContext: nil ]
+! !
+
+!ASTDebugger methodsFor: 'private'!
+
+onStep
+	"After each step, check if the interpreter is at the end,
+	and if it is move to its outer context if any, skipping its 
+	current node (which was just evaluated by the current 
+	interpreter).
+	
+	After each step we also flush inner contexts."
+	
+	result := self interpreter result.
+	
+	self interpreter atEnd ifTrue: [
+		self context outerContext ifNotNil: [ :outerContext | 
+			self context: outerContext ].
+		self interpreter atEnd ifFalse: [ self interpreter skip ] ].
+		
+	self flushInnerContexts
+! !
+
+!ASTDebugger methodsFor: 'stepping'!
+
+proceed
+	[ self atEnd ] whileFalse: [ self stepOver ]
+!
+
+restart
+	self interpreter restart.
+	self flushInnerContexts
+!
+
+stepInto
+	self shouldBeImplemented
+!
+
+stepOver
+	self context isTopContext 
+		ifFalse: [ self interpreter skip ]
+		ifTrue: [ self interpreter stepOver ].
+	self onStep
+! !
+
+!ASTDebugger methodsFor: 'testing'!
+
+atEnd	
+	self context ifNil: [ ^ true ].
+	
+	^ self interpreter atEnd and: [ 
+		self context isTopContext ]
+! !
+
+!ASTDebugger class methodsFor: 'instance creation'!
+
+context: aContext
+	^ self new
+		context: aContext;
+		yourself
+! !
+
+NodeVisitor subclass: #ASTInterpreter
+	instanceVariableNames: 'node context stack returnValue returned forceAtEnd'
+	package: 'Compiler-Interpreter'!
+!ASTInterpreter commentStamp!
+I visit an AST, interpreting (evaluating) nodes one after the other, using a small stack machine.
+
+## API
+
+While my instances should be used from within an `ASTDebugger`, which provides a more high level interface,
+you can use methods from the `interpreting` protocol:
+
+- `#step` evaluates the current `node` only
+- `#stepOver` evaluates the AST from the current `node` up to the next stepping node (most likely the next send node)
+- `#proceed` evaluates eagerly the AST
+- `#restart` select the first node of the AST
+- `#skip` skips the current node, moving to the next one if any!
+
+!ASTInterpreter methodsFor: 'accessing'!
+
+context
+	^ context
+!
+
+context: aContext
+	context := aContext
+!
+
+node
+	"Answer the next node, ie the node to be evaluated in the next step"
+	
+	^ node
+!
+
+node: aNode
+	node := aNode
+!
+
+result
+	^ self hasReturned 
+		ifTrue: [ self returnValue ] 
+		ifFalse: [ self context receiver ]
+!
+
+returnValue
+	^ returnValue
+!
+
+returnValue: anObject
+	returnValue := anObject
+!
+
+stack
+	^ stack ifNil: [ stack := OrderedCollection new ]
+! !
+
+!ASTInterpreter methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+
+	forceAtEnd := false
+! !
+
+!ASTInterpreter methodsFor: 'interpreting'!
+
+interpret
+	"Interpret the next node to be evaluated"
+	
+	self visit: self node
+!
+
+interpret: aNode
+	self node: aNode.
+	self interpret
+!
+
+next
+	self node: self node nextNode
+!
+
+proceed
+	"Eagerly evaluate the ast"
+	
+	[ self atEnd ] 
+		whileFalse: [ self step ]
+!
+
+restart
+	self node: self context ast nextChild
+!
+
+setNonLocalReturnFromContext: aContext
+	aContext interpreter hasReturned ifTrue: [
+		returned := true.
+		self returnValue: aContext interpreter returnValue ]
+!
+
+skip
+	self next
+!
+
+step
+	self 
+		interpret; 
+		next
+!
+
+stepOver
+	self step.
+	
+	[ self node isNil or: [ self node isSteppingNode ] ] whileFalse: [ 
+		self step ]
+! !
+
+!ASTInterpreter methodsFor: 'private'!
+
+assign: aNode to: anObject
+	aNode binding isInstanceVar
+		ifTrue: [ self context receiver instVarAt: aNode value put: anObject ]
+		ifFalse: [ self context localAt: aNode value put: anObject ]
+!
+
+eval: aString
+	"Evaluate aString as JS source inside an JS function.
+	aString is not sandboxed."
+	
+	| source function |
+	
+	source := String streamContents: [ :str |
+		str nextPutAll: '0,(function('.
+		self context locals keys
+			do: [ :each | str nextPutAll: each ]
+			separatedBy: [ str nextPutAll: ',' ].
+		str
+			nextPutAll: '){ return (function() {';
+			nextPutAll: aString;
+			nextPutAll: '})()})' ].
+			
+	function := Compiler new eval: source.
+	
+	^ function valueWithPossibleArguments: self context locals values
+!
+
+messageFromSendNode: aSendNode arguments: aCollection
+	^ Message new
+		selector: aSendNode selector;
+		arguments: aCollection;
+		yourself
+!
+
+messageNotUnderstood: aMessage receiver: anObject
+	MessageNotUnderstood new
+		meesage: aMessage;
+		receiver: anObject;
+		signal
+!
+
+sendMessage: aMessage to: anObject superSend: aBoolean
+	| method |
+	
+	aBoolean ifFalse: [ ^ aMessage sendTo: anObject ].
+	anObject class superclass ifNil: [ ^ self messageNotUnderstood: aMessage receiver: anObject ].
+	
+	method := anObject class superclass methodDictionary
+		at: aMessage selector
+		ifAbsent: [ ^ self messageNotUnderstood: aMessage receiver: anObject ].
+		
+	^ method sendTo: anObject arguments: aMessage arguments
+! !
+
+!ASTInterpreter methodsFor: 'stack'!
+
+peek
+	"Peek the top object of the context stack"
+	
+	self stack ifEmpty: [ ^ nil ].
+	
+	^ self stack last
+!
+
+pop
+	"Pop an object from the context stack"
+	
+	| peekedValue |
+	
+	peekedValue := self peek.
+	self stack removeLast.
+	^ peekedValue
+!
+
+push: anObject
+	"Push an object to the context stack"
+	
+	^ self stack add: anObject
+! !
+
+!ASTInterpreter methodsFor: 'testing'!
+
+atEnd
+	forceAtEnd ifTrue: [ ^ true ].
+	
+	^ self hasReturned or: [ self node isNil ]
+!
+
+hasReturned
+	^ returned ifNil: [ false ]
+! !
+
+!ASTInterpreter methodsFor: 'visiting'!
+
+visit: aNode
+	self hasReturned ifFalse: [ super visit: aNode ]
+!
+
+visitAssignmentNode: aNode
+	| poppedValue |
+	
+	poppedValue := self pop.
+	
+	"Pop the left side of the assignment.
+	It already has been visited, and we don't need its value."
+	self pop.
+	
+	self push: poppedValue.
+	self assign: aNode left to: poppedValue
+!
+
+visitBlockNode: aNode
+	"Do not evaluate the block node.
+	Instead, put all instructions into a block that we push to the stack for later evaluation"
+	
+	| block |
+	
+	block := AIBlockClosure forContext: self context node: aNode.
+	
+	self push: block
+!
+
+visitBlockSequenceNode: aNode
+	"If the receiver is actually visiting a BlockSequenceNode,
+	it means the the context is a block context. Evaluation should 
+	stop right after evaluating the block sequence and the outer
+	context's interpreter should take over. 
+	Therefore we force #atEnd."
+	
+	super visitBlockSequenceNode: aNode.
+	forceAtEnd := true
+!
+
+visitDynamicArrayNode: aNode
+	| array |
+	
+	array := #().
+	aNode nodes do: [ :each |
+		array addFirst: self pop ].
+	
+	self push: array
+!
+
+visitDynamicDictionaryNode: aNode
+	| keyValueList |
+	
+	keyValueList := OrderedCollection new.
+	
+	aNode nodes do: [ :each | 
+		keyValueList add: self pop ].
+	
+	self push: (HashedCollection newFromPairs: keyValueList reversed)
+!
+
+visitJSStatementNode: aNode
+	returned := true.
+	self returnValue: (self eval: aNode source)
+!
+
+visitNode: aNode
+	"Do nothing by default. Especially, do not visit children recursively."
+!
+
+visitReturnNode: aNode
+	returned := true.
+	self returnValue: self pop
+!
+
+visitSendNode: aNode
+	| receiver args message result |
+	
+	args := aNode arguments collect: [ :each | self pop ].
+	receiver := self pop.
+	
+	message := self
+		messageFromSendNode: aNode
+		arguments: args reversed.
+	
+	result := self sendMessage: message to: receiver superSend: aNode superSend.
+	
+	"For cascade sends, push the reciever if the send is not the last one"
+	(aNode isCascadeSendNode and: [ aNode isLastChild not ])
+		ifTrue: [ self push: receiver ]
+		ifFalse: [ self push: result ]
+!
+
+visitSequenceNode: aNode
+	aNode temps do: [ :each |
+		self context defineLocal: each ]
+!
+
+visitValueNode: aNode
+	self push: aNode value
+!
+
+visitVariableNode: aNode
+	aNode binding isUnknownVar ifTrue: [
+		^ self push: (PlatformInterface globals at: aNode value ifAbsent: [ self error: 'Unknown variable' ]) ].
+		
+	self push: (aNode binding isInstanceVar
+		ifTrue: [ self context receiver instVarAt: aNode value ]
+		ifFalse: [ self context 
+			localAt: aNode value
+			ifAbsent: [
+				aNode value isCapitalized
+					ifTrue: [
+						Smalltalk globals 
+							at: aNode value 
+							ifAbsent: [ PlatformInterface globals at: aNode value ] ] ] ])
+! !
+
+Error subclass: #ASTInterpreterError
+	instanceVariableNames: ''
+	package: 'Compiler-Interpreter'!
+!ASTInterpreterError commentStamp!
+I get signaled when an AST interpreter is unable to interpret a node.!
+
+NodeVisitor subclass: #ASTPCNodeVisitor
+	instanceVariableNames: 'context index selector currentNode'
+	package: 'Compiler-Interpreter'!
+!ASTPCNodeVisitor commentStamp!
+I visit an AST until I get to the current node for the `context` and answer it.
+
+## API
+
+My instances must be filled with a context object using `#context:`.
+
+After visiting the AST the current node is answered by `#currentNode`!
+
+!ASTPCNodeVisitor methodsFor: 'accessing'!
+
+context
+	^ context
+!
+
+context: aContext
+	context := aContext
+!
+
+currentNode
+	^ currentNode
+!
+
+increaseIndex
+	index := self index + 1
+!
+
+index
+	^ index ifNil: [ index := 0 ]
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+! !
+
+!ASTPCNodeVisitor methodsFor: 'visiting'!
+
+visitJSStatementNode: aNode
+	"If a JSStatementNode is encountered, it always is the current node.
+	Stop visiting the AST there"
+	
+	currentNode := aNode
+!
+
+visitSendNode: aNode
+	| sendIndex |
+	sendIndex := self context sendIndexAt: self selector.
+	
+	super visitSendNode: aNode.
+	
+	self selector = aNode selector ifTrue: [
+		self index = sendIndex ifTrue: [ currentNode := aNode ].
+		self increaseIndex ]
+! !
+
+!AssignmentNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+
+!BlockNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+
+!DynamicArrayNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+
+!DynamicDictionaryNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+
+!JSStatementNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+
+!Node methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ false
+! !
+
+!SendNode methodsFor: '*Compiler-Interpreter'!
+
+isSteppingNode
+	^ true
+! !
+

+ 2708 - 0
bower_components/amber/src/Compiler-Semantic.js

@@ -0,0 +1,2708 @@
+define("amber_core/Compiler-Semantic", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Compiler-Core"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Semantic');
+$core.packages["Compiler-Semantic"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('LexicalScope', $globals.Object, ['node', 'instruction', 'temps', 'args', 'outerScope', 'blockIndex'], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.LexicalScope.comment="I represent a lexical scope where variable names are associated with ScopeVars\x0aInstances are used for block scopes. Method scopes are instances of MethodLexicalScope.\x0a\x0aI am attached to a ScopeVar and method/block nodes.\x0aEach context (method/closure) get a fresh scope that inherits from its outer scope.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addArg:",
+protocol: 'adding',
+fn: function (aString){
+var self=this;
+function $ArgVar(){return $globals.ArgVar||(typeof ArgVar=="undefined"?nil:ArgVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._args();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["args"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._at_put_(aString,$recv($ArgVar())._on_(aString));
+$recv($recv(self._args())._at_(aString))._scope_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addArg:",{aString:aString},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "addArg: aString\x0a\x09self args at: aString put: (ArgVar on: aString).\x0a\x09(self args at: aString) scope: self",
+referencedClasses: ["ArgVar"],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "args", "on:", "scope:", "at:"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "addTemp:",
+protocol: 'adding',
+fn: function (aString){
+var self=this;
+function $TempVar(){return $globals.TempVar||(typeof TempVar=="undefined"?nil:TempVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._temps();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["temps"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._at_put_(aString,$recv($TempVar())._on_(aString));
+$recv($recv(self._temps())._at_(aString))._scope_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addTemp:",{aString:aString},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "addTemp: aString\x0a\x09self temps at: aString put: (TempVar on: aString).\x0a\x09(self temps at: aString) scope: self",
+referencedClasses: ["TempVar"],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "temps", "on:", "scope:", "at:"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1="$ctx".__comma($recv(self._scopeLevel())._asString());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09^ '$ctx', self scopeLevel asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "asString", "scopeLevel"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "allVariableNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(self._args())._keys();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["keys"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma($recv(self._temps())._keys());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allVariableNames",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allVariableNames\x0a\x09^ self args keys, self temps keys",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "keys", "args", "temps"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "args",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@args"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@args"]=$recv($Dictionary())._new();
+$1=self["@args"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"args",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "args\x0a\x09^ args ifNil: [ args := Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "bindingFor:",
+protocol: 'accessing',
+fn: function (aStringOrNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$5,$1;
+$2=self._pseudoVars();
+$3=$recv(aStringOrNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._at_ifAbsent_($3,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._args();
+$5=$recv(aStringOrNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value"]=2;
+//>>excludeEnd("ctx");
+return $recv($4)._at_ifAbsent_($5,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self._temps())._at_ifAbsent_($recv(aStringOrNode)._value(),(function(){
+return nil;
+
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["at:ifAbsent:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:ifAbsent:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"bindingFor:",{aStringOrNode:aStringOrNode},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStringOrNode"],
+source: "bindingFor: aStringOrNode\x0a\x09^ self pseudoVars at: aStringOrNode value ifAbsent: [\x0a\x09\x09self args at: aStringOrNode value ifAbsent: [\x0a\x09\x09\x09self temps at: aStringOrNode value ifAbsent: [ nil ]]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "pseudoVars", "value", "args", "temps"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "blockIndex",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@blockIndex"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=(0);
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"blockIndex",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "blockIndex\x0a\x09^ blockIndex ifNil: [ 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "blockIndex:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@blockIndex"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "blockIndex: anInteger \x0a\x09blockIndex := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "canInlineNonLocalReturns",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._isInlined())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._outerScope())._canInlineNonLocalReturns();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"canInlineNonLocalReturns",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "canInlineNonLocalReturns\x0a\x09^ self isInlined and: [ self outerScope canInlineNonLocalReturns ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "isInlined", "canInlineNonLocalReturns", "outerScope"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "instruction",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@instruction"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "instruction\x0a\x09^ instruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "instruction:",
+protocol: 'accessing',
+fn: function (anIRInstruction){
+var self=this;
+self["@instruction"]=anIRInstruction;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIRInstruction"],
+source: "instruction: anIRInstruction\x0a\x09instruction := anIRInstruction",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockScope",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._isMethodScope())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isBlockScope",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockScope\x0a\x09^ self isMethodScope not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isMethodScope"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "isInlined",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=self._instruction();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instruction"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._notNil();
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._instruction())._isInlined();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isInlined",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInlined\x0a\x09^ self instruction notNil and: [\x0a\x09\x09self instruction isInlined ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "notNil", "instruction", "isInlined"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "isMethodScope",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMethodScope\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "lookupVariable:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+var lookup;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$receiver;
+lookup=self._bindingFor_(aNode);
+$1=lookup;
+if(($receiver = $1) == null || $receiver.isNil){
+$2=self._outerScope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["outerScope"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+lookup=$2;
+} else {
+lookup=$recv(self._outerScope())._lookupVariable_(aNode);
+};
+lookup;
+} else {
+$1;
+};
+$3=lookup;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lookupVariable:",{aNode:aNode,lookup:lookup},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "lookupVariable: aNode\x0a\x09| lookup |\x0a\x09lookup := (self bindingFor: aNode).\x0a\x09lookup ifNil: [\x0a\x09\x09lookup := self outerScope ifNotNil: [\x0a\x09\x09\x09(self outerScope lookupVariable: aNode) ]].\x0a\x09^ lookup",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bindingFor:", "ifNil:", "ifNotNil:", "outerScope", "lookupVariable:"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "methodScope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._outerScope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["outerScope"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+$1=$recv(self._outerScope())._methodScope();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodScope",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodScope\x0a\x09^ self outerScope ifNotNil: [\x0a\x09\x09self outerScope methodScope ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "outerScope", "methodScope"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "node",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@node"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "node\x0a\x09\x22Answer the node in which I am defined\x22\x0a\x09\x0a\x09^ node",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "node:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@node"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "node: aNode\x0a\x09node := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "outerScope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@outerScope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "outerScope\x0a\x09^ outerScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "outerScope:",
+protocol: 'accessing',
+fn: function (aLexicalScope){
+var self=this;
+self["@outerScope"]=aLexicalScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aLexicalScope"],
+source: "outerScope: aLexicalScope\x0a\x09outerScope := aLexicalScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "pseudoVars",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methodScope())._pseudoVars();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pseudoVars",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pseudoVars\x0a\x09^ self methodScope pseudoVars",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["pseudoVars", "methodScope"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "scopeLevel",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$3,$5,$receiver;
+$1=self._outerScope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["outerScope"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+return (1);
+} else {
+$1;
+};
+$2=self._isInlined();
+if($core.assert($2)){
+$4=self._outerScope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["outerScope"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4)._scopeLevel();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scopeLevel"]=1;
+//>>excludeEnd("ctx");
+return $3;
+};
+$5=$recv($recv(self._outerScope())._scopeLevel()).__plus((1));
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scopeLevel",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scopeLevel\x0a\x09self outerScope ifNil: [ ^ 1 ].\x0a\x09self isInlined ifTrue: [ ^ self outerScope scopeLevel ].\x0a\x09\x0a\x09^ self outerScope scopeLevel + 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "outerScope", "ifTrue:", "isInlined", "scopeLevel", "+"]
+}),
+$globals.LexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "temps",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@temps"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@temps"]=$recv($Dictionary())._new();
+$1=self["@temps"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"temps",{},$globals.LexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "temps\x0a\x09^ temps ifNil: [ temps := Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.LexicalScope);
+
+
+
+$core.addClass('MethodLexicalScope', $globals.LexicalScope, ['iVars', 'pseudoVars', 'unknownVariables', 'localReturn', 'nonLocalReturns'], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodLexicalScope.comment="I represent a method scope.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addIVar:",
+protocol: 'adding',
+fn: function (aString){
+var self=this;
+function $InstanceVar(){return $globals.InstanceVar||(typeof InstanceVar=="undefined"?nil:InstanceVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._iVars();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["iVars"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._at_put_(aString,$recv($InstanceVar())._on_(aString));
+$recv($recv(self._iVars())._at_(aString))._scope_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addIVar:",{aString:aString},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "addIVar: aString\x0a\x09self iVars at: aString put: (InstanceVar on: aString).\x0a\x09(self iVars at: aString) scope: self",
+referencedClasses: ["InstanceVar"],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "iVars", "on:", "scope:", "at:"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "addNonLocalReturn:",
+protocol: 'adding',
+fn: function (aScope){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._nonLocalReturns())._add_(aScope);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addNonLocalReturn:",{aScope:aScope},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "addNonLocalReturn: aScope\x0a\x09self nonLocalReturns add: aScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "nonLocalReturns"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "allVariableNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.MethodLexicalScope.superclass.fn.prototype._allVariableNames.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($2).__comma($recv(self._iVars())._keys());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allVariableNames",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allVariableNames\x0a\x09^ super allVariableNames, self iVars keys",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "allVariableNames", "keys", "iVars"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "bindingFor:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.MethodLexicalScope.superclass.fn.prototype._bindingFor_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$recv(self._iVars())._at_ifAbsent_($recv(aNode)._value(),(function(){
+return nil;
+
+}));
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"bindingFor:",{aNode:aNode},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "bindingFor: aNode\x0a\x09^ (super bindingFor: aNode) ifNil: [\x0a\x09\x09self iVars at: aNode value ifAbsent: [ nil ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "bindingFor:", "at:ifAbsent:", "iVars", "value"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "canInlineNonLocalReturns",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "canInlineNonLocalReturns\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "hasLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._localReturn();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hasLocalReturn",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hasLocalReturn\x0a\x09^ self localReturn",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["localReturn"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "hasNonLocalReturn",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._nonLocalReturns())._notEmpty();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hasNonLocalReturn",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hasNonLocalReturn\x0a\x09^ self nonLocalReturns notEmpty",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["notEmpty", "nonLocalReturns"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "iVars",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@iVars"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@iVars"]=$recv($Dictionary())._new();
+$1=self["@iVars"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"iVars",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "iVars\x0a\x09^ iVars ifNil: [ iVars := Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "isMethodScope",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMethodScope\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "localReturn",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@localReturn"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"localReturn",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "localReturn\x0a\x09^ localReturn ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "localReturn:",
+protocol: 'accessing',
+fn: function (aBoolean){
+var self=this;
+self["@localReturn"]=aBoolean;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "localReturn: aBoolean\x0a\x09localReturn := aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "methodScope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodScope\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "nonLocalReturns",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@nonLocalReturns"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@nonLocalReturns"]=$recv($OrderedCollection())._new();
+$1=self["@nonLocalReturns"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nonLocalReturns",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nonLocalReturns\x0a\x09^ nonLocalReturns ifNil: [ nonLocalReturns := OrderedCollection new ]",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "pseudoVars",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $PseudoVar(){return $globals.PseudoVar||(typeof PseudoVar=="undefined"?nil:PseudoVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$receiver;
+$1=self["@pseudoVars"];
+if(($receiver = $1) == null || $receiver.isNil){
+self["@pseudoVars"]=$recv($Dictionary())._new();
+self["@pseudoVars"];
+$recv($recv($Smalltalk())._pseudoVariableNames())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv($PseudoVar())._on_(each);
+$recv($2)._scope_(self._methodScope());
+$3=$recv($2)._yourself();
+return $recv(self["@pseudoVars"])._at_put_(each,$3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+} else {
+$1;
+};
+$4=self["@pseudoVars"];
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pseudoVars",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pseudoVars\x0a\x09pseudoVars ifNil: [\x0a\x09\x09pseudoVars := Dictionary new.\x0a\x09\x09Smalltalk pseudoVariableNames do: [ :each |\x0a\x09\x09\x09pseudoVars at: each put: ((PseudoVar on: each)\x0a\x09\x09\x09\x09scope: self methodScope;\x0a\x09\x09\x09\x09yourself) ]].\x0a\x09^ pseudoVars",
+referencedClasses: ["Dictionary", "Smalltalk", "PseudoVar"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new", "do:", "pseudoVariableNames", "at:put:", "scope:", "on:", "methodScope", "yourself"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "removeNonLocalReturn:",
+protocol: 'adding',
+fn: function (aScope){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._nonLocalReturns())._remove_ifAbsent_(aScope,(function(){
+
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeNonLocalReturn:",{aScope:aScope},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "removeNonLocalReturn: aScope\x0a\x09self nonLocalReturns remove: aScope ifAbsent: []",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:ifAbsent:", "nonLocalReturns"]
+}),
+$globals.MethodLexicalScope);
+
+$core.addMethod(
+$core.method({
+selector: "unknownVariables",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@unknownVariables"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@unknownVariables"]=$recv($OrderedCollection())._new();
+$1=self["@unknownVariables"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"unknownVariables",{},$globals.MethodLexicalScope)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "unknownVariables\x0a\x09^ unknownVariables ifNil: [ unknownVariables := OrderedCollection new ]",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.MethodLexicalScope);
+
+
+
+$core.addClass('ScopeVar', $globals.Object, ['scope', 'name'], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ScopeVar.comment="I am an entry in a LexicalScope that gets associated with variable nodes of the same name.\x0aThere are 4 different subclasses of vars: temp vars, local vars, args, and unknown/global vars.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._name())._asVariableName();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.ScopeVar)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09^ self name asVariableName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asVariableName", "name"]
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isArgVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isArgVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isClassRefVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClassRefVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isInstanceVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInstanceVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isPseudoVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isPseudoVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isTempVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTempVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "isUnknownVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isUnknownVar\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "name",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@name"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "name\x0a\x09^ name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "name:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@name"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "name: aString\x0a\x09name := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "scope",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@scope"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "scope\x0a\x09^ scope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "scope:",
+protocol: 'accessing',
+fn: function (aScope){
+var self=this;
+self["@scope"]=aScope;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "scope: aScope\x0a\x09scope := aScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ScopeVar);
+
+$core.addMethod(
+$core.method({
+selector: "validateAssignment",
+protocol: 'testing',
+fn: function (){
+var self=this;
+function $InvalidAssignmentError(){return $globals.InvalidAssignmentError||(typeof InvalidAssignmentError=="undefined"?nil:InvalidAssignmentError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+$1=$recv(self._isArgVar())._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._isPseudoVar();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+$2=$recv($InvalidAssignmentError())._new();
+$recv($2)._variableName_(self._name());
+$3=$recv($2)._signal();
+$3;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"validateAssignment",{},$globals.ScopeVar)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "validateAssignment\x0a\x09(self isArgVar or: [ self isPseudoVar ]) ifTrue: [\x0a\x09\x09InvalidAssignmentError new\x0a\x09\x09\x09variableName: self name;\x0a\x09\x09\x09signal]",
+referencedClasses: ["InvalidAssignmentError"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "or:", "isArgVar", "isPseudoVar", "variableName:", "new", "name", "signal"]
+}),
+$globals.ScopeVar);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._name_(aString);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aString:aString},$globals.ScopeVar.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "on: aString\x0a\x09^ self new\x0a\x09\x09name: aString;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["name:", "new", "yourself"]
+}),
+$globals.ScopeVar.klass);
+
+
+$core.addClass('AliasVar', $globals.ScopeVar, ['node'], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AliasVar.comment="I am an internally defined variable by the compiler";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "node",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@node"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "node\x0a\x09^ node",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AliasVar);
+
+$core.addMethod(
+$core.method({
+selector: "node:",
+protocol: 'accessing',
+fn: function (aNode){
+var self=this;
+self["@node"]=aNode;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "node: aNode\x0a\x09node := aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AliasVar);
+
+
+
+$core.addClass('ArgVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ArgVar.comment="I am an argument of a method or block.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "isArgVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isArgVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ArgVar);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ArgVar);
+
+
+
+$core.addClass('ClassRefVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassRefVar.comment="I am an class reference variable";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("$".__comma(self._name())).__comma("()");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.ClassRefVar)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09\x22Fixes issue #190.\x0a\x09A function is created in the method definition, answering the class or nil.\x0a\x09See JSStream >> #nextPutClassRefFunction:\x22\x0a\x09\x0a\x09^ '$', self name, '()'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "name"]
+}),
+$globals.ClassRefVar);
+
+$core.addMethod(
+$core.method({
+selector: "isClassRefVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClassRefVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassRefVar);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassRefVar);
+
+
+
+$core.addClass('InstanceVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.InstanceVar.comment="I am an instance variable of a method or block.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("self[\x22@".__comma(self._name())).__comma("\x22]");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.InstanceVar)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09^ 'self[\x22@', self name, '\x22]'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "name"]
+}),
+$globals.InstanceVar);
+
+$core.addMethod(
+$core.method({
+selector: "isInstanceVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isInstanceVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.InstanceVar);
+
+
+
+$core.addClass('PseudoVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PseudoVar.comment="I am an pseudo variable.\x0a\x0aThe five Smalltalk pseudo variables are: 'self', 'super', 'nil', 'true' and 'false'";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "alias",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._name();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alias",{},$globals.PseudoVar)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "alias\x0a\x09^ self name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["name"]
+}),
+$globals.PseudoVar);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PseudoVar);
+
+$core.addMethod(
+$core.method({
+selector: "isPseudoVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isPseudoVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PseudoVar);
+
+
+
+$core.addClass('TempVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TempVar.comment="I am an temporary variable of a method or block.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "isTempVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTempVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TempVar);
+
+
+
+$core.addClass('UnknownVar', $globals.ScopeVar, [], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.UnknownVar.comment="I am an unknown variable. Amber uses unknown variables as JavaScript globals";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "isUnknownVar",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isUnknownVar\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UnknownVar);
+
+
+
+$core.addClass('SemanticAnalyzer', $globals.NodeVisitor, ['currentScope', 'blockIndex', 'theClass', 'classReferences', 'messageSends', 'superSends'], 'Compiler-Semantic');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SemanticAnalyzer.comment="I semantically analyze the abstract syntax tree and annotate it with informations such as non local returns and variable scopes.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "classReferences",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@classReferences"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@classReferences"]=$recv($Set())._new();
+$1=self["@classReferences"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classReferences",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classReferences\x0a\x09^ classReferences ifNil: [ classReferences := Set new ]",
+referencedClasses: ["Set"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "errorShadowingVariable:",
+protocol: 'error handling',
+fn: function (aString){
+var self=this;
+function $ShadowingVariableError(){return $globals.ShadowingVariableError||(typeof ShadowingVariableError=="undefined"?nil:ShadowingVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($ShadowingVariableError())._new();
+$recv($1)._variableName_(aString);
+$2=$recv($1)._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"errorShadowingVariable:",{aString:aString},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "errorShadowingVariable: aString\x0a\x09ShadowingVariableError new\x0a\x09\x09variableName: aString;\x0a\x09\x09signal",
+referencedClasses: ["ShadowingVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["variableName:", "new", "signal"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "errorUnknownVariable:",
+protocol: 'error handling',
+fn: function (aNode){
+var self=this;
+var identifier;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $UnknownVariableError(){return $globals.UnknownVariableError||(typeof UnknownVariableError=="undefined"?nil:UnknownVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5;
+identifier=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($recv($recv($recv($Smalltalk())._globalJsVariables())._includes_(identifier))._not())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._isVariableGloballyUndefined_(identifier);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+$2=$recv($UnknownVariableError())._new();
+$3=$2;
+$4=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=2;
+//>>excludeEnd("ctx");
+$recv($3)._variableName_($4);
+$5=$recv($2)._signal();
+$5;
+} else {
+$recv($recv($recv(self["@currentScope"])._methodScope())._unknownVariables())._add_($recv(aNode)._value());
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"errorUnknownVariable:",{aNode:aNode,identifier:identifier},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "errorUnknownVariable: aNode\x0a\x09\x22Throw an error if the variable is undeclared in the global JS scope (i.e. window).\x0a\x09We allow all variables listed by Smalltalk>>#globalJsVariables.\x0a\x09This list includes: `jQuery`, `window`, `document`,  `process` and `global`\x0a\x09for nodejs and browser environments.\x0a\x09\x0a\x09This is only to make sure compilation works on both browser-based and nodejs environments.\x0a\x09The ideal solution would be to use a pragma instead\x22\x0a\x0a\x09| identifier |\x0a\x09identifier := aNode value.\x0a\x09\x0a\x09((Smalltalk globalJsVariables includes: identifier) not\x0a\x09\x09and: [ self isVariableGloballyUndefined: identifier ])\x0a\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09UnknownVariableError new\x0a\x09\x09\x09\x09\x09variableName: aNode value;\x0a\x09\x09\x09\x09\x09signal ]\x0a\x09\x09\x09ifFalse: [\x0a\x09\x09\x09\x09currentScope methodScope unknownVariables add: aNode value ]",
+referencedClasses: ["Smalltalk", "UnknownVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["value", "ifTrue:ifFalse:", "and:", "not", "includes:", "globalJsVariables", "isVariableGloballyUndefined:", "variableName:", "new", "signal", "add:", "unknownVariables", "methodScope"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "isVariableGloballyUndefined:",
+protocol: 'testing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return eval('typeof ' + aString + ' == "undefined"');
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isVariableGloballyUndefined:",{aString:aString},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "isVariableGloballyUndefined: aString\x0a\x09<return eval('typeof ' + aString + ' == \x22undefined\x22')>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "messageSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@messageSends"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@messageSends"]=$recv($Dictionary())._new();
+$1=self["@messageSends"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageSends",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageSends\x0a\x09^ messageSends ifNil: [ messageSends := Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "newBlockScope",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $LexicalScope(){return $globals.LexicalScope||(typeof LexicalScope=="undefined"?nil:LexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newScopeOfClass_($LexicalScope());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newBlockScope",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newBlockScope\x0a\x09^ self newScopeOfClass: LexicalScope",
+referencedClasses: ["LexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["newScopeOfClass:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "newMethodScope",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newScopeOfClass_($MethodLexicalScope());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newMethodScope",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newMethodScope\x0a\x09^ self newScopeOfClass: MethodLexicalScope",
+referencedClasses: ["MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["newScopeOfClass:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "newScopeOfClass:",
+protocol: 'factory',
+fn: function (aLexicalScopeClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv(aLexicalScopeClass)._new();
+$recv($2)._outerScope_(self["@currentScope"]);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newScopeOfClass:",{aLexicalScopeClass:aLexicalScopeClass},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aLexicalScopeClass"],
+source: "newScopeOfClass: aLexicalScopeClass\x0a\x09^ aLexicalScopeClass new\x0a\x09\x09outerScope: currentScope;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["outerScope:", "new", "yourself"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "nextBlockIndex",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=self["@blockIndex"];
+if(($receiver = $1) == null || $receiver.isNil){
+self["@blockIndex"]=(0);
+self["@blockIndex"];
+} else {
+$1;
+};
+self["@blockIndex"]=$recv(self["@blockIndex"]).__plus((1));
+$2=self["@blockIndex"];
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextBlockIndex",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextBlockIndex\x0a\x09blockIndex ifNil: [ blockIndex := 0 ].\x0a\x09\x0a\x09blockIndex := blockIndex + 1.\x0a\x09^ blockIndex",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "+"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "popScope",
+protocol: 'scope',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=self["@currentScope"];
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+self["@currentScope"]=$recv(self["@currentScope"])._outerScope();
+self["@currentScope"];
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"popScope",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "popScope\x0a\x09currentScope ifNotNil: [\x0a\x09\x09currentScope := currentScope outerScope ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "outerScope"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "pushScope:",
+protocol: 'scope',
+fn: function (aScope){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aScope)._outerScope_(self["@currentScope"]);
+self["@currentScope"]=aScope;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pushScope:",{aScope:aScope},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aScope"],
+source: "pushScope: aScope\x0a\x09aScope outerScope: currentScope.\x0a\x09currentScope := aScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["outerScope:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "superSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@superSends"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@superSends"]=$recv($Dictionary())._new();
+$1=self["@superSends"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"superSends",{},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "superSends\x0a\x09^ superSends ifNil: [ superSends := Dictionary new ]",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "validateVariableScope:",
+protocol: 'scope',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(self["@currentScope"])._lookupVariable_(aString);
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+self._errorShadowingVariable_(aString);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"validateVariableScope:",{aString:aString},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "validateVariableScope: aString\x0a\x09\x22Validate the variable scope in by doing a recursive lookup, up to the method scope\x22\x0a\x0a\x09(currentScope lookupVariable: aString) ifNotNil: [\x0a\x09\x09self errorShadowingVariable: aString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "lookupVariable:", "errorShadowingVariable:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitAssignmentNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitAssignmentNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv($recv(aNode)._left())._beAssigned();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitAssignmentNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitAssignmentNode: aNode\x0a\x09super visitAssignmentNode: aNode.\x0a\x09aNode left beAssigned",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitAssignmentNode:", "beAssigned", "left"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitBlockNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._pushScope_(self._newBlockScope());
+$recv(aNode)._scope_(self["@currentScope"]);
+$recv(self["@currentScope"])._node_(aNode);
+$recv(self["@currentScope"])._blockIndex_(self._nextBlockIndex());
+$recv($recv(aNode)._parameters())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._validateVariableScope_(each);
+return $recv(self["@currentScope"])._addArg_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitBlockNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self._popScope();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitBlockNode: aNode\x0a\x09self pushScope: self newBlockScope.\x0a\x09aNode scope: currentScope.\x0a\x09currentScope node: aNode.\x0a\x09currentScope blockIndex: self nextBlockIndex.\x0a\x0a\x09aNode parameters do: [ :each |\x0a\x09\x09self validateVariableScope: each.\x0a\x09\x09currentScope addArg: each ].\x0a\x0a\x09super visitBlockNode: aNode.\x0a\x09self popScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["pushScope:", "newBlockScope", "scope:", "node:", "blockIndex:", "nextBlockIndex", "do:", "parameters", "validateVariableScope:", "addArg:", "visitBlockNode:", "popScope"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitCascadeNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitCascadeNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$3=$recv(aNode)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._first();
+$1=$recv($2)._superSend();
+if($core.assert($1)){
+$recv($recv(aNode)._nodes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._superSend_(true);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitCascadeNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitCascadeNode: aNode\x0a\x09super visitCascadeNode: aNode.\x0a\x09aNode nodes first superSend ifTrue: [\x0a\x09\x09aNode nodes do: [ :each | each superSend: true ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["visitCascadeNode:", "ifTrue:", "superSend", "first", "nodes", "do:", "superSend:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitMethodNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._pushScope_(self._newMethodScope());
+$recv(aNode)._scope_(self["@currentScope"]);
+$recv(self["@currentScope"])._node_(aNode);
+$recv($recv(self._theClass())._allInstanceVariableNames())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@currentScope"])._addIVar_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(aNode)._arguments())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._validateVariableScope_(each);
+return $recv(self["@currentScope"])._addArg_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitMethodNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aNode)._classReferences_(self._classReferences());
+$recv(aNode)._sendIndexes_(self._messageSends());
+$1=$recv(aNode)._superSends_($recv(self._superSends())._keys());
+self._popScope();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitMethodNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitMethodNode: aNode\x0a\x09self pushScope: self newMethodScope.\x0a\x09aNode scope: currentScope.\x0a\x09currentScope node: aNode.\x0a\x0a\x09self theClass allInstanceVariableNames do: [ :each |\x0a\x09\x09currentScope addIVar: each ].\x0a\x09aNode arguments do: [ :each |\x0a\x09\x09self validateVariableScope: each.\x0a\x09\x09currentScope addArg: each ].\x0a\x0a\x09super visitMethodNode: aNode.\x0a\x0a\x09aNode\x0a\x09\x09classReferences: self classReferences;\x0a\x09\x09sendIndexes: self messageSends;\x0a\x09\x09superSends: self superSends keys.\x0a\x09self popScope",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["pushScope:", "newMethodScope", "scope:", "node:", "do:", "allInstanceVariableNames", "theClass", "addIVar:", "arguments", "validateVariableScope:", "addArg:", "visitMethodNode:", "classReferences:", "classReferences", "sendIndexes:", "messageSends", "superSends:", "keys", "superSends", "popScope"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitReturnNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aNode)._scope_(self["@currentScope"]);
+$1=$recv(self["@currentScope"])._isMethodScope();
+if($core.assert($1)){
+$recv(self["@currentScope"])._localReturn_(true);
+} else {
+$recv($recv(self["@currentScope"])._methodScope())._addNonLocalReturn_(self["@currentScope"]);
+};
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitReturnNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitReturnNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitReturnNode: aNode\x0a\x09aNode scope: currentScope.\x0a\x09currentScope isMethodScope\x0a\x09\x09ifTrue: [ currentScope localReturn: true ]\x0a\x09\x09ifFalse: [ currentScope methodScope addNonLocalReturn: currentScope ].\x0a\x09super visitReturnNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["scope:", "ifTrue:ifFalse:", "isMethodScope", "localReturn:", "addNonLocalReturn:", "methodScope", "visitReturnNode:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitSendNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+function $IRSendInliner(){return $globals.IRSendInliner||(typeof IRSendInliner=="undefined"?nil:IRSendInliner)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$4,$5,$6,$8,$9,$7,$11,$12,$10,$13,$14,$15,$17,$18,$16,$receiver;
+$3=$recv(aNode)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._value();
+$1=$recv($2).__eq("super");
+if($core.assert($1)){
+$recv(aNode)._superSend_(true);
+$4=$recv(aNode)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=2;
+//>>excludeEnd("ctx");
+$recv($4)._value_("self");
+$5=self._superSends();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superSends"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(aNode)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+$recv($5)._at_ifAbsentPut_($6,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($Set())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:ifAbsentPut:"]=1;
+//>>excludeEnd("ctx");
+$8=self._superSends();
+$9=$recv(aNode)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=2;
+//>>excludeEnd("ctx");
+$7=$recv($8)._at_($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:"]=1;
+//>>excludeEnd("ctx");
+$recv($7)._add_(aNode);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$11=$recv($IRSendInliner())._inlinedSelectors();
+$12=$recv(aNode)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=3;
+//>>excludeEnd("ctx");
+$10=$recv($11)._includes_($12);
+if($core.assert($10)){
+$recv(aNode)._shouldBeInlined_(true);
+$13=$recv(aNode)._receiver();
+if(($receiver = $13) == null || $receiver.isNil){
+$13;
+} else {
+var receiver;
+receiver=$receiver;
+$recv(receiver)._shouldBeAliased_(true);
+};
+};
+};
+$14=self._messageSends();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["messageSends"]=1;
+//>>excludeEnd("ctx");
+$15=$recv(aNode)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=4;
+//>>excludeEnd("ctx");
+$recv($14)._at_ifAbsentPut_($15,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($Set())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
+//>>excludeEnd("ctx");
+}));
+$17=self._messageSends();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["messageSends"]=2;
+//>>excludeEnd("ctx");
+$18=$recv(aNode)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=5;
+//>>excludeEnd("ctx");
+$16=$recv($17)._at_($18);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:"]=2;
+//>>excludeEnd("ctx");
+$recv($16)._add_(aNode);
+$recv(aNode)._index_($recv($recv(self._messageSends())._at_($recv(aNode)._selector()))._size());
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitSendNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSendNode: aNode\x0a\x0a\x09aNode receiver value = 'super'\x0a\x09\x09ifTrue: [\x0a\x09\x09\x09aNode superSend: true.\x0a\x09\x09\x09aNode receiver value: 'self'.\x0a\x09\x09\x09self superSends at: aNode selector ifAbsentPut: [ Set new ].\x0a\x09\x09\x09(self superSends at: aNode selector) add: aNode ]\x0a\x09\x09\x0a\x09\x09ifFalse: [ (IRSendInliner inlinedSelectors includes: aNode selector) ifTrue: [\x0a\x09\x09\x09aNode shouldBeInlined: true.\x0a\x09\x09\x09aNode receiver ifNotNil: [ :receiver |\x0a\x09\x09\x09\x09receiver shouldBeAliased: true ] ] ].\x0a\x0a\x09self messageSends at: aNode selector ifAbsentPut: [ Set new ].\x0a\x09(self messageSends at: aNode selector) add: aNode.\x0a\x0a\x09aNode index: (self messageSends at: aNode selector) size.\x0a\x0a\x09super visitSendNode: aNode",
+referencedClasses: ["Set", "IRSendInliner"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "=", "value", "receiver", "superSend:", "value:", "at:ifAbsentPut:", "superSends", "selector", "new", "add:", "at:", "ifTrue:", "includes:", "inlinedSelectors", "shouldBeInlined:", "ifNotNil:", "shouldBeAliased:", "messageSends", "index:", "size", "visitSendNode:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitSequenceNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aNode)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._validateVariableScope_(each);
+return $recv(self["@currentScope"])._addTemp_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SemanticAnalyzer.superclass.fn.prototype._visitSequenceNode_.apply($recv(self), [aNode]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitSequenceNode:",{aNode:aNode},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitSequenceNode: aNode\x0a\x09aNode temps do: [ :each |\x0a\x09\x09self validateVariableScope: each.\x0a\x09\x09currentScope addTemp: each ].\x0a\x0a\x09super visitSequenceNode: aNode",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "temps", "validateVariableScope:", "addTemp:", "visitSequenceNode:"]
+}),
+$globals.SemanticAnalyzer);
+
+$core.addMethod(
+$core.method({
+selector: "visitVariableNode:",
+protocol: 'visiting',
+fn: function (aNode){
+var self=this;
+var binding;
+function $ClassRefVar(){return $globals.ClassRefVar||(typeof ClassRefVar=="undefined"?nil:ClassRefVar)}
+function $UnknownVar(){return $globals.UnknownVar||(typeof UnknownVar=="undefined"?nil:UnknownVar)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$6,$7,$8,$9,$10,$11,$receiver;
+binding=$recv(self["@currentScope"])._lookupVariable_(aNode);
+$1=binding;
+if(($receiver = $1) == null || $receiver.isNil){
+$3=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._isCapitalized();
+if($core.assert($2)){
+$4=$recv($ClassRefVar())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$5=$4;
+$6=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=2;
+//>>excludeEnd("ctx");
+$recv($5)._name_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name:"]=1;
+//>>excludeEnd("ctx");
+$7=$recv($4)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+binding=$7;
+binding;
+$8=self._classReferences();
+$9=$recv(aNode)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["value"]=3;
+//>>excludeEnd("ctx");
+$recv($8)._add_($9);
+} else {
+self._errorUnknownVariable_(aNode);
+$10=$recv($UnknownVar())._new();
+$recv($10)._name_($recv(aNode)._value());
+$11=$recv($10)._yourself();
+binding=$11;
+binding;
+};
+} else {
+$1;
+};
+$recv(aNode)._binding_(binding);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode,binding:binding},$globals.SemanticAnalyzer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode"],
+source: "visitVariableNode: aNode\x0a\x09\x22Bind a ScopeVar to aNode by doing a lookup in the current scope.\x0a\x09If no ScopeVar is found, bind a UnknowVar and throw an error.\x22\x0a\x0a\x09| binding |\x0a\x09binding := currentScope lookupVariable: aNode.\x0a\x09\x0a\x09binding ifNil: [\x0a\x09\x09aNode value isCapitalized\x0a\x09\x09\x09ifTrue: [ \x22Capital letter variables might be globals.\x22\x0a\x09\x09\x09\x09binding := ClassRefVar new name: aNode value; yourself.\x0a\x09\x09\x09\x09self classReferences add: aNode value]\x0a\x09\x09\x09ifFalse: [\x0a\x09\x09\x09\x09self errorUnknownVariable: aNode.\x0a\x09\x09\x09\x09binding := UnknownVar new name: aNode value; yourself ] ].\x0a\x09\x09\x0a\x09aNode binding: binding.",
+referencedClasses: ["ClassRefVar", "UnknownVar"],
+//>>excludeEnd("ide");
+messageSends: ["lookupVariable:", "ifNil:", "ifTrue:ifFalse:", "isCapitalized", "value", "name:", "new", "yourself", "add:", "classReferences", "errorUnknownVariable:", "binding:"]
+}),
+$globals.SemanticAnalyzer);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._theClass_(aClass);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aClass:aClass},$globals.SemanticAnalyzer.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "on: aClass\x0a\x09^ self new\x0a\x09\x09theClass: aClass;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["theClass:", "new", "yourself"]
+}),
+$globals.SemanticAnalyzer.klass);
+
+});

+ 625 - 0
bower_components/amber/src/Compiler-Semantic.st

@@ -0,0 +1,625 @@
+Smalltalk createPackage: 'Compiler-Semantic'!
+Object subclass: #LexicalScope
+	instanceVariableNames: 'node instruction temps args outerScope blockIndex'
+	package: 'Compiler-Semantic'!
+!LexicalScope commentStamp!
+I represent a lexical scope where variable names are associated with ScopeVars
+Instances are used for block scopes. Method scopes are instances of MethodLexicalScope.
+
+I am attached to a ScopeVar and method/block nodes.
+Each context (method/closure) get a fresh scope that inherits from its outer scope.!
+
+!LexicalScope methodsFor: 'accessing'!
+
+alias
+	^ '$ctx', self scopeLevel asString
+!
+
+allVariableNames
+	^ self args keys, self temps keys
+!
+
+args
+	^ args ifNil: [ args := Dictionary new ]
+!
+
+bindingFor: aStringOrNode
+	^ self pseudoVars at: aStringOrNode value ifAbsent: [
+		self args at: aStringOrNode value ifAbsent: [
+			self temps at: aStringOrNode value ifAbsent: [ nil ]]]
+!
+
+blockIndex
+	^ blockIndex ifNil: [ 0 ]
+!
+
+blockIndex: anInteger 
+	blockIndex := anInteger
+!
+
+instruction
+	^ instruction
+!
+
+instruction: anIRInstruction
+	instruction := anIRInstruction
+!
+
+lookupVariable: aNode
+	| lookup |
+	lookup := (self bindingFor: aNode).
+	lookup ifNil: [
+		lookup := self outerScope ifNotNil: [
+			(self outerScope lookupVariable: aNode) ]].
+	^ lookup
+!
+
+methodScope
+	^ self outerScope ifNotNil: [
+		self outerScope methodScope ]
+!
+
+node
+	"Answer the node in which I am defined"
+	
+	^ node
+!
+
+node: aNode
+	node := aNode
+!
+
+outerScope
+	^ outerScope
+!
+
+outerScope: aLexicalScope
+	outerScope := aLexicalScope
+!
+
+pseudoVars
+	^ self methodScope pseudoVars
+!
+
+scopeLevel
+	self outerScope ifNil: [ ^ 1 ].
+	self isInlined ifTrue: [ ^ self outerScope scopeLevel ].
+	
+	^ self outerScope scopeLevel + 1
+!
+
+temps
+	^ temps ifNil: [ temps := Dictionary new ]
+! !
+
+!LexicalScope methodsFor: 'adding'!
+
+addArg: aString
+	self args at: aString put: (ArgVar on: aString).
+	(self args at: aString) scope: self
+!
+
+addTemp: aString
+	self temps at: aString put: (TempVar on: aString).
+	(self temps at: aString) scope: self
+! !
+
+!LexicalScope methodsFor: 'testing'!
+
+canInlineNonLocalReturns
+	^ self isInlined and: [ self outerScope canInlineNonLocalReturns ]
+!
+
+isBlockScope
+	^ self isMethodScope not
+!
+
+isInlined
+	^ self instruction notNil and: [
+		self instruction isInlined ]
+!
+
+isMethodScope
+	^ false
+! !
+
+LexicalScope subclass: #MethodLexicalScope
+	instanceVariableNames: 'iVars pseudoVars unknownVariables localReturn nonLocalReturns'
+	package: 'Compiler-Semantic'!
+!MethodLexicalScope commentStamp!
+I represent a method scope.!
+
+!MethodLexicalScope methodsFor: 'accessing'!
+
+allVariableNames
+	^ super allVariableNames, self iVars keys
+!
+
+bindingFor: aNode
+	^ (super bindingFor: aNode) ifNil: [
+		self iVars at: aNode value ifAbsent: [ nil ]]
+!
+
+iVars
+	^ iVars ifNil: [ iVars := Dictionary new ]
+!
+
+localReturn
+	^ localReturn ifNil: [ false ]
+!
+
+localReturn: aBoolean
+	localReturn := aBoolean
+!
+
+methodScope
+	^ self
+!
+
+nonLocalReturns
+	^ nonLocalReturns ifNil: [ nonLocalReturns := OrderedCollection new ]
+!
+
+pseudoVars
+	pseudoVars ifNil: [
+		pseudoVars := Dictionary new.
+		Smalltalk pseudoVariableNames do: [ :each |
+			pseudoVars at: each put: ((PseudoVar on: each)
+				scope: self methodScope;
+				yourself) ]].
+	^ pseudoVars
+!
+
+unknownVariables
+	^ unknownVariables ifNil: [ unknownVariables := OrderedCollection new ]
+! !
+
+!MethodLexicalScope methodsFor: 'adding'!
+
+addIVar: aString
+	self iVars at: aString put: (InstanceVar on: aString).
+	(self iVars at: aString) scope: self
+!
+
+addNonLocalReturn: aScope
+	self nonLocalReturns add: aScope
+!
+
+removeNonLocalReturn: aScope
+	self nonLocalReturns remove: aScope ifAbsent: []
+! !
+
+!MethodLexicalScope methodsFor: 'testing'!
+
+canInlineNonLocalReturns
+	^ true
+!
+
+hasLocalReturn
+	^ self localReturn
+!
+
+hasNonLocalReturn
+	^ self nonLocalReturns notEmpty
+!
+
+isMethodScope
+	^ true
+! !
+
+Object subclass: #ScopeVar
+	instanceVariableNames: 'scope name'
+	package: 'Compiler-Semantic'!
+!ScopeVar commentStamp!
+I am an entry in a LexicalScope that gets associated with variable nodes of the same name.
+There are 4 different subclasses of vars: temp vars, local vars, args, and unknown/global vars.!
+
+!ScopeVar methodsFor: 'accessing'!
+
+alias
+	^ self name asVariableName
+!
+
+name
+	^ name
+!
+
+name: aString
+	name := aString
+!
+
+scope
+	^ scope
+!
+
+scope: aScope
+	scope := aScope
+! !
+
+!ScopeVar methodsFor: 'testing'!
+
+isArgVar
+	^ false
+!
+
+isClassRefVar
+	^ false
+!
+
+isImmutable
+	^ false
+!
+
+isInstanceVar
+	^ false
+!
+
+isPseudoVar
+	^ false
+!
+
+isTempVar
+	^ false
+!
+
+isUnknownVar
+	^ false
+!
+
+validateAssignment
+	(self isArgVar or: [ self isPseudoVar ]) ifTrue: [
+		InvalidAssignmentError new
+			variableName: self name;
+			signal]
+! !
+
+!ScopeVar class methodsFor: 'instance creation'!
+
+on: aString
+	^ self new
+		name: aString;
+		yourself
+! !
+
+ScopeVar subclass: #AliasVar
+	instanceVariableNames: 'node'
+	package: 'Compiler-Semantic'!
+!AliasVar commentStamp!
+I am an internally defined variable by the compiler!
+
+!AliasVar methodsFor: 'accessing'!
+
+node
+	^ node
+!
+
+node: aNode
+	node := aNode
+! !
+
+ScopeVar subclass: #ArgVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!ArgVar commentStamp!
+I am an argument of a method or block.!
+
+!ArgVar methodsFor: 'testing'!
+
+isArgVar
+	^ true
+!
+
+isImmutable
+	^ true
+! !
+
+ScopeVar subclass: #ClassRefVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!ClassRefVar commentStamp!
+I am an class reference variable!
+
+!ClassRefVar methodsFor: 'accessing'!
+
+alias
+	"Fixes issue #190.
+	A function is created in the method definition, answering the class or nil.
+	See JSStream >> #nextPutClassRefFunction:"
+	
+	^ '$', self name, '()'
+! !
+
+!ClassRefVar methodsFor: 'testing'!
+
+isClassRefVar
+	^ true
+!
+
+isImmutable
+	^ true
+! !
+
+ScopeVar subclass: #InstanceVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!InstanceVar commentStamp!
+I am an instance variable of a method or block.!
+
+!InstanceVar methodsFor: 'testing'!
+
+alias
+	^ 'self["@', self name, '"]'
+!
+
+isInstanceVar
+	^ true
+! !
+
+ScopeVar subclass: #PseudoVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!PseudoVar commentStamp!
+I am an pseudo variable.
+
+The five Smalltalk pseudo variables are: 'self', 'super', 'nil', 'true' and 'false'!
+
+!PseudoVar methodsFor: 'accessing'!
+
+alias
+	^ self name
+! !
+
+!PseudoVar methodsFor: 'testing'!
+
+isImmutable
+	^ true
+!
+
+isPseudoVar
+	^ true
+! !
+
+ScopeVar subclass: #TempVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!TempVar commentStamp!
+I am an temporary variable of a method or block.!
+
+!TempVar methodsFor: 'testing'!
+
+isTempVar
+	^ true
+! !
+
+ScopeVar subclass: #UnknownVar
+	instanceVariableNames: ''
+	package: 'Compiler-Semantic'!
+!UnknownVar commentStamp!
+I am an unknown variable. Amber uses unknown variables as JavaScript globals!
+
+!UnknownVar methodsFor: 'testing'!
+
+isUnknownVar
+	^ true
+! !
+
+NodeVisitor subclass: #SemanticAnalyzer
+	instanceVariableNames: 'currentScope blockIndex theClass classReferences messageSends superSends'
+	package: 'Compiler-Semantic'!
+!SemanticAnalyzer commentStamp!
+I semantically analyze the abstract syntax tree and annotate it with informations such as non local returns and variable scopes.!
+
+!SemanticAnalyzer methodsFor: 'accessing'!
+
+classReferences
+	^ classReferences ifNil: [ classReferences := Set new ]
+!
+
+messageSends
+	^ messageSends ifNil: [ messageSends := Dictionary new ]
+!
+
+superSends
+	^ superSends ifNil: [ superSends := Dictionary new ]
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+!SemanticAnalyzer methodsFor: 'error handling'!
+
+errorShadowingVariable: aString
+	ShadowingVariableError new
+		variableName: aString;
+		signal
+!
+
+errorUnknownVariable: aNode
+	"Throw an error if the variable is undeclared in the global JS scope (i.e. window).
+	We allow all variables listed by Smalltalk>>#globalJsVariables.
+	This list includes: `jQuery`, `window`, `document`,  `process` and `global`
+	for nodejs and browser environments.
+	
+	This is only to make sure compilation works on both browser-based and nodejs environments.
+	The ideal solution would be to use a pragma instead"
+
+	| identifier |
+	identifier := aNode value.
+	
+	((Smalltalk globalJsVariables includes: identifier) not
+		and: [ self isVariableGloballyUndefined: identifier ])
+			ifTrue: [
+				UnknownVariableError new
+					variableName: aNode value;
+					signal ]
+			ifFalse: [
+				currentScope methodScope unknownVariables add: aNode value ]
+! !
+
+!SemanticAnalyzer methodsFor: 'factory'!
+
+newBlockScope
+	^ self newScopeOfClass: LexicalScope
+!
+
+newMethodScope
+	^ self newScopeOfClass: MethodLexicalScope
+!
+
+newScopeOfClass: aLexicalScopeClass
+	^ aLexicalScopeClass new
+		outerScope: currentScope;
+		yourself
+! !
+
+!SemanticAnalyzer methodsFor: 'private'!
+
+nextBlockIndex
+	blockIndex ifNil: [ blockIndex := 0 ].
+	
+	blockIndex := blockIndex + 1.
+	^ blockIndex
+! !
+
+!SemanticAnalyzer methodsFor: 'scope'!
+
+popScope
+	currentScope ifNotNil: [
+		currentScope := currentScope outerScope ]
+!
+
+pushScope: aScope
+	aScope outerScope: currentScope.
+	currentScope := aScope
+!
+
+validateVariableScope: aString
+	"Validate the variable scope in by doing a recursive lookup, up to the method scope"
+
+	(currentScope lookupVariable: aString) ifNotNil: [
+		self errorShadowingVariable: aString ]
+! !
+
+!SemanticAnalyzer methodsFor: 'testing'!
+
+isVariableGloballyUndefined: aString
+	<return eval('typeof ' + aString + ' == "undefined"')>
+! !
+
+!SemanticAnalyzer methodsFor: 'visiting'!
+
+visitAssignmentNode: aNode
+	super visitAssignmentNode: aNode.
+	aNode left beAssigned
+!
+
+visitBlockNode: aNode
+	self pushScope: self newBlockScope.
+	aNode scope: currentScope.
+	currentScope node: aNode.
+	currentScope blockIndex: self nextBlockIndex.
+
+	aNode parameters do: [ :each |
+		self validateVariableScope: each.
+		currentScope addArg: each ].
+
+	super visitBlockNode: aNode.
+	self popScope
+!
+
+visitCascadeNode: aNode
+	super visitCascadeNode: aNode.
+	aNode nodes first superSend ifTrue: [
+		aNode nodes do: [ :each | each superSend: true ] ]
+!
+
+visitMethodNode: aNode
+	self pushScope: self newMethodScope.
+	aNode scope: currentScope.
+	currentScope node: aNode.
+
+	self theClass allInstanceVariableNames do: [ :each |
+		currentScope addIVar: each ].
+	aNode arguments do: [ :each |
+		self validateVariableScope: each.
+		currentScope addArg: each ].
+
+	super visitMethodNode: aNode.
+
+	aNode
+		classReferences: self classReferences;
+		sendIndexes: self messageSends;
+		superSends: self superSends keys.
+	self popScope
+!
+
+visitReturnNode: aNode
+	aNode scope: currentScope.
+	currentScope isMethodScope
+		ifTrue: [ currentScope localReturn: true ]
+		ifFalse: [ currentScope methodScope addNonLocalReturn: currentScope ].
+	super visitReturnNode: aNode
+!
+
+visitSendNode: aNode
+
+	aNode receiver value = 'super'
+		ifTrue: [
+			aNode superSend: true.
+			aNode receiver value: 'self'.
+			self superSends at: aNode selector ifAbsentPut: [ Set new ].
+			(self superSends at: aNode selector) add: aNode ]
+		
+		ifFalse: [ (IRSendInliner inlinedSelectors includes: aNode selector) ifTrue: [
+			aNode shouldBeInlined: true.
+			aNode receiver ifNotNil: [ :receiver |
+				receiver shouldBeAliased: true ] ] ].
+
+	self messageSends at: aNode selector ifAbsentPut: [ Set new ].
+	(self messageSends at: aNode selector) add: aNode.
+
+	aNode index: (self messageSends at: aNode selector) size.
+
+	super visitSendNode: aNode
+!
+
+visitSequenceNode: aNode
+	aNode temps do: [ :each |
+		self validateVariableScope: each.
+		currentScope addTemp: each ].
+
+	super visitSequenceNode: aNode
+!
+
+visitVariableNode: aNode
+	"Bind a ScopeVar to aNode by doing a lookup in the current scope.
+	If no ScopeVar is found, bind a UnknowVar and throw an error."
+
+	| binding |
+	binding := currentScope lookupVariable: aNode.
+	
+	binding ifNil: [
+		aNode value isCapitalized
+			ifTrue: [ "Capital letter variables might be globals."
+				binding := ClassRefVar new name: aNode value; yourself.
+				self classReferences add: aNode value]
+			ifFalse: [
+				self errorUnknownVariable: aNode.
+				binding := UnknownVar new name: aNode value; yourself ] ].
+		
+	aNode binding: binding.
+! !
+
+!SemanticAnalyzer class methodsFor: 'instance creation'!
+
+on: aClass
+	^ self new
+		theClass: aClass;
+		yourself
+! !
+

+ 3009 - 0
bower_components/amber/src/Compiler-Tests.js

@@ -0,0 +1,3009 @@
+define("amber_core/Compiler-Tests", ["amber/boot", "amber_core/SUnit"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Compiler-Tests');
+$core.packages["Compiler-Tests"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ASTParsingTest', $globals.TestCase, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "analyze:forClass:",
+protocol: 'convenience',
+fn: function (aNode,aClass){
+var self=this;
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($SemanticAnalyzer())._on_(aClass))._visit_(aNode);
+return aNode;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"analyze:forClass:",{aNode:aNode,aClass:aClass},$globals.ASTParsingTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode", "aClass"],
+source: "analyze: aNode forClass: aClass\x0a\x09(SemanticAnalyzer on: aClass) visit: aNode.\x0a\x09^ aNode",
+referencedClasses: ["SemanticAnalyzer"],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "on:"]
+}),
+$globals.ASTParsingTest);
+
+$core.addMethod(
+$core.method({
+selector: "parse:",
+protocol: 'parsing',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._parse_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:",{aString:aString},$globals.ASTParsingTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "parse: aString\x0a\x09^ Smalltalk parse: aString",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:"]
+}),
+$globals.ASTParsingTest);
+
+$core.addMethod(
+$core.method({
+selector: "parse:forClass:",
+protocol: 'parsing',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._analyze_forClass_(self._parse_(aString),aClass);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:forClass:",{aString:aString,aClass:aClass},$globals.ASTParsingTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "parse: aString forClass: aClass\x0a\x09^ self analyze: (self parse: aString) forClass: aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["analyze:forClass:", "parse:"]
+}),
+$globals.ASTParsingTest);
+
+
+
+$core.addClass('ASTPCNodeVisitorTest', $globals.ASTParsingTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "astPCNodeVisitor",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $ASTPCNodeVisitor(){return $globals.ASTPCNodeVisitor||(typeof ASTPCNodeVisitor=="undefined"?nil:ASTPCNodeVisitor)}
+function $AIContext(){return $globals.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$5,$1;
+$2=$recv($ASTPCNodeVisitor())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$3=$2;
+$4=$recv($recv($AIContext())._new())._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._context_($4);
+$5=$recv($2)._yourself();
+$1=$5;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"astPCNodeVisitor",{},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "astPCNodeVisitor\x0a\x09^ ASTPCNodeVisitor new\x0a\x09\x09context: (AIContext new\x0a\x09\x09\x09yourself);\x0a\x09\x09yourself",
+referencedClasses: ["ASTPCNodeVisitor", "AIContext"],
+//>>excludeEnd("ide");
+messageSends: ["context:", "new", "yourself"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "astPCNodeVisitorForSelector:",
+protocol: 'factory',
+fn: function (aString){
+var self=this;
+function $ASTPCNodeVisitor(){return $globals.ASTPCNodeVisitor||(typeof ASTPCNodeVisitor=="undefined"?nil:ASTPCNodeVisitor)}
+function $AIContext(){return $globals.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$5,$1;
+$2=$recv($ASTPCNodeVisitor())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._selector_(aString);
+$3=$2;
+$4=$recv($recv($AIContext())._new())._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._context_($4);
+$5=$recv($2)._yourself();
+$1=$5;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"astPCNodeVisitorForSelector:",{aString:aString},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "astPCNodeVisitorForSelector: aString\x0a\x09^ ASTPCNodeVisitor new\x0a\x09\x09selector: aString;\x0a\x09\x09context: (AIContext new\x0a\x09\x09\x09yourself);\x0a\x09\x09yourself",
+referencedClasses: ["ASTPCNodeVisitor", "AIContext"],
+//>>excludeEnd("ide");
+messageSends: ["selector:", "new", "context:", "yourself"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testJSStatementNode",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast,visitor;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+ast=self._parse_forClass_("foo <consolee.log(1)>",$Object());
+$1=self._astPCNodeVisitor();
+$recv($1)._visit_(ast);
+$2=$recv($1)._currentNode();
+self._assert_($recv($2)._isJSStatementNode());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testJSStatementNode",{ast:ast,visitor:visitor},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testJSStatementNode\x0a\x09| ast visitor |\x0a\x09\x0a\x09ast := self parse: 'foo <consolee.log(1)>' forClass: Object.\x0a\x09self assert: (self astPCNodeVisitor\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) isJSStatementNode",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:", "isJSStatementNode", "visit:", "astPCNodeVisitor", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMessageSend",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+ast=self._parse_forClass_("foo self asString yourself. ^ self asBoolean",$Object());
+$1=self._astPCNodeVisitorForSelector_("yourself");
+$recv($1)._visit_(ast);
+$2=$recv($1)._currentNode();
+self._assert_equals_($recv($2)._selector(),"yourself");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMessageSend",{ast:ast},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMessageSend\x0a\x09| ast |\x0a\x09\x0a\x09ast := self parse: 'foo self asString yourself. ^ self asBoolean' forClass: Object.\x0a\x09self assert: ((self astPCNodeVisitorForSelector: 'yourself')\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) selector equals: 'yourself'",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:equals:", "selector", "visit:", "astPCNodeVisitorForSelector:", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMessageSendWithBlocks",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+ast=self._parse_forClass_("foo true ifTrue: [ [ self asString yourself ] value.  ]. ^ self asBoolean",$Object());
+$1=self._astPCNodeVisitorForSelector_("yourself");
+$recv($1)._visit_(ast);
+$2=$recv($1)._currentNode();
+self._assert_equals_($recv($2)._selector(),"yourself");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMessageSendWithBlocks",{ast:ast},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMessageSendWithBlocks\x0a\x09| ast |\x0a\x09\x0a\x09ast := self parse: 'foo true ifTrue: [ [ self asString yourself ] value.  ]. ^ self asBoolean' forClass: Object.\x0a\x09self assert: ((self astPCNodeVisitorForSelector: 'yourself')\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) selector equals: 'yourself'",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:equals:", "selector", "visit:", "astPCNodeVisitorForSelector:", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMessageSendWithInlining",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$1,$5,$6;
+ast=self._parse_forClass_("foo true ifTrue: [ self asString yourself ]. ^ self asBoolean",$Object());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["parse:forClass:"]=1;
+//>>excludeEnd("ctx");
+$3=self._astPCNodeVisitorForSelector_("yourself");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["astPCNodeVisitorForSelector:"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["visit:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($3)._currentNode();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["currentNode"]=1;
+//>>excludeEnd("ctx");
+$2=$4;
+$1=$recv($2)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($1,"yourself");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+ast=self._parse_forClass_("foo true ifTrue: [ self asString yourself ]. ^ self asBoolean",$Object());
+$5=self._astPCNodeVisitorForSelector_("asBoolean");
+$recv($5)._visit_(ast);
+$6=$recv($5)._currentNode();
+self._assert_equals_($recv($6)._selector(),"asBoolean");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMessageSendWithInlining",{ast:ast},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMessageSendWithInlining\x0a\x09| ast |\x0a\x09\x0a\x09ast := self parse: 'foo true ifTrue: [ self asString yourself ]. ^ self asBoolean' forClass: Object.\x0a\x09self assert: ((self astPCNodeVisitorForSelector: 'yourself')\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) selector equals: 'yourself'.\x0a\x09\x09\x0a\x09ast := self parse: 'foo true ifTrue: [ self asString yourself ]. ^ self asBoolean' forClass: Object.\x0a\x09self assert: ((self astPCNodeVisitorForSelector: 'asBoolean')\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) selector equals: 'asBoolean'",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:equals:", "selector", "visit:", "astPCNodeVisitorForSelector:", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNoMessageSend",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+ast=self._parse_forClass_("foo ^ self",$Object());
+$1=self._astPCNodeVisitor();
+$recv($1)._visit_(ast);
+$2=$recv($1)._currentNode();
+self._assert_($recv($2)._isNil());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNoMessageSend",{ast:ast},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNoMessageSend\x0a\x09| ast |\x0a\x09\x0a\x09ast := self parse: 'foo ^ self' forClass: Object.\x0a\x09self assert: (self astPCNodeVisitor\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) isNil",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:", "isNil", "visit:", "astPCNodeVisitor", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testPC",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var ast,visitor;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+ast=self._parse_forClass_("foo <console.log(1)>",$Object());
+$1=self._astPCNodeVisitor();
+$recv($1)._visit_(ast);
+$2=$recv($1)._currentNode();
+self._assert_($recv($2)._isJSStatementNode());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testPC",{ast:ast,visitor:visitor},$globals.ASTPCNodeVisitorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testPC\x0a\x09| ast visitor |\x0a\x09\x0a\x09ast := self parse: 'foo <console.log(1)>' forClass: Object.\x0a\x09self assert: (self astPCNodeVisitor\x0a\x09\x09visit: ast;\x0a\x09\x09currentNode) isJSStatementNode",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["parse:forClass:", "assert:", "isJSStatementNode", "visit:", "astPCNodeVisitor", "currentNode"]
+}),
+$globals.ASTPCNodeVisitorTest);
+
+
+
+$core.addClass('ASTPositionTest', $globals.ASTParsingTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "testNodeAtPosition",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$1,$7,$8,$6,$5;
+node=self._parse_("yourself\x0a\x09^ self");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["parse:"]=1;
+//>>excludeEnd("ctx");
+$3=node;
+$4=(2).__at((4));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["@"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._navigationNodeAt_ifAbsent_($4,(function(){
+return nil;
+
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["navigationNodeAt:ifAbsent:"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._source();
+self._assert_equals_($1,"self");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+node=self._parse_("foo\x0a\x09true ifTrue: [ 1 ]");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["parse:"]=2;
+//>>excludeEnd("ctx");
+$7=node;
+$8=(2).__at((7));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["@"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._navigationNodeAt_ifAbsent_($8,(function(){
+return nil;
+
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["navigationNodeAt:ifAbsent:"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($5,"ifTrue:");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=2;
+//>>excludeEnd("ctx");
+node=self._parse_("foo\x0a\x09self foo; bar; baz");
+self._assert_equals_($recv($recv(node)._navigationNodeAt_ifAbsent_((2).__at((8)),(function(){
+return nil;
+
+})))._selector(),"foo");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNodeAtPosition",{node:node},$globals.ASTPositionTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNodeAtPosition\x0a\x09| node |\x0a\x09\x0a\x09node := self parse: 'yourself\x0a\x09^ self'.\x0a\x09\x0a\x09self assert: (node navigationNodeAt: 2@4 ifAbsent: [ nil ]) source equals: 'self'.\x0a\x09\x0a\x09node := self parse: 'foo\x0a\x09true ifTrue: [ 1 ]'.\x0a\x09\x0a\x09self assert: (node navigationNodeAt: 2@7 ifAbsent: [ nil ]) selector equals: 'ifTrue:'.\x0a\x09\x0a\x09node := self parse: 'foo\x0a\x09self foo; bar; baz'.\x0a\x09\x0a\x09self assert: (node navigationNodeAt: 2@8 ifAbsent: [ nil ]) selector equals: 'foo'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "assert:equals:", "source", "navigationNodeAt:ifAbsent:", "@", "selector"]
+}),
+$globals.ASTPositionTest);
+
+
+
+$core.addClass('CodeGeneratorTest', $globals.ASTParsingTest, ['receiver'], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "codeGeneratorClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $CodeGenerator(){return $globals.CodeGenerator||(typeof CodeGenerator=="undefined"?nil:CodeGenerator)}
+return $CodeGenerator();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "codeGeneratorClass\x0a\x09^ CodeGenerator",
+referencedClasses: ["CodeGenerator"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "compiler",
+protocol: 'factory',
+fn: function (){
+var self=this;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($Compiler())._new();
+$recv($2)._codeGeneratorClass_(self._codeGeneratorClass());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compiler",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "compiler\x0a\x09^ Compiler new\x0a\x09\x09codeGeneratorClass: self codeGeneratorClass;\x0a\x09\x09yourself",
+referencedClasses: ["Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["codeGeneratorClass:", "new", "codeGeneratorClass", "yourself"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $DoIt(){return $globals.DoIt||(typeof DoIt=="undefined"?nil:DoIt)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@receiver"]=$recv($DoIt())._new();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setUp",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp\x0a\x09receiver := DoIt new",
+referencedClasses: ["DoIt"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "should:receiver:return:",
+protocol: 'testing',
+fn: function (aString,anObject,aResult){
+var self=this;
+var method,result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self["@receiver"]=anObject;
+$1=self._compiler();
+$2=$recv(anObject)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+method=$recv($1)._install_forClass_protocol_(aString,$2,"tests");
+result=$recv(self["@receiver"])._perform_($recv(method)._selector());
+$recv($recv(anObject)._class())._removeCompiledMethod_(method);
+self._assert_equals_(aResult,result);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:receiver:return:",{aString:aString,anObject:anObject,aResult:aResult,method:method,result:result},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "aResult"],
+source: "should: aString receiver: anObject return: aResult\x0a\x09| method result |\x0a\x0a\x09receiver := anObject.\x0a\x09method := self compiler install: aString forClass: anObject class protocol: 'tests'.\x0a\x09result := receiver perform: method selector.\x0a\x09anObject class removeCompiledMethod: method.\x0a\x09self assert: aResult equals: result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["install:forClass:protocol:", "compiler", "class", "perform:", "selector", "removeCompiledMethod:", "assert:equals:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "should:return:",
+protocol: 'testing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._should_receiver_return_(aString,self["@receiver"],anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:return:",{aString:aString,anObject:anObject},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "should: aString return: anObject\x0a\x09^ self \x0a\x09\x09should: aString \x0a\x09\x09receiver: receiver \x0a\x09\x09return: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:receiver:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "tearDown",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tearDown\x0a\x09\x22receiver := nil\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testAssignment",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | a := true ifTrue: [ 1 ]. ^ a",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | a := false ifTrue: [ 1 ]. ^ a",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | ^ a := true ifTrue: [ 1 ]",(1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testAssignment",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testAssignment\x0a\x09self should: 'foo | a | a := true ifTrue: [ 1 ]. ^ a' return: 1.\x0a\x09self should: 'foo | a | a := false ifTrue: [ 1 ]. ^ a' return: nil.\x0a\x0a\x09self should: 'foo | a | ^ a := true ifTrue: [ 1 ]' return: 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testBackslashSelectors",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("\x5c arg ^ 4",(4));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("\x5c\x5c arg ^ 42",(42));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testBackslashSelectors",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testBackslashSelectors\x0a\x09\x0a\x09self should: '\x5c arg ^ 4' return: 4.\x0a\x09self should: '\x5c\x5c arg ^ 42' return: 42",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testBlockReturn",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #(1 2 3) collect: [ :each | true ifTrue: [ each + 1 ] ]",[(2), (3), (4)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #(1 2 3) collect: [ :each | false ifFalse: [ each + 1 ] ]",[(2), (3), (4)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #(1 2 3) collect: [ :each | each odd ifTrue: [ each + 1 ] ifFalse: [ each - 1 ] ]",[(2), (1), (4)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testBlockReturn",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testBlockReturn\x0a\x09self should: 'foo ^ #(1 2 3) collect: [ :each | true ifTrue: [ each + 1 ] ]' return: #(2 3 4).\x0a\x09self should: 'foo ^ #(1 2 3) collect: [ :each | false ifFalse: [ each + 1 ] ]' return: #(2 3 4).\x0a\x09self should: 'foo ^ #(1 2 3) collect: [ :each | each odd ifTrue: [ each + 1 ] ifFalse: [ each - 1 ] ]' return: #(2 1 4).",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testCascades",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ Array new add: 3; add: 4; yourself",[(3), (4)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testCascades",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testCascades\x0a\x09\x0a\x09self should: 'foo ^ Array new add: 3; add: 4; yourself' return: #(3 4)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testCascadesWithInlining",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifTrue: [ 1 ] ifFalse: [ 2 ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false ifTrue: [ 1 ] ifFalse: [ 2 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testCascadesWithInlining",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testCascadesWithInlining\x0a\x09\x0a\x09self should: 'foo ^ true ifTrue: [ 1 ] ifFalse: [ 2 ]' return: 1.\x0a\x09self should: 'foo ^ false ifTrue: [ 1 ] ifFalse: [ 2 ]' return: 2",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testDynamicArrayElementsOrdered",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { x. x := 2 }\x0a",[(1), (2)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { x. true ifTrue: [ x := 2 ] }\x0a",[(1), (2)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testDynamicArrayElementsOrdered",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testDynamicArrayElementsOrdered\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { x. x := 2 }\x0a' return: #(1 2).\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { x. true ifTrue: [ x := 2 ] }\x0a' return: #(1 2).",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testDynamicDictionaryElementsOrdered",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 'foo'.\x0a\x09^ #{ x->1. 'bar'->(true ifTrue: [ 2 ]) }\x0a",$globals.HashedCollection._newFromPairs_(["foo",(1),"bar",(2)]));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testDynamicDictionaryElementsOrdered",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testDynamicDictionaryElementsOrdered\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := ''foo''.\x0a\x09^ #{ x->1. ''bar''->(true ifTrue: [ 2 ]) }\x0a' return: #{'foo'->1. 'bar'->2}.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testDynamicDictionaryWithMoreArrows",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv((1).__minus_gt((2))).__minus_gt((3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($HashedCollection())._with_($2);
+self._should_return_("foo ^ #{1->2->3}",$1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testDynamicDictionaryWithMoreArrows",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testDynamicDictionaryWithMoreArrows\x0a\x09self should: 'foo ^ #{1->2->3}' return: (HashedCollection with: 1->2->3)",
+referencedClasses: ["HashedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:", "with:", "->"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testGlobalVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $BlockClosure(){return $globals.BlockClosure||(typeof BlockClosure=="undefined"?nil:BlockClosure)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ eval class",$BlockClosure());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ Math cos: 0",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ NonExistingVar",nil);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testGlobalVar",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testGlobalVar\x0a\x09self should: 'foo ^ eval class' return: BlockClosure.\x0a\x09self should: 'foo ^ Math cos: 0' return: 1.\x0a\x09self should: 'foo ^ NonExistingVar' return: nil",
+referencedClasses: ["BlockClosure"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testInnerTemporalDependentElementsOrdered",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$5,$6,$4,$8,$9,$7,$11,$10;
+$2="foo".__minus_gt($Array());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=1;
+//>>excludeEnd("ctx");
+$3="bar".__minus_gt((2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=2;
+//>>excludeEnd("ctx");
+$1=[$2,$3];
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: 'foo'->x with: 'bar'->(x := 2)\x0a",$1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+$5="foo".__minus_gt($Array());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=3;
+//>>excludeEnd("ctx");
+$6="bar".__minus_gt((2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=4;
+//>>excludeEnd("ctx");
+$4=[$5,$6];
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: 'foo'->x with: 'bar'->(true ifTrue: [ x := 2 ])\x0a",$4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+$8="foo".__minus_gt((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=5;
+//>>excludeEnd("ctx");
+$9="bar".__minus_gt((2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=6;
+//>>excludeEnd("ctx");
+$7=[$8,$9];
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ Array with: 'foo'->x with: 'bar'->(true ifTrue: [ x := 2 ])\x0a",$7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+$11="foo".__minus_gt((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["->"]=7;
+//>>excludeEnd("ctx");
+$10=[$11,"bar".__minus_gt((2))];
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { 'foo'->x. 'bar'->(true ifTrue: [ x := 2 ]) }\x0a",$10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ #{ 'foo'->x. 'bar'->(true ifTrue: [ x := 2 ]) }\x0a",$globals.HashedCollection._newFromPairs_(["foo",(1),"bar",(2)]));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testInnerTemporalDependentElementsOrdered",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testInnerTemporalDependentElementsOrdered\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: ''foo''->x with: ''bar''->(x := 2)\x0a' return: {'foo'->Array. 'bar'->2}.\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: ''foo''->x with: ''bar''->(true ifTrue: [ x := 2 ])\x0a' return: {'foo'->Array. 'bar'->2}.\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ Array with: ''foo''->x with: ''bar''->(true ifTrue: [ x := 2 ])\x0a' return: {'foo'->1. 'bar'->2}.\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ { ''foo''->x. ''bar''->(true ifTrue: [ x := 2 ]) }\x0a' return: {'foo'->1. 'bar'->2}.\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ #{ ''foo''->x. ''bar''->(true ifTrue: [ x := 2 ]) }\x0a' return: #{'foo'->1. 'bar'->2}.",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:", "->"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testJSStatement",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo <return 2+3>",(5));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testJSStatement",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testJSStatement\x0a\x09self should: 'foo <return 2+3>' return: 5",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testLexicalScope",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | a := 1. [ a := 2 ] value. ^ a",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testLexicalScope",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testLexicalScope\x0a\x09self should: 'foo | a | a := 1. [ a := 2 ] value. ^ a' return: 2",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testLiterals",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 'hello'","hello");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #(1 2 3 4)",[(1), (2), (3), (4)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ {1. [:x | x ] value: 2. 3. [4] value}",[(1), (2), (3), (4)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true",true);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=5;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false",false);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=6;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #{1->2. 3->4}",$globals.HashedCollection._newFromPairs_([(1),(2),(3),(4)]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=7;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #hello","hello");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=8;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ $h","h");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=9;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ -123.456",(-123.456));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=10;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ -2.5e4",(-25000));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testLiterals",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testLiterals\x0a\x09self should: 'foo ^ 1' return: 1.\x0a\x09self should: 'foo ^ ''hello''' return: 'hello'.\x0a\x09self should: 'foo ^ #(1 2 3 4)' return: #(1 2 3 4).\x0a\x09self should: 'foo ^ {1. [:x | x ] value: 2. 3. [4] value}' return: #(1 2 3 4).\x0a\x09self should: 'foo ^ true' return: true.\x0a\x09self should: 'foo ^ false' return: false.\x0a\x09self should: 'foo ^ #{1->2. 3->4}' return: #{1->2. 3->4}.\x0a\x09self should: 'foo ^ #hello' return: #hello.\x0a\x09self should: 'foo ^ $h' return: 'h'.\x0a\x09self should: 'foo ^ -123.456' return: -123.456.\x0a\x09self should: 'foo ^ -2.5e4' return: -25000.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testLocalReturn",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 + 1",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ",self["@receiver"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo self asString",self["@receiver"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a b | a := 1. b := 2. ^ a + b",(3));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testLocalReturn",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testLocalReturn\x0a\x09self should: 'foo ^ 1' return: 1.\x0a\x09self should: 'foo ^ 1 + 1' return: 2.\x0a\x09self should: 'foo ' return: receiver.\x0a\x09self should: 'foo self asString' return: receiver.\x0a\x09self should: 'foo | a b | a := 1. b := 2. ^ a + b' return: 3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMessageSends",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 asString","1");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 + 1",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 + 2 * 3",(9));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 to: 3",[(1), (2), (3)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 to: 5 by: 2",[(1), (3), (5)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMessageSends",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMessageSends\x0a\x09self should: 'foo ^ 1 asString' return: '1'.\x0a\x0a\x09self should: 'foo ^ 1 + 1' return: 2.\x0a\x09self should: 'foo ^ 1 + 2 * 3' return: 9.\x0a\x0a\x09self should: 'foo ^ 1 to: 3' return: #(1 2 3).\x0a\x09self should: 'foo ^ 1 to: 5 by: 2' return: #(1 3 5)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMultipleSequences",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo | a b c | a := 2. b := 3. c := a + b. ^ c * 6",(30));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMultipleSequences",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMultipleSequences\x0a\x09self should: 'foo | a b c | a := 2. b := 3. c := a + b. ^ c * 6' return: 30",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testMutableLiterals",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ #( 1 2 ) at: 1 put: 3; yourself",[(3), (2)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testMutableLiterals",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testMutableLiterals\x0a\x09\x22Mutable literals must be aliased in cascades.\x0a\x09See https://github.com/amber-smalltalk/amber/issues/428\x22\x0a\x09\x0a\x09self \x0a\x09\x09should: 'foo ^ #( 1 2 ) at: 1 put: 3; yourself' \x0a\x09\x09return: #(3 2)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNestedIfTrue",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifTrue: [ false ifFalse: [ 1 ] ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifTrue: [ false ifTrue: [ 1 ] ]",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifTrue: [ false ifFalse: [ ^ 1 ] ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifTrue: [ false ifTrue: [ ^ 1 ] ]",self["@receiver"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNestedIfTrue",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNestedIfTrue\x0a\x09self should: 'foo ^ true ifTrue: [ false ifFalse: [ 1 ] ]' return: 1.\x0a\x09self should: 'foo ^ true ifTrue: [ false ifTrue: [ 1 ] ]' return: nil.\x0a\x0a\x09self should: 'foo true ifTrue: [ false ifFalse: [ ^ 1 ] ]' return: 1.\x0a\x09self should: 'foo true ifTrue: [ false ifTrue: [ ^ 1 ] ]' return: receiver.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNestedSends",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ (Point x: (Point x: 2 y: 3) y: 4) asString",$recv($recv($Point())._x_y_((2).__at((3)),(4)))._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNestedSends",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNestedSends\x0a\x09self should: 'foo ^ (Point x: (Point x: 2 y: 3) y: 4) asString' return: (Point x: (2@3) y: 4) asString",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:", "asString", "x:y:", "@"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNonLocalReturn",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo [ ^ 1 ] value",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo [ ^ 1 + 1 ] value",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a b | a := 1. b := 2. [ ^ a + b ] value. self halt",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo [ :x | ^ x + x ] value: 4. ^ 2",(8));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNonLocalReturn",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNonLocalReturn\x0a\x09self should: 'foo [ ^ 1 ] value' return: 1.\x0a\x09self should: 'foo [ ^ 1 + 1 ] value' return: 2.\x0a\x09self should: 'foo | a b | a := 1. b := 2. [ ^ a + b ] value. self halt' return: 3.\x0a\x09self should: 'foo [ :x | ^ x + x ] value: 4. ^ 2' return: 8",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testPascalCaseGlobal",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^Object",$recv($recv($Smalltalk())._globals())._at_("Object"));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^NonExistent",nil);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testPascalCaseGlobal",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testPascalCaseGlobal\x0a\x09self should: 'foo ^Object' return: (Smalltalk globals at: 'Object').\x0a\x09self should: 'foo ^NonExistent' return: nil",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:", "at:", "globals"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testSendReceiverAndArgumentsOrdered",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ Array with: x with: (true ifTrue: [ x := 2 ])\x0a",[(1), (2)]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: x with: (true ifTrue: [ x := 2 ])\x0a",[$Array(),(2)]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testSendReceiverAndArgumentsOrdered",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testSendReceiverAndArgumentsOrdered\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := 1.\x0a\x09^ Array with: x with: (true ifTrue: [ x := 2 ])\x0a' return: #(1 2).\x0a\x0a\x09self should: 'foo\x0a\x09| x |\x0a\x09x := Array.\x0a\x09^ x with: x with: (true ifTrue: [ x := 2 ])\x0a' return: {Array. 2}.",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testSuperSend",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_receiver_return_("foo ^ super isBoolean",true,false);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testSuperSend",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testSuperSend\x0a\x09self \x0a\x09\x09should: 'foo ^ super isBoolean' \x0a\x09\x09receiver: true\x0a\x09\x09return: false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:receiver:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testTempVariables",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | ^ a",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo | AVariable | ^ AVariable",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a b c | ^ c",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | [ | d | ^ d ] value",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo | a | a:= 1. ^ a",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=5;
+//>>excludeEnd("ctx");
+self._should_return_("foo | AVariable | AVariable := 1. ^ AVariable",(1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testTempVariables",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testTempVariables\x0a\x09self should: 'foo | a | ^ a' return: nil.\x0a\x09self should: 'foo | AVariable | ^ AVariable' return: nil.\x0a\x09self should: 'foo | a b c | ^ c' return: nil.\x0a\x09self should: 'foo | a | [ | d | ^ d ] value' return: nil.\x0a\x09\x0a\x09self should: 'foo | a | a:= 1. ^ a' return: 1.\x0a\x09self should: 'foo | AVariable | AVariable := 1. ^ AVariable' return: 1.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testThisContext",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ [ thisContext ] value outerContext == thisContext",true);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testThisContext",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testThisContext\x0a\x09self should: 'foo ^ [ thisContext ] value outerContext == thisContext' return: true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifFalse",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifFalse: [ ^ 1 ]",self["@receiver"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo false ifFalse: [ ^ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifFalse: [ 1 ]",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false ifFalse: [ 2 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifFalse",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifFalse\x0a\x09self should: 'foo true ifFalse: [ ^ 1 ]' return: receiver.\x0a\x09self should: 'foo false ifFalse: [ ^ 2 ]' return: 2.\x0a\x09\x0a\x09self should: 'foo ^ true ifFalse: [ 1 ]' return: nil.\x0a\x09self should: 'foo ^ false ifFalse: [ 2 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifFalseIfTrue",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifFalse: [ ^ 1 ] ifTrue: [ ^ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo false ifFalse: [ ^ 2 ] ifTrue: [ ^1 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifFalse: [ 1 ] ifTrue: [ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false ifFalse: [ 2 ] ifTrue: [ 1 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifFalseIfTrue",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifFalseIfTrue\x0a\x09self should: 'foo true ifFalse: [ ^ 1 ] ifTrue: [ ^ 2 ]' return: 2.\x0a\x09self should: 'foo false ifFalse: [ ^ 2 ] ifTrue: [ ^1 ]' return: 2.\x0a\x09\x0a\x09self should: 'foo ^ true ifFalse: [ 1 ] ifTrue: [ 2 ]' return: 2.\x0a\x09self should: 'foo ^ false ifFalse: [ 2 ] ifTrue: [ 1 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifNil",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNil: [ 2 ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNil: [ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo 1 ifNil: [ ^ 2 ]",self["@receiver"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo nil ifNil: [ ^ 2 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifNil",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifNil\x0a\x09self should: 'foo ^ 1 ifNil: [ 2 ]' return: 1.\x0a\x09self should: 'foo ^ nil ifNil: [ 2 ]' return: 2.\x0a\x0a\x09self should: 'foo 1 ifNil: [ ^ 2 ]' return: receiver.\x0a\x09self should: 'foo nil ifNil: [ ^ 2 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifNilIfNotNil",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNil: [ 2 ] ifNotNil: [ 3 ]",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNil: [ 2 ] ifNotNil: [ 3 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo 1 ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo nil ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifNilIfNotNil",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifNilIfNotNil\x0a\x09self should: 'foo ^ 1 ifNil: [ 2 ] ifNotNil: [ 3 ]' return: 3.\x0a\x09self should: 'foo ^ nil ifNil: [ 2 ] ifNotNil: [ 3 ]' return: 2.\x0a\x0a\x09self should: 'foo 1 ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]' return: 3.\x0a\x09self should: 'foo nil ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifNotNil",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNotNil: [ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNotNil: [ 2 ]",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo 1 ifNotNil: [ ^ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo nil ifNotNil: [ ^ 2 ]",self["@receiver"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifNotNil",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifNotNil\x0a\x09self should: 'foo ^ 1 ifNotNil: [ 2 ]' return: 2.\x0a\x09self should: 'foo ^ nil ifNotNil: [ 2 ]' return: nil.\x0a\x0a\x09self should: 'foo 1 ifNotNil: [ ^ 2 ]' return: 2.\x0a\x09self should: 'foo nil ifNotNil: [ ^ 2 ]' return: receiver.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifNotNilWithArgument",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNotNil: [ :val | val + 2 ]",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNotNil: [ :val | val + 2 ]",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]",(5));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=4;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ 1 ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]",(3));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=5;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ nil ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]",(5));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifNotNilWithArgument",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifNotNilWithArgument\x0a\x09self should: 'foo ^ 1 ifNotNil: [ :val | val + 2 ]' return: 3.\x0a\x09self should: 'foo ^ nil ifNotNil: [ :val | val + 2 ]' return: nil.\x0a\x09\x0a\x09self should: 'foo ^ 1 ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]' return: 3.\x0a\x09self should: 'foo ^ nil ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]' return: 5.\x0a\x09\x0a\x09self should: 'foo ^ 1 ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]' return: 3.\x0a\x09self should: 'foo ^ nil ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]' return: 5",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifTrue",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo false ifTrue: [ ^ 1 ]",self["@receiver"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifTrue: [ ^ 2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false ifTrue: [ 1 ]",nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifTrue: [ 2 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifTrue",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifTrue\x0a\x09self should: 'foo false ifTrue: [ ^ 1 ]' return: receiver.\x0a\x09self should: 'foo true ifTrue: [ ^ 2 ]' return: 2.\x0a\x09\x0a\x09self should: 'foo ^ false ifTrue: [ 1 ]' return: nil.\x0a\x09self should: 'foo ^ true ifTrue: [ 2 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+$core.addMethod(
+$core.method({
+selector: "testifTrueIfFalse",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_return_("foo false ifTrue: [ ^ 1 ] ifFalse: [ ^2 ]",(2));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=1;
+//>>excludeEnd("ctx");
+self._should_return_("foo true ifTrue: [ ^ 1 ] ifFalse: [ ^ 2 ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=2;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ false ifTrue: [ 2 ] ifFalse: [ 1 ]",(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:return:"]=3;
+//>>excludeEnd("ctx");
+self._should_return_("foo ^ true ifTrue: [ 2 ] ifFalse: [ 1 ]",(2));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testifTrueIfFalse",{},$globals.CodeGeneratorTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testifTrueIfFalse\x0a\x09self should: 'foo false ifTrue: [ ^ 1 ] ifFalse: [ ^2 ]' return: 2.\x0a\x09self should: 'foo true ifTrue: [ ^ 1 ] ifFalse: [ ^ 2 ]' return: 1.\x0a\x09\x0a\x09self should: 'foo ^ false ifTrue: [ 2 ] ifFalse: [ 1 ]' return: 1.\x0a\x09self should: 'foo ^ true ifTrue: [ 2 ] ifFalse: [ 1 ]' return: 2.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:return:"]
+}),
+$globals.CodeGeneratorTest);
+
+
+
+$core.addClass('ASTInterpreterTest', $globals.CodeGeneratorTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "analyze:forClass:",
+protocol: 'parsing',
+fn: function (aNode,aClass){
+var self=this;
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($SemanticAnalyzer())._on_(aClass))._visit_(aNode);
+return aNode;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"analyze:forClass:",{aNode:aNode,aClass:aClass},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNode", "aClass"],
+source: "analyze: aNode forClass: aClass\x0a\x09(SemanticAnalyzer on: aClass) visit: aNode.\x0a\x09^ aNode",
+referencedClasses: ["SemanticAnalyzer"],
+//>>excludeEnd("ide");
+messageSends: ["visit:", "on:"]
+}),
+$globals.ASTInterpreterTest);
+
+$core.addMethod(
+$core.method({
+selector: "interpret:receiver:withArguments:",
+protocol: 'private',
+fn: function (aString,anObject,aDictionary){
+var self=this;
+var ctx,ast,interpreter;
+function $ASTInterpreter(){return $globals.ASTInterpreter||(typeof ASTInterpreter=="undefined"?nil:ASTInterpreter)}
+function $AIContext(){return $globals.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$5,$6,$4,$receiver;
+interpreter=$recv($ASTInterpreter())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+ast=self._parse_forClass_(aString,$recv(anObject)._class());
+$1=$recv($AIContext())._new();
+$recv($1)._receiver_(anObject);
+$recv($1)._interpreter_(interpreter);
+$2=$recv($1)._yourself();
+ctx=$2;
+$3=$recv(ast)._sequenceNode();
+if(($receiver = $3) == null || $receiver.isNil){
+$3;
+} else {
+var sequence;
+sequence=$receiver;
+$recv($recv(sequence)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(ctx)._defineLocal_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+};
+$recv(aDictionary)._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(ctx)._localAt_put_(key,value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$5=interpreter;
+$recv($5)._context_(ctx);
+$recv($5)._interpret_($recv(ast)._nextChild());
+$recv($5)._proceed();
+$6=$recv($5)._result();
+$4=$6;
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpret:receiver:withArguments:",{aString:aString,anObject:anObject,aDictionary:aDictionary,ctx:ctx,ast:ast,interpreter:interpreter},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "aDictionary"],
+source: "interpret: aString receiver: anObject withArguments: aDictionary\x0a\x09\x22The food is a methodNode. Interpret the sequenceNode only\x22\x0a\x09\x0a\x09| ctx ast interpreter |\x0a\x09\x0a\x09interpreter := ASTInterpreter new.\x0a\x09ast := self parse: aString forClass: anObject class.\x0a\x09\x0a\x09ctx := AIContext new\x0a\x09\x09receiver: anObject;\x0a\x09\x09interpreter: interpreter;\x0a\x09\x09yourself.\x0a\x09\x09\x0a\x09\x22Define locals for the context\x22\x0a\x09ast sequenceNode ifNotNil: [ :sequence |\x0a\x09\x09sequence temps do: [ :each |\x0a\x09\x09\x09ctx defineLocal: each ] ].\x0a\x09\x09\x0a\x09aDictionary keysAndValuesDo: [ :key :value |\x0a\x09\x09ctx localAt: key put: value ].\x0a\x09\x0a\x09^ interpreter\x0a\x09\x09context: ctx;\x0a\x09\x09interpret: ast nextChild;\x0a\x09\x09proceed;\x0a\x09\x09result",
+referencedClasses: ["ASTInterpreter", "AIContext"],
+//>>excludeEnd("ide");
+messageSends: ["new", "parse:forClass:", "class", "receiver:", "interpreter:", "yourself", "ifNotNil:", "sequenceNode", "do:", "temps", "defineLocal:", "keysAndValuesDo:", "localAt:put:", "context:", "interpret:", "nextChild", "proceed", "result"]
+}),
+$globals.ASTInterpreterTest);
+
+$core.addMethod(
+$core.method({
+selector: "parse:",
+protocol: 'parsing',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._parse_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:",{aString:aString},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "parse: aString\x0a\x09^ Smalltalk parse: aString",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:"]
+}),
+$globals.ASTInterpreterTest);
+
+$core.addMethod(
+$core.method({
+selector: "parse:forClass:",
+protocol: 'parsing',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._analyze_forClass_(self._parse_(aString),aClass);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:forClass:",{aString:aString,aClass:aClass},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "parse: aString forClass: aClass\x0a\x09^ self analyze: (self parse: aString) forClass: aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["analyze:forClass:", "parse:"]
+}),
+$globals.ASTInterpreterTest);
+
+$core.addMethod(
+$core.method({
+selector: "should:receiver:return:",
+protocol: 'testing',
+fn: function (aString,anObject,aResult){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self["@receiver"]=anObject;
+$1=self._assert_equals_(self._interpret_receiver_withArguments_(aString,self["@receiver"],$globals.HashedCollection._newFromPairs_([])),aResult);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:receiver:return:",{aString:aString,anObject:anObject,aResult:aResult},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "aResult"],
+source: "should: aString receiver: anObject return: aResult\x0a\x09receiver := anObject.\x0a\x09\x0a\x09^ self \x0a\x09\x09assert: (self interpret: aString receiver: receiver withArguments: #{})\x0a\x09\x09equals: aResult",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:equals:", "interpret:receiver:withArguments:"]
+}),
+$globals.ASTInterpreterTest);
+
+$core.addMethod(
+$core.method({
+selector: "should:return:",
+protocol: 'testing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._should_receiver_return_(aString,self["@receiver"],anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:return:",{aString:aString,anObject:anObject},$globals.ASTInterpreterTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "should: aString return: anObject\x0a\x09^ self \x0a\x09\x09should: aString\x0a\x09\x09receiver: receiver\x0a\x09\x09return: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["should:receiver:return:"]
+}),
+$globals.ASTInterpreterTest);
+
+
+
+$core.addClass('ASTDebuggerTest', $globals.ASTInterpreterTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "interpret:receiver:withArguments:",
+protocol: 'private',
+fn: function (aString,anObject,aDictionary){
+var self=this;
+var ctx,ast,debugger_;
+function $AIContext(){return $globals.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
+function $ASTInterpreter(){return $globals.ASTInterpreter||(typeof ASTInterpreter=="undefined"?nil:ASTInterpreter)}
+function $ASTDebugger(){return $globals.ASTDebugger||(typeof ASTDebugger=="undefined"?nil:ASTDebugger)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$6,$7,$5,$receiver;
+$1=$recv($AIContext())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._receiver_(anObject);
+$recv($1)._interpreter_($recv($ASTInterpreter())._new());
+$2=$recv($1)._yourself();
+ctx=$2;
+ast=self._parse_forClass_(aString,$recv(anObject)._class());
+$3=$recv(ast)._sequenceNode();
+if(($receiver = $3) == null || $receiver.isNil){
+$3;
+} else {
+var sequence;
+sequence=$receiver;
+$recv($recv(sequence)._temps())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(ctx)._defineLocal_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+};
+$recv(aDictionary)._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(ctx)._localAt_put_(key,value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$4=$recv(ctx)._interpreter();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["interpreter"]=1;
+//>>excludeEnd("ctx");
+$recv($4)._context_(ctx);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(ctx)._interpreter())._node_($recv(ast)._nextChild());
+debugger_=$recv($ASTDebugger())._context_(ctx);
+$6=debugger_;
+$recv($6)._proceed();
+$7=$recv($6)._result();
+$5=$7;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"interpret:receiver:withArguments:",{aString:aString,anObject:anObject,aDictionary:aDictionary,ctx:ctx,ast:ast,debugger_:debugger_},$globals.ASTDebuggerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "aDictionary"],
+source: "interpret: aString receiver: anObject withArguments: aDictionary\x0a\x09| ctx ast debugger |\x0a\x09\x0a\x09ctx := AIContext new\x0a\x09\x09receiver: anObject;\x0a\x09\x09interpreter: ASTInterpreter new;\x0a\x09\x09yourself.\x0a\x09ast := self parse: aString forClass: anObject class.\x0a\x09\x09\x0a\x09\x22Define locals for the context\x22\x0a\x09ast sequenceNode ifNotNil: [ :sequence |\x0a\x09\x09sequence temps do: [ :each |\x0a\x09\x09\x09ctx defineLocal: each ] ].\x0a\x09\x0a\x09aDictionary keysAndValuesDo: [ :key :value |\x0a\x09\x09ctx localAt: key put: value ].\x0a\x09ctx interpreter context: ctx.\x0a\x09\x0a\x09ctx interpreter node: ast nextChild.\x0a\x09\x0a\x09debugger := ASTDebugger context: ctx.\x0a\x09\x0a\x09^ debugger \x0a\x09\x09proceed; \x0a\x09\x09result",
+referencedClasses: ["AIContext", "ASTInterpreter", "ASTDebugger"],
+//>>excludeEnd("ide");
+messageSends: ["receiver:", "new", "interpreter:", "yourself", "parse:forClass:", "class", "ifNotNil:", "sequenceNode", "do:", "temps", "defineLocal:", "keysAndValuesDo:", "localAt:put:", "context:", "interpreter", "node:", "nextChild", "proceed", "result"]
+}),
+$globals.ASTDebuggerTest);
+
+
+
+$core.addClass('InliningCodeGeneratorTest', $globals.CodeGeneratorTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "codeGeneratorClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $InliningCodeGenerator(){return $globals.InliningCodeGenerator||(typeof InliningCodeGenerator=="undefined"?nil:InliningCodeGenerator)}
+return $InliningCodeGenerator();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "codeGeneratorClass\x0a\x09^ InliningCodeGenerator",
+referencedClasses: ["InliningCodeGenerator"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.InliningCodeGeneratorTest);
+
+
+
+$core.addClass('ScopeVarTest', $globals.TestCase, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "testClassRefVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$1=$recv($VariableNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._value_("Object");
+$2=$recv($1)._yourself();
+node=$2;
+$3=$recv($SemanticAnalyzer())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=2;
+//>>excludeEnd("ctx");
+$recv($3)._pushScope_($recv($MethodLexicalScope())._new());
+$4=$recv($3)._visit_(node);
+self._assert_($recv($recv(node)._binding())._isClassRefVar());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testClassRefVar",{node:node},$globals.ScopeVarTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testClassRefVar\x0a\x09| node |\x0a\x09node := VariableNode new\x0a\x09\x09value: 'Object';\x0a\x09\x09yourself.\x0a\x09SemanticAnalyzer new \x0a\x09\x09pushScope: MethodLexicalScope new;\x0a\x09\x09visit: node.\x0a\x09self assert: node binding isClassRefVar",
+referencedClasses: ["VariableNode", "SemanticAnalyzer", "MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "new", "yourself", "pushScope:", "visit:", "assert:", "isClassRefVar", "binding"]
+}),
+$globals.ScopeVarTest);
+
+$core.addMethod(
+$core.method({
+selector: "testInstanceVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node,scope;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($VariableNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._value_("bzzz");
+$2=$recv($1)._yourself();
+node=$2;
+scope=$recv($MethodLexicalScope())._new();
+$recv(scope)._addIVar_("bzzz");
+self._assert_($recv($recv(scope)._bindingFor_(node))._isInstanceVar());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testInstanceVar",{node:node,scope:scope},$globals.ScopeVarTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testInstanceVar\x0a\x09| node scope |\x0a\x09node := VariableNode new\x0a\x09\x09value: 'bzzz';\x0a\x09\x09yourself.\x0a\x09scope := MethodLexicalScope new.\x0a\x09scope addIVar: 'bzzz'.\x0a\x09self assert: (scope bindingFor: node) isInstanceVar",
+referencedClasses: ["VariableNode", "MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "new", "yourself", "addIVar:", "assert:", "isInstanceVar", "bindingFor:"]
+}),
+$globals.ScopeVarTest);
+
+$core.addMethod(
+$core.method({
+selector: "testPseudoVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node,pseudoVars;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+pseudoVars=["self", "super", "true", "false", "nil"];
+$recv(pseudoVars)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv($VariableNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._value_(each);
+$2=$recv($1)._yourself();
+node=$2;
+node;
+return self._assert_($recv($recv($recv($MethodLexicalScope())._new())._bindingFor_(node))._isPseudoVar());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testPseudoVar",{node:node,pseudoVars:pseudoVars},$globals.ScopeVarTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testPseudoVar\x0a\x09| node pseudoVars |\x0a\x09pseudoVars := #('self' 'super' 'true' 'false' 'nil').\x0a\x09pseudoVars do: [:each |\x0a\x09\x09node := VariableNode new\x0a\x09\x09value: each;\x0a\x09\x09yourself.\x0a\x09\x09self assert: (MethodLexicalScope new bindingFor: node) isPseudoVar]",
+referencedClasses: ["VariableNode", "MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["do:", "value:", "new", "yourself", "assert:", "isPseudoVar", "bindingFor:"]
+}),
+$globals.ScopeVarTest);
+
+$core.addMethod(
+$core.method({
+selector: "testTempVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node,scope;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($VariableNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._value_("bzzz");
+$2=$recv($1)._yourself();
+node=$2;
+scope=$recv($MethodLexicalScope())._new();
+$recv(scope)._addTemp_("bzzz");
+self._assert_($recv($recv(scope)._bindingFor_(node))._isTempVar());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testTempVar",{node:node,scope:scope},$globals.ScopeVarTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testTempVar\x0a\x09| node scope |\x0a\x09node := VariableNode new\x0a\x09\x09value: 'bzzz';\x0a\x09\x09yourself.\x0a\x09scope := MethodLexicalScope new.\x0a\x09scope addTemp: 'bzzz'.\x0a\x09self assert: (scope bindingFor: node) isTempVar",
+referencedClasses: ["VariableNode", "MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "new", "yourself", "addTemp:", "assert:", "isTempVar", "bindingFor:"]
+}),
+$globals.ScopeVarTest);
+
+$core.addMethod(
+$core.method({
+selector: "testUnknownVar",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var node;
+function $VariableNode(){return $globals.VariableNode||(typeof VariableNode=="undefined"?nil:VariableNode)}
+function $MethodLexicalScope(){return $globals.MethodLexicalScope||(typeof MethodLexicalScope=="undefined"?nil:MethodLexicalScope)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($VariableNode())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._value_("bzzz");
+$2=$recv($1)._yourself();
+node=$2;
+self._assert_($recv($recv($recv($MethodLexicalScope())._new())._bindingFor_(node))._isNil());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testUnknownVar",{node:node},$globals.ScopeVarTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testUnknownVar\x0a\x09| node |\x0a\x09node := VariableNode new\x0a\x09\x09value: 'bzzz';\x0a\x09\x09yourself.\x0a\x09self assert: (MethodLexicalScope new bindingFor: node) isNil",
+referencedClasses: ["VariableNode", "MethodLexicalScope"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "new", "yourself", "assert:", "isNil", "bindingFor:"]
+}),
+$globals.ScopeVarTest);
+
+
+
+$core.addClass('SemanticAnalyzerTest', $globals.TestCase, ['analyzer'], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'running',
+fn: function (){
+var self=this;
+function $SemanticAnalyzer(){return $globals.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@analyzer"]=$recv($SemanticAnalyzer())._on_($Object());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setUp",{},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp\x0a\x09analyzer := SemanticAnalyzer on: Object",
+referencedClasses: ["SemanticAnalyzer", "Object"],
+//>>excludeEnd("ide");
+messageSends: ["on:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testAssignment",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $InvalidAssignmentError(){return $globals.InvalidAssignmentError||(typeof InvalidAssignmentError=="undefined"?nil:InvalidAssignmentError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo self := 1";
+ast=$recv($Smalltalk())._parse_(src);
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$InvalidAssignmentError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testAssignment",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testAssignment\x0a\x09| src ast |\x0a\x0a\x09src := 'foo self := 1'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09self should: [analyzer visit: ast] raise: InvalidAssignmentError",
+referencedClasses: ["Smalltalk", "InvalidAssignmentError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "should:raise:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNonLocalReturn",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. ^ a";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+self._deny_($recv($recv(ast)._scope())._hasNonLocalReturn());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNonLocalReturn",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNonLocalReturn\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. ^ a'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09self deny: ast scope hasNonLocalReturn",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "deny:", "hasNonLocalReturn", "scope"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testNonLocalReturn2",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. [ [ ^ a] ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+self._assert_($recv($recv(ast)._scope())._hasNonLocalReturn());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testNonLocalReturn2",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testNonLocalReturn2\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. [ [ ^ a] ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09self assert: ast scope hasNonLocalReturn",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "assert:", "hasNonLocalReturn", "scope"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testScope",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+src="foo | a | a + 1. [ | b | b := a ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+$4=$recv($recv($recv(ast)._nodes())._first())._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._last();
+$2=$recv($3)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq_eq($recv(ast)._scope());
+self._deny_($1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testScope",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testScope\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. [ | b | b := a ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09self deny: ast nodes first nodes last scope == ast scope.",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "deny:", "==", "scope", "last", "nodes", "first"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testScope2",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $8,$7,$6,$5,$4,$3,$2,$1;
+src="foo | a | a + 1. [ [ | b | b := a ] ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+$8=$recv($recv($recv(ast)._nodes())._first())._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=3;
+//>>excludeEnd("ctx");
+$7=$recv($8)._last();
+$6=$recv($7)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($5)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq_eq($recv(ast)._scope());
+self._deny_($1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testScope2",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testScope2\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. [ [ | b | b := a ] ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09self deny: ast nodes first nodes last nodes first nodes first scope == ast scope.",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "deny:", "==", "scope", "first", "nodes", "last"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testScopeLevel",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$10,$9,$8,$7,$6,$5,$4,$3;
+src="foo | a | a + 1. [ [ | b | b := a ] ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+$2=$recv(ast)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._scopeLevel();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scopeLevel"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($1,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+$10=$recv($recv($recv(ast)._nodes())._first())._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=3;
+//>>excludeEnd("ctx");
+$9=$recv($10)._last();
+$8=$recv($9)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=2;
+//>>excludeEnd("ctx");
+$7=$recv($8)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._scope();
+$3=$recv($4)._scopeLevel();
+self._assert_equals_($3,(3));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testScopeLevel",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testScopeLevel\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. [ [ | b | b := a ] ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09self assert: ast scope scopeLevel equals: 1.\x0a\x09self assert: ast nodes first nodes last nodes first nodes first scope scopeLevel equals: 3",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "assert:equals:", "scopeLevel", "scope", "first", "nodes", "last"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testUnknownVariables",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $UnknownVariableError(){return $globals.UnknownVariableError||(typeof UnknownVariableError=="undefined"?nil:UnknownVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | b + a";
+ast=$recv($Smalltalk())._parse_(src);
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$UnknownVariableError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testUnknownVariables",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testUnknownVariables\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | b + a'.\x0a\x09ast := Smalltalk parse: src.\x0a\x0a\x09self should: [ analyzer visit: ast ] raise: UnknownVariableError",
+referencedClasses: ["Smalltalk", "UnknownVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "should:raise:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testUnknownVariablesWithScope",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $UnknownVariableError(){return $globals.UnknownVariableError||(typeof UnknownVariableError=="undefined"?nil:UnknownVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a b | [ c + 1. [ a + 1. d + 1 ]]";
+ast=$recv($Smalltalk())._parse_(src);
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$UnknownVariableError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testUnknownVariablesWithScope",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testUnknownVariablesWithScope\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a b | [ c + 1. [ a + 1. d + 1 ]]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09\x0a\x09self should: [ analyzer visit: ast ] raise: UnknownVariableError",
+referencedClasses: ["Smalltalk", "UnknownVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "should:raise:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariableShadowing",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariableShadowing",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariableShadowing\x0a\x09| src ast |\x0a\x09src := 'foo | a | a + 1'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariableShadowing2",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $ShadowingVariableError(){return $globals.ShadowingVariableError||(typeof ShadowingVariableError=="undefined"?nil:ShadowingVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. [ | a | a := 2 ]";
+ast=$recv($Smalltalk())._parse_(src);
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$ShadowingVariableError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariableShadowing2",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariableShadowing2\x0a\x09| src ast |\x0a\x09src := 'foo | a | a + 1. [ | a | a := 2 ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09self should: [analyzer visit: ast] raise: ShadowingVariableError",
+referencedClasses: ["Smalltalk", "ShadowingVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "should:raise:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariableShadowing3",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. [ | b | b := 2 ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariableShadowing3",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariableShadowing3\x0a\x09| src ast |\x0a\x09src := 'foo | a | a + 1. [ | b | b := 2 ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariableShadowing4",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. [ [ [ | b | b := 2 ] ] ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariableShadowing4",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariableShadowing4\x0a\x09| src ast |\x0a\x09src := 'foo | a | a + 1. [ [ [ | b | b := 2 ] ] ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariableShadowing5",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $ShadowingVariableError(){return $globals.ShadowingVariableError||(typeof ShadowingVariableError=="undefined"?nil:ShadowingVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | a + 1. [ [ [ | a | a := 2 ] ] ]";
+ast=$recv($Smalltalk())._parse_(src);
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$ShadowingVariableError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariableShadowing5",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariableShadowing5\x0a\x09| src ast |\x0a\x09src := 'foo | a | a + 1. [ [ [ | a | a := 2 ] ] ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09self should: [analyzer visit: ast] raise: ShadowingVariableError",
+referencedClasses: ["Smalltalk", "ShadowingVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "should:raise:", "visit:"]
+}),
+$globals.SemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testVariablesLookup",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $7,$6,$5,$4,$3,$2,$1,$15,$14,$13,$12,$11,$10,$9,$16,$8,$27,$26,$25,$24,$23,$22,$21,$20,$19,$18,$17,$39,$38,$37,$36,$35,$34,$33,$32,$31,$30,$29,$42,$41,$40,$28;
+src="foo | a | a + 1. [ | b | b := a ]";
+ast=$recv($Smalltalk())._parse_(src);
+$recv(self["@analyzer"])._visit_(ast);
+$7=$recv(ast)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._binding();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["binding"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isTempVar();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["isTempVar"]=1;
+//>>excludeEnd("ctx");
+self._assert_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:"]=1;
+//>>excludeEnd("ctx");
+$15=$recv(ast)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=4;
+//>>excludeEnd("ctx");
+$14=$recv($15)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=4;
+//>>excludeEnd("ctx");
+$13=$recv($14)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=3;
+//>>excludeEnd("ctx");
+$12=$recv($13)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=3;
+//>>excludeEnd("ctx");
+$11=$recv($12)._receiver();
+$10=$recv($11)._binding();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["binding"]=2;
+//>>excludeEnd("ctx");
+$9=$recv($10)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=1;
+//>>excludeEnd("ctx");
+$16=$recv(ast)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=2;
+//>>excludeEnd("ctx");
+$8=$recv($9).__eq_eq($16);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["=="]=1;
+//>>excludeEnd("ctx");
+self._assert_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:"]=2;
+//>>excludeEnd("ctx");
+$27=$recv(ast)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=8;
+//>>excludeEnd("ctx");
+$26=$recv($27)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=7;
+//>>excludeEnd("ctx");
+$25=$recv($26)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=7;
+//>>excludeEnd("ctx");
+$24=$recv($25)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["last"]=1;
+//>>excludeEnd("ctx");
+$23=$recv($24)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=6;
+//>>excludeEnd("ctx");
+$22=$recv($23)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=6;
+//>>excludeEnd("ctx");
+$21=$recv($22)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=5;
+//>>excludeEnd("ctx");
+$20=$recv($21)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=5;
+//>>excludeEnd("ctx");
+$19=$recv($20)._left();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["left"]=1;
+//>>excludeEnd("ctx");
+$18=$recv($19)._binding();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["binding"]=3;
+//>>excludeEnd("ctx");
+$17=$recv($18)._isTempVar();
+self._assert_($17);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:"]=3;
+//>>excludeEnd("ctx");
+$39=$recv(ast)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=12;
+//>>excludeEnd("ctx");
+$38=$recv($39)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=10;
+//>>excludeEnd("ctx");
+$37=$recv($38)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=11;
+//>>excludeEnd("ctx");
+$36=$recv($37)._last();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["last"]=2;
+//>>excludeEnd("ctx");
+$35=$recv($36)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=10;
+//>>excludeEnd("ctx");
+$34=$recv($35)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=9;
+//>>excludeEnd("ctx");
+$33=$recv($34)._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=9;
+//>>excludeEnd("ctx");
+$32=$recv($33)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=8;
+//>>excludeEnd("ctx");
+$31=$recv($32)._left();
+$30=$recv($31)._binding();
+$29=$recv($30)._scope();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["scope"]=3;
+//>>excludeEnd("ctx");
+$42=$recv($recv($recv(ast)._nodes())._first())._nodes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nodes"]=13;
+//>>excludeEnd("ctx");
+$41=$recv($42)._last();
+$40=$recv($41)._scope();
+$28=$recv($29).__eq_eq($40);
+self._assert_($28);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testVariablesLookup",{src:src,ast:ast},$globals.SemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testVariablesLookup\x0a\x09| src ast |\x0a\x0a\x09src := 'foo | a | a + 1. [ | b | b := a ]'.\x0a\x09ast := Smalltalk parse: src.\x0a\x09analyzer visit: ast.\x0a\x0a\x09\x22Binding for `a` in the message send\x22\x0a\x09self assert: ast nodes first nodes first receiver binding isTempVar.\x0a\x09self assert: ast nodes first nodes first receiver binding scope == ast scope.\x0a\x0a\x09\x22Binding for `b`\x22\x0a\x09self assert: ast nodes first nodes last nodes first nodes first left binding isTempVar.\x0a\x09self assert: ast nodes first nodes last nodes first nodes first left binding scope == ast nodes first nodes last scope.",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "visit:", "assert:", "isTempVar", "binding", "receiver", "first", "nodes", "==", "scope", "left", "last"]
+}),
+$globals.SemanticAnalyzerTest);
+
+
+
+$core.addClass('AISemanticAnalyzerTest', $globals.SemanticAnalyzerTest, [], 'Compiler-Tests');
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'running',
+fn: function (){
+var self=this;
+function $AISemanticAnalyzer(){return $globals.AISemanticAnalyzer||(typeof AISemanticAnalyzer=="undefined"?nil:AISemanticAnalyzer)}
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+function $AIContext(){return $globals.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$4,$5,$3,$6;
+$1=$recv($AISemanticAnalyzer())._on_($Object());
+$2=$1;
+$4=$recv($AIContext())._new();
+$recv($4)._defineLocal_("local");
+$recv($4)._localAt_put_("local",(3));
+$5=$recv($4)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$3=$5;
+$recv($2)._context_($3);
+$6=$recv($1)._yourself();
+self["@analyzer"]=$6;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setUp",{},$globals.AISemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp\x0a\x09analyzer := (AISemanticAnalyzer on: Object)\x0a\x09\x09context: (AIContext new\x0a\x09\x09\x09defineLocal: 'local';\x0a\x09\x09\x09localAt: 'local' put: 3;\x0a\x09\x09\x09yourself);\x0a\x09\x09yourself",
+referencedClasses: ["AISemanticAnalyzer", "Object", "AIContext"],
+//>>excludeEnd("ide");
+messageSends: ["context:", "on:", "defineLocal:", "new", "localAt:put:", "yourself"]
+}),
+$globals.AISemanticAnalyzerTest);
+
+$core.addMethod(
+$core.method({
+selector: "testContextVariables",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var src,ast;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $UnknownVariableError(){return $globals.UnknownVariableError||(typeof UnknownVariableError=="undefined"?nil:UnknownVariableError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+src="foo | a | local + a";
+ast=$recv($Smalltalk())._parse_(src);
+self._shouldnt_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@analyzer"])._visit_(ast);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$UnknownVariableError());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testContextVariables",{src:src,ast:ast},$globals.AISemanticAnalyzerTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testContextVariables\x0a\x09| src ast |\x0a\x09\x0a\x09src := 'foo | a | local + a'.\x0a\x09ast := Smalltalk parse: src.\x0a\x0a\x09self shouldnt: [ analyzer visit: ast ] raise: UnknownVariableError",
+referencedClasses: ["Smalltalk", "UnknownVariableError"],
+//>>excludeEnd("ide");
+messageSends: ["parse:", "shouldnt:raise:", "visit:"]
+}),
+$globals.AISemanticAnalyzerTest);
+
+
+});

+ 781 - 0
bower_components/amber/src/Compiler-Tests.st

@@ -0,0 +1,781 @@
+Smalltalk createPackage: 'Compiler-Tests'!
+TestCase subclass: #ASTParsingTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ASTParsingTest methodsFor: 'convenience'!
+
+analyze: aNode forClass: aClass
+	(SemanticAnalyzer on: aClass) visit: aNode.
+	^ aNode
+! !
+
+!ASTParsingTest methodsFor: 'parsing'!
+
+parse: aString
+	^ Smalltalk parse: aString
+!
+
+parse: aString forClass: aClass
+	^ self analyze: (self parse: aString) forClass: aClass
+! !
+
+ASTParsingTest subclass: #ASTPCNodeVisitorTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ASTPCNodeVisitorTest methodsFor: 'factory'!
+
+astPCNodeVisitor
+	^ ASTPCNodeVisitor new
+		context: (AIContext new
+			yourself);
+		yourself
+!
+
+astPCNodeVisitorForSelector: aString
+	^ ASTPCNodeVisitor new
+		selector: aString;
+		context: (AIContext new
+			yourself);
+		yourself
+! !
+
+!ASTPCNodeVisitorTest methodsFor: 'tests'!
+
+testJSStatementNode
+	| ast visitor |
+	
+	ast := self parse: 'foo <consolee.log(1)>' forClass: Object.
+	self assert: (self astPCNodeVisitor
+		visit: ast;
+		currentNode) isJSStatementNode
+!
+
+testMessageSend
+	| ast |
+	
+	ast := self parse: 'foo self asString yourself. ^ self asBoolean' forClass: Object.
+	self assert: ((self astPCNodeVisitorForSelector: 'yourself')
+		visit: ast;
+		currentNode) selector equals: 'yourself'
+!
+
+testMessageSendWithBlocks
+	| ast |
+	
+	ast := self parse: 'foo true ifTrue: [ [ self asString yourself ] value.  ]. ^ self asBoolean' forClass: Object.
+	self assert: ((self astPCNodeVisitorForSelector: 'yourself')
+		visit: ast;
+		currentNode) selector equals: 'yourself'
+!
+
+testMessageSendWithInlining
+	| ast |
+	
+	ast := self parse: 'foo true ifTrue: [ self asString yourself ]. ^ self asBoolean' forClass: Object.
+	self assert: ((self astPCNodeVisitorForSelector: 'yourself')
+		visit: ast;
+		currentNode) selector equals: 'yourself'.
+		
+	ast := self parse: 'foo true ifTrue: [ self asString yourself ]. ^ self asBoolean' forClass: Object.
+	self assert: ((self astPCNodeVisitorForSelector: 'asBoolean')
+		visit: ast;
+		currentNode) selector equals: 'asBoolean'
+!
+
+testNoMessageSend
+	| ast |
+	
+	ast := self parse: 'foo ^ self' forClass: Object.
+	self assert: (self astPCNodeVisitor
+		visit: ast;
+		currentNode) isNil
+!
+
+testPC
+	| ast visitor |
+	
+	ast := self parse: 'foo <console.log(1)>' forClass: Object.
+	self assert: (self astPCNodeVisitor
+		visit: ast;
+		currentNode) isJSStatementNode
+! !
+
+ASTParsingTest subclass: #ASTPositionTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ASTPositionTest methodsFor: 'tests'!
+
+testNodeAtPosition
+	| node |
+	
+	node := self parse: 'yourself
+	^ self'.
+	
+	self assert: (node navigationNodeAt: 2@4 ifAbsent: [ nil ]) source equals: 'self'.
+	
+	node := self parse: 'foo
+	true ifTrue: [ 1 ]'.
+	
+	self assert: (node navigationNodeAt: 2@7 ifAbsent: [ nil ]) selector equals: 'ifTrue:'.
+	
+	node := self parse: 'foo
+	self foo; bar; baz'.
+	
+	self assert: (node navigationNodeAt: 2@8 ifAbsent: [ nil ]) selector equals: 'foo'
+! !
+
+ASTParsingTest subclass: #CodeGeneratorTest
+	instanceVariableNames: 'receiver'
+	package: 'Compiler-Tests'!
+
+!CodeGeneratorTest methodsFor: 'accessing'!
+
+codeGeneratorClass
+	^ CodeGenerator
+! !
+
+!CodeGeneratorTest methodsFor: 'factory'!
+
+compiler
+	^ Compiler new
+		codeGeneratorClass: self codeGeneratorClass;
+		yourself
+! !
+
+!CodeGeneratorTest methodsFor: 'initialization'!
+
+setUp
+	receiver := DoIt new
+!
+
+tearDown
+	"receiver := nil"
+! !
+
+!CodeGeneratorTest methodsFor: 'testing'!
+
+should: aString receiver: anObject return: aResult
+	| method result |
+
+	receiver := anObject.
+	method := self compiler install: aString forClass: anObject class protocol: 'tests'.
+	result := receiver perform: method selector.
+	anObject class removeCompiledMethod: method.
+	self assert: aResult equals: result
+!
+
+should: aString return: anObject
+	^ self 
+		should: aString 
+		receiver: receiver 
+		return: anObject
+! !
+
+!CodeGeneratorTest methodsFor: 'tests'!
+
+testAssignment
+	self should: 'foo | a | a := true ifTrue: [ 1 ]. ^ a' return: 1.
+	self should: 'foo | a | a := false ifTrue: [ 1 ]. ^ a' return: nil.
+
+	self should: 'foo | a | ^ a := true ifTrue: [ 1 ]' return: 1
+!
+
+testBackslashSelectors
+	
+	self should: '\ arg ^ 4' return: 4.
+	self should: '\\ arg ^ 42' return: 42
+!
+
+testBlockReturn
+	self should: 'foo ^ #(1 2 3) collect: [ :each | true ifTrue: [ each + 1 ] ]' return: #(2 3 4).
+	self should: 'foo ^ #(1 2 3) collect: [ :each | false ifFalse: [ each + 1 ] ]' return: #(2 3 4).
+	self should: 'foo ^ #(1 2 3) collect: [ :each | each odd ifTrue: [ each + 1 ] ifFalse: [ each - 1 ] ]' return: #(2 1 4).
+!
+
+testCascades
+	
+	self should: 'foo ^ Array new add: 3; add: 4; yourself' return: #(3 4)
+!
+
+testCascadesWithInlining
+	
+	self should: 'foo ^ true ifTrue: [ 1 ] ifFalse: [ 2 ]' return: 1.
+	self should: 'foo ^ false ifTrue: [ 1 ] ifFalse: [ 2 ]' return: 2
+!
+
+testDynamicArrayElementsOrdered
+	self should: 'foo
+	| x |
+	x := 1.
+	^ { x. x := 2 }
+' return: #(1 2).
+
+	self should: 'foo
+	| x |
+	x := 1.
+	^ { x. true ifTrue: [ x := 2 ] }
+' return: #(1 2).
+!
+
+testDynamicDictionaryElementsOrdered
+	self should: 'foo
+	| x |
+	x := ''foo''.
+	^ #{ x->1. ''bar''->(true ifTrue: [ 2 ]) }
+' return: #{'foo'->1. 'bar'->2}.
+!
+
+testDynamicDictionaryWithMoreArrows
+	self should: 'foo ^ #{1->2->3}' return: (HashedCollection with: 1->2->3)
+!
+
+testGlobalVar
+	self should: 'foo ^ eval class' return: BlockClosure.
+	self should: 'foo ^ Math cos: 0' return: 1.
+	self should: 'foo ^ NonExistingVar' return: nil
+!
+
+testInnerTemporalDependentElementsOrdered
+	self should: 'foo
+	| x |
+	x := Array.
+	^ x with: ''foo''->x with: ''bar''->(x := 2)
+' return: {'foo'->Array. 'bar'->2}.
+
+	self should: 'foo
+	| x |
+	x := Array.
+	^ x with: ''foo''->x with: ''bar''->(true ifTrue: [ x := 2 ])
+' return: {'foo'->Array. 'bar'->2}.
+
+	self should: 'foo
+	| x |
+	x := 1.
+	^ Array with: ''foo''->x with: ''bar''->(true ifTrue: [ x := 2 ])
+' return: {'foo'->1. 'bar'->2}.
+
+	self should: 'foo
+	| x |
+	x := 1.
+	^ { ''foo''->x. ''bar''->(true ifTrue: [ x := 2 ]) }
+' return: {'foo'->1. 'bar'->2}.
+
+	self should: 'foo
+	| x |
+	x := 1.
+	^ #{ ''foo''->x. ''bar''->(true ifTrue: [ x := 2 ]) }
+' return: #{'foo'->1. 'bar'->2}.
+!
+
+testJSStatement
+	self should: 'foo <return 2+3>' return: 5
+!
+
+testLexicalScope
+	self should: 'foo | a | a := 1. [ a := 2 ] value. ^ a' return: 2
+!
+
+testLiterals
+	self should: 'foo ^ 1' return: 1.
+	self should: 'foo ^ ''hello''' return: 'hello'.
+	self should: 'foo ^ #(1 2 3 4)' return: #(1 2 3 4).
+	self should: 'foo ^ {1. [:x | x ] value: 2. 3. [4] value}' return: #(1 2 3 4).
+	self should: 'foo ^ true' return: true.
+	self should: 'foo ^ false' return: false.
+	self should: 'foo ^ #{1->2. 3->4}' return: #{1->2. 3->4}.
+	self should: 'foo ^ #hello' return: #hello.
+	self should: 'foo ^ $h' return: 'h'.
+	self should: 'foo ^ -123.456' return: -123.456.
+	self should: 'foo ^ -2.5e4' return: -25000.
+!
+
+testLocalReturn
+	self should: 'foo ^ 1' return: 1.
+	self should: 'foo ^ 1 + 1' return: 2.
+	self should: 'foo ' return: receiver.
+	self should: 'foo self asString' return: receiver.
+	self should: 'foo | a b | a := 1. b := 2. ^ a + b' return: 3
+!
+
+testMessageSends
+	self should: 'foo ^ 1 asString' return: '1'.
+
+	self should: 'foo ^ 1 + 1' return: 2.
+	self should: 'foo ^ 1 + 2 * 3' return: 9.
+
+	self should: 'foo ^ 1 to: 3' return: #(1 2 3).
+	self should: 'foo ^ 1 to: 5 by: 2' return: #(1 3 5)
+!
+
+testMultipleSequences
+	self should: 'foo | a b c | a := 2. b := 3. c := a + b. ^ c * 6' return: 30
+!
+
+testMutableLiterals
+	"Mutable literals must be aliased in cascades.
+	See https://github.com/amber-smalltalk/amber/issues/428"
+	
+	self 
+		should: 'foo ^ #( 1 2 ) at: 1 put: 3; yourself' 
+		return: #(3 2)
+!
+
+testNestedIfTrue
+	self should: 'foo ^ true ifTrue: [ false ifFalse: [ 1 ] ]' return: 1.
+	self should: 'foo ^ true ifTrue: [ false ifTrue: [ 1 ] ]' return: nil.
+
+	self should: 'foo true ifTrue: [ false ifFalse: [ ^ 1 ] ]' return: 1.
+	self should: 'foo true ifTrue: [ false ifTrue: [ ^ 1 ] ]' return: receiver.
+!
+
+testNestedSends
+	self should: 'foo ^ (Point x: (Point x: 2 y: 3) y: 4) asString' return: (Point x: (2@3) y: 4) asString
+!
+
+testNonLocalReturn
+	self should: 'foo [ ^ 1 ] value' return: 1.
+	self should: 'foo [ ^ 1 + 1 ] value' return: 2.
+	self should: 'foo | a b | a := 1. b := 2. [ ^ a + b ] value. self halt' return: 3.
+	self should: 'foo [ :x | ^ x + x ] value: 4. ^ 2' return: 8
+!
+
+testPascalCaseGlobal
+	self should: 'foo ^Object' return: (Smalltalk globals at: 'Object').
+	self should: 'foo ^NonExistent' return: nil
+!
+
+testSendReceiverAndArgumentsOrdered
+	self should: 'foo
+	| x |
+	x := 1.
+	^ Array with: x with: (true ifTrue: [ x := 2 ])
+' return: #(1 2).
+
+	self should: 'foo
+	| x |
+	x := Array.
+	^ x with: x with: (true ifTrue: [ x := 2 ])
+' return: {Array. 2}.
+!
+
+testSuperSend
+	self 
+		should: 'foo ^ super isBoolean' 
+		receiver: true
+		return: false
+!
+
+testTempVariables
+	self should: 'foo | a | ^ a' return: nil.
+	self should: 'foo | AVariable | ^ AVariable' return: nil.
+	self should: 'foo | a b c | ^ c' return: nil.
+	self should: 'foo | a | [ | d | ^ d ] value' return: nil.
+	
+	self should: 'foo | a | a:= 1. ^ a' return: 1.
+	self should: 'foo | AVariable | AVariable := 1. ^ AVariable' return: 1.
+!
+
+testThisContext
+	self should: 'foo ^ [ thisContext ] value outerContext == thisContext' return: true
+!
+
+testifFalse
+	self should: 'foo true ifFalse: [ ^ 1 ]' return: receiver.
+	self should: 'foo false ifFalse: [ ^ 2 ]' return: 2.
+	
+	self should: 'foo ^ true ifFalse: [ 1 ]' return: nil.
+	self should: 'foo ^ false ifFalse: [ 2 ]' return: 2.
+!
+
+testifFalseIfTrue
+	self should: 'foo true ifFalse: [ ^ 1 ] ifTrue: [ ^ 2 ]' return: 2.
+	self should: 'foo false ifFalse: [ ^ 2 ] ifTrue: [ ^1 ]' return: 2.
+	
+	self should: 'foo ^ true ifFalse: [ 1 ] ifTrue: [ 2 ]' return: 2.
+	self should: 'foo ^ false ifFalse: [ 2 ] ifTrue: [ 1 ]' return: 2.
+!
+
+testifNil
+	self should: 'foo ^ 1 ifNil: [ 2 ]' return: 1.
+	self should: 'foo ^ nil ifNil: [ 2 ]' return: 2.
+
+	self should: 'foo 1 ifNil: [ ^ 2 ]' return: receiver.
+	self should: 'foo nil ifNil: [ ^ 2 ]' return: 2.
+!
+
+testifNilIfNotNil
+	self should: 'foo ^ 1 ifNil: [ 2 ] ifNotNil: [ 3 ]' return: 3.
+	self should: 'foo ^ nil ifNil: [ 2 ] ifNotNil: [ 3 ]' return: 2.
+
+	self should: 'foo 1 ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]' return: 3.
+	self should: 'foo nil ifNil: [ ^ 2 ] ifNotNil: [ ^3 ]' return: 2.
+!
+
+testifNotNil
+	self should: 'foo ^ 1 ifNotNil: [ 2 ]' return: 2.
+	self should: 'foo ^ nil ifNotNil: [ 2 ]' return: nil.
+
+	self should: 'foo 1 ifNotNil: [ ^ 2 ]' return: 2.
+	self should: 'foo nil ifNotNil: [ ^ 2 ]' return: receiver.
+!
+
+testifNotNilWithArgument
+	self should: 'foo ^ 1 ifNotNil: [ :val | val + 2 ]' return: 3.
+	self should: 'foo ^ nil ifNotNil: [ :val | val + 2 ]' return: nil.
+	
+	self should: 'foo ^ 1 ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]' return: 3.
+	self should: 'foo ^ nil ifNil: [ 5 ] ifNotNil: [ :val | val + 2 ]' return: 5.
+	
+	self should: 'foo ^ 1 ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]' return: 3.
+	self should: 'foo ^ nil ifNotNil: [ :val | val + 2 ] ifNil: [ 5 ]' return: 5
+!
+
+testifTrue
+	self should: 'foo false ifTrue: [ ^ 1 ]' return: receiver.
+	self should: 'foo true ifTrue: [ ^ 2 ]' return: 2.
+	
+	self should: 'foo ^ false ifTrue: [ 1 ]' return: nil.
+	self should: 'foo ^ true ifTrue: [ 2 ]' return: 2.
+!
+
+testifTrueIfFalse
+	self should: 'foo false ifTrue: [ ^ 1 ] ifFalse: [ ^2 ]' return: 2.
+	self should: 'foo true ifTrue: [ ^ 1 ] ifFalse: [ ^ 2 ]' return: 1.
+	
+	self should: 'foo ^ false ifTrue: [ 2 ] ifFalse: [ 1 ]' return: 1.
+	self should: 'foo ^ true ifTrue: [ 2 ] ifFalse: [ 1 ]' return: 2.
+! !
+
+CodeGeneratorTest subclass: #ASTInterpreterTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ASTInterpreterTest methodsFor: 'parsing'!
+
+analyze: aNode forClass: aClass
+	(SemanticAnalyzer on: aClass) visit: aNode.
+	^ aNode
+!
+
+parse: aString
+	^ Smalltalk parse: aString
+!
+
+parse: aString forClass: aClass
+	^ self analyze: (self parse: aString) forClass: aClass
+! !
+
+!ASTInterpreterTest methodsFor: 'private'!
+
+interpret: aString receiver: anObject withArguments: aDictionary
+	"The food is a methodNode. Interpret the sequenceNode only"
+	
+	| ctx ast interpreter |
+	
+	interpreter := ASTInterpreter new.
+	ast := self parse: aString forClass: anObject class.
+	
+	ctx := AIContext new
+		receiver: anObject;
+		interpreter: interpreter;
+		yourself.
+		
+	"Define locals for the context"
+	ast sequenceNode ifNotNil: [ :sequence |
+		sequence temps do: [ :each |
+			ctx defineLocal: each ] ].
+		
+	aDictionary keysAndValuesDo: [ :key :value |
+		ctx localAt: key put: value ].
+	
+	^ interpreter
+		context: ctx;
+		interpret: ast nextChild;
+		proceed;
+		result
+! !
+
+!ASTInterpreterTest methodsFor: 'testing'!
+
+should: aString receiver: anObject return: aResult
+	receiver := anObject.
+	
+	^ self 
+		assert: (self interpret: aString receiver: receiver withArguments: #{})
+		equals: aResult
+!
+
+should: aString return: anObject
+	^ self 
+		should: aString
+		receiver: receiver
+		return: anObject
+! !
+
+ASTInterpreterTest subclass: #ASTDebuggerTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ASTDebuggerTest methodsFor: 'private'!
+
+interpret: aString receiver: anObject withArguments: aDictionary
+	| ctx ast debugger |
+	
+	ctx := AIContext new
+		receiver: anObject;
+		interpreter: ASTInterpreter new;
+		yourself.
+	ast := self parse: aString forClass: anObject class.
+		
+	"Define locals for the context"
+	ast sequenceNode ifNotNil: [ :sequence |
+		sequence temps do: [ :each |
+			ctx defineLocal: each ] ].
+	
+	aDictionary keysAndValuesDo: [ :key :value |
+		ctx localAt: key put: value ].
+	ctx interpreter context: ctx.
+	
+	ctx interpreter node: ast nextChild.
+	
+	debugger := ASTDebugger context: ctx.
+	
+	^ debugger 
+		proceed; 
+		result
+! !
+
+CodeGeneratorTest subclass: #InliningCodeGeneratorTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!InliningCodeGeneratorTest methodsFor: 'accessing'!
+
+codeGeneratorClass
+	^ InliningCodeGenerator
+! !
+
+TestCase subclass: #ScopeVarTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!ScopeVarTest methodsFor: 'tests'!
+
+testClassRefVar
+	| node |
+	node := VariableNode new
+		value: 'Object';
+		yourself.
+	SemanticAnalyzer new 
+		pushScope: MethodLexicalScope new;
+		visit: node.
+	self assert: node binding isClassRefVar
+!
+
+testInstanceVar
+	| node scope |
+	node := VariableNode new
+		value: 'bzzz';
+		yourself.
+	scope := MethodLexicalScope new.
+	scope addIVar: 'bzzz'.
+	self assert: (scope bindingFor: node) isInstanceVar
+!
+
+testPseudoVar
+	| node pseudoVars |
+	pseudoVars := #('self' 'super' 'true' 'false' 'nil').
+	pseudoVars do: [:each |
+		node := VariableNode new
+		value: each;
+		yourself.
+		self assert: (MethodLexicalScope new bindingFor: node) isPseudoVar]
+!
+
+testTempVar
+	| node scope |
+	node := VariableNode new
+		value: 'bzzz';
+		yourself.
+	scope := MethodLexicalScope new.
+	scope addTemp: 'bzzz'.
+	self assert: (scope bindingFor: node) isTempVar
+!
+
+testUnknownVar
+	| node |
+	node := VariableNode new
+		value: 'bzzz';
+		yourself.
+	self assert: (MethodLexicalScope new bindingFor: node) isNil
+! !
+
+TestCase subclass: #SemanticAnalyzerTest
+	instanceVariableNames: 'analyzer'
+	package: 'Compiler-Tests'!
+
+!SemanticAnalyzerTest methodsFor: 'running'!
+
+setUp
+	analyzer := SemanticAnalyzer on: Object
+! !
+
+!SemanticAnalyzerTest methodsFor: 'tests'!
+
+testAssignment
+	| src ast |
+
+	src := 'foo self := 1'.
+	ast := Smalltalk parse: src.
+	self should: [analyzer visit: ast] raise: InvalidAssignmentError
+!
+
+testNonLocalReturn
+	| src ast |
+
+	src := 'foo | a | a + 1. ^ a'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	self deny: ast scope hasNonLocalReturn
+!
+
+testNonLocalReturn2
+	| src ast |
+
+	src := 'foo | a | a + 1. [ [ ^ a] ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	self assert: ast scope hasNonLocalReturn
+!
+
+testScope
+	| src ast |
+
+	src := 'foo | a | a + 1. [ | b | b := a ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	self deny: ast nodes first nodes last scope == ast scope.
+!
+
+testScope2
+	| src ast |
+
+	src := 'foo | a | a + 1. [ [ | b | b := a ] ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	self deny: ast nodes first nodes last nodes first nodes first scope == ast scope.
+!
+
+testScopeLevel
+	| src ast |
+
+	src := 'foo | a | a + 1. [ [ | b | b := a ] ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	self assert: ast scope scopeLevel equals: 1.
+	self assert: ast nodes first nodes last nodes first nodes first scope scopeLevel equals: 3
+!
+
+testUnknownVariables
+	| src ast |
+
+	src := 'foo | a | b + a'.
+	ast := Smalltalk parse: src.
+
+	self should: [ analyzer visit: ast ] raise: UnknownVariableError
+!
+
+testUnknownVariablesWithScope
+	| src ast |
+
+	src := 'foo | a b | [ c + 1. [ a + 1. d + 1 ]]'.
+	ast := Smalltalk parse: src.
+	
+	self should: [ analyzer visit: ast ] raise: UnknownVariableError
+!
+
+testVariableShadowing
+	| src ast |
+	src := 'foo | a | a + 1'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast
+!
+
+testVariableShadowing2
+	| src ast |
+	src := 'foo | a | a + 1. [ | a | a := 2 ]'.
+	ast := Smalltalk parse: src.
+	self should: [analyzer visit: ast] raise: ShadowingVariableError
+!
+
+testVariableShadowing3
+	| src ast |
+	src := 'foo | a | a + 1. [ | b | b := 2 ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast
+!
+
+testVariableShadowing4
+	| src ast |
+	src := 'foo | a | a + 1. [ [ [ | b | b := 2 ] ] ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast
+!
+
+testVariableShadowing5
+	| src ast |
+	src := 'foo | a | a + 1. [ [ [ | a | a := 2 ] ] ]'.
+	ast := Smalltalk parse: src.
+	self should: [analyzer visit: ast] raise: ShadowingVariableError
+!
+
+testVariablesLookup
+	| src ast |
+
+	src := 'foo | a | a + 1. [ | b | b := a ]'.
+	ast := Smalltalk parse: src.
+	analyzer visit: ast.
+
+	"Binding for `a` in the message send"
+	self assert: ast nodes first nodes first receiver binding isTempVar.
+	self assert: ast nodes first nodes first receiver binding scope == ast scope.
+
+	"Binding for `b`"
+	self assert: ast nodes first nodes last nodes first nodes first left binding isTempVar.
+	self assert: ast nodes first nodes last nodes first nodes first left binding scope == ast nodes first nodes last scope.
+! !
+
+SemanticAnalyzerTest subclass: #AISemanticAnalyzerTest
+	instanceVariableNames: ''
+	package: 'Compiler-Tests'!
+
+!AISemanticAnalyzerTest methodsFor: 'running'!
+
+setUp
+	analyzer := (AISemanticAnalyzer on: Object)
+		context: (AIContext new
+			defineLocal: 'local';
+			localAt: 'local' put: 3;
+			yourself);
+		yourself
+! !
+
+!AISemanticAnalyzerTest methodsFor: 'tests'!
+
+testContextVariables
+	| src ast |
+	
+	src := 'foo | a | local + a'.
+	ast := Smalltalk parse: src.
+
+	self shouldnt: [ analyzer visit: ast ] raise: UnknownVariableError
+! !
+

+ 196 - 0
bower_components/amber/src/Examples.js

@@ -0,0 +1,196 @@
+define("amber_core/Examples", ["amber/boot", "amber_core/Web"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Examples');
+$core.packages["Examples"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Counter', $globals.Widget, ['count', 'header'], 'Examples');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Counter.comment="This is a trivial Widget example mimicking the classic Counter example in Seaside.\x0aIn order to play with it, just evaluate the doit below in a workspace.\x0aThen take a look in the HTML document above the IDE.\x0a\x0a\x09\x09Counter tryExample";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "decrease",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@count"]=$recv(self["@count"]).__minus((1));
+$recv(self["@header"])._contents_((function(html){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(html)._with_($recv(self["@count"])._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"decrease",{},$globals.Counter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "decrease\x0a\x09count := count - 1.\x0a\x09header contents: [ :html | html with: count asString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["-", "contents:", "with:", "asString"]
+}),
+$globals.Counter);
+
+$core.addMethod(
+$core.method({
+selector: "increase",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@count"]=$recv(self["@count"]).__plus((1));
+$recv(self["@header"])._contents_((function(html){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(html)._with_($recv(self["@count"])._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({html:html},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"increase",{},$globals.Counter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "increase\x0a\x09count := count + 1.\x0a\x09header contents: [ :html | html with: count asString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["+", "contents:", "with:", "asString"]
+}),
+$globals.Counter);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Counter.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@count"]=(0);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Counter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09count := 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize"]
+}),
+$globals.Counter);
+
+$core.addMethod(
+$core.method({
+selector: "renderOn:",
+protocol: 'rendering',
+fn: function (html){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$6;
+$1=$recv(html)._h1();
+$recv($1)._with_($recv(self["@count"])._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["with:"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($1)._yourself();
+self["@header"]=$2;
+$3=$recv(html)._button();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["button"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._with_("++");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["with:"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($3)._onClick_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._increase();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["onClick:"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(html)._button();
+$recv($5)._with_("--");
+$6=$recv($5)._onClick_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._decrease();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"renderOn:",{html:html},$globals.Counter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["html"],
+source: "renderOn: html\x0a\x09header := html h1\x0a\x09\x09with: count asString;\x0a\x09\x09yourself.\x0a\x09html button\x0a\x09\x09with: '++';\x0a\x09\x09onClick: [ self increase ].\x0a\x09html button\x0a\x09\x09with: '--';\x0a\x09\x09onClick: [ self decrease ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h1", "asString", "yourself", "button", "onClick:", "increase", "decrease"]
+}),
+$globals.Counter);
+
+
+$core.addMethod(
+$core.method({
+selector: "tryExample",
+protocol: 'example',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._new())._appendToJQuery_("body"._asJQuery());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tryExample",{},$globals.Counter.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tryExample\x0a\x09\x22In order to play with the Counter, just select the\x0a\x09doit below and press the Do it button. Then take a\x0a\x09look in the HTML document above the IDE.\x22\x0a\x0a\x09\x22Counter tryExample\x22\x0a\x09\x09self new appendToJQuery: 'body' asJQuery",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendToJQuery:", "new", "asJQuery"]
+}),
+$globals.Counter.klass);
+
+});

+ 55 - 0
bower_components/amber/src/Examples.st

@@ -0,0 +1,55 @@
+Smalltalk createPackage: 'Examples'!
+Widget subclass: #Counter
+	instanceVariableNames: 'count header'
+	package: 'Examples'!
+!Counter commentStamp!
+This is a trivial Widget example mimicking the classic Counter example in Seaside.
+In order to play with it, just evaluate the doit below in a workspace.
+Then take a look in the HTML document above the IDE.
+
+		Counter tryExample!
+
+!Counter methodsFor: 'actions'!
+
+decrease
+	count := count - 1.
+	header contents: [ :html | html with: count asString ]
+!
+
+increase
+	count := count + 1.
+	header contents: [ :html | html with: count asString ]
+! !
+
+!Counter methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	count := 0
+! !
+
+!Counter methodsFor: 'rendering'!
+
+renderOn: html
+	header := html h1
+		with: count asString;
+		yourself.
+	html button
+		with: '++';
+		onClick: [ self increase ].
+	html button
+		with: '--';
+		onClick: [ self decrease ]
+! !
+
+!Counter class methodsFor: 'example'!
+
+tryExample
+	"In order to play with the Counter, just select the
+	doit below and press the Do it button. Then take a
+	look in the HTML document above the IDE."
+
+	"Counter tryExample"
+		self new appendToJQuery: 'body' asJQuery
+! !
+

Diff do ficheiro suprimidas por serem muito extensas
+ 5684 - 0
bower_components/amber/src/IDE.js


+ 2397 - 0
bower_components/amber/src/IDE.st

@@ -0,0 +1,2397 @@
+Smalltalk createPackage: 'IDE'!
+Widget subclass: #ClassesList
+	instanceVariableNames: 'browser ul nodes'
+	package: 'IDE'!
+
+!ClassesList methodsFor: 'accessing'!
+
+browser
+	^ browser
+!
+
+browser: aBrowser
+	browser := aBrowser
+!
+
+category
+	^ self browser selectedPackage
+!
+
+getNodes
+	| classes children others |
+	classes := self browser classes.
+	children := #().
+	others := #().
+	classes do: [ :each |
+		(classes includes: each superclass)
+			ifFalse: [ children add: each ]
+			ifTrue: [ others add: each ]].
+	^ children collect: [ :each |
+		ClassesListNode on: each browser: self browser classes: others level: 0 ]
+!
+
+nodes
+	nodes ifNil: [ nodes := self getNodes ].
+	^ nodes
+!
+
+resetNodes
+	nodes := nil
+! !
+
+!ClassesList methodsFor: 'rendering'!
+
+renderOn: html
+	ul := html ul
+		class: 'amber_column browser classes';
+		yourself.
+	self updateNodes
+!
+
+updateNodes
+	ul contents: [ :html |
+		self nodes do: [ :each |
+			each renderOn: html ]]
+! !
+
+!ClassesList class methodsFor: 'instance creation'!
+
+on: aBrowser
+	^ self new
+		browser: aBrowser;
+		yourself
+! !
+
+Widget subclass: #ClassesListNode
+	instanceVariableNames: 'browser theClass level nodes'
+	package: 'IDE'!
+
+!ClassesListNode methodsFor: 'accessing'!
+
+browser
+	^ browser
+!
+
+browser: aBrowser
+	browser := aBrowser
+!
+
+getNodesFrom: aCollection
+	| children others |
+	children := #().
+	others := #().
+	aCollection do: [ :each |
+		(each superclass = self theClass)
+			ifTrue: [ children add: each ]
+			ifFalse: [ others add: each ]].
+	nodes:= children collect: [ :each |
+		ClassesListNode on: each browser: self browser classes: others level: self level + 1 ]
+!
+
+label
+	| str |
+	str := String new writeStream.
+	self level timesRepeat: [
+		str nextPutAll: '&nbsp;&nbsp;&nbsp;&nbsp;' ].
+	str nextPutAll: self theClass name.
+	^ str contents
+!
+
+level
+	^ level
+!
+
+level: anInteger
+	level := anInteger
+!
+
+nodes
+	^ nodes
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+!ClassesListNode methodsFor: 'rendering'!
+
+renderOn: html
+	| li cssClass |
+	cssClass := ''.
+	li := html li
+		onClick: [ self browser selectClass: self theClass ].
+	li asJQuery html: self label.
+
+	self browser selectedClass = self theClass ifTrue: [
+		cssClass := cssClass, ' selected' ].
+
+	self theClass comment isEmpty ifFalse: [
+		cssClass := cssClass, ' commented' ].
+
+	li class: cssClass.
+
+	self nodes do: [ :each |
+		each renderOn: html ]
+! !
+
+!ClassesListNode class methodsFor: 'instance creation'!
+
+on: aClass browser: aBrowser classes: aCollection level: anInteger
+	^ self new
+		theClass: aClass;
+		browser: aBrowser;
+		level: anInteger;
+		getNodesFrom: aCollection;
+		yourself
+! !
+
+Object subclass: #DebugErrorHandler
+	instanceVariableNames: ''
+	package: 'IDE'!
+
+!DebugErrorHandler methodsFor: 'error handling'!
+
+handleError: anError
+	[ Debugger new
+		error: anError;
+		open ] on: Error do: [ :error |
+			ConsoleErrorHandler new handleError: error ]
+! !
+
+!DebugErrorHandler class methodsFor: 'initialization'!
+
+initialize
+	ErrorHandler register: self new
+! !
+
+Widget subclass: #SourceArea
+	instanceVariableNames: 'editor div receiver onDoIt'
+	package: 'IDE'!
+
+!SourceArea methodsFor: 'accessing'!
+
+currentLine
+	^ editor getLine: (editor getCursor line)
+!
+
+currentLineOrSelection
+	^ editor somethingSelected
+	ifFalse: [ self currentLine ]
+	ifTrue: [ self selection ]
+!
+
+editor
+	^ editor
+!
+
+onDoIt
+	^ onDoIt
+!
+
+onDoIt: aBlock
+	onDoIt := aBlock
+!
+
+receiver
+	^ receiver ifNil: [ DoIt new ]
+!
+
+receiver: anObject
+	receiver := anObject
+!
+
+selection
+	^ editor getSelection
+!
+
+setEditorOn: aTextarea
+	<self['@editor'] = self._class()._codeMirror().fromTextArea(aTextarea, {
+		theme: 'ide.codeMirrorTheme'._settingValueIfAbsent_('default'),
+		mode: 'text/x-stsrc',
+		lineNumbers: true,
+		enterMode: 'flat',
+		indentWithTabs: true,
+		indentUnit: 4,
+		matchBrackets: true,
+		electricChars: false
+	})>
+!
+
+val
+	^ editor getValue
+!
+
+val: aString
+	editor setValue: aString
+! !
+
+!SourceArea methodsFor: 'actions'!
+
+clear
+	self val: ''
+!
+
+doIt
+	| result |
+	result := self eval: self currentLineOrSelection.
+	self onDoIt ifNotNil: [ self onDoIt value ].
+	^ result
+!
+
+eval: aString
+	| compiler |
+	compiler := Compiler new.
+	[ compiler parseExpression: aString ] on: Error do: [ :ex |
+		^ self alert: ex messageText ].
+	^ compiler evaluateExpression: aString on: self receiver
+!
+
+fileIn
+	Importer new import: self currentLineOrSelection readStream
+!
+
+focus
+	self editor focus.
+!
+
+handleKeyDown: anEvent
+	<if(anEvent.ctrlKey) {
+		if(anEvent.keyCode === 80) { //ctrl+p
+			self._printIt();
+			anEvent.preventDefault();
+			return false;
+		}
+		if(anEvent.keyCode === 68) { //ctrl+d
+			self._doIt();
+			anEvent.preventDefault();
+			return false;
+		}
+		if(anEvent.keyCode === 73) { //ctrl+i
+			self._inspectIt();
+			anEvent.preventDefault();
+			return false;
+		}
+	}>
+!
+
+inspectIt
+	self doIt inspect
+!
+
+print: aString
+	| start stop currentLine |
+	currentLine := (editor getCursor: false) line.
+	start := HashedCollection new.
+	start at: 'line' put: currentLine.
+	start at: 'ch' put: (editor getCursor: false) ch.
+	(editor getSelection) ifEmpty: [
+		"select current line if selection is empty"
+		start at: 'ch' put: (editor getLine: currentLine) size.
+		editor setSelection: #{'line' -> currentLine. 'ch' -> 0} end: start.
+	].
+	stop := HashedCollection new.
+	stop at: 'line' put: currentLine.
+	stop at: 'ch' put: ((start at: 'ch') + aString size + 2).
+
+	editor replaceSelection: (editor getSelection, ' ', aString, ' ').
+	editor setCursor: (editor getCursor: true).
+	editor setSelection: stop end: start
+!
+
+printIt
+	self print: self doIt printString.
+	self focus.
+! !
+
+!SourceArea methodsFor: 'events'!
+
+onKeyDown: aBlock
+	div onKeyDown: aBlock
+!
+
+onKeyUp: aBlock
+	div onKeyUp: aBlock
+! !
+
+!SourceArea methodsFor: 'rendering'!
+
+renderOn: html
+	| textarea |
+	div := html div class: 'source'.
+	div with: [ textarea := html textarea ].
+	self setEditorOn: textarea element.
+	div onKeyDown: [ :e | self handleKeyDown: e ]
+! !
+
+!SourceArea class methodsFor: 'accessing'!
+
+codeMirror
+	^ require value: 'codemirror/lib/codemirror'
+! !
+
+!SourceArea class methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	self setupCodeMirror
+!
+
+setupCodeMirror
+	< self._codeMirror().keyMap["default"].fallthrough = ["basic"] >
+! !
+
+Widget subclass: #TabManager
+	instanceVariableNames: 'selectedTab tabs opened ul input'
+	package: 'IDE'!
+
+!TabManager methodsFor: 'accessing'!
+
+labelFor: aWidget
+	| label maxSize |
+	maxSize := 15.
+	label := aWidget label copyFrom: 0 to: (aWidget label size min: maxSize).
+	aWidget label size > maxSize ifTrue: [
+		label := label, '...' ].
+	^ label
+!
+
+tabs
+	^ tabs ifNil: [ tabs := Array new ]
+! !
+
+!TabManager methodsFor: 'actions'!
+
+close
+	opened ifTrue: [
+	'#amber' asJQuery hide.
+	ul asJQuery hide.
+	selectedTab hide.
+	self removeBodyMargin.
+	'body' asJQuery removeClass: 'amberBody'.
+	opened := false ]
+!
+
+closeTab: aWidget
+	self removeTab: aWidget.
+	self selectTab: self tabs last.
+	aWidget remove.
+	self update
+!
+
+newBrowserTab
+	Browser open
+!
+
+onResize: aBlock
+	'#amber' asJQuery resizable: #{
+		'handles' -> 'n'.
+		'resize' -> aBlock.
+		'minHeight' -> 230
+	}
+!
+
+onWindowResize: aBlock
+	window asJQuery resize: aBlock
+!
+
+open
+	opened ifFalse: [
+	'body' asJQuery addClass: 'amberBody'.
+	'#amber' asJQuery show.
+	ul asJQuery show.
+	self updateBodyMargin.
+	selectedTab show.
+	opened := true ]
+!
+
+removeBodyMargin
+	self setBodyMargin: 0
+!
+
+search: aString
+	| searchedClass |
+	searchedClass := Smalltalk globals at: aString.
+		searchedClass isClass
+			ifTrue: [ Browser openOn: searchedClass ]
+			ifFalse: [ ReferencesBrowser search: aString ]
+!
+
+selectTab: aWidget
+	self open.
+	selectedTab := aWidget.
+	self tabs do: [ :each |
+	each hide ].
+	aWidget show.
+	
+	self update
+!
+
+setBodyMargin: anInteger
+	'.amberBody' asJQuery css: 'margin-bottom' put: anInteger asString, 'px'
+!
+
+updateBodyMargin
+	self setBodyMargin: '#amber' asJQuery height
+!
+
+updatePosition
+	'#amber' asJQuery
+		css: 'top' put: '';
+		css: 'bottom' put: '0px'
+! !
+
+!TabManager methodsFor: 'adding/Removing'!
+
+addTab: aWidget
+	self tabs add: aWidget.
+	aWidget appendToJQuery: '#amber' asJQuery.
+	aWidget hide
+!
+
+removeTab: aWidget
+	self tabs remove: aWidget.
+	self update
+! !
+
+!TabManager methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	Inspector register: IDEInspector.
+	opened := true.
+	[ :html | html div id: 'amber' ] appendToJQuery: 'body' asJQuery.
+	'body' asJQuery
+	addClass: 'amberBody'.
+	self appendToJQuery: '#amber' asJQuery.
+	self
+	addTab: IDETranscript current;
+	addTab: Workspace new;
+	addTab: TestRunner new.
+	self selectTab: self tabs last.
+	self
+	onResize: [ self updateBodyMargin; updatePosition ];
+	onWindowResize: [ self updatePosition ]
+! !
+
+!TabManager methodsFor: 'rendering'!
+
+renderOn: html
+	html div id: 'logo'.
+	self renderToolbarOn: html.
+	ul := html ul
+		id: 'amberTabs';
+		yourself.
+	self renderTabs
+!
+
+renderTabFor: aWidget on: html
+	| li |
+	li := html li.
+	selectedTab = aWidget ifTrue: [
+	li class: 'selected' ].
+	li with: [
+		html span class: 'ltab'.
+		html span
+			class: 'mtab';
+			with: [
+				aWidget canBeClosed ifTrue: [
+					html span
+						class: 'close';
+						with: 'x';
+					onClick: [ self closeTab: aWidget ]].
+			html span with: (self labelFor: aWidget) ].
+		html span class: 'rtab' ];
+	onClick: [ self selectTab: aWidget ]
+!
+
+renderTabs
+	ul contents: [ :html |
+		self tabs do: [ :each |
+		self renderTabFor: each on: html ].
+		html li
+		class: 'newtab';
+		with: [
+			html span class: 'ltab'.
+			html span class: 'mtab'; with: ' + '.
+			html span class: 'rtab' ];
+		onClick: [ self newBrowserTab ]]
+!
+
+renderToolbarOn: html
+	html div
+		id: 'amber_toolbar';
+		with: [
+			input := html input
+				class: 'implementors';
+				yourself.
+			input onKeyPress: [ :event |
+				event keyCode = 13 ifTrue: [
+				self search: input asJQuery val ]].
+			html div id: 'amber_close'; onClick: [ self close ]]
+! !
+
+!TabManager methodsFor: 'updating'!
+
+update
+	self renderTabs
+! !
+
+TabManager class instanceVariableNames: 'current'!
+
+!TabManager class methodsFor: 'actions'!
+
+toggleAmberIDE
+	'#amber' asJQuery length = 0
+		ifTrue: [ Browser open ]
+		ifFalse: [
+			('#amber' asJQuery is: ':visible')
+				ifTrue: [ TabManager current close ]
+				ifFalse: [ TabManager current open ] ]
+! !
+
+!TabManager class methodsFor: 'instance creation'!
+
+current
+	^ current ifNil: [ current := super new ]
+!
+
+new
+	self shouldNotImplement
+! !
+
+Widget subclass: #TabWidget
+	instanceVariableNames: 'div'
+	package: 'IDE'!
+
+!TabWidget methodsFor: 'accessing'!
+
+label
+	self subclassResponsibility
+! !
+
+!TabWidget methodsFor: 'actions'!
+
+close
+	TabManager current closeTab: self
+!
+
+hide
+	div asJQuery hide
+!
+
+open
+	TabManager current addTab: self.
+	TabManager current selectTab: self
+!
+
+remove
+	div asJQuery remove
+!
+
+show
+	div asJQuery show
+! !
+
+!TabWidget methodsFor: 'rendering'!
+
+renderBoxOn: html
+!
+
+renderButtonsOn: html
+!
+
+renderOn: html
+	div := html div
+		class: 'amberTool';
+		yourself.
+	self renderTab
+!
+
+renderTab
+	div contents: [ :html |
+		html div
+		class: 'amber_box';
+		with: [ self renderBoxOn: html ].
+		html div
+		class: 'amber_buttons';
+		with: [ self renderButtonsOn: html ]]
+!
+
+update
+	self renderTab
+! !
+
+!TabWidget methodsFor: 'testing'!
+
+canBeClosed
+	^ false
+! !
+
+!TabWidget class methodsFor: 'instance creation'!
+
+open
+	^ self new open
+! !
+
+TabWidget subclass: #Browser
+	instanceVariableNames: 'selectedPackage selectedClass selectedProtocol selectedMethod packagesList classesList protocolsList methodsList sourceArea tabsList selectedTab saveButton classButtons methodButtons unsavedChanges'
+	package: 'IDE'!
+
+!Browser methodsFor: 'accessing'!
+
+classCommentSource
+	^ selectedClass comment
+!
+
+classDeclarationSource
+	| stream |
+	stream := '' writeStream.
+	selectedClass ifNil: [ ^ self classDeclarationTemplate ].
+	stream
+		nextPutAll: selectedClass superclass asString;
+		nextPutAll: ' subclass: #';
+		nextPutAll: selectedClass name;
+		nextPutAll: String lf, String tab;
+		nextPutAll: 'instanceVariableNames: '''.
+	selectedClass instanceVariableNames
+		do: [ :each | stream nextPutAll: each ]
+		separatedBy: [ stream nextPutAll: ' ' ].
+	stream
+		nextPutAll: '''', String lf, String tab;
+		nextPutAll: 'package: ''';
+		nextPutAll: selectedClass category;
+		nextPutAll: ''''.
+	^ stream contents
+!
+
+classDeclarationTemplate
+	^ 'Object subclass: #NameOfSubclass
+	instanceVariableNames: ''''
+	package: ''', self selectedPackage, ''''
+!
+
+classes
+	^ ((Smalltalk classes
+	select: [ :each | each category = selectedPackage ])
+	sort: [ :a :b | a name < b name ]) asSet
+!
+
+declarationSource
+	^ selectedTab = #instance
+	ifTrue: [ self classDeclarationSource ]
+	ifFalse: [ self metaclassDeclarationSource ]
+!
+
+dummyMethodSource
+	^ 'messageSelectorAndArgumentNames
+	"comment stating purpose of message"
+
+	| temporary variable names |
+	statements'
+!
+
+label
+	^ selectedClass
+	ifNil: [ 'Browser (nil)' ]
+	ifNotNil: [ 'Browser: ', selectedClass name ]
+!
+
+metaclassDeclarationSource
+	| stream |
+	stream := '' writeStream.
+	selectedClass ifNotNil: [
+	stream
+		nextPutAll: selectedClass asString;
+		nextPutAll: ' class ';
+		nextPutAll: 'instanceVariableNames: '''.
+	selectedClass class instanceVariableNames
+		do: [ :each | stream nextPutAll: each ]
+		separatedBy: [ stream nextPutAll: ' ' ].
+	stream nextPutAll: '''' ].
+	^ stream contents
+!
+
+methodSource
+	^ selectedMethod
+	ifNil: [ self dummyMethodSource ]
+	ifNotNil: [ selectedMethod source ]
+!
+
+methods
+	| klass |
+	selectedTab = #comment ifTrue: [ ^ #() ].
+	selectedClass ifNotNil: [
+	klass := selectedTab = #instance
+		ifTrue: [ selectedClass ]
+		ifFalse: [ selectedClass class ]].
+	^ (selectedProtocol
+	ifNil: [
+		klass
+		ifNil: [ #() ]
+		ifNotNil: [ klass methodDictionary values ]]
+	ifNotNil: [
+		klass methodsInProtocol: selectedProtocol ]) 
+				sort: [ :a :b | a selector < b selector ]
+!
+
+packages
+	| packages |
+	packages := Array new.
+	Smalltalk classes do: [ :each |
+	(packages includes: each category) ifFalse: [
+		packages add: each category ]].
+	^ packages sort
+!
+
+protocols
+	| klass |
+	selectedClass ifNotNil: [
+	selectedTab = #comment ifTrue: [ ^ #() ].
+	klass := selectedTab = #instance
+		ifTrue: [ selectedClass ]
+		ifFalse: [ selectedClass class ].
+	klass methodDictionary isEmpty ifTrue: [
+		^ Array with: 'not yet classified' ].
+	^ klass protocols ].
+	^ Array new
+!
+
+selectedClass
+	^ selectedClass
+!
+
+selectedPackage
+	^ selectedPackage
+!
+
+source
+	selectedTab = #comment ifFalse: [
+	^ (selectedProtocol notNil or: [ selectedMethod notNil ])
+		ifFalse: [ self declarationSource ]
+		ifTrue: [ self methodSource ]].
+	^ selectedClass
+	ifNil: [ '' ]
+	ifNotNil: [ self classCommentSource ]
+! !
+
+!Browser methodsFor: 'actions'!
+
+addInstanceVariableNamed: aString toClass: aClass
+	ClassBuilder new
+		addSubclassOf: aClass superclass
+		named: aClass name
+		instanceVariableNames: (aClass instanceVariableNames copy add: aString; yourself)
+		package: aClass package name
+!
+
+addNewClass
+	| className |
+	className := self prompt: 'New class'.
+	(className notNil and: [ className notEmpty ]) ifTrue: [
+		Object subclass: className instanceVariableNames: '' package: self selectedPackage.
+			self
+			resetClassesList;
+			updateClassesList.
+		self selectClass: (Smalltalk globals at: className) ]
+!
+
+addNewProtocol
+	| newProtocol |
+	
+	newProtocol := self prompt: 'New method protocol'.
+	
+	(newProtocol notNil and: [ newProtocol notEmpty ]) ifTrue: [
+		selectedMethod protocol: newProtocol.
+		self setMethodProtocol: newProtocol ]
+!
+
+cancelChanges
+	^ unsavedChanges
+	ifTrue: [ self confirm: 'Cancel changes?' ]
+	ifFalse: [ true ]
+!
+
+commitPackage
+	selectedPackage ifNotNil: [
+		(Package named: selectedPackage) commit ]
+!
+
+compile
+	| currentEditLine |
+	self disableSaveButton.
+	currentEditLine := sourceArea editor getCursor.
+	selectedTab = #comment
+	ifTrue: [
+			selectedClass ifNotNil: [
+				self compileClassComment ]]
+	ifFalse: [
+			(selectedProtocol notNil or: [ selectedMethod notNil ])
+				ifFalse: [ self compileDefinition ]
+				ifTrue: [ self compileMethodDefinition ]].
+	sourceArea editor setCursor: currentEditLine.
+!
+
+compileClassComment
+	selectedClass comment: sourceArea val
+!
+
+compileDefinition
+	| newClass |
+	newClass := Compiler new evaluateExpression: sourceArea val.
+	self
+	resetClassesList;
+	updateCategoriesList;
+	updateClassesList.
+	self selectClass: newClass
+!
+
+compileMethodDefinition
+	selectedTab = #instance
+	ifTrue: [ self compileMethodDefinitionFor: selectedClass ]
+	ifFalse: [ self compileMethodDefinitionFor: selectedClass class ]
+!
+
+compileMethodDefinitionFor: aClass
+	| compiler method source node |
+	source := sourceArea val.
+	selectedProtocol ifNil: [ selectedProtocol := selectedMethod protocol ].
+	compiler := Compiler new.
+	compiler source: source.
+	node := compiler parse: source.
+	node isParseFailure ifTrue: [
+	^ self alert: 'PARSE ERROR: ', node reason, ', position: ', node position asString ].
+	compiler currentClass: aClass.
+	method := compiler eval: (compiler compileNode: node).
+	compiler unknownVariables do: [ :each |
+		"Do not try to redeclare javascript's objects"
+		(PlatformInterface existsGlobal: each) ifFalse: [
+		(self confirm: 'Declare ''', each, ''' as instance variable?') ifTrue: [
+			self addInstanceVariableNamed: each toClass: aClass.
+			^ self compileMethodDefinitionFor: aClass ]] ].
+	ClassBuilder new installMethod: method forClass: aClass protocol: selectedProtocol.
+	self updateMethodsList.
+	self selectMethod: method
+!
+
+copyClass
+	| className |
+	className := self prompt: 'Copy class'.
+	(className notNil and: [ className notEmpty ]) ifTrue: [
+		ClassBuilder new copyClass: self selectedClass named: className.
+			self
+			resetClassesList;
+			updateClassesList.
+		self selectClass: (Smalltalk globals at: className) ]
+!
+
+disableSaveButton
+	saveButton ifNotNil: [
+	saveButton at: 'disabled' put: true ].
+	unsavedChanges := false
+!
+
+handleSourceAreaKeyDown: anEvent
+	<if(anEvent.ctrlKey) {
+		if(anEvent.keyCode === 83) { //ctrl+s
+			self._compile();
+			anEvent.preventDefault();
+			return false;
+		}
+	}
+	>
+!
+
+hideClassButtons
+	classButtons asJQuery hide
+!
+
+hideMethodButtons
+	methodButtons asJQuery hide
+!
+
+removeClass
+	(self confirm: 'Do you really want to remove ', selectedClass name, '?')
+	ifTrue: [
+		Smalltalk removeClass: selectedClass.
+		self resetClassesList.
+		self selectClass: nil ]
+!
+
+removeMethod
+	self cancelChanges ifTrue: [
+	(self confirm: 'Do you really want to remove #', selectedMethod selector, '?')
+		ifTrue: [
+		selectedTab = #instance
+			ifTrue: [ selectedClass removeCompiledMethod: selectedMethod ]
+			ifFalse: [ selectedClass class removeCompiledMethod: selectedMethod ].
+		self selectMethod: nil ]]
+!
+
+removePackage
+
+	(self confirm: 'Do you really want to remove the whole package ', selectedPackage, ' with all its classes?')
+	ifTrue: [
+		Smalltalk removePackage: selectedPackage.
+		self updateCategoriesList ]
+!
+
+renameClass
+	| newName |
+	newName := self prompt: 'Rename class ', selectedClass name.
+	(newName notNil and: [ newName notEmpty ]) ifTrue: [
+	selectedClass rename: newName.
+	self
+		updateClassesList;
+		updateSourceAndButtons ]
+!
+
+renamePackage
+
+	| newName |
+	newName := self prompt: 'Rename package ', selectedPackage.
+	newName ifNotNil: [
+	newName notEmpty ifTrue: [
+	Smalltalk renamePackage: selectedPackage to: newName.
+	self updateCategoriesList ]]
+!
+
+search: aString
+	self cancelChanges ifTrue: [ | searchedClass |
+		searchedClass := Smalltalk globals at: aString.
+		searchedClass isClass
+			ifTrue: [ self class openOn: searchedClass ]
+			ifFalse: [ self searchReferencesOf: aString ]]
+!
+
+searchClassReferences
+	ReferencesBrowser search: selectedClass name
+!
+
+searchReferencesOf: aString
+	ReferencesBrowser search: aString
+!
+
+selectCategory: aCategory
+	self cancelChanges ifTrue: [
+	selectedPackage := aCategory.
+	selectedClass := selectedProtocol := selectedMethod := nil.
+	self resetClassesList.
+	self
+		updateCategoriesList;
+		updateClassesList;
+		updateProtocolsList;
+		updateMethodsList;
+		updateSourceAndButtons ]
+!
+
+selectClass: aClass
+	self cancelChanges ifTrue: [
+	selectedClass := aClass.
+	selectedProtocol := selectedMethod := nil.
+	self
+		updateClassesList;
+		updateProtocolsList;
+		updateMethodsList;
+		updateSourceAndButtons ]
+!
+
+selectMethod: aMethod
+	self cancelChanges ifTrue: [
+	selectedMethod := aMethod.
+	self
+		updateProtocolsList;
+		updateMethodsList;
+		updateSourceAndButtons ]
+!
+
+selectProtocol: aString
+	self cancelChanges ifTrue: [
+	selectedProtocol := aString.
+	selectedMethod := nil.
+	self
+		updateProtocolsList;
+		updateMethodsList;
+		updateSourceAndButtons ]
+!
+
+selectTab: aString
+	self cancelChanges ifTrue: [
+	selectedTab := aString.
+	self selectProtocol: nil.
+	self updateTabsList ]
+!
+
+setMethodProtocol: aString
+	self cancelChanges ifTrue: [
+	(self protocols includes: aString)
+		ifFalse: [ self addNewProtocol ]
+		ifTrue: [
+		selectedMethod protocol: aString.
+		selectedProtocol := aString.
+		selectedMethod := selectedMethod.
+		self
+			updateProtocolsList;
+			updateMethodsList;
+			updateSourceAndButtons ]]
+!
+
+showClassButtons
+	classButtons asJQuery show
+!
+
+showMethodButtons
+	methodButtons asJQuery show
+! !
+
+!Browser methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	selectedTab := #instance.
+	selectedPackage := self packages first.
+	unsavedChanges := false
+! !
+
+!Browser methodsFor: 'rendering'!
+
+renderBottomPanelOn: html
+	html div
+	class: 'amber_sourceCode';
+	with: [
+		sourceArea := SourceArea new.
+		sourceArea renderOn: html.
+			sourceArea onKeyDown: [ :e |
+				self handleSourceAreaKeyDown: e ].
+		sourceArea onKeyUp: [ self updateStatus ]]
+!
+
+renderBoxOn: html
+	self
+	renderTopPanelOn: html;
+	renderTabsOn: html;
+	renderBottomPanelOn: html
+!
+
+renderButtonsOn: html
+	saveButton := html button.
+	saveButton
+	with: 'Save';
+	onClick: [ self compile ].
+	methodButtons := html span.
+	classButtons := html span.
+	html div
+	class: 'right';
+	with: [
+		html button
+			with: 'DoIt';
+			onClick: [ sourceArea doIt ].
+		html button
+			with: 'PrintIt';
+			onClick: [ sourceArea printIt ].
+		html button with: 'InspectIt';
+			onClick: [ sourceArea inspectIt ]].
+	self updateSourceAndButtons
+!
+
+renderTabsOn: html
+	tabsList := html ul class: 'amber_tabs amber_browser'.
+	self updateTabsList.
+!
+
+renderTopPanelOn: html
+	html div
+		class: 'top';
+		with: [
+			packagesList := html ul class: 'amber_column browser packages'.
+				html div class: 'amber_packagesButtons'; with: [
+				html button
+					title: 'Commit classes in this package to disk';
+					onClick: [ self commitPackage ];
+					with: 'Commit'.
+					html button
+					title: 'Rename package';
+					onClick: [ self renamePackage ];
+					with: 'Rename'.
+					html button
+					title: 'Remove this package from the system';
+					onClick: [ self removePackage ];
+					with: 'Remove' ].
+			classesList := ClassesList on: self.
+			classesList renderOn: html.
+			protocolsList := html ul class: 'amber_column browser protocols'.
+			methodsList := html ul class: 'amber_column browser methods'.
+			self
+				updateCategoriesList;
+				updateClassesList;
+				updateProtocolsList;
+				updateMethodsList.
+			html div class: 'amber_clear' ]
+! !
+
+!Browser methodsFor: 'testing'!
+
+canBeClosed
+	^ true
+! !
+
+!Browser methodsFor: 'updating'!
+
+resetClassesList
+	classesList resetNodes
+!
+
+updateCategoriesList
+	packagesList contents: [ :html |
+	self packages do: [ :each || li label |
+		each isEmpty
+		ifTrue: [ label := 'Unclassified' ]
+		ifFalse: [ label := each ].
+		li := html li.
+		selectedPackage = each ifTrue: [
+		li class: 'selected' ].
+		li
+		with: label;
+		onClick: [ self selectCategory: each ]] ]
+!
+
+updateClassesList
+	TabManager current update.
+	classesList updateNodes
+!
+
+updateMethodsList
+	methodsList contents: [ :html |
+	self methods do: [ :each || li |
+		li := html li.
+		selectedMethod = each ifTrue: [
+		li class: 'selected' ].
+		li
+		with: each selector;
+		onClick: [ self selectMethod: each ]] ]
+!
+
+updateProtocolsList
+	protocolsList contents: [ :html |
+	self protocols do: [ :each || li |
+		li := html li.
+		selectedProtocol = each ifTrue: [
+		li class: 'selected' ].
+		li
+		with: each;
+		onClick: [ self selectProtocol: each ]] ]
+!
+
+updateSourceAndButtons
+	| currentProtocol |
+
+	self disableSaveButton.
+	classButtons contents: [ :html |
+		html button
+			title: 'Create a new class';
+			onClick: [ self addNewClass ];
+			with: 'New class'.
+		html button
+			with: 'Rename class';
+			onClick: [ self renameClass ].
+		html button
+			with: 'Copy class';
+			onClick: [ self copyClass ].
+		html button
+			with: 'Remove class';
+			onClick: [ self removeClass ].
+		html button
+			with: 'References';
+			onClick: [ self searchClassReferences ]].
+	methodButtons contents: [ :html | | protocolSelect referencesSelect |
+		html button
+			with: 'Remove method';
+			onClick: [ self removeMethod ].
+		protocolSelect := html select.
+				protocolSelect
+			onChange: [ self setMethodProtocol: protocolSelect asJQuery val ];
+			with: [
+				html option
+					with: 'Method protocol';
+					at: 'disabled' put: 'disabled'.
+				html option
+					class: 'important';
+					with: 'New...'.
+				currentProtocol := selectedProtocol.
+				(currentProtocol isNil and: [ selectedMethod notNil ])
+					ifTrue: [ currentProtocol := selectedMethod category ].
+				self protocols do: [ :each | | option |
+					option := html option with: each.
+					currentProtocol = each ifTrue: [ option at: 'selected' put: 'selected' ] ] ].
+		selectedMethod isNil ifFalse: [
+			referencesSelect := html select.
+						referencesSelect
+				onChange: [ self searchReferencesOf: referencesSelect asJQuery val ];
+				with: [ |option|
+					html option
+						with: 'References';
+						at: 'disabled' put: 'disabled';
+						at: 'selected' put: 'selected'.
+					html option
+						class: 'important';
+						with: selectedMethod selector.
+					selectedMethod messageSends sorted do: [ :each |
+						html option with: each ]] ]].
+	selectedMethod isNil
+		ifTrue: [
+			self hideMethodButtons.
+				(selectedClass isNil or: [ selectedProtocol notNil ])
+					ifTrue: [ self hideClassButtons ]
+					ifFalse: [ self showClassButtons ]]
+		ifFalse: [
+			self hideClassButtons.
+			self showMethodButtons ].
+	sourceArea val: self source
+!
+
+updateStatus
+	sourceArea val = self source
+		ifTrue: [
+			saveButton ifNotNil: [
+				saveButton at: 'disabled' put: true ].
+				unsavedChanges := false ]
+		ifFalse: [
+			saveButton ifNotNil: [
+				saveButton removeAt: 'disabled' ].
+			unsavedChanges := true ]
+!
+
+updateTabsList
+	tabsList contents: [ :html || li |
+	li := html li.
+	selectedTab = #instance ifTrue: [ li class: 'selected' ].
+	li
+		with: [
+		html span class: 'ltab'.
+		html span class: 'mtab'; with: 'Instance'.
+		html span class: 'rtab' ];
+		onClick: [ self selectTab: #instance ].
+	li := html li.
+	selectedTab = #class ifTrue: [ li class: 'selected' ].
+	li
+		with: [
+		html span class: 'ltab'.
+		html span class: 'mtab'; with: 'Class'.
+		html span class: 'rtab' ];
+		onClick: [ self selectTab: #class ].
+	li := html li.
+	selectedTab = #comment ifTrue: [ li class: 'selected' ].
+	li
+		with: [
+		html span class: 'ltab'.
+		html span class: 'mtab'; with: 'Comment'.
+		html span class: 'rtab' ];
+		onClick: [ self selectTab: #comment ]]
+! !
+
+!Browser class methodsFor: 'convenience'!
+
+open
+	self new open
+!
+
+openOn: aClass
+	^ self new
+	open;
+	selectCategory: aClass category;
+	selectClass: aClass
+! !
+
+TabWidget subclass: #Debugger
+	instanceVariableNames: 'error selectedContext sourceArea ul ul2 inspector saveButton unsavedChanges selectedVariable selectedVariableName inspectButton'
+	package: 'IDE'!
+
+!Debugger methodsFor: 'accessing'!
+
+allVariables
+	| all |
+	all := Dictionary new.
+
+	self receiver class allInstanceVariableNames do: [ :each |
+		all at: each put: (self receiver instVarAt: each) ].
+	
+	selectedContext locals keysAndValuesDo: [ :key :value |
+		all at: key put: value ].
+	
+	^ all
+!
+
+error
+	^ error
+!
+
+error: anError
+	error := anError
+!
+
+label
+	^ '[ Debugger ]'
+!
+
+method
+	^ selectedContext method
+!
+
+receiver
+	^ selectedContext receiver
+!
+
+source
+	^ self method
+		ifNil: [ 'Method doesn''t exist!!' ]
+		ifNotNil: [ self method source ]
+! !
+
+!Debugger methodsFor: 'actions'!
+
+inspectSelectedVariable
+	selectedVariable inspect
+!
+
+proceed
+	self close.
+	selectedContext receiver perform: selectedContext selector withArguments: selectedContext locals
+!
+
+save
+	| protocol |
+	protocol := (selectedContext receiver class methodDictionary at: selectedContext selector) category.
+	selectedContext receiver class compile: sourceArea val protocol: protocol.
+	self updateStatus
+!
+
+selectContext: aContext
+	selectedContext := aContext.
+	selectedVariable := nil.
+	selectedVariableName := nil.
+	self
+		updateContextsList;
+		updateSourceArea;
+		updateInspector;
+		updateVariablesList;
+		updateStatus
+!
+
+selectVariable: anObject named: aString
+	
+	selectedVariable := anObject.
+	selectedVariableName := aString.
+	inspector contents: [ :html | html with: anObject printString ].
+	self updateVariablesList
+! !
+
+!Debugger methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	unsavedChanges = false
+! !
+
+!Debugger methodsFor: 'rendering'!
+
+renderBottomPanelOn: html
+	html div
+		class: 'amber_sourceCode debugger';
+		with: [
+			sourceArea := SourceArea new.
+			sourceArea renderOn: html ].
+	ul2 := html ul class: 'amber_column debugger variables'.
+	inspector := html div class: 'amber_column debugger inspector'.
+	sourceArea
+		onKeyUp: [ self updateStatus ]
+!
+
+renderBoxOn: html
+	self
+		renderTopPanelOn: html;
+		renderBottomPanelOn: html
+!
+
+renderButtonsOn: html
+	saveButton := html button
+		with: 'Save';
+		onClick: [ self save ].
+	html button
+		with: 'DoIt';
+		onClick: [ sourceArea doIt ].
+	html button
+		with: 'PrintIt';
+		onClick: [ sourceArea printIt ].
+	html button
+		with: 'InspectIt';
+		onClick: [ sourceArea inspectIt ].
+	html button
+		with: 'Proceed';
+		onClick: [ self proceed ].
+	html button
+		with: 'Abandon';
+		onClick: [ self close ].
+	inspectButton := html button
+		class: 'amber_button debugger inspect';
+		with: 'Inspect';
+		onClick: [ self inspectSelectedVariable ].
+	self
+		updateSourceArea;
+		updateStatus;
+		updateVariablesList;
+		updateInspector
+!
+
+renderContext: aContext on: html
+	| li |
+	li := html li.
+	selectedContext = aContext ifTrue: [
+		li class: 'selected' ].
+	li
+		with: aContext asString;
+		onClick: [ self selectContext: aContext ].
+	aContext outerContext ifNotNil: [ self renderContext: aContext outerContext on: html ]
+!
+
+renderTopPanelOn: html
+	selectedContext := self error context.
+	html div
+		class: 'top';
+		with: [
+			html div
+				class: 'label';
+				with: self error messageText.
+			ul := html ul
+				class: 'amber_column debugger contexts';
+				with: [ self renderContext: self error context on: html ]]
+! !
+
+!Debugger methodsFor: 'testing'!
+
+canBeClosed
+	^ true
+! !
+
+!Debugger methodsFor: 'updating'!
+
+updateContextsList
+	ul contents: [ :html |
+		self renderContext: self error context on: html ]
+!
+
+updateInspector
+	inspector contents: [ :html | ]
+!
+
+updateSourceArea
+	sourceArea val: self source
+!
+
+updateStatus
+	sourceArea val = self source
+		ifTrue: [
+			saveButton ifNotNil: [
+				saveButton at: 'disabled' put: true ].
+			unsavedChanges := false ]
+		ifFalse: [
+			saveButton ifNotNil: [
+				saveButton removeAt: 'disabled' ].
+			unsavedChanges := true ]
+!
+
+updateVariablesList
+	ul2 contents: [ :html | | li |
+		li := html li
+			with: 'self';
+			onClick: [ self selectVariable: self receiver named: 'self' ].
+				selectedVariableName = 'self' ifTrue: [ li class: 'selected' ].
+		
+		self allVariables keysAndValuesDo: [ :key :value |
+						li := html li
+							with: key;
+							onClick: [ self selectVariable: value named: key ].
+						selectedVariableName = key ifTrue: [
+							li class: 'selected' ] ] ].
+							
+	selectedVariable
+		ifNil: [ inspectButton at: 'disabled' put: true ]
+		ifNotNil: [ inspectButton removeAt: 'disabled' ]
+! !
+
+TabWidget subclass: #IDEInspector
+	instanceVariableNames: 'label variables object selectedVariable variablesList valueTextarea diveButton sourceArea'
+	package: 'IDE'!
+
+!IDEInspector methodsFor: 'accessing'!
+
+label
+	^ label ifNil: [ 'Inspector (nil)' ]
+!
+
+selectedVariable
+	^ selectedVariable
+!
+
+selectedVariable: aString
+	selectedVariable := aString
+!
+
+setLabel: aString
+	label := aString
+!
+
+setVariables: aCollection
+	variables := aCollection
+!
+
+sourceArea
+	^ sourceArea
+!
+
+variables
+	^ variables
+! !
+
+!IDEInspector methodsFor: 'actions'!
+
+dive
+	(self variables at: self selectedVariable) inspect
+!
+
+inspect: anObject
+	object := anObject.
+	variables := #().
+	object inspectOn: self
+!
+
+refresh
+	self
+		inspect: object;
+		updateVariablesList;
+		updateValueTextarea
+! !
+
+!IDEInspector methodsFor: 'rendering'!
+
+renderBottomPanelOn: html
+	html div
+	class: 'amber_sourceCode';
+	with: [
+		sourceArea := SourceArea new
+		receiver: object;
+		onDoIt: [ self refresh ];
+		yourself.
+			sourceArea renderOn: html ]
+!
+
+renderBoxOn: html
+	self
+		renderTopPanelOn: html;
+		renderBottomPanelOn: html
+!
+
+renderButtonsOn: html
+	html button
+		with: 'DoIt';
+		onClick: [ self sourceArea doIt ].
+	html button
+		with: 'PrintIt';
+		onClick: [ self sourceArea printIt ].
+	html button
+		with: 'InspectIt';
+		onClick: [ self sourceArea inspectIt ].
+	self updateButtons
+!
+
+renderTopPanelOn: html
+	html div
+		class: 'top';
+		with: [
+			variablesList := html ul class: 'amber_column variables'.
+			valueTextarea := html textarea class: 'amber_column value'; at: 'readonly' put: 'readonly'; yourself.
+			html div class: 'amber_tabs inspector'; with: [
+				html button
+					class: 'amber_button inspector refresh';
+					with: 'Refresh';
+					onClick: [ self refresh ].
+				diveButton := html button
+					class: 'amber_button inspector dive';
+					with: 'Dive';
+					onClick: [ self dive ]].
+			html div class: 'amber_clear' ].
+	self
+		updateVariablesList;
+		updateValueTextarea.
+! !
+
+!IDEInspector methodsFor: 'testing'!
+
+canBeClosed
+	^ true
+! !
+
+!IDEInspector methodsFor: 'updating'!
+
+selectVariable: aString
+	self selectedVariable: aString.
+	self
+		updateVariablesList;
+		updateValueTextarea;
+		updateButtons
+!
+
+updateButtons
+	(self selectedVariable notNil and: [ (self variables at: self selectedVariable) notNil ])
+		ifFalse: [ diveButton at: 'disabled' put: true ]
+		ifTrue: [ diveButton removeAt: 'disabled' ]
+!
+
+updateValueTextarea
+	valueTextarea asJQuery val: (self selectedVariable isNil
+		ifTrue: [ '' ]
+		ifFalse: [ (self variables at: self selectedVariable) printString ])
+!
+
+updateVariablesList
+	variablesList contents: [ :html |
+		self variables keysDo: [ :each || li |
+			li := html li.
+			li
+				with: each;
+				onClick: [ self selectVariable: each ].
+			self selectedVariable = each ifTrue: [
+				li class: 'selected' ]] ]
+! !
+
+!IDEInspector class methodsFor: 'instance creation'!
+
+inspect: anObject
+	^ self new
+		inspect: anObject;
+		open;
+		yourself
+!
+
+on: anObject
+	^ self new
+		inspect: anObject;
+		yourself
+! !
+
+TabWidget subclass: #IDETranscript
+	instanceVariableNames: 'textarea'
+	package: 'IDE'!
+
+!IDETranscript methodsFor: 'accessing'!
+
+label
+	^ 'Transcript'
+! !
+
+!IDETranscript methodsFor: 'actions'!
+
+clear
+	textarea asJQuery val: ''
+!
+
+cr
+	textarea asJQuery val: textarea asJQuery val, String cr.
+!
+
+open
+	TabManager current
+	open;
+	selectTab: self
+!
+
+show: anObject
+	textarea ifNil: [ self open ].
+	textarea asJQuery val: textarea asJQuery val, anObject asString.
+! !
+
+!IDETranscript methodsFor: 'rendering'!
+
+renderBoxOn: html
+	textarea := html textarea.
+	textarea
+	class: 'amber_transcript';
+	at: 'spellcheck' put: 'false'
+!
+
+renderButtonsOn: html
+	html button
+	with: 'Clear transcript';
+	onClick: [ self clear ]
+! !
+
+IDETranscript class instanceVariableNames: 'current'!
+
+!IDETranscript class methodsFor: 'initialization'!
+
+initialize
+	Transcript register: self current
+! !
+
+!IDETranscript class methodsFor: 'instance creation'!
+
+current
+	^ current ifNil: [ current := super new ]
+!
+
+new
+	self shouldNotImplement
+!
+
+open
+	TabManager current
+		open;
+		selectTab: self current
+! !
+
+TabWidget subclass: #ProgressBar
+	instanceVariableNames: 'percent progressDiv div'
+	package: 'IDE'!
+
+!ProgressBar methodsFor: 'accessing'!
+
+percent
+	^ percent ifNil: [ 0 ]
+!
+
+percent: aNumber
+	percent := aNumber
+! !
+
+!ProgressBar methodsFor: 'rendering'!
+
+renderOn: html
+	div := html div
+		class: 'progress_bar';
+		yourself.
+	self renderProgressBar
+!
+
+renderProgressBar
+	div contents: [ :html |
+		html div
+			class: 'progress';
+			style: 'width:', self percent asString, '%' ]
+! !
+
+!ProgressBar methodsFor: 'updating'!
+
+updatePercent: aNumber
+	self percent: aNumber.
+	self renderProgressBar
+! !
+
+TabWidget subclass: #ReferencesBrowser
+	instanceVariableNames: 'implementors senders implementorsList input timer selector sendersList referencedClasses referencedClassesList matches matchesList'
+	package: 'IDE'!
+
+!ReferencesBrowser methodsFor: 'accessing'!
+
+classesAndMetaclasses
+	^ Smalltalk classes, (Smalltalk classes collect: [ :each | each class ])
+!
+
+implementors
+	^ implementors ifNil: [ implementors := Array new ]
+!
+
+label
+	^ '[ References ]'
+!
+
+matches
+	^ matches ifNil: [ matches := Array new ]
+!
+
+referencedClasses
+	^ referencedClasses ifNil: [ referencedClasses := Array new ]
+!
+
+selector
+	^ selector
+!
+
+senders
+	^ senders ifNil: [ senders := Array new ]
+! !
+
+!ReferencesBrowser methodsFor: 'actions'!
+
+openBrowserOn: aMethod
+	| browser |
+	browser := Browser openOn: (aMethod methodClass isMetaclass
+		ifTrue: [ aMethod methodClass instanceClass ] ifFalse: [ aMethod methodClass ]).
+	aMethod methodClass isMetaclass ifTrue: [ browser selectTab: #class ].
+	browser
+		selectProtocol: aMethod category;
+		selectMethod: aMethod
+!
+
+search: aString
+	self
+		searchReferencesFor: aString;
+		updateImplementorsList;
+		updateSendersList;
+		updateReferencedClassesList;
+		updateMatchesList
+!
+
+searchMethodSource
+	| regex |
+	regex := selector allButFirst.
+	self classesAndMetaclasses do: [ :each |
+		each methodDictionary valuesDo: [ :value |
+			(value source match: regex) ifTrue: [
+				self matches add: value ]] ]
+!
+
+searchReferencedClasses
+	self classesAndMetaclasses do: [ :each |
+		each methodDictionary valuesDo: [ :value |
+			(value referencedClasses includes: selector) ifTrue: [
+				self referencedClasses add: value ]] ]
+!
+
+searchReferencesFor: aString
+	selector := aString.
+	implementors := Array new.
+	senders := Array new.
+	referencedClasses := Array new.
+	matches := Array new.
+	self searchMethodSource.
+	(selector match: '^[A-Z]')
+		ifFalse: [ self searchSelectorReferences ]
+		ifTrue: [ self searchReferencedClasses ]
+!
+
+searchSelectorReferences
+	self classesAndMetaclasses do: [ :each |
+		each methodDictionary keysAndValuesDo: [ :key :value |
+			key = selector ifTrue: [ self implementors add: value ].
+			(value messageSends includes: selector) ifTrue: [
+				self senders add: value ]] ]
+! !
+
+!ReferencesBrowser methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	selector := ''
+! !
+
+!ReferencesBrowser methodsFor: 'private'!
+
+setInputEvents
+	input
+		onKeyUp: [ timer := [ self search: input asJQuery val ] valueWithTimeout: 100 ];
+		onKeyDown: [ timer ifNotNil: [ timer clearTimeout ]]
+! !
+
+!ReferencesBrowser methodsFor: 'rendering'!
+
+renderBoxOn: html
+	self
+		renderInputOn: html;
+		renderImplementorsOn: html;
+		renderSendersOn: html;
+		renderReferencedClassesOn: html;
+		renderMatchesOn: html
+!
+
+renderImplementorsOn: html
+	implementorsList := html ul class: 'amber_column implementors'.
+	self updateImplementorsList
+!
+
+renderInputOn: html
+	input := html input
+		class: 'implementors';
+		yourself.
+	input asJQuery val: selector.
+	self setInputEvents
+!
+
+renderMatchesOn: html
+	matchesList := html ul class: 'amber_column matches'.
+	self updateMatchesList
+!
+
+renderReferencedClassesOn: html
+	referencedClassesList := html ul class: 'amber_column referenced_classes'.
+	self updateReferencedClassesList
+!
+
+renderSendersOn: html
+	sendersList := html ul class: 'amber_column senders'.
+	self updateSendersList
+! !
+
+!ReferencesBrowser methodsFor: 'testing'!
+
+canBeClosed
+	^ true
+! !
+
+!ReferencesBrowser methodsFor: 'updating'!
+
+updateImplementorsList
+	implementorsList contents: [ :html |
+	html li
+		class: 'column_label';
+		with: 'Implementors (', self implementors size asString, ')';
+		style: 'font-weight: bold'.
+	self implementors do: [ :each || li |
+		li := html li.
+		li
+		with: (each methodClass asString, ' >> ', self selector);
+		onClick: [ self openBrowserOn: each ]] ]
+!
+
+updateMatchesList
+	matchesList contents: [ :html |
+	html li
+		class: 'column_label';
+		with: 'Regex matches (', self matches size asString, ')';
+		style: 'font-weight: bold'.
+	self matches do: [ :each || li |
+		li := html li.
+		li
+		with: (each methodClass asString, ' >> ', each selector);
+		onClick: [ self openBrowserOn: each ]] ]
+!
+
+updateReferencedClassesList
+	referencedClassesList contents: [ :html |
+	html li
+		class: 'column_label';
+		with: 'Class references (', self referencedClasses size asString, ')';
+		style: 'font-weight: bold'.
+	self referencedClasses do: [ :each |
+		html li
+			with: (each methodClass asString, ' >> ', each selector);
+			onClick: [ self openBrowserOn: each ]] ]
+!
+
+updateSendersList
+	sendersList contents: [ :html |
+	html li
+		class: 'column_label';
+		with: 'Senders (', self senders size asString, ')';
+		style: 'font-weight: bold'.
+	self senders do: [ :each |
+		html li
+			with: (each methodClass asString, ' >> ', each selector);
+			onClick: [ self openBrowserOn: each ]] ]
+! !
+
+!ReferencesBrowser class methodsFor: 'instance creation'!
+
+search: aString
+	^ self new
+		searchReferencesFor: aString;
+		open
+! !
+
+TabWidget subclass: #TestRunner
+	instanceVariableNames: 'selectedCategories packagesList selectedClasses classesList selectedMethods progressBar methodsList result statusDiv'
+	package: 'IDE'!
+
+!TestRunner methodsFor: 'accessing'!
+
+allClasses
+	^ TestCase allSubclasses select: [ :each | each isAbstract not ]
+!
+
+classes
+	^ (self allClasses
+	select: [ :each | self selectedCategories includes: each category ])
+	sort: [ :a :b | a name > b name ]
+!
+
+label
+	^ 'SUnit'
+!
+
+packages
+	| packages |
+	packages := Array new.
+	self allClasses do: [ :each |
+	(packages includes: each category) ifFalse: [
+		packages add: each category ]].
+	^ packages sort
+!
+
+progressBar
+	^ progressBar ifNil: [ progressBar := ProgressBar new ]
+!
+
+result
+	^ result
+!
+
+selectedCategories
+	^ selectedCategories ifNil: [ selectedCategories := Array new ]
+!
+
+selectedClasses
+	^ selectedClasses ifNil: [ selectedClasses := Array new ]
+!
+
+statusInfo
+	^ self printTotal, self printPasses, self printErrors, self printFailures
+!
+
+testCases
+	| testCases |
+	testCases := #().
+	(self selectedClasses
+		select: [ :each | self selectedCategories includes: each category ])
+		do: [ :each | testCases addAll: each buildSuite ].
+	^ testCases
+! !
+
+!TestRunner methodsFor: 'actions'!
+
+performFailure: aTestCase
+	aTestCase runCase
+!
+
+run: aCollection
+| worker |
+	worker := TestSuiteRunner on: aCollection.
+	result := worker result.
+	worker announcer on: ResultAnnouncement do: [ :ann |
+		ann result == result ifTrue: [
+			self progressBar updatePercent: result runs / result total * 100.
+			self updateStatusDiv.
+			self updateMethodsList
+		]
+	].
+	worker run
+!
+
+selectAllCategories
+	self packages do: [ :each |
+		(selectedCategories includes: each) ifFalse: [
+			self selectedCategories add: each ]].
+	self
+		updateCategoriesList;
+		updateClassesList
+!
+
+selectAllClasses
+	self classes do: [ :each |
+		(selectedClasses includes: each) ifFalse: [
+			self selectedClasses add: each ]].
+	self
+		updateCategoriesList;
+		updateClassesList
+!
+
+toggleCategory: aCategory
+	(self isSelectedCategory: aCategory)
+		ifFalse: [ selectedCategories add: aCategory ]
+		ifTrue: [ selectedCategories remove: aCategory ].
+	self
+		updateCategoriesList;
+		updateClassesList
+!
+
+toggleClass: aClass
+	(self isSelectedClass: aClass)
+		ifFalse: [ selectedClasses add: aClass ]
+		ifTrue: [ selectedClasses remove: aClass ].
+	self
+		updateClassesList
+! !
+
+!TestRunner methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	result := TestResult new
+! !
+
+!TestRunner methodsFor: 'printing'!
+
+printErrors
+	^ self result errors size asString , ' errors, '
+!
+
+printFailures
+	^ self result failures size asString, ' failures'
+!
+
+printPasses
+	^ (self result runs - self result errors size - self result failures size) asString , ' passes, '
+!
+
+printTotal
+	^ self result total asString, ' runs, '
+! !
+
+!TestRunner methodsFor: 'rendering'!
+
+renderBoxOn: html
+	self
+	renderCategoriesOn: html;
+	renderClassesOn: html;
+	renderResultsOn: html
+!
+
+renderButtonsOn: html
+	html button
+	with: 'Run selected';
+	onClick: [ self run: self testCases ]
+!
+
+renderCategoriesOn: html
+	packagesList := html ul class: 'amber_column sunit packages'.
+	self updateCategoriesList
+!
+
+renderClassesOn: html
+	classesList := html ul class: 'amber_column sunit classes'.
+	self updateClassesList
+!
+
+renderErrorsOn: html
+	self result errors do: [ :each |
+		html li
+			class: 'errors';
+			with: each class name, ' >> ', each selector;
+						onClick: [ self performFailure: each ]]
+!
+
+renderFailuresOn: html
+	self result failures do: [ :each |
+		html li
+			class: 'failures';
+			with: each class name, ' >> ', each selector;
+						onClick: [ self performFailure: each ]]
+!
+
+renderResultsOn: html
+	statusDiv := html div.
+	html with: self progressBar.
+	methodsList := html ul class: 'amber_column sunit results'.
+	self updateMethodsList.
+	self updateStatusDiv
+! !
+
+!TestRunner methodsFor: 'testing'!
+
+isSelectedCategory: aCategory
+	^ (self selectedCategories includes: aCategory)
+!
+
+isSelectedClass: aClass
+	^ (self selectedClasses includes: aClass)
+! !
+
+!TestRunner methodsFor: 'updating'!
+
+updateCategoriesList
+	packagesList contents: [ :html |
+		html li
+		class: 'all';
+		with: 'All';
+		onClick: [ self selectAllCategories ].
+	self packages do: [ :each || li |
+		li := html li.
+		(self selectedCategories includes: each) ifTrue: [
+		li class: 'selected' ].
+		li
+		with: each;
+		onClick: [ self toggleCategory: each ]] ]
+!
+
+updateClassesList
+	classesList contents: [ :html |
+	(self selectedCategories isEmpty) ifFalse: [
+		html li
+			class: 'all';
+			with: 'All';
+			onClick: [ self selectAllClasses ]].
+	self classes do: [ :each || li |
+		li := html li.
+		(self selectedClasses includes: each) ifTrue: [
+			li class: 'selected' ].
+		li
+			with: each name;
+			onClick: [ self toggleClass: each ]] ]
+!
+
+updateMethodsList
+	methodsList contents: [ :html |
+		self renderErrorsOn: html.
+				self renderFailuresOn: html ]
+!
+
+updateStatusDiv
+	statusDiv class: 'sunit status ', result status.
+	statusDiv contents: [ :html |
+		html span with: self statusInfo ]
+! !
+
+TabWidget subclass: #Workspace
+	instanceVariableNames: 'sourceArea'
+	package: 'IDE'!
+
+!Workspace methodsFor: 'accessing'!
+
+label
+	^ 'Workspace'
+! !
+
+!Workspace methodsFor: 'actions'!
+
+clearWorkspace
+	sourceArea clear
+!
+
+doIt
+	sourceArea doIt
+!
+
+fileIn
+	sourceArea fileIn
+!
+
+inspectIt
+	sourceArea inspectIt
+!
+
+printIt
+	sourceArea printIt
+!
+
+show
+	super show.
+	sourceArea focus.
+! !
+
+!Workspace methodsFor: 'rendering'!
+
+renderBoxOn: html
+	sourceArea := SourceArea new.
+	sourceArea renderOn: html
+!
+
+renderButtonsOn: html
+	html button
+	with: 'DoIt';
+	title: 'ctrl+d';
+	onClick: [ self doIt ].
+	html button
+	with: 'PrintIt';
+	title: 'ctrl+p';
+	onClick: [ self printIt ].
+	html button
+	with: 'InspectIt';
+	title: 'ctrl+i';
+	onClick: [ self inspectIt ].
+	html button
+	with: 'FileIn';
+	title: 'ctrl+f';
+	onClick: [ self fileIn ].
+	html button
+	with: 'Clear workspace';
+	onClick: [ self clearWorkspace ]
+! !
+
+!AssociativeCollection methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	variables at: '#keys' put: self keys.
+	self keysAndValuesDo: [ :key :value |
+		variables at: key put: value ].
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!Collection methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	self withIndexDo: [ :each :i |
+		variables at: i put: each ].
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!Date methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	variables at: '#year' put: self year.
+	variables at: '#month' put: self month.
+	variables at: '#day' put: self day.
+	variables at: '#hours' put: self hours.
+	variables at: '#minutes' put: self minutes.
+	variables at: '#seconds' put: self seconds.
+	variables at: '#milliseconds' put: self milliseconds.
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!MethodContext methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	variables at: '#home' put: self home.
+	variables at: '#receiver' put: self receiver.
+	variables at: '#selector' put: self selector.
+	variables at: '#locals' put: self locals.
+	self class instanceVariableNames do: [ :each |
+		variables at: each put: (self instVarAt: each) ].
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!Set methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| variables i |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	i := 1.
+	self do: [ :each |
+		variables at: i put: each.
+		i := i + 1 ].
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!String methodsFor: '*IDE'!
+
+inspectOn: anInspector
+	| label |
+	super inspectOn: anInspector.
+	self printString size > 30
+		ifTrue: [ label := (self printString copyFrom: 1 to: 30), '...''' ]
+		ifFalse: [ label := self printString ].
+	anInspector setLabel: label
+! !
+

+ 1241 - 0
bower_components/amber/src/Kernel-Announcements.js

@@ -0,0 +1,1241 @@
+define("amber_core/Kernel-Announcements", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Announcements');
+$core.packages["Kernel-Announcements"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('AnnouncementSubscription', $globals.Object, ['valuable', 'announcementClass'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AnnouncementSubscription.comment="I am a single entry in a subscription registry of an `Announcer`.\x0aSeveral subscriptions by the same object is possible.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "announcementClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@announcementClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "announcementClass\x0a\x09^ announcementClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "announcementClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@announcementClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "announcementClass: aClass\x0a\x09announcementClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "block",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=self._valuable();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"block",{},$globals.AnnouncementSubscription)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "block\x0a\x09\x22Use #valuable instead\x22\x0a\x09\x0a\x09self deprecatedAPI.\x0a\x09^ self valuable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "valuable"]
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "block:",
+protocol: 'accessing',
+fn: function (aValuable){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._deprecatedAPI();
+self._valuable_(aValuable);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"block:",{aValuable:aValuable},$globals.AnnouncementSubscription)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aValuable"],
+source: "block: aValuable\x0a\x09\x22Use #valuable instead\x22\x0a\x09\x0a\x09self deprecatedAPI.\x0a\x09self valuable: aValuable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "valuable:"]
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "deliver:",
+protocol: 'announcing',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._handlesAnnouncement_(anAnnouncement);
+if($core.assert($1)){
+$recv(self._valuable())._value_(anAnnouncement);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deliver:",{anAnnouncement:anAnnouncement},$globals.AnnouncementSubscription)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "deliver: anAnnouncement\x0a\x09(self handlesAnnouncement: anAnnouncement)\x0a\x09\x09ifTrue: [ self valuable value: anAnnouncement ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "handlesAnnouncement:", "value:", "valuable"]
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "handlesAnnouncement:",
+protocol: 'announcing',
+fn: function (anAnnouncement){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$1,$receiver;
+$3=$recv($Smalltalk())._globals();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["globals"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(self._announcementClass())._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._at_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+return false;
+} else {
+var class_;
+class_=$receiver;
+$1=$recv($recv($recv($Smalltalk())._globals())._at_($recv($recv($recv(anAnnouncement)._class())._theNonMetaClass())._name()))._includesBehavior_(class_);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"handlesAnnouncement:",{anAnnouncement:anAnnouncement},$globals.AnnouncementSubscription)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "handlesAnnouncement: anAnnouncement\x0a\x09\x22anAnnouncement might be announced from within another Amber environment\x22\x0a\x09\x0a\x09^ (Smalltalk globals at: self announcementClass name)\x0a\x09\x09ifNil: [ ^ false ]\x0a\x09\x09ifNotNil: [ :class |\x0a\x09\x09(Smalltalk globals at: anAnnouncement class theNonMetaClass name) includesBehavior: class ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "at:", "globals", "name", "announcementClass", "includesBehavior:", "theNonMetaClass", "class"]
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._valuable())._receiver();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"receiver",{},$globals.AnnouncementSubscription)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ self valuable receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["receiver", "valuable"]
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "valuable",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@valuable"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "valuable\x0a\x09^ valuable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementSubscription);
+
+$core.addMethod(
+$core.method({
+selector: "valuable:",
+protocol: 'accessing',
+fn: function (aValuable){
+var self=this;
+self["@valuable"]=aValuable;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aValuable"],
+source: "valuable: aValuable\x0a\x09valuable := aValuable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementSubscription);
+
+
+
+$core.addClass('AnnouncementValuable', $globals.Object, ['valuable', 'receiver'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AnnouncementValuable.comment="I wrap `valuable` objects (typically instances of `BlockClosure`) with a `receiver` to be able to unregister subscriptions based on a `receiver`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@receiver"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementValuable);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@receiver"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "receiver: anObject\x0a\x09receiver := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementValuable);
+
+$core.addMethod(
+$core.method({
+selector: "valuable",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@valuable"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "valuable\x0a\x09^ valuable",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementValuable);
+
+$core.addMethod(
+$core.method({
+selector: "valuable:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@valuable"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "valuable: anObject\x0a\x09valuable := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AnnouncementValuable);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._valuable())._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.AnnouncementValuable)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ self valuable value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value", "valuable"]
+}),
+$globals.AnnouncementValuable);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'evaluating',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._valuable())._value_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{anObject:anObject},$globals.AnnouncementValuable)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "value: anObject\x0a\x09^ self valuable value: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:", "valuable"]
+}),
+$globals.AnnouncementValuable);
+
+
+
+$core.addClass('Announcer', $globals.Object, ['registry', 'subscriptions'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Announcer.comment="I hold annoncement subscriptions (instances of `AnnouncementSubscription`) in a private registry.\x0aI announce (trigger) announces, which are then dispatched to all subscriptions.\x0a\x0aThe code is based on the announcements as [described by Vassili Bykov](http://www.cincomsmalltalk.com/userblogs/vbykov/blogView?searchCategory=Announcements%20Framework).\x0a\x0a## API\x0a\x0aUse `#announce:` to trigger an announcement.\x0a\x0aUse `#on:do:` or `#on:send:to:` to register subscriptions.\x0a\x0aWhen using `#on:send:to:`, unregistration can be done with `#unregister:`.\x0a\x0a## Usage example:\x0a\x0a    SystemAnnouncer current\x0a        on: ClassAdded\x0a        do: [ :ann | window alert: ann theClass name, ' added' ].";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "announce:",
+protocol: 'announcing',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@subscriptions"])._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._deliver_(anAnnouncement);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"announce:",{anAnnouncement:anAnnouncement},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "announce: anAnnouncement\x0a\x09subscriptions do: [ :each |\x0a\x09\x09each deliver: anAnnouncement ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "deliver:"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Announcer.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@subscriptions"]=$recv($OrderedCollection())._new();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09subscriptions := OrderedCollection new",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "on:do:",
+protocol: 'subscribing',
+fn: function (aClass,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._on_do_for_(aClass,aBlock,nil);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:do:",{aClass:aClass,aBlock:aBlock},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aBlock"],
+source: "on: aClass do: aBlock\x0a\x09self on: aClass do: aBlock for: nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["on:do:for:"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "on:do:for:",
+protocol: 'subscribing',
+fn: function (aClass,aBlock,aReceiver){
+var self=this;
+function $AnnouncementSubscription(){return $globals.AnnouncementSubscription||(typeof AnnouncementSubscription=="undefined"?nil:AnnouncementSubscription)}
+function $AnnouncementValuable(){return $globals.AnnouncementValuable||(typeof AnnouncementValuable=="undefined"?nil:AnnouncementValuable)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$4,$6,$7,$5,$8,$2;
+$1=self["@subscriptions"];
+$3=$recv($AnnouncementSubscription())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$4=$3;
+$6=$recv($AnnouncementValuable())._new();
+$recv($6)._valuable_(aBlock);
+$recv($6)._receiver_(aReceiver);
+$7=$recv($6)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$5=$7;
+$recv($4)._valuable_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["valuable:"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._announcementClass_(aClass);
+$8=$recv($3)._yourself();
+$2=$8;
+$recv($1)._add_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:do:for:",{aClass:aClass,aBlock:aBlock,aReceiver:aReceiver},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aBlock", "aReceiver"],
+source: "on: aClass do: aBlock for: aReceiver\x0a\x09subscriptions add: (AnnouncementSubscription new\x0a\x09\x09valuable: (AnnouncementValuable new\x0a\x09\x09\x09valuable: aBlock;\x0a\x09\x09\x09receiver: aReceiver;\x0a\x09\x09\x09yourself);\x0a\x09\x09announcementClass: aClass;\x0a\x09\x09yourself)",
+referencedClasses: ["AnnouncementSubscription", "AnnouncementValuable"],
+//>>excludeEnd("ide");
+messageSends: ["add:", "valuable:", "new", "receiver:", "yourself", "announcementClass:"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "on:doOnce:",
+protocol: 'subscribing',
+fn: function (aClass,aBlock){
+var self=this;
+var subscription;
+function $AnnouncementSubscription(){return $globals.AnnouncementSubscription||(typeof AnnouncementSubscription=="undefined"?nil:AnnouncementSubscription)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($AnnouncementSubscription())._new();
+$recv($1)._announcementClass_(aClass);
+$2=$recv($1)._yourself();
+subscription=$2;
+$recv(subscription)._valuable_((function(ann){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(self["@subscriptions"])._remove_(subscription);
+return $recv(aBlock)._value_(ann);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(self["@subscriptions"])._add_(subscription);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:doOnce:",{aClass:aClass,aBlock:aBlock,subscription:subscription},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aBlock"],
+source: "on: aClass doOnce: aBlock\x0a\x09| subscription |\x0a\x09\x0a\x09subscription := AnnouncementSubscription new\x0a\x09\x09announcementClass: aClass;\x0a\x09\x09yourself.\x0a\x09subscription valuable: [ :ann |\x0a\x09\x09subscriptions remove: subscription.\x0a\x09\x09aBlock value: ann ].\x0a\x0a\x09subscriptions add: subscription",
+referencedClasses: ["AnnouncementSubscription"],
+//>>excludeEnd("ide");
+messageSends: ["announcementClass:", "new", "yourself", "valuable:", "remove:", "value:", "add:"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "on:send:to:",
+protocol: 'subscribing',
+fn: function (aClass,aSelector,anObject){
+var self=this;
+function $AnnouncementSubscription(){return $globals.AnnouncementSubscription||(typeof AnnouncementSubscription=="undefined"?nil:AnnouncementSubscription)}
+function $MessageSend(){return $globals.MessageSend||(typeof MessageSend=="undefined"?nil:MessageSend)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$4,$6,$7,$5,$8,$2;
+$1=self["@subscriptions"];
+$3=$recv($AnnouncementSubscription())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$4=$3;
+$6=$recv($MessageSend())._new();
+$recv($6)._receiver_(anObject);
+$recv($6)._selector_(aSelector);
+$7=$recv($6)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+$5=$7;
+$recv($4)._valuable_($5);
+$recv($3)._announcementClass_(aClass);
+$8=$recv($3)._yourself();
+$2=$8;
+$recv($1)._add_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:send:to:",{aClass:aClass,aSelector:aSelector,anObject:anObject},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aSelector", "anObject"],
+source: "on: aClass send: aSelector to: anObject\x0a\x09subscriptions add: (AnnouncementSubscription new\x0a\x09\x09valuable: (MessageSend new\x0a\x09\x09\x09receiver: anObject;\x0a\x09\x09\x09selector: aSelector;\x0a\x09\x09\x09yourself);\x0a\x09\x09announcementClass: aClass;\x0a\x09\x09yourself)",
+referencedClasses: ["AnnouncementSubscription", "MessageSend"],
+//>>excludeEnd("ide");
+messageSends: ["add:", "valuable:", "new", "receiver:", "selector:", "yourself", "announcementClass:"]
+}),
+$globals.Announcer);
+
+$core.addMethod(
+$core.method({
+selector: "unsubscribe:",
+protocol: 'subscribing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@subscriptions"]=$recv(self["@subscriptions"])._reject_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._receiver()).__eq(anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"unsubscribe:",{anObject:anObject},$globals.Announcer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "unsubscribe: anObject\x0a\x09subscriptions := subscriptions reject: [ :each |\x0a\x09\x09each receiver = anObject ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reject:", "=", "receiver"]
+}),
+$globals.Announcer);
+
+
+
+$core.addClass('SystemAnnouncer', $globals.Announcer, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SystemAnnouncer.comment="My unique instance is the global announcer handling all Amber system-related announces.\x0a\x0a## API\x0a\x0aAccess to the unique instance is done via `#current`";
+//>>excludeEnd("ide");
+
+$globals.SystemAnnouncer.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@current"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@current"]=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SystemAnnouncer.klass.superclass.fn.prototype._new.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=self["@current"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"current",{},$globals.SystemAnnouncer.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09^ current ifNil: [ current := super new ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.SystemAnnouncer.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.SystemAnnouncer.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.SystemAnnouncer.klass);
+
+
+$core.addClass('SystemAnnouncement', $globals.Object, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SystemAnnouncement.comment="I am the superclass of all system announcements";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "announcement";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'announcement'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SystemAnnouncement.klass);
+
+
+$core.addClass('ClassAnnouncement', $globals.SystemAnnouncement, ['theClass'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassAnnouncement.comment="I am the abstract superclass of class-related announcements.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassAnnouncement);
+
+
+
+$core.addClass('ClassAdded', $globals.ClassAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassAdded.comment="I am emitted when a class is added to the system.\x0aSee ClassBuilder >> #addSubclassOf:... methods";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ClassCommentChanged', $globals.ClassAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassCommentChanged.comment="I am emitted when the comment of a class changes. (Behavior >> #comment)";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ClassDefinitionChanged', $globals.ClassAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassDefinitionChanged.comment="I am emitted when the definition of a class changes.\x0aSee ClassBuilder >> #class:instanceVariableNames:";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ClassMigrated', $globals.ClassAnnouncement, ['oldClass'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassMigrated.comment="I am emitted when a class is migrated.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "oldClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@oldClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "oldClass\x0a\x09^ oldClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassMigrated);
+
+$core.addMethod(
+$core.method({
+selector: "oldClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@oldClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "oldClass: aClass\x0a\x09oldClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassMigrated);
+
+
+
+$core.addClass('ClassMoved', $globals.ClassAnnouncement, ['oldPackage'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassMoved.comment="I am emitted when a class is moved from one package to another.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "oldPackage",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@oldPackage"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "oldPackage\x0a\x09^ oldPackage",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassMoved);
+
+$core.addMethod(
+$core.method({
+selector: "oldPackage:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+self["@oldPackage"]=aPackage;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "oldPackage: aPackage\x0a\x09oldPackage := aPackage",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassMoved);
+
+
+
+$core.addClass('ClassRemoved', $globals.ClassAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassRemoved.comment="I am emitted when a class is removed.\x0aSee Smalltalk >> #removeClass:";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ClassRenamed', $globals.ClassAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassRenamed.comment="I am emitted when a class is renamed.\x0aSee ClassBuilder >> #renameClass:to:";
+//>>excludeEnd("ide");
+
+
+$core.addClass('MethodAnnouncement', $globals.SystemAnnouncement, ['method'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodAnnouncement.comment="I am the abstract superclass of method-related announcements.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@method"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09^ method",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "method:",
+protocol: 'accessing',
+fn: function (aCompiledMethod){
+var self=this;
+self["@method"]=aCompiledMethod;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCompiledMethod"],
+source: "method: aCompiledMethod\x0a\x09method := aCompiledMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodAnnouncement);
+
+
+
+$core.addClass('MethodAdded', $globals.MethodAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodAdded.comment="I am emitted when a `CompiledMethod` is added to a class.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('MethodModified', $globals.MethodAnnouncement, ['oldMethod'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodModified.comment="I am emitted when a `CompiledMethod` is modified (a new method is installed). I hold a reference to the old method being replaced.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "oldMethod",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@oldMethod"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "oldMethod\x0a\x09^ oldMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodModified);
+
+$core.addMethod(
+$core.method({
+selector: "oldMethod:",
+protocol: 'accessing',
+fn: function (aMethod){
+var self=this;
+self["@oldMethod"]=aMethod;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "oldMethod: aMethod\x0a\x09oldMethod := aMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodModified);
+
+
+
+$core.addClass('MethodMoved', $globals.MethodAnnouncement, ['oldProtocol'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodMoved.comment="I am emitted when a `CompiledMethod` is moved to another protocol. I hold a refernce to the old protocol of the method.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "oldProtocol",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@oldProtocol"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "oldProtocol\x0a\x09^ oldProtocol",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodMoved);
+
+$core.addMethod(
+$core.method({
+selector: "oldProtocol:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@oldProtocol"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "oldProtocol: aString\x0a\x09oldProtocol := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodMoved);
+
+
+
+$core.addClass('MethodRemoved', $globals.MethodAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodRemoved.comment="I am emitted when a `CompiledMethod` is removed from a class.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('PackageAnnouncement', $globals.SystemAnnouncement, ['package'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageAnnouncement.comment="I am the abstract superclass of package-related announcements.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@package"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x09^ package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "package:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+self["@package"]=aPackage;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "package: aPackage\x0a\x09package := aPackage",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageAnnouncement);
+
+
+
+$core.addClass('PackageAdded', $globals.PackageAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageAdded.comment="I am emitted when a `Package` is added to the system.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('PackageClean', $globals.PackageAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageClean.comment="I am emitted when a package is committed and becomes clean.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('PackageDirty', $globals.PackageAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageDirty.comment="I am emitted when a package becomes dirty.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('PackageRemoved', $globals.PackageAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageRemoved.comment="I am emitted when a `Package` is removed from the system.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ProtocolAnnouncement', $globals.SystemAnnouncement, ['theClass', 'protocol'], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ProtocolAnnouncement.comment="I am the abstract superclass of protocol-related announcements.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Package(){return $globals.Package||(typeof Package=="undefined"?nil:Package)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4;
+$2=self._protocol();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["protocol"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._beginsWith_("*");
+if(!$core.assert($1)){
+$3=$recv(self._theClass())._package();
+return $3;
+};
+$4=$recv($Package())._named_ifAbsent_($recv(self._protocol())._allButFirst(),(function(){
+return nil;
+
+}));
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"package",{},$globals.ProtocolAnnouncement)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x0a\x09(self protocol beginsWith: '*') ifFalse: [\x0a\x09\x09^ self theClass package ].\x0a\x09\x09\x0a\x09^ Package \x0a\x09\x09named: self protocol allButFirst\x0a\x09\x09ifAbsent: [ nil ]",
+referencedClasses: ["Package"],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "beginsWith:", "protocol", "package", "theClass", "named:ifAbsent:", "allButFirst"]
+}),
+$globals.ProtocolAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "protocol",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@protocol"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "protocol\x0a\x09^ protocol",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtocolAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "protocol:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@protocol"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "protocol: aString\x0a\x09protocol := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtocolAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtocolAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtocolAnnouncement);
+
+
+
+$core.addClass('ProtocolAdded', $globals.ProtocolAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ProtocolAdded.comment="I am emitted when a protocol is added to a class.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('ProtocolRemoved', $globals.ProtocolAnnouncement, [], 'Kernel-Announcements');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ProtocolRemoved.comment="I am emitted when a protocol is removed from a class.";
+//>>excludeEnd("ide");
+
+});

+ 439 - 0
bower_components/amber/src/Kernel-Announcements.st

@@ -0,0 +1,439 @@
+Smalltalk createPackage: 'Kernel-Announcements'!
+Object subclass: #AnnouncementSubscription
+	instanceVariableNames: 'valuable announcementClass'
+	package: 'Kernel-Announcements'!
+!AnnouncementSubscription commentStamp!
+I am a single entry in a subscription registry of an `Announcer`.
+Several subscriptions by the same object is possible.!
+
+!AnnouncementSubscription methodsFor: 'accessing'!
+
+announcementClass
+	^ announcementClass
+!
+
+announcementClass: aClass
+	announcementClass := aClass
+!
+
+block
+	"Use #valuable instead"
+	
+	self deprecatedAPI.
+	^ self valuable
+!
+
+block: aValuable
+	"Use #valuable instead"
+	
+	self deprecatedAPI.
+	self valuable: aValuable
+!
+
+receiver
+	^ self valuable receiver
+!
+
+valuable
+	^ valuable
+!
+
+valuable: aValuable
+	valuable := aValuable
+! !
+
+!AnnouncementSubscription methodsFor: 'announcing'!
+
+deliver: anAnnouncement
+	(self handlesAnnouncement: anAnnouncement)
+		ifTrue: [ self valuable value: anAnnouncement ]
+!
+
+handlesAnnouncement: anAnnouncement
+	"anAnnouncement might be announced from within another Amber environment"
+	
+	^ (Smalltalk globals at: self announcementClass name)
+		ifNil: [ ^ false ]
+		ifNotNil: [ :class |
+		(Smalltalk globals at: anAnnouncement class theNonMetaClass name) includesBehavior: class ]
+! !
+
+Object subclass: #AnnouncementValuable
+	instanceVariableNames: 'valuable receiver'
+	package: 'Kernel-Announcements'!
+!AnnouncementValuable commentStamp!
+I wrap `valuable` objects (typically instances of `BlockClosure`) with a `receiver` to be able to unregister subscriptions based on a `receiver`.!
+
+!AnnouncementValuable methodsFor: 'accessing'!
+
+receiver
+	^ receiver
+!
+
+receiver: anObject
+	receiver := anObject
+!
+
+valuable
+	^ valuable
+!
+
+valuable: anObject
+	valuable := anObject
+! !
+
+!AnnouncementValuable methodsFor: 'evaluating'!
+
+value
+	^ self valuable value
+!
+
+value: anObject
+	^ self valuable value: anObject
+! !
+
+Object subclass: #Announcer
+	instanceVariableNames: 'registry subscriptions'
+	package: 'Kernel-Announcements'!
+!Announcer commentStamp!
+I hold annoncement subscriptions (instances of `AnnouncementSubscription`) in a private registry.
+I announce (trigger) announces, which are then dispatched to all subscriptions.
+
+The code is based on the announcements as [described by Vassili Bykov](http://www.cincomsmalltalk.com/userblogs/vbykov/blogView?searchCategory=Announcements%20Framework).
+
+## API
+
+Use `#announce:` to trigger an announcement.
+
+Use `#on:do:` or `#on:send:to:` to register subscriptions.
+
+When using `#on:send:to:`, unregistration can be done with `#unregister:`.
+
+## Usage example:
+
+    SystemAnnouncer current
+        on: ClassAdded
+        do: [ :ann | window alert: ann theClass name, ' added' ].!
+
+!Announcer methodsFor: 'announcing'!
+
+announce: anAnnouncement
+	subscriptions do: [ :each |
+		each deliver: anAnnouncement ]
+! !
+
+!Announcer methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	subscriptions := OrderedCollection new
+! !
+
+!Announcer methodsFor: 'subscribing'!
+
+on: aClass do: aBlock
+	self on: aClass do: aBlock for: nil
+!
+
+on: aClass do: aBlock for: aReceiver
+	subscriptions add: (AnnouncementSubscription new
+		valuable: (AnnouncementValuable new
+			valuable: aBlock;
+			receiver: aReceiver;
+			yourself);
+		announcementClass: aClass;
+		yourself)
+!
+
+on: aClass doOnce: aBlock
+	| subscription |
+	
+	subscription := AnnouncementSubscription new
+		announcementClass: aClass;
+		yourself.
+	subscription valuable: [ :ann |
+		subscriptions remove: subscription.
+		aBlock value: ann ].
+
+	subscriptions add: subscription
+!
+
+on: aClass send: aSelector to: anObject
+	subscriptions add: (AnnouncementSubscription new
+		valuable: (MessageSend new
+			receiver: anObject;
+			selector: aSelector;
+			yourself);
+		announcementClass: aClass;
+		yourself)
+!
+
+unsubscribe: anObject
+	subscriptions := subscriptions reject: [ :each |
+		each receiver = anObject ]
+! !
+
+Announcer subclass: #SystemAnnouncer
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!SystemAnnouncer commentStamp!
+My unique instance is the global announcer handling all Amber system-related announces.
+
+## API
+
+Access to the unique instance is done via `#current`!
+
+SystemAnnouncer class instanceVariableNames: 'current'!
+
+!SystemAnnouncer class methodsFor: 'accessing'!
+
+current
+	^ current ifNil: [ current := super new ]
+! !
+
+!SystemAnnouncer class methodsFor: 'instance creation'!
+
+new
+	self shouldNotImplement
+! !
+
+Object subclass: #SystemAnnouncement
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!SystemAnnouncement commentStamp!
+I am the superclass of all system announcements!
+
+!SystemAnnouncement class methodsFor: 'helios'!
+
+heliosClass
+	^ 'announcement'
+! !
+
+SystemAnnouncement subclass: #ClassAnnouncement
+	instanceVariableNames: 'theClass'
+	package: 'Kernel-Announcements'!
+!ClassAnnouncement commentStamp!
+I am the abstract superclass of class-related announcements.!
+
+!ClassAnnouncement methodsFor: 'accessing'!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+ClassAnnouncement subclass: #ClassAdded
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ClassAdded commentStamp!
+I am emitted when a class is added to the system.
+See ClassBuilder >> #addSubclassOf:... methods!
+
+ClassAnnouncement subclass: #ClassCommentChanged
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ClassCommentChanged commentStamp!
+I am emitted when the comment of a class changes. (Behavior >> #comment)!
+
+ClassAnnouncement subclass: #ClassDefinitionChanged
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ClassDefinitionChanged commentStamp!
+I am emitted when the definition of a class changes.
+See ClassBuilder >> #class:instanceVariableNames:!
+
+ClassAnnouncement subclass: #ClassMigrated
+	instanceVariableNames: 'oldClass'
+	package: 'Kernel-Announcements'!
+!ClassMigrated commentStamp!
+I am emitted when a class is migrated.!
+
+!ClassMigrated methodsFor: 'accessing'!
+
+oldClass
+	^ oldClass
+!
+
+oldClass: aClass
+	oldClass := aClass
+! !
+
+ClassAnnouncement subclass: #ClassMoved
+	instanceVariableNames: 'oldPackage'
+	package: 'Kernel-Announcements'!
+!ClassMoved commentStamp!
+I am emitted when a class is moved from one package to another.!
+
+!ClassMoved methodsFor: 'accessing'!
+
+oldPackage
+	^ oldPackage
+!
+
+oldPackage: aPackage
+	oldPackage := aPackage
+! !
+
+ClassAnnouncement subclass: #ClassRemoved
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ClassRemoved commentStamp!
+I am emitted when a class is removed.
+See Smalltalk >> #removeClass:!
+
+ClassAnnouncement subclass: #ClassRenamed
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ClassRenamed commentStamp!
+I am emitted when a class is renamed.
+See ClassBuilder >> #renameClass:to:!
+
+SystemAnnouncement subclass: #MethodAnnouncement
+	instanceVariableNames: 'method'
+	package: 'Kernel-Announcements'!
+!MethodAnnouncement commentStamp!
+I am the abstract superclass of method-related announcements.!
+
+!MethodAnnouncement methodsFor: 'accessing'!
+
+method
+	^ method
+!
+
+method: aCompiledMethod
+	method := aCompiledMethod
+! !
+
+MethodAnnouncement subclass: #MethodAdded
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!MethodAdded commentStamp!
+I am emitted when a `CompiledMethod` is added to a class.!
+
+MethodAnnouncement subclass: #MethodModified
+	instanceVariableNames: 'oldMethod'
+	package: 'Kernel-Announcements'!
+!MethodModified commentStamp!
+I am emitted when a `CompiledMethod` is modified (a new method is installed). I hold a reference to the old method being replaced.!
+
+!MethodModified methodsFor: 'accessing'!
+
+oldMethod
+	^ oldMethod
+!
+
+oldMethod: aMethod
+	oldMethod := aMethod
+! !
+
+MethodAnnouncement subclass: #MethodMoved
+	instanceVariableNames: 'oldProtocol'
+	package: 'Kernel-Announcements'!
+!MethodMoved commentStamp!
+I am emitted when a `CompiledMethod` is moved to another protocol. I hold a refernce to the old protocol of the method.!
+
+!MethodMoved methodsFor: 'accessing'!
+
+oldProtocol
+	^ oldProtocol
+!
+
+oldProtocol: aString
+	oldProtocol := aString
+! !
+
+MethodAnnouncement subclass: #MethodRemoved
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!MethodRemoved commentStamp!
+I am emitted when a `CompiledMethod` is removed from a class.!
+
+SystemAnnouncement subclass: #PackageAnnouncement
+	instanceVariableNames: 'package'
+	package: 'Kernel-Announcements'!
+!PackageAnnouncement commentStamp!
+I am the abstract superclass of package-related announcements.!
+
+!PackageAnnouncement methodsFor: 'accessing'!
+
+package
+	^ package
+!
+
+package: aPackage
+	package := aPackage
+! !
+
+PackageAnnouncement subclass: #PackageAdded
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!PackageAdded commentStamp!
+I am emitted when a `Package` is added to the system.!
+
+PackageAnnouncement subclass: #PackageClean
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!PackageClean commentStamp!
+I am emitted when a package is committed and becomes clean.!
+
+PackageAnnouncement subclass: #PackageDirty
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!PackageDirty commentStamp!
+I am emitted when a package becomes dirty.!
+
+PackageAnnouncement subclass: #PackageRemoved
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!PackageRemoved commentStamp!
+I am emitted when a `Package` is removed from the system.!
+
+SystemAnnouncement subclass: #ProtocolAnnouncement
+	instanceVariableNames: 'theClass protocol'
+	package: 'Kernel-Announcements'!
+!ProtocolAnnouncement commentStamp!
+I am the abstract superclass of protocol-related announcements.!
+
+!ProtocolAnnouncement methodsFor: 'accessing'!
+
+package
+
+	(self protocol beginsWith: '*') ifFalse: [
+		^ self theClass package ].
+		
+	^ Package 
+		named: self protocol allButFirst
+		ifAbsent: [ nil ]
+!
+
+protocol
+	^ protocol
+!
+
+protocol: aString
+	protocol := aString
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+ProtocolAnnouncement subclass: #ProtocolAdded
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ProtocolAdded commentStamp!
+I am emitted when a protocol is added to a class.!
+
+ProtocolAnnouncement subclass: #ProtocolRemoved
+	instanceVariableNames: ''
+	package: 'Kernel-Announcements'!
+!ProtocolRemoved commentStamp!
+I am emitted when a protocol is removed from a class.!
+

+ 3556 - 0
bower_components/amber/src/Kernel-Classes.js

@@ -0,0 +1,3556 @@
+define("amber_core/Kernel-Classes", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Classes');
+$core.packages["Kernel-Classes"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Behavior', $globals.Object, [], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Behavior.comment="I am the superclass of all class objects.\x0a\x0aI define the protocol for creating instances of a class with `#basicNew` and `#new` (see `boot.js` for class constructors details).\x0a\x0aMy instances know about the subclass/superclass relationships between classes, contain the description that instances are created from,\x0aand hold the method dictionary that's associated with each class.\x0a\x0aI also provides methods for compiling methods, examining the method dictionary, and iterating over the class hierarchy.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: ">>",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._methodAt_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">>",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: ">> aString\x0a\x09^ self methodAt: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["methodAt:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "addCompiledMethod:",
+protocol: 'compiling',
+fn: function (aMethod){
+var self=this;
+var oldMethod,announcement;
+function $MethodAdded(){return $globals.MethodAdded||(typeof MethodAdded=="undefined"?nil:MethodAdded)}
+function $MethodModified(){return $globals.MethodModified||(typeof MethodModified=="undefined"?nil:MethodModified)}
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$4,$5,$6,$7,$8,$9,$10,$11,$receiver;
+oldMethod=$recv(self._methodDictionary())._at_ifAbsent_($recv(aMethod)._selector(),(function(){
+return nil;
+
+}));
+$2=self._protocols();
+$3=$recv(aMethod)._protocol();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["protocol"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._includes_($3);
+if(!$core.assert($1)){
+$4=self._organization();
+$5=$recv(aMethod)._protocol();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["protocol"]=2;
+//>>excludeEnd("ctx");
+$recv($4)._addElement_($5);
+};
+self._basicAddCompiledMethod_(aMethod);
+$6=oldMethod;
+if(($receiver = $6) == null || $receiver.isNil){
+$6;
+} else {
+self._removeProtocolIfEmpty_($recv(oldMethod)._protocol());
+};
+$7=oldMethod;
+if(($receiver = $7) == null || $receiver.isNil){
+$8=$recv($MethodAdded())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($8)._method_(aMethod);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["method:"]=1;
+//>>excludeEnd("ctx");
+$9=$recv($8)._yourself();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["yourself"]=1;
+//>>excludeEnd("ctx");
+announcement=$9;
+} else {
+$10=$recv($MethodModified())._new();
+$recv($10)._oldMethod_(oldMethod);
+$recv($10)._method_(aMethod);
+$11=$recv($10)._yourself();
+announcement=$11;
+};
+$recv($recv($SystemAnnouncer())._current())._announce_(announcement);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addCompiledMethod:",{aMethod:aMethod,oldMethod:oldMethod,announcement:announcement},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "addCompiledMethod: aMethod\x0a\x09| oldMethod announcement |\x0a\x09\x0a\x09oldMethod := self methodDictionary\x0a\x09\x09at: aMethod selector\x0a\x09\x09ifAbsent: [ nil ].\x0a\x09\x0a\x09(self protocols includes: aMethod protocol)\x0a\x09\x09ifFalse: [ self organization addElement: aMethod protocol ].\x0a\x0a\x09self basicAddCompiledMethod: aMethod.\x0a\x09\x0a\x09oldMethod ifNotNil: [\x0a\x09\x09self removeProtocolIfEmpty: oldMethod protocol ].\x0a\x09\x0a\x09announcement := oldMethod\x0a\x09\x09ifNil: [\x0a\x09\x09\x09MethodAdded new\x0a\x09\x09\x09\x09\x09method: aMethod;\x0a\x09\x09\x09\x09\x09yourself ]\x0a\x09\x09ifNotNil: [\x0a\x09\x09\x09MethodModified new\x0a\x09\x09\x09\x09\x09oldMethod: oldMethod;\x0a\x09\x09\x09\x09\x09method: aMethod;\x0a\x09\x09\x09\x09\x09yourself ].\x0a\x09\x09\x09\x09\x09\x0a\x09\x09\x09\x09\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09\x09\x09announce: announcement",
+referencedClasses: ["MethodAdded", "MethodModified", "SystemAnnouncer"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "methodDictionary", "selector", "ifFalse:", "includes:", "protocols", "protocol", "addElement:", "organization", "basicAddCompiledMethod:", "ifNotNil:", "removeProtocolIfEmpty:", "ifNil:ifNotNil:", "method:", "new", "yourself", "oldMethod:", "announce:", "current"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "allInstanceVariableNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+result=$recv(self._instanceVariableNames())._copy();
+$1=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$recv(result)._addAll_($recv(self._superclass())._allInstanceVariableNames());
+};
+$2=result;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allInstanceVariableNames",{result:result},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allInstanceVariableNames\x0a\x09| result |\x0a\x09result := self instanceVariableNames copy.\x0a\x09self superclass ifNotNil: [\x0a\x09\x09result addAll: self superclass allInstanceVariableNames ].\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copy", "instanceVariableNames", "ifNotNil:", "superclass", "addAll:", "allInstanceVariableNames"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "allSelectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$1;
+$2=self._allSuperclasses();
+$3=self._selectors();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selectors"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._inject_into_($3,(function(acc,each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(acc)._addAll_($recv(each)._selectors());
+$4=$recv(acc)._yourself();
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({acc:acc,each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSelectors",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allSelectors\x0a\x09^ self allSuperclasses\x0a\x09\x09inject: self selectors\x0a\x09\x09into: [ :acc :each | acc addAll: each selectors; yourself ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["inject:into:", "allSuperclasses", "selectors", "addAll:", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "allSubclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var subclasses,index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+subclasses=self._subclasses();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["subclasses"]=1;
+//>>excludeEnd("ctx");
+index=(1);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(index).__gt($recv(subclasses)._size());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(subclasses)._addAll_($recv($recv(subclasses)._at_(index))._subclasses());
+index=$recv(index).__plus((1));
+return index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$1=subclasses;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSubclasses",{subclasses:subclasses,index:index},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allSubclasses\x0a\x09\x22Answer an collection of the receiver's and the receiver's descendent's subclasses. \x22\x0a\x0a\x09| subclasses index |\x0a\x09\x0a\x09subclasses := self subclasses.\x0a\x09index := 1.\x0a\x09[ index > subclasses size ]\x0a\x09\x09whileFalse: [ subclasses addAll: (subclasses at: index) subclasses.\x0a\x09\x09\x09index := index + 1 ].\x0a\x0a\x09^ subclasses",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclasses", "whileFalse:", ">", "size", "addAll:", "at:", "+"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "allSubclassesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._allSubclasses())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSubclassesDo:",{aBlock:aBlock},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "allSubclassesDo: aBlock\x0a\x09\x22Evaluate the argument, aBlock, for each of the receiver's subclasses.\x22\x0a\x0a\x09self allSubclasses do: [ :each |\x0a    \x09aBlock value: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "allSubclasses", "value:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "allSuperclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$5,$4,$6,$3,$receiver;
+$1=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$2=[];
+return $2;
+} else {
+$1;
+};
+$5=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($OrderedCollection())._with_($5);
+$recv($4)._addAll_($recv(self._superclass())._allSuperclasses());
+$6=$recv($4)._yourself();
+$3=$6;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSuperclasses",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allSuperclasses\x0a\x09\x0a\x09self superclass ifNil: [ ^ #() ].\x0a\x09\x0a\x09^ (OrderedCollection with: self superclass)\x0a\x09\x09addAll: self superclass allSuperclasses;\x0a\x09\x09yourself",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "superclass", "addAll:", "with:", "allSuperclasses", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "basicAddCompiledMethod:",
+protocol: 'private',
+fn: function (aMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.addMethod(aMethod, self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicAddCompiledMethod:",{aMethod:aMethod},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "basicAddCompiledMethod: aMethod\x0a\x09<$core.addMethod(aMethod, self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "basicNew",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return new self.fn();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicNew",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "basicNew\x0a\x09<return new self.fn()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "basicRemoveCompiledMethod:",
+protocol: 'private',
+fn: function (aMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.removeMethod(aMethod,self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicRemoveCompiledMethod:",{aMethod:aMethod},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "basicRemoveCompiledMethod: aMethod\x0a\x09<$core.removeMethod(aMethod,self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "canUnderstand:",
+protocol: 'testing',
+fn: function (aSelector){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$1=$recv(self._includesSelector_($recv(aSelector)._asString()))._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._notNil();
+return $recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self._superclass())._canUnderstand_(aSelector);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"canUnderstand:",{aSelector:aSelector},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSelector"],
+source: "canUnderstand: aSelector\x0a\x09^ (self includesSelector: aSelector asString) or: [\x0a\x09\x09self superclass notNil and: [ self superclass canUnderstand: aSelector ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["or:", "includesSelector:", "asString", "and:", "notNil", "superclass", "canUnderstand:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "comment",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._basicAt_("comment");
+if(($receiver = $2) == null || $receiver.isNil){
+$1="";
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"comment",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "comment\x0a\x09^ (self basicAt: 'comment') ifNil: [ '' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "basicAt:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "comment:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassCommentChanged(){return $globals.ClassCommentChanged||(typeof ClassCommentChanged=="undefined"?nil:ClassCommentChanged)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._basicAt_put_("comment",aString);
+$1=$recv($ClassCommentChanged())._new();
+$recv($1)._theClass_(self);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"comment:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "comment: aString\x0a\x09self basicAt: 'comment' put: aString.\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassCommentChanged new\x0a\x09\x09\x09theClass: self;\x0a\x09\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ClassCommentChanged"],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "commentStamp",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $ClassCommentReader(){return $globals.ClassCommentReader||(typeof ClassCommentReader=="undefined"?nil:ClassCommentReader)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($ClassCommentReader())._new();
+$recv($2)._class_(self);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commentStamp",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commentStamp\x0a\x09^ ClassCommentReader new\x0a\x09class: self;\x0a\x09yourself",
+referencedClasses: ["ClassCommentReader"],
+//>>excludeEnd("ide");
+messageSends: ["class:", "new", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "commentStamp:prior:",
+protocol: 'accessing',
+fn: function (aStamp,prior){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._commentStamp();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commentStamp:prior:",{aStamp:aStamp,prior:prior},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStamp", "prior"],
+source: "commentStamp: aStamp prior: prior\x0a\x09\x09^ self commentStamp",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commentStamp"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "compile:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._compile_protocol_(aString,"");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compile:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compile: aString\x0a\x09^ self compile: aString protocol: ''",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["compile:protocol:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "compile:protocol:",
+protocol: 'compiling',
+fn: function (aString,anotherString){
+var self=this;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Compiler())._new())._install_forClass_protocol_(aString,self,anotherString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compile:protocol:",{aString:aString,anotherString:anotherString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString"],
+source: "compile: aString protocol: anotherString\x0a\x09^ Compiler new\x0a\x09\x09install: aString\x0a\x09\x09forClass: self\x0a\x09\x09protocol: anotherString",
+referencedClasses: ["Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["install:forClass:protocol:", "new"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ ''",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "includesBehavior:",
+protocol: 'testing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self.__eq_eq(aClass))._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._inheritsFrom_(aClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesBehavior:",{aClass:aClass},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "includesBehavior: aClass\x0a\x09^ self == aClass or: [\x0a\x09\x09\x09self inheritsFrom: aClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["or:", "==", "inheritsFrom:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "includesSelector:",
+protocol: 'testing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methodDictionary())._includesKey_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesSelector:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "includesSelector: aString\x0a\x09^ self methodDictionary includesKey: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["includesKey:", "methodDictionary"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "inheritsFrom:",
+protocol: 'testing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$4,$3,$2,$receiver;
+$1=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+return false;
+} else {
+$1;
+};
+$4=self._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=2;
+//>>excludeEnd("ctx");
+$3=$recv(aClass).__eq_eq($4);
+$2=$recv($3)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._superclass())._inheritsFrom_(aClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inheritsFrom:",{aClass:aClass},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "inheritsFrom: aClass\x0a\x09self superclass ifNil: [ ^ false ].\x0a\x0a\x09^ aClass == self superclass or: [ \x0a\x09\x09self superclass inheritsFrom: aClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "superclass", "or:", "==", "inheritsFrom:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "instanceVariableNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.iVarNames;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instanceVariableNames",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "instanceVariableNames\x0a\x09<return self.iVarNames>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "isBehavior",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBehavior\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "javascriptConstructor",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.fn;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"javascriptConstructor",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "javascriptConstructor\x0a\x09\x22Answer the JS constructor used to instantiate. See boot.js\x22\x0a\x09\x0a\x09<return self.fn>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "javascriptConstructor:",
+protocol: 'accessing',
+fn: function (aJavaScriptFunction){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.setClassConstructor(self, aJavaScriptFunction);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"javascriptConstructor:",{aJavaScriptFunction:aJavaScriptFunction},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJavaScriptFunction"],
+source: "javascriptConstructor: aJavaScriptFunction\x0a\x09\x22Set the JS constructor used to instantiate.\x0a\x09See the JS counter-part in boot.js `$core.setClassConstructor'\x22\x0a\x09\x0a\x09<$core.setClassConstructor(self, aJavaScriptFunction);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "lookupSelector:",
+protocol: 'accessing',
+fn: function (selector){
+var self=this;
+var lookupClass;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+lookupClass=self;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(lookupClass).__eq(nil);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(lookupClass)._includesSelector_(selector);
+if($core.assert($1)){
+$2=$recv(lookupClass)._methodAt_(selector);
+throw $early=[$2];
+};
+lookupClass=$recv(lookupClass)._superclass();
+return lookupClass;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return nil;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lookupSelector:",{selector:selector,lookupClass:lookupClass},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["selector"],
+source: "lookupSelector: selector\x0a\x09\x22Look up the given selector in my methodDictionary.\x0a\x09Return the corresponding method if found.\x0a\x09Otherwise chase the superclass chain and try again.\x0a\x09Return nil if no method is found.\x22\x0a\x09\x0a\x09| lookupClass |\x0a\x09\x0a\x09lookupClass := self.\x0a\x09[ lookupClass = nil ] whileFalse: [\x0a\x09\x09(lookupClass includesSelector: selector)\x0a\x09\x09\x09\x09ifTrue: [ ^ lookupClass methodAt: selector ].\x0a\x09\x09\x09lookupClass := lookupClass superclass ].\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "=", "ifTrue:", "includesSelector:", "methodAt:", "superclass"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methodDictionary())._at_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodAt:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "methodAt: aString\x0a\x09^ self methodDictionary at: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "methodDictionary"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodDictionary",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var dict = $globals.HashedCollection._new();
+	var methods = self.methods;
+	Object.keys(methods).forEach(function(i) {
+		if(methods[i].selector) {
+			dict._at_put_(methods[i].selector, methods[i]);
+		}
+	});
+	return dict;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodDictionary",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodDictionary\x0a\x09<var dict = $globals.HashedCollection._new();\x0a\x09var methods = self.methods;\x0a\x09Object.keys(methods).forEach(function(i) {\x0a\x09\x09if(methods[i].selector) {\x0a\x09\x09\x09dict._at_put_(methods[i].selector, methods[i]);\x0a\x09\x09}\x0a\x09});\x0a\x09return dict>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodTemplate",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$7,$8,$6,$9,$5,$10,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("messageSelectorAndArgumentNames");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("\x22comment stating purpose of message\x22");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$7=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$8=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$6=$recv($7).__comma($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$9=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6).__comma($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("| temporary variable names |");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($recv($recv($String())._lf()).__comma($recv($String())._tab()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$10=$recv(stream)._nextPutAll_("statements");
+return $10;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodTemplate",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodTemplate\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream \x0a\x09\x09\x09nextPutAll: 'messageSelectorAndArgumentNames';\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll: '\x22comment stating purpose of message\x22';\x0a\x09\x09\x09nextPutAll: String lf, String lf, String tab;\x0a\x09\x09\x09nextPutAll: '| temporary variable names |';\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll: 'statements' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", ",", "lf", "tab"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methods",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methodDictionary())._values();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methods",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methods\x0a\x09^ self methodDictionary values",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["values", "methodDictionary"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodsFor:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $ClassCategoryReader(){return $globals.ClassCategoryReader||(typeof ClassCategoryReader=="undefined"?nil:ClassCategoryReader)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($ClassCategoryReader())._new();
+$recv($2)._class_category_(self,aString);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodsFor:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "methodsFor: aString\x0a\x09^ ClassCategoryReader new\x0a\x09\x09class: self category: aString;\x0a\x09\x09yourself",
+referencedClasses: ["ClassCategoryReader"],
+//>>excludeEnd("ide");
+messageSends: ["class:category:", "new", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodsFor:stamp:",
+protocol: 'accessing',
+fn: function (aString,aStamp){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._methodsFor_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodsFor:stamp:",{aString:aString,aStamp:aStamp},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aStamp"],
+source: "methodsFor: aString stamp: aStamp\x0a\x09\x22Added for file-in compatibility, ignores stamp.\x22\x0a\x09^ self methodsFor: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["methodsFor:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "methodsInProtocol:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methods())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._protocol()).__eq(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodsInProtocol:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "methodsInProtocol: aString\x0a\x09^ self methods select: [ :each | each protocol = aString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["select:", "methods", "=", "protocol"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "name",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.className || nil;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"name",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "name\x0a\x09<return self.className || nil>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._basicNew())._initialize();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09^ self basicNew initialize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "basicNew"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "organization",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("organization");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"organization",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "organization\x0a\x09^ self basicAt: 'organization'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "ownMethods",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv($recv(self._ownProtocols())._inject_into_($recv($OrderedCollection())._new(),(function(acc,each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(acc).__comma(self._methodsInProtocol_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({acc:acc,each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(a)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+return $recv($2).__lt_eq($recv(b)._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownMethods",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ownMethods\x0a\x09\x22Answer the methods of the receiver that are not package extensions\x22\x0a\x0a\x09^ (self ownProtocols \x0a\x09\x09inject: OrderedCollection new\x0a\x09\x09into: [ :acc :each | acc, (self methodsInProtocol: each) ])\x0a\x09\x09\x09sorted: [ :a :b | a selector <= b selector ]",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["sorted:", "inject:into:", "ownProtocols", "new", ",", "methodsInProtocol:", "<=", "selector"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "ownProtocols",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._protocols())._reject_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._match_("^\x5c*");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownProtocols",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ownProtocols\x0a\x09\x22Answer the protocols of the receiver that are not package extensions\x22\x0a\x0a\x09^ self protocols reject: [ :each |\x0a\x09\x09each match: '^\x5c*' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reject:", "protocols", "match:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "protocols",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._organization())._elements())._sorted();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"protocols",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "protocols\x0a\x09^ self organization elements sorted",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sorted", "elements", "organization"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "protocolsDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var methodsByProtocol;
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+methodsByProtocol=$recv($HashedCollection())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv(self._methodDictionary())._valuesDo_((function(m){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(methodsByProtocol)._at_ifAbsentPut_($recv(m)._protocol(),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($Array())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+})))._add_(m);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({m:m},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(self._protocols())._do_((function(protocol){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_value_(protocol,$recv(methodsByProtocol)._at_(protocol));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({protocol:protocol},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"protocolsDo:",{aBlock:aBlock,methodsByProtocol:methodsByProtocol},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "protocolsDo: aBlock\x0a\x09\x22Execute aBlock for each method protocol with\x0a\x09its collection of methods in the sort order of protocol name.\x22\x0a\x0a\x09| methodsByProtocol |\x0a\x09methodsByProtocol := HashedCollection new.\x0a\x09self methodDictionary valuesDo: [ :m |\x0a\x09\x09(methodsByProtocol at: m protocol ifAbsentPut: [ Array new ])\x0a\x09\x09\x09add: m ].\x0a\x09self protocols do: [ :protocol |\x0a\x09\x09aBlock value: protocol value: (methodsByProtocol at: protocol) ]",
+referencedClasses: ["HashedCollection", "Array"],
+//>>excludeEnd("ide");
+messageSends: ["new", "valuesDo:", "methodDictionary", "add:", "at:ifAbsentPut:", "protocol", "do:", "protocols", "value:value:", "at:"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "prototype",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.fn.prototype;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prototype",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "prototype\x0a\x09<return self.fn.prototype>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "recompile",
+protocol: 'compiling',
+fn: function (){
+var self=this;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Compiler())._new())._recompile_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"recompile",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "recompile\x0a\x09^ Compiler new recompile: self",
+referencedClasses: ["Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["recompile:", "new"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "removeCompiledMethod:",
+protocol: 'compiling',
+fn: function (aMethod){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $MethodRemoved(){return $globals.MethodRemoved||(typeof MethodRemoved=="undefined"?nil:MethodRemoved)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._basicRemoveCompiledMethod_(aMethod);
+self._removeProtocolIfEmpty_($recv(aMethod)._protocol());
+$1=$recv($MethodRemoved())._new();
+$recv($1)._method_(aMethod);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeCompiledMethod:",{aMethod:aMethod},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "removeCompiledMethod: aMethod\x0a\x09self basicRemoveCompiledMethod: aMethod.\x0a\x09\x0a\x09self removeProtocolIfEmpty: aMethod protocol.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (MethodRemoved new\x0a\x09\x09\x09method: aMethod;\x0a\x09\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "MethodRemoved"],
+//>>excludeEnd("ide");
+messageSends: ["basicRemoveCompiledMethod:", "removeProtocolIfEmpty:", "protocol", "announce:", "current", "method:", "new", "yourself"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "removeProtocolIfEmpty:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._methods())._detect_ifNone_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._protocol()).__eq(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._organization())._removeElement_(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeProtocolIfEmpty:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "removeProtocolIfEmpty: aString\x0a\x09self methods\x0a\x09\x09detect: [ :each | each protocol = aString ]\x0a\x09\x09ifNone: [ self organization removeElement: aString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["detect:ifNone:", "methods", "=", "protocol", "removeElement:", "organization"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "selectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._methodDictionary())._keys();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selectors",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selectors\x0a\x09^ self methodDictionary keys",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keys", "methodDictionary"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "subclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclasses",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subclasses\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "superclass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.superclass || nil;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"superclass",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "superclass\x0a\x09<return self.superclass || nil>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "theMetaClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._class();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"theMetaClass",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theMetaClass\x0a\x09^ self class",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["class"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "theNonMetaClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theNonMetaClass\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "withAllSubclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv($Array())._with_(self);
+$recv($2)._addAll_(self._allSubclasses());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withAllSubclasses",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "withAllSubclasses\x0a\x09^ (Array with: self) addAll: self allSubclasses; yourself",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "with:", "allSubclasses", "yourself"]
+}),
+$globals.Behavior);
+
+
+
+$core.addClass('Class', $globals.Behavior, [], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Class.comment="I am __the__ class object.\x0a\x0aMy instances are the classes of the system.\x0aClass creation is done throught a `ClassBuilder` instance.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1="$globals.".__comma(self._name());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09^ '$globals.', self name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "name"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "browse",
+protocol: 'browsing',
+fn: function (){
+var self=this;
+function $Finder(){return $globals.Finder||(typeof Finder=="undefined"?nil:Finder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Finder())._findClass_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"browse",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "browse\x0a\x09Finder findClass: self",
+referencedClasses: ["Finder"],
+//>>excludeEnd("ide");
+messageSends: ["findClass:"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "category",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._package();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["package"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $2) == null || $receiver.isNil){
+$1="Unclassified";
+} else {
+$1=$recv(self._package())._name();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"category",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "category\x0a\x09^ self package ifNil: [ 'Unclassified' ] ifNotNil: [ self package name ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "package", "name"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$5,$6,$7,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($recv(self._superclass())._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(" subclass: #");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(self._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$3=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$5=$recv(stream)._nextPutAll_("instanceVariableNames: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$5;
+$recv(self._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+$6=$recv("'".__comma($recv($String())._lf())).__comma($recv($String())._tab());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("package: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(self._category());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+$7=$recv(stream)._nextPutAll_("'");
+return $7;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"definition",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream\x0a\x09\x09\x09nextPutAll: self superclass asString;\x0a\x09\x09\x09nextPutAll: ' subclass: #';\x0a\x09\x09\x09nextPutAll: self name;\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll: 'instanceVariableNames: '''.\x0a\x09\x09self instanceVariableNames\x0a\x09\x09\x09do: [ :each | stream nextPutAll: each ]\x0a\x09\x09\x09separatedBy: [ stream nextPutAll: ' ' ].\x0a\x09\x09stream\x0a\x09\x09\x09nextPutAll: '''', String lf, String tab;\x0a\x09\x09\x09nextPutAll: 'package: ''';\x0a\x09\x09\x09nextPutAll: self category;\x0a\x09\x09\x09nextPutAll: '''' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", "asString", "superclass", "name", ",", "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "class";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09\x22Should be an Helios extension. Unfortunately, since helios can browse remote\x0a\x09environments, we can't extend base classes\x22\x0a\x09\x0a\x09^ 'class'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "isClass",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClass\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("pkg");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"package",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x09^ self basicAt: 'pkg'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "package:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+var oldPackage;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassMoved(){return $globals.ClassMoved||(typeof ClassMoved=="undefined"?nil:ClassMoved)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4,$5;
+$2=self._package();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["package"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq(aPackage);
+if($core.assert($1)){
+return self;
+};
+oldPackage=self._package();
+self._basicAt_put_("pkg",aPackage);
+$3=$recv(oldPackage)._organization();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["organization"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._removeElement_(self);
+$recv($recv(aPackage)._organization())._addElement_(self);
+$4=$recv($ClassMoved())._new();
+$recv($4)._theClass_(self);
+$recv($4)._oldPackage_(oldPackage);
+$5=$recv($4)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($5);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"package:",{aPackage:aPackage,oldPackage:oldPackage},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "package: aPackage\x0a\x09| oldPackage |\x0a\x09\x0a\x09self package = aPackage ifTrue: [ ^ self ].\x0a\x09\x0a\x09oldPackage := self package.\x0a\x09\x0a\x09self basicAt: 'pkg' put: aPackage.\x0a\x09oldPackage organization removeElement: self.\x0a\x09aPackage organization addElement: self.\x0a\x0a\x09SystemAnnouncer current announce: (ClassMoved new\x0a\x09\x09theClass: self;\x0a\x09\x09oldPackage: oldPackage;\x0a\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ClassMoved"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "=", "package", "basicAt:put:", "removeElement:", "organization", "addElement:", "announce:", "current", "theClass:", "new", "oldPackage:", "yourself"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._name());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: self name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "name"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "rename:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($ClassBuilder())._new())._renameClass_to_(self,aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"rename:",{aString:aString},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "rename: aString\x0a\x09ClassBuilder new renameClass: self to: aString",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["renameClass:to:", "new"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:",
+protocol: 'class creation',
+fn: function (aString,anotherString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,anotherString,nil);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:",{aString:aString,anotherString:anotherString},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString"],
+source: "subclass: aString instanceVariableNames: anotherString\x0a\x09\x22Kept for file-in compatibility.\x22\x0a\x09^ self subclass: aString instanceVariableNames: anotherString package: nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:category:",
+protocol: 'class creation',
+fn: function (aString,aString2,aString3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:category:",{aString:aString,aString2:aString2,aString3:aString3},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 category: aString3\x0a\x09\x22Kept for file-in compatibility.\x22\x0a\x09^ self subclass: aString instanceVariableNames: aString2 package: aString3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:classVariableNames:poolDictionaries:category:",
+protocol: 'class creation',
+fn: function (aString,aString2,classVars,pools,aString3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:classVariableNames:poolDictionaries:category:",{aString:aString,aString2:aString2,classVars:classVars,pools:pools,aString3:aString3},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "classVars", "pools", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 classVariableNames: classVars poolDictionaries: pools category: aString3\x0a\x09\x22Kept for file-in compatibility. ignores class variables and pools.\x22\x0a\x09^ self subclass: aString instanceVariableNames: aString2 package: aString3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:package:",
+protocol: 'class creation',
+fn: function (aString,aString2,aString3){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($ClassBuilder())._new())._superclass_subclass_instanceVariableNames_package_(self,$recv(aString)._asString(),aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:package:",{aString:aString,aString2:aString2,aString3:aString3},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 package: aString3\x0a\x09^ ClassBuilder new\x0a\x09\x09superclass: self subclass: aString asString instanceVariableNames: aString2 package: aString3",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["superclass:subclass:instanceVariableNames:package:", "new", "asString"]
+}),
+$globals.Class);
+
+$core.addMethod(
+$core.method({
+selector: "subclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.subclasses._copy();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclasses",{},$globals.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subclasses\x0a\x09<return self.subclasses._copy()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Class);
+
+
+
+$core.addClass('Metaclass', $globals.Behavior, [], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Metaclass.comment="I am the root of the class hierarchy.\x0a\x0aMy instances are metaclasses, one for each real class, and have a single instance, which they hold onto: the class that they are the metaclass of.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("$globals.".__comma($recv(self._instanceClass())._name())).__comma(".klass");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09^ '$globals.', self instanceClass name, '.klass'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "name", "instanceClass"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(self._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$2=$recv(stream)._nextPutAll_(" instanceVariableNames: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$2;
+$recv(self._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+return $recv(stream)._nextPutAll_("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"definition",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream\x0a\x09\x09\x09nextPutAll: self asString;\x0a\x09\x09\x09nextPutAll: ' instanceVariableNames: '''.\x0a\x09\x09self instanceVariableNames\x0a\x09\x09\x09do: [ :each | stream nextPutAll: each ]\x0a\x09\x09\x09separatedBy: [ stream nextPutAll: ' ' ].\x0a\x09\x09stream nextPutAll: '''' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", "asString", "do:separatedBy:", "instanceVariableNames"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "instanceClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.instanceClass;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instanceClass",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "instanceClass\x0a\x09<return self.instanceClass>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "instanceVariableNames:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($ClassBuilder())._new())._class_instanceVariableNames_(self,aCollection);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instanceVariableNames:",{aCollection:aCollection},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "instanceVariableNames: aCollection\x0a\x09ClassBuilder new\x0a\x09\x09class: self instanceVariableNames: aCollection",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["class:instanceVariableNames:", "new"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "isMetaclass",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMetaclass\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._instanceClass())._package();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"package",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x09^ self instanceClass package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["package", "instanceClass"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_($recv(self._instanceClass())._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(" class");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: self instanceClass name;\x0a\x09\x09nextPutAll: ' class'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "name", "instanceClass"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "subclasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv(self._instanceClass())._subclasses())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._isMetaclass())._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._theMetaClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclasses",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subclasses\x0a\x09^ (self instanceClass subclasses \x0a\x09\x09select: [ :each | each isMetaclass not ])\x0a\x09\x09collect: [ :each | each theMetaClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "select:", "subclasses", "instanceClass", "not", "isMetaclass", "theMetaClass"]
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "theMetaClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theMetaClass\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Metaclass);
+
+$core.addMethod(
+$core.method({
+selector: "theNonMetaClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._instanceClass();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"theNonMetaClass",{},$globals.Metaclass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theNonMetaClass\x0a\x09^ self instanceClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["instanceClass"]
+}),
+$globals.Metaclass);
+
+
+
+$core.addClass('ClassBuilder', $globals.Object, [], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassBuilder.comment="I am responsible for compiling new classes or modifying existing classes in the system.\x0a\x0aRather than using me directly to compile a class, use `Class >> subclass:instanceVariableNames:package:`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addSubclassOf:named:instanceVariableNames:package:",
+protocol: 'class definition',
+fn: function (aClass,className,aCollection,packageName){
+var self=this;
+var theClass,thePackage;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $Package(){return $globals.Package||(typeof Package=="undefined"?nil:Package)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$receiver;
+theClass=$recv($recv($Smalltalk())._globals())._at_(className);
+thePackage=$recv($Package())._named_(packageName);
+$1=theClass;
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$recv(theClass)._package_(thePackage);
+$2=$recv($recv(theClass)._superclass()).__eq_eq(aClass);
+if(!$core.assert($2)){
+$3=self._migrateClassNamed_superclass_instanceVariableNames_package_(className,aClass,aCollection,packageName);
+return $3;
+};
+};
+$4=self._basicAddSubclassOf_named_instanceVariableNames_package_(aClass,className,aCollection,packageName);
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addSubclassOf:named:instanceVariableNames:package:",{aClass:aClass,className:className,aCollection:aCollection,packageName:packageName,theClass:theClass,thePackage:thePackage},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "className", "aCollection", "packageName"],
+source: "addSubclassOf: aClass named: className instanceVariableNames: aCollection package: packageName\x0a\x09| theClass thePackage |\x0a\x09\x0a\x09theClass := Smalltalk globals at: className.\x0a\x09thePackage := Package named: packageName.\x0a\x09\x0a\x09theClass ifNotNil: [\x0a\x09\x09theClass package: thePackage.\x0a\x09\x09theClass superclass == aClass ifFalse: [\x0a\x09\x09\x09^ self\x0a\x09\x09\x09\x09migrateClassNamed: className\x0a\x09\x09\x09\x09superclass: aClass\x0a\x09\x09\x09\x09instanceVariableNames: aCollection\x0a\x09\x09\x09\x09package: packageName ] ].\x0a\x09\x09\x0a\x09^ self\x0a\x09\x09basicAddSubclassOf: aClass\x0a\x09\x09named: className\x0a\x09\x09instanceVariableNames: aCollection\x0a\x09\x09package: packageName",
+referencedClasses: ["Smalltalk", "Package"],
+//>>excludeEnd("ide");
+messageSends: ["at:", "globals", "named:", "ifNotNil:", "package:", "ifFalse:", "==", "superclass", "migrateClassNamed:superclass:instanceVariableNames:package:", "basicAddSubclassOf:named:instanceVariableNames:package:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicAddSubclassOf:named:instanceVariableNames:package:",
+protocol: 'private',
+fn: function (aClass,aString,aCollection,packageName){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		$core.addClass(aString, aClass, aCollection, packageName);
+		return $globals[aString]
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicAddSubclassOf:named:instanceVariableNames:package:",{aClass:aClass,aString:aString,aCollection:aCollection,packageName:packageName},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString", "aCollection", "packageName"],
+source: "basicAddSubclassOf: aClass named: aString instanceVariableNames: aCollection package: packageName\x0a\x09<\x0a\x09\x09$core.addClass(aString, aClass, aCollection, packageName);\x0a\x09\x09return $globals[aString]\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicClass:instanceVariableNames:",
+protocol: 'private',
+fn: function (aClass,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicClass_instanceVariables_(aClass,self._instanceVariableNamesFor_(aString));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicClass:instanceVariableNames:",{aClass:aClass,aString:aString},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString"],
+source: "basicClass: aClass instanceVariableNames: aString\x0a\x09self basicClass: aClass instanceVariables: (self instanceVariableNamesFor: aString)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicClass:instanceVariables:", "instanceVariableNamesFor:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicClass:instanceVariables:",
+protocol: 'private',
+fn: function (aClass,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aClass)._isMetaclass();
+if(!$core.assert($1)){
+self._error_($recv($recv(aClass)._name()).__comma(" is not a metaclass"));
+};
+$recv(aClass)._basicAt_put_("iVarNames",aCollection);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicClass:instanceVariables:",{aClass:aClass,aCollection:aCollection},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aCollection"],
+source: "basicClass: aClass instanceVariables: aCollection\x0a\x0a\x09aClass isMetaclass ifFalse: [ self error: aClass name, ' is not a metaclass' ].\x0a\x09aClass basicAt: 'iVarNames' put: aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isMetaclass", "error:", ",", "name", "basicAt:put:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicRemoveClass:",
+protocol: 'private',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.removeClass(aClass);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicRemoveClass:",{aClass:aClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "basicRemoveClass: aClass\x0a\x09<$core.removeClass(aClass)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicRenameClass:to:",
+protocol: 'private',
+fn: function (aClass,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		$globals[aString] = aClass;
+		delete $globals[aClass.className];
+		aClass.className = aString;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicRenameClass:to:",{aClass:aClass,aString:aString},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString"],
+source: "basicRenameClass: aClass to: aString\x0a\x09<\x0a\x09\x09$globals[aString] = aClass;\x0a\x09\x09delete $globals[aClass.className];\x0a\x09\x09aClass.className = aString;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "basicSwapClassNames:with:",
+protocol: 'private',
+fn: function (aClass,anotherClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var tmp = aClass.className;
+		aClass.className = anotherClass.className;
+		anotherClass.className = tmp;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicSwapClassNames:with:",{aClass:aClass,anotherClass:anotherClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "anotherClass"],
+source: "basicSwapClassNames: aClass with: anotherClass\x0a\x09<\x0a\x09\x09var tmp = aClass.className;\x0a\x09\x09aClass.className = anotherClass.className;\x0a\x09\x09anotherClass.className = tmp;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "class:instanceVariableNames:",
+protocol: 'class definition',
+fn: function (aClass,ivarNames){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassDefinitionChanged(){return $globals.ClassDefinitionChanged||(typeof ClassDefinitionChanged=="undefined"?nil:ClassDefinitionChanged)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._basicClass_instanceVariableNames_(aClass,ivarNames);
+self._setupClass_(aClass);
+$1=$recv($ClassDefinitionChanged())._new();
+$recv($1)._theClass_(aClass);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"class:instanceVariableNames:",{aClass:aClass,ivarNames:ivarNames},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "ivarNames"],
+source: "class: aClass instanceVariableNames: ivarNames\x0a\x09self basicClass: aClass instanceVariableNames: ivarNames.\x0a\x09self setupClass: aClass.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassDefinitionChanged new\x0a\x09\x09\x09theClass: aClass;\x0a\x09\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ClassDefinitionChanged"],
+//>>excludeEnd("ide");
+messageSends: ["basicClass:instanceVariableNames:", "setupClass:", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "copyClass:named:",
+protocol: 'copying',
+fn: function (aClass,className){
+var self=this;
+var newClass;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassAdded(){return $globals.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+newClass=self._addSubclassOf_named_instanceVariableNames_package_($recv(aClass)._superclass(),className,$recv(aClass)._instanceVariableNames(),$recv($recv(aClass)._package())._name());
+self._copyClass_to_(aClass,newClass);
+$1=$recv($ClassAdded())._new();
+$recv($1)._theClass_(newClass);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+$3=newClass;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyClass:named:",{aClass:aClass,className:className,newClass:newClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "className"],
+source: "copyClass: aClass named: className\x0a\x09| newClass |\x0a\x0a\x09newClass := self\x0a\x09\x09addSubclassOf: aClass superclass\x0a\x09\x09named: className\x0a\x09\x09instanceVariableNames: aClass instanceVariableNames\x0a\x09\x09package: aClass package name.\x0a\x0a\x09self copyClass: aClass to: newClass.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassAdded new\x0a\x09\x09\x09theClass: newClass;\x0a\x09\x09\x09yourself).\x0a\x09\x0a\x09^ newClass",
+referencedClasses: ["SystemAnnouncer", "ClassAdded"],
+//>>excludeEnd("ide");
+messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "superclass", "instanceVariableNames", "name", "package", "copyClass:to:", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "copyClass:to:",
+protocol: 'copying',
+fn: function (aClass,anotherClass){
+var self=this;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$7,$6,$9,$8;
+$recv(anotherClass)._comment_($recv(aClass)._comment());
+$1=$recv(aClass)._methodDictionary();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodDictionary"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._valuesDo_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv($Compiler())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(each)._source();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["source"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(each)._protocol();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["protocol"]=1;
+//>>excludeEnd("ctx");
+return $recv($2)._install_forClass_protocol_($3,anotherClass,$4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["install:forClass:protocol:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["valuesDo:"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(anotherClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$7=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=2;
+//>>excludeEnd("ctx");
+$6=$recv($7)._instanceVariableNames();
+self._basicClass_instanceVariables_($5,$6);
+$9=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=3;
+//>>excludeEnd("ctx");
+$8=$recv($9)._methodDictionary();
+$recv($8)._valuesDo_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv($Compiler())._new())._install_forClass_protocol_($recv(each)._source(),$recv(anotherClass)._class(),$recv(each)._protocol());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+self._setupClass_(anotherClass);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyClass:to:",{aClass:aClass,anotherClass:anotherClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "anotherClass"],
+source: "copyClass: aClass to: anotherClass\x0a\x0a\x09anotherClass comment: aClass comment.\x0a\x0a\x09aClass methodDictionary valuesDo: [ :each |\x0a\x09\x09Compiler new install: each source forClass: anotherClass protocol: each protocol ].\x0a\x0a\x09self basicClass: anotherClass class instanceVariables: aClass class instanceVariableNames.\x0a\x0a\x09aClass class methodDictionary valuesDo: [ :each |\x0a\x09\x09Compiler new install: each source forClass: anotherClass class protocol: each protocol ].\x0a\x0a\x09self setupClass: anotherClass",
+referencedClasses: ["Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["comment:", "comment", "valuesDo:", "methodDictionary", "install:forClass:protocol:", "new", "source", "protocol", "basicClass:instanceVariables:", "class", "instanceVariableNames", "setupClass:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "installMethod:forClass:protocol:",
+protocol: 'method definition',
+fn: function (aCompiledMethod,aBehavior,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aCompiledMethod)._protocol_(aString);
+$recv(aBehavior)._addCompiledMethod_(aCompiledMethod);
+return aCompiledMethod;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"installMethod:forClass:protocol:",{aCompiledMethod:aCompiledMethod,aBehavior:aBehavior,aString:aString},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCompiledMethod", "aBehavior", "aString"],
+source: "installMethod: aCompiledMethod forClass: aBehavior protocol: aString\x0a\x09aCompiledMethod protocol: aString.\x0a\x09aBehavior addCompiledMethod: aCompiledMethod.\x0a\x09^ aCompiledMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["protocol:", "addCompiledMethod:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "instanceVariableNamesFor:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aString)._tokenize_(" "))._reject_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._isEmpty();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instanceVariableNamesFor:",{aString:aString},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "instanceVariableNamesFor: aString\x0a\x09^ (aString tokenize: ' ') reject: [ :each | each isEmpty ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reject:", "tokenize:", "isEmpty"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "migrateClass:superclass:",
+protocol: 'class migration',
+fn: function (aClass,anotherClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(aClass)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$1=self._migrateClassNamed_superclass_instanceVariableNames_package_($2,anotherClass,$recv(aClass)._instanceVariableNames(),$recv($recv(aClass)._package())._name());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"migrateClass:superclass:",{aClass:aClass,anotherClass:anotherClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "anotherClass"],
+source: "migrateClass: aClass superclass: anotherClass\x0a\x09^ self\x0a\x09\x09migrateClassNamed: aClass name\x0a\x09\x09superclass: anotherClass\x0a\x09\x09instanceVariableNames: aClass instanceVariableNames\x0a\x09\x09package: aClass package name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["migrateClassNamed:superclass:instanceVariableNames:package:", "name", "instanceVariableNames", "package"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "migrateClassNamed:superclass:instanceVariableNames:package:",
+protocol: 'class migration',
+fn: function (className,aClass,aCollection,packageName){
+var self=this;
+var oldClass,newClass,tmp;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassMigrated(){return $globals.ClassMigrated||(typeof ClassMigrated=="undefined"?nil:ClassMigrated)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5;
+tmp="new*".__comma(className);
+oldClass=$recv($recv($Smalltalk())._globals())._at_(className);
+newClass=self._addSubclassOf_named_instanceVariableNames_package_(aClass,tmp,aCollection,packageName);
+self._basicSwapClassNames_with_(oldClass,newClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["basicSwapClassNames:with:"]=1;
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._copyClass_to_(oldClass,newClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(exception){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._basicSwapClassNames_with_(oldClass,newClass);
+$1=self._basicRemoveClass_(newClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["basicRemoveClass:"]=1;
+//>>excludeEnd("ctx");
+$1;
+return $recv(exception)._signal();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({exception:exception},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+self._rawRenameClass_to_(oldClass,tmp);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["rawRenameClass:to:"]=1;
+//>>excludeEnd("ctx");
+$2=self._rawRenameClass_to_(newClass,className);
+$recv($recv(oldClass)._subclasses())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._migrateClass_superclass_(each,newClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+self._basicRemoveClass_(oldClass);
+$3=$recv($ClassMigrated())._new();
+$recv($3)._theClass_(newClass);
+$recv($3)._oldClass_(oldClass);
+$4=$recv($3)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($4);
+$5=newClass;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"migrateClassNamed:superclass:instanceVariableNames:package:",{className:className,aClass:aClass,aCollection:aCollection,packageName:packageName,oldClass:oldClass,newClass:newClass,tmp:tmp},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["className", "aClass", "aCollection", "packageName"],
+source: "migrateClassNamed: className superclass: aClass instanceVariableNames: aCollection package: packageName\x0a\x09| oldClass newClass tmp |\x0a\x09\x0a\x09tmp := 'new*', className.\x0a\x09oldClass := Smalltalk globals at: className.\x0a\x09\x0a\x09newClass := self\x0a\x09\x09addSubclassOf: aClass\x0a\x09\x09named: tmp\x0a\x09\x09instanceVariableNames: aCollection\x0a\x09\x09package: packageName.\x0a\x0a\x09self basicSwapClassNames: oldClass with: newClass.\x0a\x0a\x09[ self copyClass: oldClass to: newClass ]\x0a\x09\x09on: Error\x0a\x09\x09do: [ :exception |\x0a\x09\x09\x09self\x0a\x09\x09\x09\x09basicSwapClassNames: oldClass with: newClass;\x0a\x09\x09\x09\x09basicRemoveClass: newClass.\x0a\x09\x09\x09exception signal ].\x0a\x0a\x09self\x0a\x09\x09rawRenameClass: oldClass to: tmp;\x0a\x09\x09rawRenameClass: newClass to: className.\x0a\x0a\x09oldClass subclasses \x0a\x09\x09do: [ :each | self migrateClass: each superclass: newClass ].\x0a\x0a\x09self basicRemoveClass: oldClass.\x0a\x09\x0a\x09SystemAnnouncer current announce: (ClassMigrated new\x0a\x09\x09theClass: newClass;\x0a\x09\x09oldClass: oldClass;\x0a\x09\x09yourself).\x0a\x09\x0a\x09^ newClass",
+referencedClasses: ["Smalltalk", "Error", "SystemAnnouncer", "ClassMigrated"],
+//>>excludeEnd("ide");
+messageSends: [",", "at:", "globals", "addSubclassOf:named:instanceVariableNames:package:", "basicSwapClassNames:with:", "on:do:", "copyClass:to:", "basicRemoveClass:", "signal", "rawRenameClass:to:", "do:", "subclasses", "migrateClass:superclass:", "announce:", "current", "theClass:", "new", "oldClass:", "yourself"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "rawRenameClass:to:",
+protocol: 'private',
+fn: function (aClass,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		$globals[aString] = aClass;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"rawRenameClass:to:",{aClass:aClass,aString:aString},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString"],
+source: "rawRenameClass: aClass to: aString\x0a\x09<\x0a\x09\x09$globals[aString] = aClass;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "renameClass:to:",
+protocol: 'class migration',
+fn: function (aClass,className){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassRenamed(){return $globals.ClassRenamed||(typeof ClassRenamed=="undefined"?nil:ClassRenamed)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._basicRenameClass_to_(aClass,className);
+$recv(aClass)._recompile();
+$1=$recv($ClassRenamed())._new();
+$recv($1)._theClass_(aClass);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"renameClass:to:",{aClass:aClass,className:className},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "className"],
+source: "renameClass: aClass to: className\x0a\x09self basicRenameClass: aClass to: className.\x0a\x09\x0a\x09\x22Recompile the class to fix potential issues with super sends\x22\x0a\x09aClass recompile.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassRenamed new\x0a\x09\x09\x09theClass: aClass;\x0a\x09\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ClassRenamed"],
+//>>excludeEnd("ide");
+messageSends: ["basicRenameClass:to:", "recompile", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "setupClass:",
+protocol: 'public',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.init(aClass);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setupClass:",{aClass:aClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "setupClass: aClass\x0a\x09<$core.init(aClass);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "superclass:subclass:",
+protocol: 'class definition',
+fn: function (aClass,className){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._superclass_subclass_instanceVariableNames_package_(aClass,className,"",nil);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"superclass:subclass:",{aClass:aClass,className:className},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "className"],
+source: "superclass: aClass subclass: className\x0a\x09^ self superclass: aClass subclass: className instanceVariableNames: '' package: nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["superclass:subclass:instanceVariableNames:package:"]
+}),
+$globals.ClassBuilder);
+
+$core.addMethod(
+$core.method({
+selector: "superclass:subclass:instanceVariableNames:package:",
+protocol: 'class definition',
+fn: function (aClass,className,ivarNames,packageName){
+var self=this;
+var newClass;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassAdded(){return $globals.ClassAdded||(typeof ClassAdded=="undefined"?nil:ClassAdded)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5,$receiver;
+$1=self._instanceVariableNamesFor_(ivarNames);
+if(($receiver = packageName) == null || $receiver.isNil){
+$2="unclassified";
+} else {
+$2=packageName;
+};
+newClass=self._addSubclassOf_named_instanceVariableNames_package_(aClass,className,$1,$2);
+self._setupClass_(newClass);
+$3=$recv($ClassAdded())._new();
+$recv($3)._theClass_(newClass);
+$4=$recv($3)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($4);
+$5=newClass;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"superclass:subclass:instanceVariableNames:package:",{aClass:aClass,className:className,ivarNames:ivarNames,packageName:packageName,newClass:newClass},$globals.ClassBuilder)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "className", "ivarNames", "packageName"],
+source: "superclass: aClass subclass: className instanceVariableNames: ivarNames package: packageName\x0a\x09| newClass |\x0a\x09\x0a\x09newClass := self addSubclassOf: aClass\x0a\x09\x09named: className instanceVariableNames: (self instanceVariableNamesFor: ivarNames)\x0a\x09\x09package: (packageName ifNil: [ 'unclassified' ]).\x0a\x09self setupClass: newClass.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassAdded new\x0a\x09\x09\x09theClass: newClass;\x0a\x09\x09\x09yourself).\x0a\x09\x0a\x09^ newClass",
+referencedClasses: ["SystemAnnouncer", "ClassAdded"],
+//>>excludeEnd("ide");
+messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "instanceVariableNamesFor:", "ifNil:", "setupClass:", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.ClassBuilder);
+
+
+
+$core.addClass('ClassCategoryReader', $globals.Object, ['class', 'category'], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassCategoryReader.comment="I provide a mechanism for retrieving class descriptions stored on a file in the Smalltalk chunk format.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "class:category:",
+protocol: 'accessing',
+fn: function (aClass,aString){
+var self=this;
+self["@class"]=aClass;
+self["@category"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString"],
+source: "class: aClass category: aString\x0a\x09class := aClass.\x0a\x09category := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassCategoryReader);
+
+$core.addMethod(
+$core.method({
+selector: "compileMethod:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($Compiler())._new())._install_forClass_protocol_(aString,self["@class"],self["@category"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileMethod:",{aString:aString},$globals.ClassCategoryReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compileMethod: aString\x0a\x09Compiler new install: aString forClass: class protocol: category",
+referencedClasses: ["Compiler"],
+//>>excludeEnd("ide");
+messageSends: ["install:forClass:protocol:", "new"]
+}),
+$globals.ClassCategoryReader);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ClassCategoryReader.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ClassCategoryReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize"]
+}),
+$globals.ClassCategoryReader);
+
+$core.addMethod(
+$core.method({
+selector: "scanFrom:",
+protocol: 'fileIn',
+fn: function (aChunkParser){
+var self=this;
+var chunk;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+chunk=$recv(aChunkParser)._nextChunk();
+chunk;
+return $recv(chunk)._isEmpty();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._compileMethod_(chunk);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv($recv($ClassBuilder())._new())._setupClass_(self["@class"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scanFrom:",{aChunkParser:aChunkParser,chunk:chunk},$globals.ClassCategoryReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aChunkParser"],
+source: "scanFrom: aChunkParser\x0a\x09| chunk |\x0a\x09[ chunk := aChunkParser nextChunk.\x0a\x09chunk isEmpty ] whileFalse: [\x0a\x09\x09self compileMethod: chunk ].\x0a\x09ClassBuilder new setupClass: class",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "nextChunk", "isEmpty", "compileMethod:", "setupClass:", "new"]
+}),
+$globals.ClassCategoryReader);
+
+
+
+$core.addClass('ClassCommentReader', $globals.Object, ['class'], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassCommentReader.comment="I provide a mechanism for retrieving class comments stored on a file.\x0a\x0aSee also `ClassCategoryReader`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "class:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@class"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "class: aClass\x0a\x09class := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassCommentReader);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ClassCommentReader.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ClassCommentReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize"]
+}),
+$globals.ClassCommentReader);
+
+$core.addMethod(
+$core.method({
+selector: "scanFrom:",
+protocol: 'fileIn',
+fn: function (aChunkParser){
+var self=this;
+var chunk;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+chunk=$recv(aChunkParser)._nextChunk();
+$1=$recv(chunk)._isEmpty();
+if(!$core.assert($1)){
+self._setComment_(chunk);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"scanFrom:",{aChunkParser:aChunkParser,chunk:chunk},$globals.ClassCommentReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aChunkParser"],
+source: "scanFrom: aChunkParser\x0a\x09| chunk |\x0a\x09chunk := aChunkParser nextChunk.\x0a\x09chunk isEmpty ifFalse: [\x0a\x09\x09self setComment: chunk ].",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextChunk", "ifFalse:", "isEmpty", "setComment:"]
+}),
+$globals.ClassCommentReader);
+
+$core.addMethod(
+$core.method({
+selector: "setComment:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@class"])._comment_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setComment:",{aString:aString},$globals.ClassCommentReader)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "setComment: aString\x0a\x09class comment: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["comment:"]
+}),
+$globals.ClassCommentReader);
+
+
+
+$core.addClass('ClassSorterNode', $globals.Object, ['theClass', 'level', 'nodes'], 'Kernel-Classes');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassSorterNode.comment="I provide an algorithm for sorting classes alphabetically.\x0a\x0aSee [Issue #143](https://github.com/amber-smalltalk/amber/issues/143) on GitHub.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "getNodesFrom:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+var children,others;
+function $ClassSorterNode(){return $globals.ClassSorterNode||(typeof ClassSorterNode=="undefined"?nil:ClassSorterNode)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+children=[];
+others=[];
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv($recv(each)._superclass()).__eq(self._theClass());
+if($core.assert($1)){
+return $recv(children)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+} else {
+return $recv(others)._add_(each);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self["@nodes"]=$recv(children)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($ClassSorterNode())._on_classes_level_(each,others,$recv(self._level()).__plus((1)));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"getNodesFrom:",{aCollection:aCollection,children:children,others:others},$globals.ClassSorterNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "getNodesFrom: aCollection\x0a\x09| children others |\x0a\x09children := #().\x0a\x09others := #().\x0a\x09aCollection do: [ :each |\x0a\x09\x09(each superclass = self theClass)\x0a\x09\x09\x09ifTrue: [ children add: each ]\x0a\x09\x09\x09ifFalse: [ others add: each ]].\x0a\x09nodes:= children collect: [ :each |\x0a\x09\x09ClassSorterNode on: each classes: others level: self level + 1 ]",
+referencedClasses: ["ClassSorterNode"],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifTrue:ifFalse:", "=", "superclass", "theClass", "add:", "collect:", "on:classes:level:", "+", "level"]
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "level",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@level"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "level\x0a\x09^ level",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "level:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@level"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "level: anInteger\x0a\x09level := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "nodes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@nodes"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nodes\x0a\x09^ nodes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassSorterNode);
+
+$core.addMethod(
+$core.method({
+selector: "traverseClassesWith:",
+protocol: 'visiting',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2;
+$1=self._theClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["theClass"]=1;
+//>>excludeEnd("ctx");
+$recv(aCollection)._add_($1);
+$recv($recv(self._nodes())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=$recv(a)._theClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["theClass"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+return $recv($2).__lt_eq($recv($recv(b)._theClass())._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._do_((function(aNode){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aNode)._traverseClassesWith_(aCollection);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({aNode:aNode},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"traverseClassesWith:",{aCollection:aCollection},$globals.ClassSorterNode)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "traverseClassesWith: aCollection\x0a\x09\x22sort classes alphabetically Issue #143\x22\x0a\x0a\x09aCollection add: self theClass.\x0a\x09(self nodes sorted: [ :a :b | a theClass name <= b theClass name ]) do: [ :aNode |\x0a\x09\x09aNode traverseClassesWith: aCollection ].",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "theClass", "do:", "sorted:", "nodes", "<=", "name", "traverseClassesWith:"]
+}),
+$globals.ClassSorterNode);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:classes:level:",
+protocol: 'instance creation',
+fn: function (aClass,aCollection,anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._theClass_(aClass);
+$recv($2)._level_(anInteger);
+$recv($2)._getNodesFrom_(aCollection);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:classes:level:",{aClass:aClass,aCollection:aCollection,anInteger:anInteger},$globals.ClassSorterNode.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aCollection", "anInteger"],
+source: "on: aClass classes: aCollection level: anInteger\x0a\x09^ self new\x0a\x09\x09theClass: aClass;\x0a\x09\x09level: anInteger;\x0a\x09\x09getNodesFrom: aCollection;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["theClass:", "new", "level:", "getNodesFrom:", "yourself"]
+}),
+$globals.ClassSorterNode.klass);
+
+});

+ 891 - 0
bower_components/amber/src/Kernel-Classes.st

@@ -0,0 +1,891 @@
+Smalltalk createPackage: 'Kernel-Classes'!
+Object subclass: #Behavior
+	instanceVariableNames: ''
+	package: 'Kernel-Classes'!
+!Behavior commentStamp!
+I am the superclass of all class objects.
+
+I define the protocol for creating instances of a class with `#basicNew` and `#new` (see `boot.js` for class constructors details).
+
+My instances know about the subclass/superclass relationships between classes, contain the description that instances are created from,
+and hold the method dictionary that's associated with each class.
+
+I also provides methods for compiling methods, examining the method dictionary, and iterating over the class hierarchy.!
+
+!Behavior methodsFor: 'accessing'!
+
+>> aString
+	^ self methodAt: aString
+!
+
+allInstanceVariableNames
+	| result |
+	result := self instanceVariableNames copy.
+	self superclass ifNotNil: [
+		result addAll: self superclass allInstanceVariableNames ].
+	^ result
+!
+
+allSelectors
+	^ self allSuperclasses
+		inject: self selectors
+		into: [ :acc :each | acc addAll: each selectors; yourself ]
+!
+
+allSubclasses
+	"Answer an collection of the receiver's and the receiver's descendent's subclasses. "
+
+	| subclasses index |
+	
+	subclasses := self subclasses.
+	index := 1.
+	[ index > subclasses size ]
+		whileFalse: [ subclasses addAll: (subclasses at: index) subclasses.
+			index := index + 1 ].
+
+	^ subclasses
+!
+
+allSuperclasses
+	
+	self superclass ifNil: [ ^ #() ].
+	
+	^ (OrderedCollection with: self superclass)
+		addAll: self superclass allSuperclasses;
+		yourself
+!
+
+comment
+	^ (self basicAt: 'comment') ifNil: [ '' ]
+!
+
+comment: aString
+	self basicAt: 'comment' put: aString.
+	SystemAnnouncer current
+		announce: (ClassCommentChanged new
+			theClass: self;
+			yourself)
+!
+
+commentStamp
+	^ ClassCommentReader new
+	class: self;
+	yourself
+!
+
+commentStamp: aStamp prior: prior
+		^ self commentStamp
+!
+
+definition
+	^ ''
+!
+
+instanceVariableNames
+	<return self.iVarNames>
+!
+
+javascriptConstructor
+	"Answer the JS constructor used to instantiate. See boot.js"
+	
+	<return self.fn>
+!
+
+javascriptConstructor: aJavaScriptFunction
+	"Set the JS constructor used to instantiate.
+	See the JS counter-part in boot.js `$core.setClassConstructor'"
+	
+	<$core.setClassConstructor(self, aJavaScriptFunction);>
+!
+
+lookupSelector: selector
+	"Look up the given selector in my methodDictionary.
+	Return the corresponding method if found.
+	Otherwise chase the superclass chain and try again.
+	Return nil if no method is found."
+	
+	| lookupClass |
+	
+	lookupClass := self.
+	[ lookupClass = nil ] whileFalse: [
+		(lookupClass includesSelector: selector)
+				ifTrue: [ ^ lookupClass methodAt: selector ].
+			lookupClass := lookupClass superclass ].
+	^ nil
+!
+
+methodAt: aString
+	^ self methodDictionary at: aString
+!
+
+methodDictionary
+	<var dict = $globals.HashedCollection._new();
+	var methods = self.methods;
+	Object.keys(methods).forEach(function(i) {
+		if(methods[i].selector) {
+			dict._at_put_(methods[i].selector, methods[i]);
+		}
+	});
+	return dict>
+!
+
+methodTemplate
+	^ String streamContents: [ :stream |
+		stream 
+			nextPutAll: 'messageSelectorAndArgumentNames';
+			nextPutAll: String lf, String tab;
+			nextPutAll: '"comment stating purpose of message"';
+			nextPutAll: String lf, String lf, String tab;
+			nextPutAll: '| temporary variable names |';
+			nextPutAll: String lf, String tab;
+			nextPutAll: 'statements' ]
+!
+
+methods
+	^ self methodDictionary values
+!
+
+methodsFor: aString
+	^ ClassCategoryReader new
+		class: self category: aString;
+		yourself
+!
+
+methodsFor: aString stamp: aStamp
+	"Added for file-in compatibility, ignores stamp."
+	^ self methodsFor: aString
+!
+
+methodsInProtocol: aString
+	^ self methods select: [ :each | each protocol = aString ]
+!
+
+name
+	<return self.className || nil>
+!
+
+organization
+	^ self basicAt: 'organization'
+!
+
+ownMethods
+	"Answer the methods of the receiver that are not package extensions"
+
+	^ (self ownProtocols 
+		inject: OrderedCollection new
+		into: [ :acc :each | acc, (self methodsInProtocol: each) ])
+			sorted: [ :a :b | a selector <= b selector ]
+!
+
+ownProtocols
+	"Answer the protocols of the receiver that are not package extensions"
+
+	^ self protocols reject: [ :each |
+		each match: '^\*' ]
+!
+
+protocols
+	^ self organization elements sorted
+!
+
+prototype
+	<return self.fn.prototype>
+!
+
+removeProtocolIfEmpty: aString
+	self methods
+		detect: [ :each | each protocol = aString ]
+		ifNone: [ self organization removeElement: aString ]
+!
+
+selectors
+	^ self methodDictionary keys
+!
+
+subclasses
+	self subclassResponsibility
+!
+
+superclass
+	<return self.superclass || nil>
+!
+
+theMetaClass
+	^ self class
+!
+
+theNonMetaClass
+	^ self
+!
+
+withAllSubclasses
+	^ (Array with: self) addAll: self allSubclasses; yourself
+! !
+
+!Behavior methodsFor: 'compiling'!
+
+addCompiledMethod: aMethod
+	| oldMethod announcement |
+	
+	oldMethod := self methodDictionary
+		at: aMethod selector
+		ifAbsent: [ nil ].
+	
+	(self protocols includes: aMethod protocol)
+		ifFalse: [ self organization addElement: aMethod protocol ].
+
+	self basicAddCompiledMethod: aMethod.
+	
+	oldMethod ifNotNil: [
+		self removeProtocolIfEmpty: oldMethod protocol ].
+	
+	announcement := oldMethod
+		ifNil: [
+			MethodAdded new
+					method: aMethod;
+					yourself ]
+		ifNotNil: [
+			MethodModified new
+					oldMethod: oldMethod;
+					method: aMethod;
+					yourself ].
+					
+					
+	SystemAnnouncer current
+				announce: announcement
+!
+
+compile: aString
+	^ self compile: aString protocol: ''
+!
+
+compile: aString protocol: anotherString
+	^ Compiler new
+		install: aString
+		forClass: self
+		protocol: anotherString
+!
+
+recompile
+	^ Compiler new recompile: self
+!
+
+removeCompiledMethod: aMethod
+	self basicRemoveCompiledMethod: aMethod.
+	
+	self removeProtocolIfEmpty: aMethod protocol.
+	
+	SystemAnnouncer current
+		announce: (MethodRemoved new
+			method: aMethod;
+			yourself)
+! !
+
+!Behavior methodsFor: 'enumerating'!
+
+allSubclassesDo: aBlock
+	"Evaluate the argument, aBlock, for each of the receiver's subclasses."
+
+	self allSubclasses do: [ :each |
+    	aBlock value: each ]
+!
+
+protocolsDo: aBlock
+	"Execute aBlock for each method protocol with
+	its collection of methods in the sort order of protocol name."
+
+	| methodsByProtocol |
+	methodsByProtocol := HashedCollection new.
+	self methodDictionary valuesDo: [ :m |
+		(methodsByProtocol at: m protocol ifAbsentPut: [ Array new ])
+			add: m ].
+	self protocols do: [ :protocol |
+		aBlock value: protocol value: (methodsByProtocol at: protocol) ]
+! !
+
+!Behavior methodsFor: 'instance creation'!
+
+basicNew
+	<return new self.fn()>
+!
+
+new
+	^ self basicNew initialize
+! !
+
+!Behavior methodsFor: 'private'!
+
+basicAddCompiledMethod: aMethod
+	<$core.addMethod(aMethod, self)>
+!
+
+basicRemoveCompiledMethod: aMethod
+	<$core.removeMethod(aMethod,self)>
+! !
+
+!Behavior methodsFor: 'testing'!
+
+canUnderstand: aSelector
+	^ (self includesSelector: aSelector asString) or: [
+		self superclass notNil and: [ self superclass canUnderstand: aSelector ]]
+!
+
+includesBehavior: aClass
+	^ self == aClass or: [
+			self inheritsFrom: aClass ]
+!
+
+includesSelector: aString
+	^ self methodDictionary includesKey: aString
+!
+
+inheritsFrom: aClass
+	self superclass ifNil: [ ^ false ].
+
+	^ aClass == self superclass or: [ 
+		self superclass inheritsFrom: aClass ]
+!
+
+isBehavior
+	^ true
+! !
+
+Behavior subclass: #Class
+	instanceVariableNames: ''
+	package: 'Kernel-Classes'!
+!Class commentStamp!
+I am __the__ class object.
+
+My instances are the classes of the system.
+Class creation is done throught a `ClassBuilder` instance.!
+
+!Class methodsFor: 'accessing'!
+
+category
+	^ self package ifNil: [ 'Unclassified' ] ifNotNil: [ self package name ]
+!
+
+definition
+	^ String streamContents: [ :stream |
+		stream
+			nextPutAll: self superclass asString;
+			nextPutAll: ' subclass: #';
+			nextPutAll: self name;
+			nextPutAll: String lf, String tab;
+			nextPutAll: 'instanceVariableNames: '''.
+		self instanceVariableNames
+			do: [ :each | stream nextPutAll: each ]
+			separatedBy: [ stream nextPutAll: ' ' ].
+		stream
+			nextPutAll: '''', String lf, String tab;
+			nextPutAll: 'package: ''';
+			nextPutAll: self category;
+			nextPutAll: '''' ]
+!
+
+heliosClass
+	"Should be an Helios extension. Unfortunately, since helios can browse remote
+	environments, we can't extend base classes"
+	
+	^ 'class'
+!
+
+package
+	^ self basicAt: 'pkg'
+!
+
+package: aPackage
+	| oldPackage |
+	
+	self package = aPackage ifTrue: [ ^ self ].
+	
+	oldPackage := self package.
+	
+	self basicAt: 'pkg' put: aPackage.
+	oldPackage organization removeElement: self.
+	aPackage organization addElement: self.
+
+	SystemAnnouncer current announce: (ClassMoved new
+		theClass: self;
+		oldPackage: oldPackage;
+		yourself)
+!
+
+rename: aString
+	ClassBuilder new renameClass: self to: aString
+!
+
+subclasses
+	<return self.subclasses._copy()>
+! !
+
+!Class methodsFor: 'browsing'!
+
+browse
+	Finder findClass: self
+! !
+
+!Class methodsFor: 'class creation'!
+
+subclass: aString instanceVariableNames: anotherString
+	"Kept for file-in compatibility."
+	^ self subclass: aString instanceVariableNames: anotherString package: nil
+!
+
+subclass: aString instanceVariableNames: aString2 category: aString3
+	"Kept for file-in compatibility."
+	^ self subclass: aString instanceVariableNames: aString2 package: aString3
+!
+
+subclass: aString instanceVariableNames: aString2 classVariableNames: classVars poolDictionaries: pools category: aString3
+	"Kept for file-in compatibility. ignores class variables and pools."
+	^ self subclass: aString instanceVariableNames: aString2 package: aString3
+!
+
+subclass: aString instanceVariableNames: aString2 package: aString3
+	^ ClassBuilder new
+		superclass: self subclass: aString asString instanceVariableNames: aString2 package: aString3
+! !
+
+!Class methodsFor: 'converting'!
+
+asJavascript
+	^ '$globals.', self name
+! !
+
+!Class methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: self name
+! !
+
+!Class methodsFor: 'testing'!
+
+isClass
+	^ true
+! !
+
+Behavior subclass: #Metaclass
+	instanceVariableNames: ''
+	package: 'Kernel-Classes'!
+!Metaclass commentStamp!
+I am the root of the class hierarchy.
+
+My instances are metaclasses, one for each real class, and have a single instance, which they hold onto: the class that they are the metaclass of.!
+
+!Metaclass methodsFor: 'accessing'!
+
+definition
+	^ String streamContents: [ :stream |
+		stream
+			nextPutAll: self asString;
+			nextPutAll: ' instanceVariableNames: '''.
+		self instanceVariableNames
+			do: [ :each | stream nextPutAll: each ]
+			separatedBy: [ stream nextPutAll: ' ' ].
+		stream nextPutAll: '''' ]
+!
+
+instanceClass
+	<return self.instanceClass>
+!
+
+instanceVariableNames: aCollection
+	ClassBuilder new
+		class: self instanceVariableNames: aCollection
+!
+
+package
+	^ self instanceClass package
+!
+
+subclasses
+	^ (self instanceClass subclasses 
+		select: [ :each | each isMetaclass not ])
+		collect: [ :each | each theMetaClass ]
+!
+
+theMetaClass
+	^ self
+!
+
+theNonMetaClass
+	^ self instanceClass
+! !
+
+!Metaclass methodsFor: 'converting'!
+
+asJavascript
+	^ '$globals.', self instanceClass name, '.klass'
+! !
+
+!Metaclass methodsFor: 'printing'!
+
+printOn: aStream
+	aStream
+		nextPutAll: self instanceClass name;
+		nextPutAll: ' class'
+! !
+
+!Metaclass methodsFor: 'testing'!
+
+isMetaclass
+	^ true
+! !
+
+Object subclass: #ClassBuilder
+	instanceVariableNames: ''
+	package: 'Kernel-Classes'!
+!ClassBuilder commentStamp!
+I am responsible for compiling new classes or modifying existing classes in the system.
+
+Rather than using me directly to compile a class, use `Class >> subclass:instanceVariableNames:package:`.!
+
+!ClassBuilder methodsFor: 'accessing'!
+
+instanceVariableNamesFor: aString
+	^ (aString tokenize: ' ') reject: [ :each | each isEmpty ]
+! !
+
+!ClassBuilder methodsFor: 'class definition'!
+
+addSubclassOf: aClass named: className instanceVariableNames: aCollection package: packageName
+	| theClass thePackage |
+	
+	theClass := Smalltalk globals at: className.
+	thePackage := Package named: packageName.
+	
+	theClass ifNotNil: [
+		theClass package: thePackage.
+		theClass superclass == aClass ifFalse: [
+			^ self
+				migrateClassNamed: className
+				superclass: aClass
+				instanceVariableNames: aCollection
+				package: packageName ] ].
+		
+	^ self
+		basicAddSubclassOf: aClass
+		named: className
+		instanceVariableNames: aCollection
+		package: packageName
+!
+
+class: aClass instanceVariableNames: ivarNames
+	self basicClass: aClass instanceVariableNames: ivarNames.
+	self setupClass: aClass.
+	
+	SystemAnnouncer current
+		announce: (ClassDefinitionChanged new
+			theClass: aClass;
+			yourself)
+!
+
+superclass: aClass subclass: className
+	^ self superclass: aClass subclass: className instanceVariableNames: '' package: nil
+!
+
+superclass: aClass subclass: className instanceVariableNames: ivarNames package: packageName
+	| newClass |
+	
+	newClass := self addSubclassOf: aClass
+		named: className instanceVariableNames: (self instanceVariableNamesFor: ivarNames)
+		package: (packageName ifNil: [ 'unclassified' ]).
+	self setupClass: newClass.
+	
+	SystemAnnouncer current
+		announce: (ClassAdded new
+			theClass: newClass;
+			yourself).
+	
+	^ newClass
+! !
+
+!ClassBuilder methodsFor: 'class migration'!
+
+migrateClass: aClass superclass: anotherClass
+	^ self
+		migrateClassNamed: aClass name
+		superclass: anotherClass
+		instanceVariableNames: aClass instanceVariableNames
+		package: aClass package name
+!
+
+migrateClassNamed: className superclass: aClass instanceVariableNames: aCollection package: packageName
+	| oldClass newClass tmp |
+	
+	tmp := 'new*', className.
+	oldClass := Smalltalk globals at: className.
+	
+	newClass := self
+		addSubclassOf: aClass
+		named: tmp
+		instanceVariableNames: aCollection
+		package: packageName.
+
+	self basicSwapClassNames: oldClass with: newClass.
+
+	[ self copyClass: oldClass to: newClass ]
+		on: Error
+		do: [ :exception |
+			self
+				basicSwapClassNames: oldClass with: newClass;
+				basicRemoveClass: newClass.
+			exception signal ].
+
+	self
+		rawRenameClass: oldClass to: tmp;
+		rawRenameClass: newClass to: className.
+
+	oldClass subclasses 
+		do: [ :each | self migrateClass: each superclass: newClass ].
+
+	self basicRemoveClass: oldClass.
+	
+	SystemAnnouncer current announce: (ClassMigrated new
+		theClass: newClass;
+		oldClass: oldClass;
+		yourself).
+	
+	^ newClass
+!
+
+renameClass: aClass to: className
+	self basicRenameClass: aClass to: className.
+	
+	"Recompile the class to fix potential issues with super sends"
+	aClass recompile.
+	
+	SystemAnnouncer current
+		announce: (ClassRenamed new
+			theClass: aClass;
+			yourself)
+! !
+
+!ClassBuilder methodsFor: 'copying'!
+
+copyClass: aClass named: className
+	| newClass |
+
+	newClass := self
+		addSubclassOf: aClass superclass
+		named: className
+		instanceVariableNames: aClass instanceVariableNames
+		package: aClass package name.
+
+	self copyClass: aClass to: newClass.
+	
+	SystemAnnouncer current
+		announce: (ClassAdded new
+			theClass: newClass;
+			yourself).
+	
+	^ newClass
+!
+
+copyClass: aClass to: anotherClass
+
+	anotherClass comment: aClass comment.
+
+	aClass methodDictionary valuesDo: [ :each |
+		Compiler new install: each source forClass: anotherClass protocol: each protocol ].
+
+	self basicClass: anotherClass class instanceVariables: aClass class instanceVariableNames.
+
+	aClass class methodDictionary valuesDo: [ :each |
+		Compiler new install: each source forClass: anotherClass class protocol: each protocol ].
+
+	self setupClass: anotherClass
+! !
+
+!ClassBuilder methodsFor: 'method definition'!
+
+installMethod: aCompiledMethod forClass: aBehavior protocol: aString
+	aCompiledMethod protocol: aString.
+	aBehavior addCompiledMethod: aCompiledMethod.
+	^ aCompiledMethod
+! !
+
+!ClassBuilder methodsFor: 'private'!
+
+basicAddSubclassOf: aClass named: aString instanceVariableNames: aCollection package: packageName
+	<
+		$core.addClass(aString, aClass, aCollection, packageName);
+		return $globals[aString]
+	>
+!
+
+basicClass: aClass instanceVariableNames: aString
+	self basicClass: aClass instanceVariables: (self instanceVariableNamesFor: aString)
+!
+
+basicClass: aClass instanceVariables: aCollection
+
+	aClass isMetaclass ifFalse: [ self error: aClass name, ' is not a metaclass' ].
+	aClass basicAt: 'iVarNames' put: aCollection
+!
+
+basicRemoveClass: aClass
+	<$core.removeClass(aClass)>
+!
+
+basicRenameClass: aClass to: aString
+	<
+		$globals[aString] = aClass;
+		delete $globals[aClass.className];
+		aClass.className = aString;
+	>
+!
+
+basicSwapClassNames: aClass with: anotherClass
+	<
+		var tmp = aClass.className;
+		aClass.className = anotherClass.className;
+		anotherClass.className = tmp;
+	>
+!
+
+rawRenameClass: aClass to: aString
+	<
+		$globals[aString] = aClass;
+	>
+! !
+
+!ClassBuilder methodsFor: 'public'!
+
+setupClass: aClass
+	<$core.init(aClass);>
+! !
+
+Object subclass: #ClassCategoryReader
+	instanceVariableNames: 'class category'
+	package: 'Kernel-Classes'!
+!ClassCategoryReader commentStamp!
+I provide a mechanism for retrieving class descriptions stored on a file in the Smalltalk chunk format.!
+
+!ClassCategoryReader methodsFor: 'accessing'!
+
+class: aClass category: aString
+	class := aClass.
+	category := aString
+! !
+
+!ClassCategoryReader methodsFor: 'fileIn'!
+
+scanFrom: aChunkParser
+	| chunk |
+	[ chunk := aChunkParser nextChunk.
+	chunk isEmpty ] whileFalse: [
+		self compileMethod: chunk ].
+	ClassBuilder new setupClass: class
+! !
+
+!ClassCategoryReader methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+! !
+
+!ClassCategoryReader methodsFor: 'private'!
+
+compileMethod: aString
+	Compiler new install: aString forClass: class protocol: category
+! !
+
+Object subclass: #ClassCommentReader
+	instanceVariableNames: 'class'
+	package: 'Kernel-Classes'!
+!ClassCommentReader commentStamp!
+I provide a mechanism for retrieving class comments stored on a file.
+
+See also `ClassCategoryReader`.!
+
+!ClassCommentReader methodsFor: 'accessing'!
+
+class: aClass
+	class := aClass
+! !
+
+!ClassCommentReader methodsFor: 'fileIn'!
+
+scanFrom: aChunkParser
+	| chunk |
+	chunk := aChunkParser nextChunk.
+	chunk isEmpty ifFalse: [
+		self setComment: chunk ].
+! !
+
+!ClassCommentReader methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+! !
+
+!ClassCommentReader methodsFor: 'private'!
+
+setComment: aString
+	class comment: aString
+! !
+
+Object subclass: #ClassSorterNode
+	instanceVariableNames: 'theClass level nodes'
+	package: 'Kernel-Classes'!
+!ClassSorterNode commentStamp!
+I provide an algorithm for sorting classes alphabetically.
+
+See [Issue #143](https://github.com/amber-smalltalk/amber/issues/143) on GitHub.!
+
+!ClassSorterNode methodsFor: 'accessing'!
+
+getNodesFrom: aCollection
+	| children others |
+	children := #().
+	others := #().
+	aCollection do: [ :each |
+		(each superclass = self theClass)
+			ifTrue: [ children add: each ]
+			ifFalse: [ others add: each ]].
+	nodes:= children collect: [ :each |
+		ClassSorterNode on: each classes: others level: self level + 1 ]
+!
+
+level
+	^ level
+!
+
+level: anInteger
+	level := anInteger
+!
+
+nodes
+	^ nodes
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+!ClassSorterNode methodsFor: 'visiting'!
+
+traverseClassesWith: aCollection
+	"sort classes alphabetically Issue #143"
+
+	aCollection add: self theClass.
+	(self nodes sorted: [ :a :b | a theClass name <= b theClass name ]) do: [ :aNode |
+		aNode traverseClassesWith: aCollection ].
+! !
+
+!ClassSorterNode class methodsFor: 'instance creation'!
+
+on: aClass classes: aCollection level: anInteger
+	^ self new
+		theClass: aClass;
+		level: anInteger;
+		getNodesFrom: aCollection;
+		yourself
+! !
+

+ 10040 - 0
bower_components/amber/src/Kernel-Collections.js

@@ -0,0 +1,10040 @@
+define("amber_core/Kernel-Collections", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Collections');
+$core.packages["Kernel-Collections"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Association', $globals.Object, ['key', 'value'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Association.comment="I represent a pair of associated objects, a key and a value. My instances can serve as entries in a dictionary.\x0a\x0aInstances can be created with the class-side method `#key:value:`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (anAssociation){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$5,$4,$6,$1;
+$3=self._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__eq($recv(anAssociation)._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=self._key();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["key"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__eq($recv(anAssociation)._key());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=2;
+//>>excludeEnd("ctx");
+return $recv($4)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$6=self._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+return $recv($6).__eq($recv(anAssociation)._value());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["and:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{anAssociation:anAssociation},$globals.Association)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAssociation"],
+source: "= anAssociation\x0a\x09^ self class = anAssociation class and: [\x0a\x09\x09self key = anAssociation key and: [\x0a\x09\x09self value = anAssociation value ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "=", "class", "key", "value"]
+}),
+$globals.Association);
+
+$core.addMethod(
+$core.method({
+selector: "key",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@key"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "key\x0a\x09^ key",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Association);
+
+$core.addMethod(
+$core.method({
+selector: "key:",
+protocol: 'accessing',
+fn: function (aKey){
+var self=this;
+self["@key"]=aKey;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "key: aKey\x0a\x09key := aKey",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Association);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._key())._printOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printOn:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(" -> ");
+$recv(self._value())._printOn_(aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Association)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09self key printOn: aStream.\x0a\x09aStream nextPutAll: ' -> '.\x0a\x09self value printOn: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "key", "nextPutAll:", "value"]
+}),
+$globals.Association);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@value"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Association);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'accessing',
+fn: function (aValue){
+var self=this;
+self["@value"]=aValue;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aValue"],
+source: "value: aValue\x0a\x09value := aValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Association);
+
+
+$core.addMethod(
+$core.method({
+selector: "key:value:",
+protocol: 'instance creation',
+fn: function (aKey,aValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._key_(aKey);
+$recv($2)._value_(aValue);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"key:value:",{aKey:aKey,aValue:aValue},$globals.Association.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aValue"],
+source: "key: aKey value: aValue\x0a\x09\x09^ self new\x0a\x09\x09key: aKey;\x0a\x09\x09value: aValue;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["key:", "new", "value:", "yourself"]
+}),
+$globals.Association.klass);
+
+
+$core.addClass('BucketStore', $globals.Object, ['buckets', 'hashBlock'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.BucketStore.comment="I am an helper class for hash-based stores.\x0a\x0aI hold buckets which are selected by a hash, specified using `#hashBlock:`.\x0aThe hash can be any object, and\x0ait is used as a JS property (that is, in ES5\x0aits toString() value counts).\x0a\x0a## API\x0aI maintain a list of buckets. Client code can use this API:\x0a - `#bucketOfElement:` (to ask a bucket for element, I can return JS null if n/a)\x0a - `#do:` (to enumerate all elements of all buckets)\x0a - `#removeAll` (to remove all buckets)\x0a\x0aClient code itself should add/remove elements\x0ain a bucket. The `nil` object should not be put into any bucket.\x0a\x0aTypes of buckets are the responsibility of subclasses via `#newBucket`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "bucketOfElement:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var hash = self['@hashBlock'](anObject);
+		if (!hash) return null;
+		var buckets = self['@buckets'],
+			bucket = buckets[hash];
+		if (!bucket) { bucket = buckets[hash] = self._newBucket(); }
+		return bucket;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"bucketOfElement:",{anObject:anObject},$globals.BucketStore)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "bucketOfElement: anObject\x0a\x09<\x0a\x09\x09var hash = self['@hashBlock'](anObject);\x0a\x09\x09if (!hash) return null;\x0a\x09\x09var buckets = self['@buckets'],\x0a\x09\x09\x09bucket = buckets[hash];\x0a\x09\x09if (!bucket) { bucket = buckets[hash] = self._newBucket(); }\x0a\x09\x09return bucket;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BucketStore);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var buckets = self['@buckets'];
+		var keys = Object.keys(buckets);
+		for (var i = 0; i < keys.length; ++i) { buckets[keys[i]]._do_(aBlock); }
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.BucketStore)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09<\x0a\x09\x09var buckets = self['@buckets'];\x0a\x09\x09var keys = Object.keys(buckets);\x0a\x09\x09for (var i = 0; i < keys.length; ++i) { buckets[keys[i]]._do_(aBlock); }\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BucketStore);
+
+$core.addMethod(
+$core.method({
+selector: "hashBlock:",
+protocol: 'accessing',
+fn: function (aBlock){
+var self=this;
+self["@hashBlock"]=aBlock;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "hashBlock: aBlock\x0a\x09hashBlock := aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BucketStore);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.BucketStore.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self._removeAll();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.BucketStore)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09self removeAll",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "removeAll"]
+}),
+$globals.BucketStore);
+
+$core.addMethod(
+$core.method({
+selector: "newBucket",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newBucket",{},$globals.BucketStore)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newBucket\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.BucketStore);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self['@buckets'] = Object.create(null);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.BucketStore)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09<self['@buckets'] = Object.create(null);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BucketStore);
+
+
+$core.addMethod(
+$core.method({
+selector: "hashBlock:",
+protocol: 'instance creation',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._hashBlock_(aBlock);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hashBlock:",{aBlock:aBlock},$globals.BucketStore.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "hashBlock: aBlock\x0a\x09^ self new\x0a\x09\x09hashBlock: aBlock;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["hashBlock:", "new", "yourself"]
+}),
+$globals.BucketStore.klass);
+
+
+$core.addClass('ArrayBucketStore', $globals.BucketStore, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ArrayBucketStore.comment="I am a concrete `BucketStore` with buckets being instance of `Array`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "newBucket",
+protocol: 'private',
+fn: function (){
+var self=this;
+var $1;
+$1=[];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newBucket\x0a\x09^ #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ArrayBucketStore);
+
+
+
+$core.addClass('Collection', $globals.Object, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Collection.comment="I am the abstract superclass of all classes that represent a group of elements.\x0a\x0aI provide a set of useful methods to the Collection hierarchy such as enumerating and converting methods.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: ",",
+protocol: 'copying',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._copy();
+$recv($2)._addAll_(aCollection);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,",",{aCollection:aCollection},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: ", aCollection\x0a\x09^ self copy\x0a\x09\x09addAll: aCollection;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "copy", "yourself"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anObject:anObject},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "add: anObject\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "addAll:",
+protocol: 'adding/removing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return aCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addAll:",{aCollection:aCollection},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "addAll: aCollection\x0a\x09aCollection do: [ :each |\x0a\x09\x09self add: each ].\x0a\x09^ aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "add:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "allSatisfy:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(each);
+if(!$core.assert($1)){
+throw $early=[false];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return true;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSatisfy:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "allSatisfy: aBlock\x0a\x09\x22Evaluate aBlock with the elements of the receiver.\x0a\x09If aBlock returns false for any element return false.\x0a\x09Otherwise return true.\x22\x0a\x0a\x09self do: [ :each | (aBlock value: each) ifFalse: [ ^ false ] ].\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifFalse:", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "anyOne",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $early={};
+try {
+self._ifEmpty_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Collection is empty");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self._do_((function(each){
+throw $early=[each];
+
+}));
+return self;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"anyOne",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "anyOne\x0a\x09\x22Answer a representative sample of the receiver. This method can\x0a\x09be helpful when needing to preinfer the nature of the contents of \x0a\x09semi-homogeneous collections.\x22\x0a\x0a\x09self ifEmpty: [ self error: 'Collection is empty' ].\x0a\x09self do: [ :each | ^ each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifEmpty:", "error:", "do:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "anySatisfy:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(each);
+if($core.assert($1)){
+throw $early=[true];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return false;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"anySatisfy:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "anySatisfy: aBlock\x0a\x09\x22Evaluate aBlock with the elements of the receiver.\x0a\x09If aBlock returns true for any element return true.\x0a\x09Otherwise return false.\x22\x0a\x0a\x09self do: [ :each | (aBlock value: each) ifTrue: [ ^ true ] ].\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifTrue:", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "asArray",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Array())._withAll_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asArray",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asArray\x0a\x09^ Array withAll: self",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["withAll:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asArray())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._asJSON();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSON",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ self asArray collect: [ :each | each asJSON ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "asArray", "asJSON"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "asOrderedCollection",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._asArray();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asOrderedCollection",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asOrderedCollection\x0a\x09^ self asArray",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asArray"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "asSet",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Set())._withAll_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSet",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSet\x0a\x09^ Set withAll: self",
+referencedClasses: ["Set"],
+//>>excludeEnd("ide");
+messageSends: ["withAll:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "collect:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+stream=$recv($recv(self._class())._new())._writeStream();
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPut_($recv(aBlock)._value_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=$recv(stream)._contents();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"collect:",{aBlock:aBlock,stream:stream},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "collect: aBlock\x0a\x09| stream |\x0a\x09stream := self class new writeStream.\x0a\x09self do: [ :each |\x0a\x09\x09stream nextPut: (aBlock value: each) ].\x0a\x09^ stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["writeStream", "new", "class", "do:", "nextPut:", "value:", "contents"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "contains:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=self._anySatisfy_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contains:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "contains: aBlock\x0a\x09self deprecatedAPI.\x0a\x0a\x09^ self anySatisfy: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "anySatisfy:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "copyWith:",
+protocol: 'copying',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._copy();
+$recv($2)._add_(anObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyWith:",{anObject:anObject},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "copyWith: anObject\x0a\x09^ self copy add: anObject; yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "copy", "yourself"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "copyWithAll:",
+protocol: 'copying',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._copy();
+$recv($2)._addAll_(aCollection);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyWithAll:",{aCollection:aCollection},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "copyWithAll: aCollection\x0a\x09^ self copy addAll: aCollection; yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "copy", "yourself"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "copyWithoutAll:",
+protocol: 'copying',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._reject_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aCollection)._includes_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyWithoutAll:",{aCollection:aCollection},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "copyWithoutAll: aCollection\x0a\x09\x22Answer a copy of the receiver that does not contain any elements\x0a\x09equal to those in aCollection.\x22\x0a\x0a\x09^ self reject: [ :each | aCollection includes: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reject:", "includes:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "detect:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._detect_ifNone_(aBlock,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"detect:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "detect: aBlock\x0a\x09^ self detect: aBlock ifNone: [ self errorNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["detect:ifNone:", "errorNotFound"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "detect:ifNone:",
+protocol: 'enumerating',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"detect:ifNone:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "detect: aBlock ifNone: anotherBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "do:separatedBy:",
+protocol: 'enumerating',
+fn: function (aBlock,anotherBlock){
+var self=this;
+var actionBeforeElement;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+actionBeforeElement=(function(){
+actionBeforeElement=anotherBlock;
+return actionBeforeElement;
+
+});
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(actionBeforeElement)._value();
+return $recv(aBlock)._value_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:separatedBy:",{aBlock:aBlock,anotherBlock:anotherBlock,actionBeforeElement:actionBeforeElement},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "do: aBlock separatedBy: anotherBlock\x0a\x09| actionBeforeElement |\x0a\x09actionBeforeElement := [ actionBeforeElement := anotherBlock ].\x0a\x09self do: [ :each |\x0a\x09\x09actionBeforeElement value.\x0a\x09\x09aBlock value: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "value", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "errorNotFound",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("Object is not in the collection");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"errorNotFound",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "errorNotFound\x0a\x09self error: 'Object is not in the collection'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "ifEmpty:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._isEmpty();
+$1=$recv($2)._ifTrue_ifFalse_(aBlock,(function(){
+return self;
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifEmpty:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifEmpty: aBlock\x0a\x09\x22Evaluate the given block with the receiver as argument, answering its value if the receiver is empty, otherwise answer the receiver. \x0a\x09Note that the fact that this method returns its argument in case the receiver is not empty allows one to write expressions like the following ones: \x0a\x09\x09self classifyMethodAs:\x0a\x09\x09\x09(myProtocol ifEmpty: ['As yet unclassified'])\x22\x0a\x09^ self isEmpty\x0a\x09\x09ifTrue: aBlock\x0a\x09\x09ifFalse: [ self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isEmpty"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "ifEmpty:ifNotEmpty:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._isEmpty();
+$1=$recv($2)._ifTrue_ifFalse_(aBlock,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(anotherBlock)._value_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifEmpty:ifNotEmpty:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifEmpty: aBlock ifNotEmpty: anotherBlock\x0a\x09^ self isEmpty\x0a\x09\x09ifTrue: aBlock\x0a\x09\x09ifFalse: [ anotherBlock value: self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isEmpty", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotEmpty:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._notEmpty();
+if($core.assert($2)){
+$1=$recv(aBlock)._value_(self);
+} else {
+$1=self;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotEmpty:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifNotEmpty: aBlock\x0a\x09^ self notEmpty\x0a\x09\x09ifTrue: [ aBlock value: self ]\x0a\x09\x09ifFalse: [ self ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "notEmpty", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotEmpty:ifEmpty:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._notEmpty();
+$1=$recv($2)._ifTrue_ifFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),anotherBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotEmpty:ifEmpty:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifNotEmpty: aBlock ifEmpty: anotherBlock\x0a\x09^ self notEmpty\x0a\x09\x09ifTrue: [ aBlock value: self ]\x0a\x09\x09ifFalse: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "notEmpty", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "includes:",
+protocol: 'testing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._anySatisfy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each).__eq(anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includes:",{anObject:anObject},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "includes: anObject\x0a\x09^ self anySatisfy: [ :each | each = anObject ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["anySatisfy:", "="]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "inject:into:",
+protocol: 'enumerating',
+fn: function (anObject,aBlock){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+result=anObject;
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+result=$recv(aBlock)._value_value_(result,each);
+return result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=result;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inject:into:",{anObject:anObject,aBlock:aBlock,result:result},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "inject: anObject into: aBlock\x0a\x09| result |\x0a\x09result := anObject.\x0a\x09self do: [ :each |\x0a\x09\x09result := aBlock value: result value: each ].\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "value:value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "intersection:",
+protocol: 'enumerating',
+fn: function (aCollection){
+var self=this;
+var set,outputSet;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3;
+set=self._asSet();
+outputSet=$recv($Set())._new();
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(set)._includes_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["includes:"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv(outputSet)._includes_(each))._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+return $recv(outputSet)._add_(each);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$3=$recv(self._class())._withAll_($recv(outputSet)._asArray());
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"intersection:",{aCollection:aCollection,set:set,outputSet:outputSet},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "intersection: aCollection\x0a\x09\x22Answer the set theoretic intersection of two collections.\x22\x0a\x0a\x09| set outputSet |\x0a\x09\x0a\x09set := self asSet.\x0a\x09outputSet := Set new.\x0a\x09\x0a\x09aCollection do: [ :each |\x0a\x09\x09((set includes: each) and: [ (outputSet includes: each) not ])\x0a\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09outputSet add: each ]].\x0a\x09\x09\x0a\x09^ self class withAll: outputSet asArray",
+referencedClasses: ["Set"],
+//>>excludeEnd("ide");
+messageSends: ["asSet", "new", "do:", "ifTrue:", "and:", "includes:", "not", "add:", "withAll:", "class", "asArray"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "isEmpty",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._size()).__eq((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isEmpty",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isEmpty\x0a\x09^ self size = 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "size"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "noneSatisfy:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+self._do_((function(item){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(item);
+if($core.assert($1)){
+throw $early=[false];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({item:item},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return true;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"noneSatisfy:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "noneSatisfy: aBlock\x0a\x09\x22Evaluate aBlock with the elements of the receiver.\x0a\x09If aBlock returns false for all elements return true.\x0a\x09Otherwise return false\x22\x0a\x0a\x09self do: [ :item | (aBlock value: item) ifTrue: [ ^ false ] ].\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifTrue:", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "notEmpty",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._isEmpty())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"notEmpty",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "notEmpty\x0a\x09^ self isEmpty not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isEmpty"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "occurrencesOf:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+var tally;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+tally=(0);
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(anObject).__eq(each);
+if($core.assert($1)){
+tally=$recv(tally).__plus((1));
+return tally;
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=tally;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"occurrencesOf:",{anObject:anObject,tally:tally},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "occurrencesOf: anObject\x0a\x09\x22Answer how many of the receiver's elements are equal to anObject.\x22\x0a\x0a\x09| tally |\x0a\x09tally := 0.\x0a\x09self do: [ :each | anObject = each ifTrue: [ tally := tally + 1 ]].\x0a\x09^ tally",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifTrue:", "=", "+"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "putOn:",
+protocol: 'streaming',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._putOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"putOn:",{aStream:aStream},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "putOn: aStream\x0a\x09self do: [ :each | each putOn: aStream ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "putOn:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "reject:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(aBlock)._value_(each)).__eq(false);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reject:",{aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "reject: aBlock\x0a\x09^ self select: [ :each | (aBlock value: each) = false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["select:", "=", "value:"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "remove:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._remove_ifAbsent_(anObject,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:",{anObject:anObject},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "remove: anObject\x0a\x09^ self remove: anObject ifAbsent: [ self errorNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:ifAbsent:", "errorNotFound"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "remove:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (anObject,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:ifAbsent:",{anObject:anObject,aBlock:aBlock},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "remove: anObject ifAbsent: aBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "select:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+stream=$recv($recv(self._class())._new())._writeStream();
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(each);
+if($core.assert($1)){
+return $recv(stream)._nextPut_(each);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv(stream)._contents();
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select:",{aBlock:aBlock,stream:stream},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "select: aBlock\x0a\x09| stream |\x0a\x09stream := self class new writeStream.\x0a\x09self do: [ :each |\x0a\x09\x09(aBlock value: each) ifTrue: [\x0a\x09\x09stream nextPut: each ] ].\x0a\x09^ stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["writeStream", "new", "class", "do:", "ifTrue:", "value:", "nextPut:", "contents"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "select:thenCollect:",
+protocol: 'enumerating',
+fn: function (selectBlock,collectBlock){
+var self=this;
+var stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+stream=$recv($recv(self._class())._new())._writeStream();
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(selectBlock)._value_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value:"]=1;
+//>>excludeEnd("ctx");
+if($core.assert($1)){
+return $recv(stream)._nextPut_($recv(collectBlock)._value_(each));
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv(stream)._contents();
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select:thenCollect:",{selectBlock:selectBlock,collectBlock:collectBlock,stream:stream},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["selectBlock", "collectBlock"],
+source: "select: selectBlock thenCollect: collectBlock\x0a\x09| stream |\x0a\x09stream := self class new writeStream.\x0a\x09self do: [ :each |\x0a\x09\x09(selectBlock value: each) ifTrue: [\x0a\x09\x09stream nextPut: (collectBlock value: each) ] ].\x0a\x09^ stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["writeStream", "new", "class", "do:", "ifTrue:", "value:", "nextPut:", "contents"]
+}),
+$globals.Collection);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.Collection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Collection);
+
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "collection";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'collection'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Collection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new:",
+protocol: 'instance creation',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new:",{anInteger:anInteger},$globals.Collection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "new: anInteger\x0a\x09^ self new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.Collection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:",
+protocol: 'instance creation',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._add_(anObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},$globals.Collection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "with: anObject\x0a\x09\x09^ self new\x0a\x09\x09add: anObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "new", "yourself"]
+}),
+$globals.Collection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:with:",
+protocol: 'instance creation',
+fn: function (anObject,anotherObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._add_(anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._add_(anotherObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:with:",{anObject:anObject,anotherObject:anotherObject},$globals.Collection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anotherObject"],
+source: "with: anObject with: anotherObject\x0a\x09\x09^ self new\x0a\x09\x09add: anObject;\x0a\x09\x09add: anotherObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "new", "yourself"]
+}),
+$globals.Collection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:with:with:",
+protocol: 'instance creation',
+fn: function (firstObject,secondObject,thirdObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._add_(firstObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._add_(secondObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._add_(thirdObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:with:with:",{firstObject:firstObject,secondObject:secondObject,thirdObject:thirdObject},$globals.Collection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstObject", "secondObject", "thirdObject"],
+source: "with: firstObject with: secondObject with: thirdObject\x0a\x09\x09^ self new\x0a\x09\x09add: firstObject;\x0a\x09\x09add: secondObject;\x0a\x09\x09add: thirdObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "new", "yourself"]
+}),
+$globals.Collection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "withAll:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._addAll_(aCollection);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withAll:",{aCollection:aCollection},$globals.Collection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "withAll: aCollection\x0a\x09\x09^ self new\x0a\x09\x09addAll: aCollection;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "new", "yourself"]
+}),
+$globals.Collection.klass);
+
+
+$core.addClass('IndexableCollection', $globals.Collection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.IndexableCollection.comment="I am a key-value store collection, that is,\x0aI store values under indexes.\x0a\x0aAs a rule of thumb, if a collection has `#at:` and `#at:put:`,\x0ait is an IndexableCollection.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "at:",
+protocol: 'accessing',
+fn: function (anIndex){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_ifAbsent_(anIndex,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:",{anIndex:anIndex},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex"],
+source: "at: anIndex\x0a\x09\x22Lookup the given index in the receiver.\x0a\x09If it is present, answer the value stored at anIndex.\x0a\x09Otherwise, raise an error.\x22\x0a\x0a\x09^ self at: anIndex ifAbsent: [ self errorNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "errorNotFound"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{anIndex:anIndex,aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock"],
+source: "at: anIndex ifAbsent: aBlock\x0a\x09\x22Lookup the given index in the receiver.\x0a\x09If it is present, answer the value stored at anIndex.\x0a\x09Otherwise, answer the value of aBlock.\x22\x0a\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsentPut:",
+protocol: 'accessing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_ifAbsent_(aKey,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._at_put_(aKey,$recv(aBlock)._value());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsentPut:",{aKey:aKey,aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "at: aKey ifAbsentPut: aBlock\x0a\x09^ self at: aKey ifAbsent: [\x0a\x09\x09self at: aKey put: aBlock value ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "at:put:", "value"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_ifPresent_ifAbsent_(anIndex,aBlock,(function(){
+return nil;
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:",{anIndex:anIndex,aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock"],
+source: "at: anIndex ifPresent: aBlock\x0a\x09\x22Lookup the given index in the receiver.\x0a\x09If it is present, answer the value of evaluating aBlock with the value stored at anIndex.\x0a\x09Otherwise, answer nil.\x22\x0a\x0a\x09^ self at: anIndex ifPresent: aBlock ifAbsent: [ nil ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifPresent:ifAbsent:"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:ifAbsent:",{anIndex:anIndex,aBlock:aBlock,anotherBlock:anotherBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock", "anotherBlock"],
+source: "at: anIndex ifPresent: aBlock ifAbsent: anotherBlock\x0a\x09\x22Lookup the given index in the receiver.\x0a\x09If it is present, answer the value of evaluating aBlock with the value stored at anIndex.\x0a\x09Otherwise, answer the value of anotherBlock.\x22\x0a\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (anIndex,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{anIndex:anIndex,anObject:anObject},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "anObject"],
+source: "at: anIndex put: anObject\x0a\x09\x22Store anObject under the given index in the receiver.\x22\x0a\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._indexOf_ifAbsent_(anObject,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:",{anObject:anObject},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "indexOf: anObject\x0a\x09\x22Lookup index at which anObject is stored in the receiver.\x0a\x09If not present, raise an error.\x22\x0a\x0a\x09^ self indexOf: anObject ifAbsent: [ self errorNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["indexOf:ifAbsent:", "errorNotFound"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:ifAbsent:",{anObject:anObject,aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "indexOf: anObject ifAbsent: aBlock\x0a\x09\x22Lookup index at which anObject is stored in the receiver.\x0a\x09If not present, return value of executing aBlock.\x22\x0a\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "with:do:",
+protocol: 'enumerating',
+fn: function (anotherCollection,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._withIndexDo_((function(each,index){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_value_(each,$recv(anotherCollection)._at_(index));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,index:index},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:do:",{anotherCollection:anotherCollection,aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anotherCollection", "aBlock"],
+source: "with: anotherCollection do: aBlock\x0a\x09\x22Calls aBlock with every value from self\x0a\x09and with indetically-indexed value from anotherCollection\x22\x0a\x0a\x09self withIndexDo: [ :each :index |\x0a\x09\x09aBlock value: each value: (anotherCollection at: index) ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["withIndexDo:", "value:value:", "at:"]
+}),
+$globals.IndexableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "withIndexDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withIndexDo:",{aBlock:aBlock},$globals.IndexableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "withIndexDo: aBlock\x0a\x09\x22Calls aBlock with every value from self\x0a\x09and with its index as the second argument\x22\x0a\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.IndexableCollection);
+
+
+
+$core.addClass('AssociativeCollection', $globals.IndexableCollection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AssociativeCollection.comment="I am a base class for object-indexed collections (Dictionary et.al.).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (anAssocitativeCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$4,$3,$6,$5;
+$2=self._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq($recv(anAssocitativeCollection)._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+if(!$core.assert($1)){
+return false;
+};
+$4=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__eq($recv(anAssocitativeCollection)._size());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=2;
+//>>excludeEnd("ctx");
+if(!$core.assert($3)){
+return false;
+};
+$6=self._associations();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["associations"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6).__eq($recv(anAssocitativeCollection)._associations());
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{anAssocitativeCollection:anAssocitativeCollection},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAssocitativeCollection"],
+source: "= anAssocitativeCollection\x0a\x09self class = anAssocitativeCollection class ifFalse: [ ^ false ].\x0a\x09self size = anAssocitativeCollection size ifFalse: [ ^ false ].\x0a\x09^ self associations = anAssocitativeCollection associations",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "=", "class", "size", "associations"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'adding/removing',
+fn: function (anAssociation){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_($recv(anAssociation)._key(),$recv(anAssociation)._value());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anAssociation:anAssociation},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAssociation"],
+source: "add: anAssociation\x0a\x09self at: anAssociation key put: anAssociation value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "key", "value"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "addAll:",
+protocol: 'adding/removing',
+fn: function (anAssociativeCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AssociativeCollection.superclass.fn.prototype._addAll_.apply($recv(self), [$recv(anAssociativeCollection)._associations()]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+return anAssociativeCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addAll:",{anAssociativeCollection:anAssociativeCollection},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAssociativeCollection"],
+source: "addAll: anAssociativeCollection\x0a\x09super addAll: anAssociativeCollection associations.\x0a\x09^ anAssociativeCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "associations"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "asDictionary",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Dictionary())._from_(self._associations());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asDictionary",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asDictionary\x0a\x09^ Dictionary from: self associations",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["from:", "associations"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "asHashedCollection",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($HashedCollection())._from_(self._associations());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asHashedCollection",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asHashedCollection\x0a\x09^ HashedCollection from: self associations",
+referencedClasses: ["HashedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["from:", "associations"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+var hash;
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+hash=$recv($HashedCollection())._new();
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(hash)._at_put_(key,$recv(value)._asJSON());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=hash;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSON",{hash:hash},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09| hash |\x0a\x09hash := HashedCollection new.\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09hash at: key put: value asJSON ].\x0a\x09^ hash",
+referencedClasses: ["HashedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["new", "keysAndValuesDo:", "at:put:", "asJSON"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "associations",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var associations;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+associations=[];
+self._associationsDo_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(associations)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=associations;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"associations",{associations:associations},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "associations\x0a\x09| associations |\x0a\x09associations := #().\x0a\x09self associationsDo: [ :each | associations add: each ].\x0a\x09^ associations",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["associationsDo:", "add:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "associationsDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+function $Association(){return $globals.Association||(typeof Association=="undefined"?nil:Association)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_($recv($Association())._key_value_(key,value));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"associationsDo:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "associationsDo: aBlock\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09aBlock value: (Association key: key value: value) ]",
+referencedClasses: ["Association"],
+//>>excludeEnd("ide");
+messageSends: ["keysAndValuesDo:", "value:", "key:value:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:ifAbsent:",
+protocol: 'accessing',
+fn: function (aKey,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._includesKey_(aKey);
+if($core.assert($2)){
+$1=$recv(aBlock)._value_(self._at_(aKey));
+} else {
+$1=$recv(anotherBlock)._value();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:ifAbsent:",{aKey:aKey,aBlock:aBlock,anotherBlock:anotherBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock", "anotherBlock"],
+source: "at: aKey ifPresent: aBlock ifAbsent: anotherBlock\x0a\x09\x22Lookup the given key in the receiver.\x0a\x09If it is present, answer the value of evaluating the oneArgBlock \x0a\x09with the value associated with the key, otherwise answer the value \x0a\x09of absentBlock.\x22\x0a\x09\x0a\x09^ (self includesKey: aKey)\x0a\x09\x09ifTrue: [ aBlock value: (self at: aKey) ]\x0a\x09\x09ifFalse: [ anotherBlock value ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "includesKey:", "value:", "at:", "value"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "collect:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var newDict;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+newDict=$recv(self._class())._new();
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(newDict)._at_put_(key,$recv(aBlock)._value_(value));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=newDict;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"collect:",{aBlock:aBlock,newDict:newDict},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "collect: aBlock\x0a\x09| newDict |\x0a\x09newDict := self class new.\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09newDict at: key put: (aBlock value: value) ].\x0a\x09^ newDict",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "keysAndValuesDo:", "at:put:", "value:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+var copy;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+copy=$recv(self._class())._new();
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(copy)._at_put_(key,$recv(value)._deepCopy());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=copy;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deepCopy",{copy:copy},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09| copy |\x0a\x09copy := self class new.\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09copy at: key put: value deepCopy ].\x0a\x09^ copy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "keysAndValuesDo:", "at:put:", "deepCopy"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "detect:ifNone:",
+protocol: 'enumerating',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._values())._detect_ifNone_(aBlock,anotherBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"detect:ifNone:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "detect: aBlock ifNone: anotherBlock\x0a\x09^ self values detect: aBlock ifNone: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["detect:ifNone:", "values"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._valuesDo_(aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09self valuesDo: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valuesDo:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "includes:",
+protocol: 'enumerating',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._values())._includes_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includes:",{anObject:anObject},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "includes: anObject\x0a\x09^ self values includes: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["includes:", "values"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "includesKey:",
+protocol: 'testing',
+fn: function (aKey){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesKey:",{aKey:aKey},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "includesKey: aKey\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._keys())._detect_ifNone_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._at_(each)).__eq(anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:ifAbsent:",{anObject:anObject,aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "indexOf: anObject ifAbsent: aBlock\x0a\x09^ self keys \x0a\x09\x09detect: [ :each | (self at: each) = anObject ] \x0a\x09\x09ifNone: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["detect:ifNone:", "keys", "=", "at:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keyAtValue:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._keyAtValue_ifAbsent_(anObject,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keyAtValue:",{anObject:anObject},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "keyAtValue: anObject\x0a\x09^ self keyAtValue: anObject ifAbsent: [ self errorNotFound ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keyAtValue:ifAbsent:", "errorNotFound"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keyAtValue:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._indexOf_ifAbsent_(anObject,aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keyAtValue:ifAbsent:",{anObject:anObject,aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "keyAtValue: anObject ifAbsent: aBlock\x0a\x09^ self indexOf: anObject ifAbsent: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["indexOf:ifAbsent:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keys",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keys",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "keys\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keysAndValuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._keysDo_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_value_(each,self._at_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysAndValuesDo:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysAndValuesDo: aBlock\x0a\x09self keysDo: [ :each |\x0a\x09\x09aBlock value: each value: (self at: each) ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keysDo:", "value:value:", "at:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keysDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysDo:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysDo: aBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AssociativeCollection.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printOn:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(" (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(self._associations())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._printOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(" , ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09\x0a\x09aStream nextPutAll: ' ('.\x0a\x09self associations\x0a\x09\x09do: [ :each | each printOn: aStream ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ' , ' ].\x0a\x09aStream nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "do:separatedBy:", "associations"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "remove:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._removeKey_ifAbsent_(aKey,aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "remove: aKey ifAbsent: aBlock\x0a\x09^ self removeKey: aKey ifAbsent: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["removeKey:ifAbsent:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._keys())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._removeKey_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09^ self keys do: [ :each | self removeKey: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "keys", "removeKey:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "removeKey:",
+protocol: 'adding/removing',
+fn: function (aKey){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._remove_(aKey);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeKey:",{aKey:aKey},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "removeKey: aKey\x0a\x09^ self remove: aKey",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "removeKey:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeKey:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "removeKey: aKey ifAbsent: aBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "select:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var newDict;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+newDict=$recv(self._class())._new();
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(value);
+if($core.assert($1)){
+return $recv(newDict)._at_put_(key,value);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=newDict;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select:",{aBlock:aBlock,newDict:newDict},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "select: aBlock\x0a\x09| newDict |\x0a\x09newDict := self class new.\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09(aBlock value: value) ifTrue: [ newDict at: key put: value ]].\x0a\x09^ newDict",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "keysAndValuesDo:", "ifTrue:", "value:", "at:put:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+var copy;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+copy=$recv(self._class())._new();
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(copy)._at_put_(key,value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=copy;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shallowCopy",{copy:copy},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09| copy |\x0a\x09copy := self class new.\x0a\x09self keysAndValuesDo: [ :key :value |\x0a\x09\x09copy at: key put: value ].\x0a\x09^ copy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "keysAndValuesDo:", "at:put:"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._keys())._size();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09^ self keys size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["size", "keys"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "values",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"values",{},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "values\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "valuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valuesDo:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "valuesDo: aBlock\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AssociativeCollection);
+
+$core.addMethod(
+$core.method({
+selector: "withIndexDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._keysAndValuesDo_((function(key,value){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_value_(value,key);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withIndexDo:",{aBlock:aBlock},$globals.AssociativeCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "withIndexDo: aBlock\x0a\x09self keysAndValuesDo: [ :key :value | aBlock value: value value: key ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["keysAndValuesDo:", "value:value:"]
+}),
+$globals.AssociativeCollection);
+
+
+$core.addMethod(
+$core.method({
+selector: "from:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+var newCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+newCollection=self._new();
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(newCollection)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=newCollection;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"from:",{aCollection:aCollection,newCollection:newCollection},$globals.AssociativeCollection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "from: aCollection\x0a\x09| newCollection |\x0a\x09newCollection := self new.\x0a\x09aCollection do: [ :each | newCollection add: each ].\x0a\x09^ newCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "add:"]
+}),
+$globals.AssociativeCollection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromPairs:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._from_(aCollection);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromPairs:",{aCollection:aCollection},$globals.AssociativeCollection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "fromPairs: aCollection\x0a\x09\x22This message is poorly named and has been replaced by #from:\x22\x0a\x09^ self from: aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["from:"]
+}),
+$globals.AssociativeCollection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "newFromPairs:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+var newCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4,$5;
+$2=$recv(aCollection)._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._even();
+if(!$core.assert($1)){
+self._error_("#newFromPairs only accepts arrays of an even length");
+};
+newCollection=self._new();
+$recv((1)._to_by_($recv(aCollection)._size(),(2)))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=newCollection;
+$4=$recv(aCollection)._at_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["at:"]=1;
+//>>excludeEnd("ctx");
+return $recv($3)._at_put_($4,$recv(aCollection)._at_($recv(each).__plus((1))));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$5=newCollection;
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newFromPairs:",{aCollection:aCollection,newCollection:newCollection},$globals.AssociativeCollection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "newFromPairs: aCollection\x0a\x09\x22Accept an array of elements where every two elements form an \x0a\x09association - the odd element being the key, and the even element the value.\x22\x0a\x09\x0a\x09| newCollection |\x0a\x09\x0a\x09aCollection size even ifFalse: [ \x0a\x09\x09self error: '#newFromPairs only accepts arrays of an even length' ].\x0a\x09\x09\x0a\x09newCollection := self new.\x0a\x09( 1 to: aCollection size by: 2 ) do: [ :each | \x0a\x09\x09newCollection at: (aCollection at: each) put: (aCollection at: each + 1) ].\x0a\x09\x09\x0a\x09^ newCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "even", "size", "error:", "new", "do:", "to:by:", "at:put:", "at:", "+"]
+}),
+$globals.AssociativeCollection.klass);
+
+
+$core.addClass('Dictionary', $globals.AssociativeCollection, ['keys', 'values'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Dictionary.comment="I represent a set of elements that can be viewed from one of two perspectives: a set of associations,\x0aor a container of values that are externally named where the name can be any object that responds to `=`.\x0a\x0aThe external name is referred to as the key.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var index = self._positionOfKey_(aKey);
+		return index >=0 ? self['@values'][index] : aBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "at: aKey ifAbsent: aBlock\x0a\x09<\x0a\x09\x09var index = self._positionOfKey_(aKey);\x0a\x09\x09return index >>=0 ? self['@values'][index] : aBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (aKey,aValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var index = self._positionOfKey_(aKey);
+		if(index === -1) {
+			var keys = self['@keys'];
+			index = keys.length;
+			keys.push(aKey);
+		}
+
+		return self['@values'][index] = aValue;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{aKey:aKey,aValue:aValue},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aValue"],
+source: "at: aKey put: aValue\x0a\x09<\x0a\x09\x09var index = self._positionOfKey_(aKey);\x0a\x09\x09if(index === -1) {\x0a\x09\x09\x09var keys = self['@keys'];\x0a\x09\x09\x09index = keys.length;\x0a\x09\x09\x09keys.push(aKey);\x0a\x09\x09}\x0a\x0a\x09\x09return self['@values'][index] = aValue;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "includesKey:",
+protocol: 'testing',
+fn: function (aKey){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return self._positionOfKey_(aKey) >= 0; ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesKey:",{aKey:aKey},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "includesKey: aKey\x0a\x09< return self._positionOfKey_(aKey) >>= 0; >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,aBlock){
+var self=this;
+var index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+index=$recv(self["@values"])._indexOf_ifAbsent_(anObject,(function(){
+return (0);
+
+}));
+$2=$recv(index).__eq((0));
+if($core.assert($2)){
+$1=$recv(aBlock)._value();
+} else {
+$1=$recv(self["@keys"])._at_(index);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:ifAbsent:",{anObject:anObject,aBlock:aBlock,index:index},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "indexOf: anObject ifAbsent: aBlock\x0a\x09| index |\x0a\x09index := values \x0a\x09\x09indexOf: anObject \x0a\x09\x09ifAbsent: [ 0 ].\x0a\x09^ index = 0 \x0a\x09\x09ifTrue: [ aBlock value ] \x0a\x09\x09ifFalse: [ keys at: index ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["indexOf:ifAbsent:", "ifTrue:ifFalse:", "=", "value", "at:"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Dictionary.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@keys"]=[];
+self["@values"]=[];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09keys := #().\x0a\x09values := #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "keys",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@keys"])._copy();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keys",{},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "keys\x0a\x09^ keys copy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copy"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "keysAndValuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@keys"])._with_do_(self["@values"],aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysAndValuesDo:",{aBlock:aBlock},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysAndValuesDo: aBlock\x0a\x09^ keys with: values do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:do:"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "keysDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@keys"])._do_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysDo:",{aBlock:aBlock},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysDo: aBlock\x0a\x09^ keys do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "positionOfKey:",
+protocol: 'private',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var keys = self['@keys'];
+		for(var i=0;i<keys.length;i++){
+			if(keys[i].__eq(anObject)) { return i;}
+		}
+		return -1;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"positionOfKey:",{anObject:anObject},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "positionOfKey: anObject\x0a\x09<\x0a\x09\x09var keys = self['@keys'];\x0a\x09\x09for(var i=0;i<keys.length;i++){\x0a\x09\x09\x09if(keys[i].__eq(anObject)) { return i;}\x0a\x09\x09}\x0a\x09\x09return -1;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@keys"])._removeAll();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["removeAll"]=1;
+//>>excludeEnd("ctx");
+$recv(self["@values"])._removeAll();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09keys removeAll.\x0a\x09values removeAll",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["removeAll"]
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "removeKey:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var index = self._positionOfKey_(aKey);
+		if(index === -1) {
+			return aBlock._value()
+		} else {
+			var keys = self['@keys'], values = self['@values'];
+			var value = values[index], l = keys.length;
+			keys[index] = keys[l-1];
+			keys.pop();
+			values[index] = values[l-1];
+			values.pop();
+			return value;
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeKey:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "removeKey: aKey ifAbsent: aBlock\x0a\x09<\x0a\x09\x09var index = self._positionOfKey_(aKey);\x0a\x09\x09if(index === -1) {\x0a\x09\x09\x09return aBlock._value()\x0a\x09\x09} else {\x0a\x09\x09\x09var keys = self['@keys'], values = self['@values'];\x0a\x09\x09\x09var value = values[index], l = keys.length;\x0a\x09\x09\x09keys[index] = keys[l-1];\x0a\x09\x09\x09keys.pop();\x0a\x09\x09\x09values[index] = values[l-1];\x0a\x09\x09\x09values.pop();\x0a\x09\x09\x09return value;\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "values",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@values"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "values\x0a\x09^ values",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Dictionary);
+
+$core.addMethod(
+$core.method({
+selector: "valuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@values"])._do_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valuesDo:",{aBlock:aBlock},$globals.Dictionary)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "valuesDo: aBlock\x0a\x09^ values do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:"]
+}),
+$globals.Dictionary);
+
+
+
+$core.addClass('HashedCollection', $globals.AssociativeCollection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.HashedCollection.comment="I am a traditional JavaScript object, or a Smalltalk `Dictionary`.\x0a\x0aUnlike a `Dictionary`, I can only have strings as keys.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._includesKey_(aKey);
+if($core.assert($2)){
+$1=self._basicAt_(aKey);
+} else {
+$1=$recv(aBlock)._value();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "at: aKey ifAbsent: aBlock\x0a\x09^ (self includesKey: aKey)\x0a\x09\x09ifTrue: [ self basicAt: aKey ]\x0a\x09\x09ifFalse: [ aBlock value ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "includesKey:", "basicAt:", "value"]
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (aKey,aValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_put_(aKey,aValue);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{aKey:aKey,aValue:aValue},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aValue"],
+source: "at: aKey put: aValue\x0a\x09^ self basicAt: aKey put: aValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:"]
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "includesKey:",
+protocol: 'testing',
+fn: function (aKey){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.hasOwnProperty(aKey);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesKey:",{aKey:aKey},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "includesKey: aKey\x0a\x09<return self.hasOwnProperty(aKey)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keys",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Object.keys(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keys",{},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "keys\x0a\x09<return Object.keys(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "keysDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._keys())._do_(aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysDo:",{aBlock:aBlock},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysDo: aBlock\x0a\x09self keys do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "keys"]
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "removeKey:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_ifPresent_ifAbsent_(aKey,(function(removed){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._basicDelete_(aKey);
+return removed;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({removed:removed},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeKey:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "removeKey: aKey ifAbsent: aBlock\x0a\x09^ self\x0a\x09\x09at: aKey\x0a\x09\x09ifPresent: [ :removed | self basicDelete: aKey. removed ]\x0a\x09\x09ifAbsent: [ aBlock value ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:ifPresent:ifAbsent:", "basicDelete:", "value"]
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "values",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return self._keys().map(function(key){
+			return self._at_(key);
+		});
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"values",{},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "values\x0a\x09<\x0a\x09\x09return self._keys().map(function(key){\x0a\x09\x09\x09return self._at_(key);\x0a\x09\x09});\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HashedCollection);
+
+$core.addMethod(
+$core.method({
+selector: "valuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._values())._do_(aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valuesDo:",{aBlock:aBlock},$globals.HashedCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "valuesDo: aBlock\x0a\x09self values do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "values"]
+}),
+$globals.HashedCollection);
+
+
+
+$core.addClass('SequenceableCollection', $globals.IndexableCollection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SequenceableCollection.comment="I am an IndexableCollection\x0awith numeric indexes starting with 1.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$4,$1,$5;
+var $early={};
+try {
+$3=self._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__eq($recv(aCollection)._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+return $recv($4).__eq($recv(aCollection)._size());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if(!$core.assert($1)){
+return false;
+};
+self._withIndexDo_((function(each,i){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=$recv($recv(aCollection)._at_(i)).__eq(each);
+if(!$core.assert($5)){
+throw $early=[false];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,i:i},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return true;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aCollection:aCollection},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "= aCollection\x0a\x09(self class = aCollection class and: [\x0a\x09\x09self size = aCollection size ]) ifFalse: [ ^ false ].\x0a\x09self withIndexDo: [ :each :i |\x0a\x09\x09\x09\x09(aCollection at: i) = each ifFalse: [ ^ false ]].\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "and:", "=", "class", "size", "withIndexDo:", "at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "addLast:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._add_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addLast:",{anObject:anObject},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "addLast: anObject\x0a\x09self add: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "allButFirst",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._copyFrom_to_((2),self._size());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allButFirst",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allButFirst\x0a\x09^ self copyFrom: 2 to: self size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copyFrom:to:", "size"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "allButLast",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._copyFrom_to_((1),$recv(self._size()).__minus((1)));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allButLast",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allButLast\x0a\x09^ self copyFrom: 1 to: self size - 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copyFrom:to:", "-", "size"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "atRandom",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_($recv(self._size())._atRandom());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atRandom",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atRandom\x0a\x09^ self at: self size atRandom",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "atRandom", "size"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "beginsWith:",
+protocol: 'testing',
+fn: function (prefix){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$4;
+$2=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(prefix)._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__lt($3);
+if($core.assert($1)){
+return false;
+};
+$4=$recv(self._first_($recv(prefix)._size())).__eq(prefix);
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beginsWith:",{prefix:prefix},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["prefix"],
+source: "beginsWith: prefix\x0a\x09self size < prefix size ifTrue: [ ^ false ].\x0a\x09^ (self first: prefix size) = prefix",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "<", "size", "=", "first:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "copyFrom:to:",
+protocol: 'copying',
+fn: function (anIndex,anotherIndex){
+var self=this;
+var range,newCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+range=$recv(anIndex)._to_(anotherIndex);
+newCollection=$recv(self._class())._new_($recv(range)._size());
+$recv(range)._withIndexDo_((function(each,i){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(newCollection)._at_put_(i,self._at_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,i:i},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=newCollection;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyFrom:to:",{anIndex:anIndex,anotherIndex:anotherIndex,range:range,newCollection:newCollection},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "anotherIndex"],
+source: "copyFrom: anIndex to: anotherIndex\x0a\x09| range newCollection |\x0a\x09range := anIndex to: anotherIndex.\x0a\x09newCollection := self class new: range size.\x0a\x09range withIndexDo: [ :each :i |\x0a\x09\x09newCollection at: i put: (self at: each) ].\x0a\x09^ newCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["to:", "new:", "class", "size", "withIndexDo:", "at:put:", "at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+var newCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+newCollection=$recv(self._class())._new_(self._size());
+self._withIndexDo_((function(each,index){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(newCollection)._at_put_(index,$recv(each)._deepCopy());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,index:index},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=newCollection;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deepCopy",{newCollection:newCollection},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09| newCollection |\x0a\x09newCollection := self class new: self size.\x0a\x09self withIndexDo: [ :each :index |\x0a\x09\x09newCollection at: index put: each deepCopy ].\x0a\x09^ newCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new:", "class", "size", "withIndexDo:", "at:put:", "deepCopy"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "detect:ifNone:",
+protocol: 'enumerating',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		for(var i = 0; i < self.length; i++)
+			if(aBlock._value_(self[i]))
+				return self[i];
+		return anotherBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"detect:ifNone:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "detect: aBlock ifNone: anotherBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09for(var i = 0; i < self.length; i++)\x0a\x09\x09\x09if(aBlock._value_(self[i]))\x0a\x09\x09\x09\x09return self[i];\x0a\x09\x09return anotherBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			aBlock._value_(self[i]);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09for(var i=0; i < self.length; i++) {\x0a\x09\x09\x09aBlock._value_(self[i]);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "endsWith:",
+protocol: 'testing',
+fn: function (suffix){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$4;
+$2=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(suffix)._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__lt($3);
+if($core.assert($1)){
+return false;
+};
+$4=$recv(self._last_($recv(suffix)._size())).__eq(suffix);
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"endsWith:",{suffix:suffix},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["suffix"],
+source: "endsWith: suffix\x0a\x09self size < suffix size ifTrue: [ ^ false ].\x0a\x09^ (self last: suffix size) = suffix",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "<", "size", "=", "last:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "first",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_((1));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"first",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "first\x0a\x09^ self at: 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "first:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(self._size()).__lt(aNumber);
+if($core.assert($1)){
+self._error_("Invalid number of elements");
+};
+$2=self._copyFrom_to_((1),aNumber);
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"first:",{aNumber:aNumber},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "first: aNumber\x0a\x09\x22Answer the first `aNumber` elements of the receiver.\x0a\x09Raise an error if there are not enough elements in the receiver.\x22\x0a\x0a\x09self size < aNumber ifTrue: [ self error: 'Invalid number of elements' ].\x0a\x0a\x09^ self copyFrom: 1 to: aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "<", "size", "error:", "copyFrom:to:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "fourth",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_((4));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fourth",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fourth\x0a\x09^ self at: 4",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "includes:",
+protocol: 'testing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._indexOf_ifAbsent_(anObject,(function(){
+return nil;
+
+})))._notNil();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includes:",{anObject:anObject},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "includes: anObject\x0a\x09^ (self indexOf: anObject ifAbsent: [ nil ]) notNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["notNil", "indexOf:ifAbsent:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			if($recv(self[i]).__eq(anObject)) {return i+1}
+		};
+		return aBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:ifAbsent:",{anObject:anObject,aBlock:aBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "indexOf: anObject ifAbsent: aBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09for(var i=0; i < self.length; i++) {\x0a\x09\x09\x09if($recv(self[i]).__eq(anObject)) {return i+1}\x0a\x09\x09};\x0a\x09\x09return aBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:startingAt:",
+protocol: 'accessing',
+fn: function (anObject,start){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._indexOf_startingAt_ifAbsent_(anObject,start,(function(){
+return (0);
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:startingAt:",{anObject:anObject,start:start},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "start"],
+source: "indexOf: anObject startingAt: start\x0a\x09\x22Answer the index of the first occurence of anElement after start\x0a\x09within the receiver. If the receiver does not contain anElement,\x0a\x09answer 0.\x22\x0a\x09^ self indexOf: anObject startingAt: start ifAbsent: [ 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["indexOf:startingAt:ifAbsent:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "indexOf:startingAt:ifAbsent:",
+protocol: 'accessing',
+fn: function (anObject,start,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		for(var i=start - 1; i < self.length; i++){
+			if($recv(self[i]).__eq(anObject)) {return i+1}
+		}
+		return aBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"indexOf:startingAt:ifAbsent:",{anObject:anObject,start:start,aBlock:aBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "start", "aBlock"],
+source: "indexOf: anObject startingAt: start ifAbsent: aBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09for(var i=start - 1; i < self.length; i++){\x0a\x09\x09\x09if($recv(self[i]).__eq(anObject)) {return i+1}\x0a\x09\x09}\x0a\x09\x09return aBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "last",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_(self._size());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"last",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "last\x0a\x09^ self at: self size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "size"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "last:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$6,$5,$4,$3;
+$2=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__lt(aNumber);
+if($core.assert($1)){
+self._error_("Invalid number of elements");
+};
+$6=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6).__minus(aNumber);
+$4=$recv($5).__plus((1));
+$3=self._copyFrom_to_($4,self._size());
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"last:",{aNumber:aNumber},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "last: aNumber\x0a\x09\x22Answer the last aNumber elements of the receiver.\x0a\x09Raise an error if there are not enough elements in the receiver.\x22\x0a\x0a\x09self size < aNumber ifTrue: [ self error: 'Invalid number of elements' ].\x0a\x0a\x09^ self copyFrom: self size - aNumber + 1 to: self size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "<", "size", "error:", "copyFrom:to:", "+", "-"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "newStream",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._streamClass())._on_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newStream",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "newStream\x0a\x09^ self streamClass on: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["on:", "streamClass"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "numericallyIndexable",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"numericallyIndexable",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "numericallyIndexable\x0a\x09\x22This is an internal converting message.\x0a\x09It answeres a representation of the receiver\x0a\x09that can use foo[i] in JavaScript code.\x0a\x09\x0a\x09It fixes IE8, where boxed String is unable\x0a\x09to numerically index its characters,\x0a\x09but primitive string can.\x22\x0a\x09\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "readStream",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"readStream",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "readStream\x0a\x09\x22For Pharo compatibility\x22\x0a\x09\x0a\x09^ self stream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["stream"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "removeLast",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._remove_(self._last());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeLast",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeLast\x0a\x09^ self remove: self last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:", "last"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "reversed",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reversed",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "reversed\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "second",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_((2));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"second",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "second\x0a\x09^ self at: 2",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+var newCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+newCollection=$recv(self._class())._new_(self._size());
+self._withIndexDo_((function(each,index){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(newCollection)._at_put_(index,each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,index:index},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=newCollection;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shallowCopy",{newCollection:newCollection},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09| newCollection |\x0a\x09newCollection := self class new: self size.\x0a\x09self withIndexDo: [ :each :index |\x0a\x09\x09newCollection at: index put: each ].\x0a\x09^ newCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new:", "class", "size", "withIndexDo:", "at:put:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "stream",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newStream();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"stream",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "stream\x0a\x09^ self newStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["newStream"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "streamClass",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._streamClass();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"streamClass",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "streamClass\x0a\x09^ self class streamClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["streamClass", "class"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "third",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_((3));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"third",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "third\x0a\x09^ self at: 3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "with:do:",
+protocol: 'enumerating',
+fn: function (anotherCollection,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		anotherCollection = anotherCollection._numericallyIndexable();
+		for(var i=0; i<self.length; i++) {
+			aBlock._value_value_(self[i], anotherCollection[i]);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:do:",{anotherCollection:anotherCollection,aBlock:aBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anotherCollection", "aBlock"],
+source: "with: anotherCollection do: aBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09anotherCollection = anotherCollection._numericallyIndexable();\x0a\x09\x09for(var i=0; i<self.length; i++) {\x0a\x09\x09\x09aBlock._value_value_(self[i], anotherCollection[i]);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "withIndexDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			aBlock._value_value_(self[i], i+1);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withIndexDo:",{aBlock:aBlock},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "withIndexDo: aBlock\x0a\x09<\x0a\x09\x09self = self._numericallyIndexable();\x0a\x09\x09for(var i=0; i < self.length; i++) {\x0a\x09\x09\x09aBlock._value_value_(self[i], i+1);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "writeStream",
+protocol: 'streaming',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._stream();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"writeStream",{},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "writeStream\x0a\x09\x22For Pharo compatibility\x22\x0a\x09\x0a\x09^ self stream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["stream"]
+}),
+$globals.SequenceableCollection);
+
+
+$core.addMethod(
+$core.method({
+selector: "streamClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Stream(){return $globals.Stream||(typeof Stream=="undefined"?nil:Stream)}
+return $Stream();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "streamClass\x0a\x09\x09^ Stream",
+referencedClasses: ["Stream"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SequenceableCollection.klass);
+
+$core.addMethod(
+$core.method({
+selector: "streamContents:",
+protocol: 'streaming',
+fn: function (aBlock){
+var self=this;
+var stream;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+stream=$recv(self._streamClass())._on_(self._new());
+$recv(aBlock)._value_(stream);
+$1=$recv(stream)._contents();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"streamContents:",{aBlock:aBlock,stream:stream},$globals.SequenceableCollection.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "streamContents: aBlock\x0a\x09| stream |\x0a\x09stream := (self streamClass on: self new).\x0a\x09aBlock value: stream.\x0a\x09^ stream contents",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["on:", "streamClass", "new", "value:", "contents"]
+}),
+$globals.SequenceableCollection.klass);
+
+
+$core.addClass('Array', $globals.SequenceableCollection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Array.comment="I represent a collection of objects ordered by the collector. The size of arrays is dynamic.\x0a\x0aI am directly mapped to JavaScript Number.\x0a\x0a*Note* In Amber, `OrderedCollection` is an alias for `Array`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.push(anObject); return anObject;;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anObject:anObject},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "add: anObject\x0a\x09<self.push(anObject); return anObject;>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "addFirst:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.unshift(anObject); return anObject;;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addFirst:",{anObject:anObject},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "addFirst: anObject\x0a\x09<self.unshift(anObject); return anObject;>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("[".__comma($recv(self._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._join_(", "))).__comma("]");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09^ '[', ((self collect: [:each | each asJavascript ]) join: ', '), ']'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "join:", "collect:", "asJavascript"]
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return anIndex >= 1 && anIndex <= self.length
+			? self[anIndex - 1]
+			: aBlock._value()
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{anIndex:anIndex,aBlock:aBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock"],
+source: "at: anIndex ifAbsent: aBlock\x0a\x09<\x0a\x09\x09return anIndex >>= 1 && anIndex <= self.length\x0a\x09\x09\x09? self[anIndex - 1]\x0a\x09\x09\x09: aBlock._value()\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return anIndex >= 1 && anIndex <= self.length
+			? aBlock._value_(self[anIndex - 1])
+			: anotherBlock._value()
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:ifAbsent:",{anIndex:anIndex,aBlock:aBlock,anotherBlock:anotherBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock", "anotherBlock"],
+source: "at: anIndex ifPresent: aBlock ifAbsent: anotherBlock\x0a\x09<\x0a\x09\x09return anIndex >>= 1 && anIndex <= self.length\x0a\x09\x09\x09? aBlock._value_(self[anIndex - 1])\x0a\x09\x09\x09: anotherBlock._value()\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (anIndex,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self[anIndex - 1] = anObject;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{anIndex:anIndex,anObject:anObject},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "anObject"],
+source: "at: anIndex put: anObject\x0a\x09<return self[anIndex - 1] = anObject>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "collect:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.map(function(each) {return aBlock._value_(each)});
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"collect:",{aBlock:aBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "collect: aBlock\x0a\x09\x22Optimized version\x22\x0a\x09\x0a\x09<return self.map(function(each) {return aBlock._value_(each)})>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "join:",
+protocol: 'enumerating',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.join(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"join:",{aString:aString},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "join: aString\x0a\x09<return self.join(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "numericallyIndexable",
+protocol: 'private',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "numericallyIndexable\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Array.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printOn:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(" (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._printOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09\x0a\x09aStream nextPutAll: ' ('.\x0a\x09self \x0a\x09\x09do: [ :each | each printOn: aStream ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ' ' ].\x0a\x09aStream nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "do:separatedBy:"]
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "remove:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (anObject,aBlock){
+var self=this;
+var index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+index=self._indexOf_ifAbsent_(anObject,(function(){
+return (0);
+
+}));
+$2=$recv(index).__eq((0));
+if($core.assert($2)){
+$1=$recv(aBlock)._value();
+} else {
+self._removeIndex_(index);
+$1=anObject;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:ifAbsent:",{anObject:anObject,aBlock:aBlock,index:index},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "remove: anObject ifAbsent: aBlock\x0a\x09| index |\x0a\x09index := self indexOf: anObject ifAbsent: [ 0 ].\x0a\x09^ index = 0\x0a\x09\x09ifFalse: [ self removeIndex: index. anObject ]\x0a\x09\x09ifTrue: [ aBlock value ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["indexOf:ifAbsent:", "ifFalse:ifTrue:", "=", "removeIndex:", "value"]
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.length = 0;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09<self.length = 0>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "removeFrom:to:",
+protocol: 'adding/removing',
+fn: function (aNumber,anotherNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.splice(aNumber -1, anotherNumber - aNumber + 1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeFrom:to:",{aNumber:aNumber,anotherNumber:anotherNumber},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber", "anotherNumber"],
+source: "removeFrom: aNumber to: anotherNumber\x0a\x09<self.splice(aNumber -1, anotherNumber - aNumber + 1)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "removeIndex:",
+protocol: 'adding/removing',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.splice(anInteger - 1, 1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeIndex:",{anInteger:anInteger},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "removeIndex: anInteger\x0a\x09<self.splice(anInteger - 1, 1)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "removeLast",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.pop();;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeLast",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeLast\x0a\x09<return self.pop();>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "reversed",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self._copy().reverse();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reversed",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "reversed\x0a\x09<return self._copy().reverse()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "select:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var result = self.klass._new();
+		for(var i=0; i<self.length; i++) {
+			if(aBlock._value_(self[i])) {
+				result.push(self[i]);
+			}
+		}
+		return result;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select:",{aBlock:aBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "select: aBlock\x0a\x09\x22Optimized version\x22\x0a\x09\x0a\x09<\x0a\x09\x09var result = self.klass._new();\x0a\x09\x09for(var i=0; i<self.length; i++) {\x0a\x09\x09\x09if(aBlock._value_(self[i])) {\x0a\x09\x09\x09\x09result.push(self[i]);\x0a\x09\x09\x09}\x0a\x09\x09}\x0a\x09\x09return result;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.length;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09<return self.length>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "sort",
+protocol: 'enumerating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._sort_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(a).__lt(b);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sort",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sort\x0a\x09^ self sort: [ :a :b | a < b ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sort:", "<"]
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "sort:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return self.sort(function(a, b) {
+			if(aBlock._value_value_(a,b)) {return -1} else {return 1}
+		})
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sort:",{aBlock:aBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "sort: aBlock\x0a\x09<\x0a\x09\x09return self.sort(function(a, b) {\x0a\x09\x09\x09if(aBlock._value_value_(a,b)) {return -1} else {return 1}\x0a\x09\x09})\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "sorted",
+protocol: 'enumerating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._copy())._sort();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sorted",{},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sorted\x0a\x09^ self copy sort",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sort", "copy"]
+}),
+$globals.Array);
+
+$core.addMethod(
+$core.method({
+selector: "sorted:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._copy())._sort_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sorted:",{aBlock:aBlock},$globals.Array)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "sorted: aBlock\x0a\x09^ self copy sort: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sort:", "copy"]
+}),
+$globals.Array);
+
+
+$core.addMethod(
+$core.method({
+selector: "new:",
+protocol: 'instance creation',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return new Array(anInteger);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new:",{anInteger:anInteger},$globals.Array.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "new: anInteger\x0a\x09<return new Array(anInteger)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Array.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:",
+protocol: 'instance creation',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new_((1));
+$recv($2)._at_put_((1),anObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},$globals.Array.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "with: anObject\x0a\x09\x09^ (self new: 1)\x0a\x09\x09at: 1 put: anObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "new:", "yourself"]
+}),
+$globals.Array.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:with:",
+protocol: 'instance creation',
+fn: function (anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new_((2));
+$recv($2)._at_put_((1),anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:put:"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._at_put_((2),anObject2);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:with:",{anObject:anObject,anObject2:anObject2},$globals.Array.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anObject2"],
+source: "with: anObject with: anObject2\x0a\x09\x09^ (self new: 2)\x0a\x09\x09at: 1 put: anObject;\x0a\x09\x09at: 2 put: anObject2;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "new:", "yourself"]
+}),
+$globals.Array.klass);
+
+$core.addMethod(
+$core.method({
+selector: "with:with:with:",
+protocol: 'instance creation',
+fn: function (anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new_((3));
+$recv($2)._at_put_((1),anObject);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:put:"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._at_put_((2),anObject2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:put:"]=2;
+//>>excludeEnd("ctx");
+$recv($2)._at_put_((3),anObject3);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:with:with:",{anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.Array.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anObject2", "anObject3"],
+source: "with: anObject with: anObject2 with: anObject3\x0a\x09\x09^ (self new: 3)\x0a\x09\x09at: 1 put: anObject;\x0a\x09\x09at: 2 put: anObject2;\x0a\x09\x09at: 3 put: anObject3;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "new:", "yourself"]
+}),
+$globals.Array.klass);
+
+$core.addMethod(
+$core.method({
+selector: "withAll:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+var instance,index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+index=(1);
+instance=self._new_($recv(aCollection)._size());
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(instance)._at_put_(index,each);
+index=$recv(index).__plus((1));
+return index;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=instance;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withAll:",{aCollection:aCollection,instance:instance,index:index},$globals.Array.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "withAll: aCollection\x0a\x09| instance index |\x0a\x09index := 1.\x0a\x09instance := self new: aCollection size.\x0a\x09aCollection do: [ :each |\x0a\x09\x09instance at: index put: each.\x0a\x09\x09index := index + 1 ].\x0a\x09^ instance",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new:", "size", "do:", "at:put:", "+"]
+}),
+$globals.Array.klass);
+
+
+$core.addClass('CharacterArray', $globals.SequenceableCollection, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.CharacterArray.comment="I am the abstract superclass of string-like collections.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: ",",
+protocol: 'copying',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._asString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asString"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma($recv(aString)._asString());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,",",{aString:aString},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: ", aString\x0a\x09^ self asString, aString asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._errorReadOnly();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anObject:anObject},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "add: anObject\x0a\x09self errorReadOnly",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["errorReadOnly"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asLowercase",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._fromString_($recv(self._asString())._asLowercase());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asLowercase",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asLowercase\x0a\x09^ self class fromString: self asString asLowercase",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromString:", "class", "asLowercase", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asNumber",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asString())._asNumber();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asNumber",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asNumber\x0a\x09^ self asString asNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asNumber", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclassResponsibility();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09^ self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asSymbol",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._asString();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSymbol",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSymbol\x0a\x09^ self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asUppercase",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._fromString_($recv(self._asString())._asUppercase());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asUppercase",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asUppercase\x0a\x09^ self class fromString: self asString asUppercase",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromString:", "class", "asUppercase", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (anIndex,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._errorReadOnly();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{anIndex:anIndex,anObject:anObject},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "anObject"],
+source: "at: anIndex put: anObject\x0a\x09self errorReadOnly",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["errorReadOnly"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "errorReadOnly",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("Object is read-only");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"errorReadOnly",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "errorReadOnly\x0a\x09self error: 'Object is read-only'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asString())._printOn_(aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09self asString printOn: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "putOn:",
+protocol: 'streaming',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutString_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"putOn:",{aStream:aStream},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "putOn: aStream\x0a\x09aStream nextPutString: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutString:"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "remove:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._errorReadOnly();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:",{anObject:anObject},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "remove: anObject\x0a\x09self errorReadOnly",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["errorReadOnly"]
+}),
+$globals.CharacterArray);
+
+
+$core.addMethod(
+$core.method({
+selector: "fromString:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:",{aString:aString},$globals.CharacterArray.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "fromString: aString\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.CharacterArray.klass);
+
+
+$core.addClass('String', $globals.CharacterArray, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.String.comment="I am an indexed collection of Characters. Unlike most Smalltalk dialects, Amber doesn't provide the Character class. Instead, elements of a String are single character strings.\x0a\x0aString inherits many useful methods from its hierarchy, such as\x0a\x09`Collection >> #,`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: ",",
+protocol: 'copying',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self) + aString;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,",",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: ", aString\x0a\x09<return String(self) + aString>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "<",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self) < aString._asString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "< aString\x0a\x09<return String(self) < aString._asString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "<=",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self) <= aString._asString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<=",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "<= aString\x0a\x09<return String(self) <= aString._asString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return aString != null &&
+			typeof aString._isString === "function" &&
+			aString._isString() &&
+			String(self) === String(aString)
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "= aString\x0a\x09<\x0a\x09\x09return aString != null &&\x0a\x09\x09\x09typeof aString._isString === \x22function\x22 &&\x0a\x09\x09\x09aString._isString() &&\x0a\x09\x09\x09String(self) === String(aString)\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "==",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__eq(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"==",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "== aString\x0a\x09^ self = aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["="]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: ">",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self) > aString._asString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "> aString\x0a\x09<return String(self) >> aString._asString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: ">=",
+protocol: 'comparing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self) >= aString._asString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">=",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: ">= aString\x0a\x09<return String(self) >>= aString._asString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJavaScriptMethodName",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.st2js(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavaScriptMethodName",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavaScriptMethodName\x0a\x09<return $core.st2js(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self.search(/^[a-zA-Z0-9_:.$ ]*$/) == -1)
+			return "\"" + self.replace(/[\x00-\x1f"\\\x7f-\x9f]/g, function(ch){var c=ch.charCodeAt(0);return "\\x"+("0"+c.toString(16)).slice(-2)}) + "\"";
+		else
+			return "\"" + self + "\"";
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09<\x0a\x09\x09if(self.search(/^[a-zA-Z0-9_:.$ ]*$/) == -1)\x0a\x09\x09\x09return \x22\x5c\x22\x22 + self.replace(/[\x5cx00-\x5cx1f\x22\x5c\x5c\x5cx7f-\x5cx9f]/g, function(ch){var c=ch.charCodeAt(0);return \x22\x5c\x5cx\x22+(\x220\x22+c.toString(16)).slice(-2)}) + \x22\x5c\x22\x22;\x0a\x09\x09else\x0a\x09\x09\x09return \x22\x5c\x22\x22 + self + \x22\x5c\x22\x22;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asLowercase",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toLowerCase();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asLowercase",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asLowercase\x0a\x09<return self.toLowerCase()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asMutator",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(self._last()).__eq(":");
+if(!$core.assert($1)){
+$2=self.__comma(":");
+return $2;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asMutator",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asMutator\x0a\x09\x22Answer a setter selector. For example,\x0a\x09#name asMutator returns #name:\x22\x0a\x0a\x09self last = ':' ifFalse: [  ^ self, ':' ].\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "=", "last", ","]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asNumber",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Number(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asNumber",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asNumber\x0a\x09<return Number(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asRegexp",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $RegularExpression(){return $globals.RegularExpression||(typeof RegularExpression=="undefined"?nil:RegularExpression)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($RegularExpression())._fromString_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asRegexp",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asRegexp\x0a\x09^ RegularExpression fromString: self",
+referencedClasses: ["RegularExpression"],
+//>>excludeEnd("ide");
+messageSends: ["fromString:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asSelector",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI_("Use #asJavaScriptMethodName");
+$1=self._asJavaScriptMethodName();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSelector",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSelector\x0a\x09self deprecatedAPI: 'Use #asJavaScriptMethodName'.\x0a\x09^ self asJavaScriptMethodName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI:", "asJavaScriptMethodName"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asSymbol",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSymbol\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asUppercase",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toUpperCase();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asUppercase",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asUppercase\x0a\x09<return self.toUpperCase()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asciiValue",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.charCodeAt(0);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asciiValue",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asciiValue\x0a\x09<return self.charCodeAt(0);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self)[anIndex - 1] || aBlock._value();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{anIndex:anIndex,aBlock:aBlock},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock"],
+source: "at: anIndex ifAbsent: aBlock\x0a\x09<return String(self)[anIndex - 1] || aBlock._value()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:ifAbsent:",
+protocol: 'accessing',
+fn: function (anIndex,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var result = String(self)[anIndex - 1];
+		return result ? aBlock._value_(result) : anotherBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:ifAbsent:",{anIndex:anIndex,aBlock:aBlock,anotherBlock:anotherBlock},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "aBlock", "anotherBlock"],
+source: "at: anIndex ifPresent: aBlock ifAbsent: anotherBlock\x0a\x09<\x0a\x09\x09var result = String(self)[anIndex - 1];\x0a\x09\x09return result ? aBlock._value_(result) : anotherBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "capitalized",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._isEmpty();
+if($core.assert($2)){
+$1=self;
+} else {
+$1=$recv($recv(self._first())._asUppercase()).__comma(self._allButFirst());
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"capitalized",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "capitalized\x0a\x09^ self isEmpty\x0a\x09\x09ifTrue: [ self ]\x0a\x09\x09ifFalse: [ self first asUppercase, self allButFirst ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isEmpty", ",", "asUppercase", "first", "allButFirst"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "charCodeAt:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.charCodeAt(anInteger - 1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"charCodeAt:",{anInteger:anInteger},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "charCodeAt: anInteger\x0a\x09<return self.charCodeAt(anInteger - 1)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "copyFrom:to:",
+protocol: 'copying',
+fn: function (anIndex,anotherIndex){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.substring(anIndex - 1, anotherIndex);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyFrom:to:",{anIndex:anIndex,anotherIndex:anotherIndex},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex", "anotherIndex"],
+source: "copyFrom: anIndex to: anotherIndex\x0a\x09<return self.substring(anIndex - 1, anotherIndex)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "crlfSanitized",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._lines())._join_($recv($String())._lf());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"crlfSanitized",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "crlfSanitized\x0a\x09^ self lines join: String lf",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["join:", "lines", "lf"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._shallowCopy();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deepCopy",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09^ self shallowCopy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shallowCopy"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "escaped",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return escape(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"escaped",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "escaped\x0a\x09<return escape(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "identityHash",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__comma("s");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"identityHash",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "identityHash\x0a\x09^ self, 's'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [","]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "includesSubString:",
+protocol: 'testing',
+fn: function (subString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.indexOf(subString) != -1;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesSubString:",{subString:subString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["subString"],
+source: "includesSubString: subString\x0a\x09<return self.indexOf(subString) != -1>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "isCapitalized",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=self._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._asUppercase();
+$1=$recv($2).__eq_eq(self._first());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isCapitalized",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCapitalized\x0a\x09^ self first asUppercase == self first",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["==", "asUppercase", "first"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "isString",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isString\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "isVowel",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._size()).__eq((1)))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return "aeiou"._includes_(self._asLowercase());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isVowel",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isVowel\x0a\x09\x22Answer true if the receiver is a one character string containing a voyel\x22\x0a\x09\x0a\x09^ self size = 1 and: [ 'aeiou' includes: self asLowercase ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "=", "size", "includes:", "asLowercase"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "join:",
+protocol: 'split join',
+fn: function (aCollection){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aCollection)._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_($recv(each)._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"join:",{aCollection:aCollection},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "join: aCollection\x0a\x09^ String\x0a\x09\x09streamContents: [ :stream | aCollection\x0a\x09\x09\x09\x09do: [ :each | stream nextPutAll: each asString ]\x0a\x09\x09\x09\x09separatedBy: [ stream nextPutAll: self ]]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "do:separatedBy:", "nextPutAll:", "asString"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "lineIndicesDo:",
+protocol: 'split join',
+fn: function (aBlock){
+var self=this;
+var cr,lf,start,sz,nextLF,nextCR;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$4,$5,$3,$6,$7,$9,$8,$10,$11;
+var $early={};
+try {
+start=(1);
+sz=self._size();
+cr=$recv($String())._cr();
+nextCR=self._indexOf_startingAt_(cr,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["indexOf:startingAt:"]=1;
+//>>excludeEnd("ctx");
+lf=$recv($String())._lf();
+nextLF=self._indexOf_startingAt_(lf,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["indexOf:startingAt:"]=2;
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(start).__lt_eq(sz);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(nextLF).__eq((0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(nextCR).__eq((0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["="]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["and:"]=1;
+//>>excludeEnd("ctx");
+if($core.assert($1)){
+$recv(aBlock)._value_value_value_(start,sz,sz);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value:value:value:"]=1;
+//>>excludeEnd("ctx");
+throw $early=[self];
+};
+$4=$recv(nextCR).__eq((0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=3;
+//>>excludeEnd("ctx");
+$3=$recv($4)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$5=(0).__lt(nextLF);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["<"]=1;
+//>>excludeEnd("ctx");
+return $recv($5)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv(nextLF).__lt(nextCR);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,6)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($3)){
+$6=start;
+$7=$recv(nextLF).__minus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["-"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_value_value_($6,$7,nextLF);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value:value:value:"]=2;
+//>>excludeEnd("ctx");
+start=(1).__plus(nextLF);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+start;
+nextLF=self._indexOf_startingAt_(lf,start);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["indexOf:startingAt:"]=3;
+//>>excludeEnd("ctx");
+return nextLF;
+} else {
+$9=(1).__plus(nextCR);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=2;
+//>>excludeEnd("ctx");
+$8=$recv($9).__eq(nextLF);
+if($core.assert($8)){
+$10=start;
+$11=$recv(nextCR).__minus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["-"]=2;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_value_value_($10,$11,nextLF);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value:value:value:"]=3;
+//>>excludeEnd("ctx");
+start=(1).__plus(nextLF);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=3;
+//>>excludeEnd("ctx");
+start;
+nextCR=self._indexOf_startingAt_(cr,start);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["indexOf:startingAt:"]=4;
+//>>excludeEnd("ctx");
+nextCR;
+nextLF=self._indexOf_startingAt_(lf,start);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["indexOf:startingAt:"]=5;
+//>>excludeEnd("ctx");
+return nextLF;
+} else {
+$recv(aBlock)._value_value_value_(start,$recv(nextCR).__minus((1)),nextCR);
+start=(1).__plus(nextCR);
+start;
+nextCR=self._indexOf_startingAt_(cr,start);
+return nextCR;
+};
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lineIndicesDo:",{aBlock:aBlock,cr:cr,lf:lf,start:start,sz:sz,nextLF:nextLF,nextCR:nextCR},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "lineIndicesDo: aBlock\x0a\x09\x22execute aBlock with 3 arguments for each line:\x0a\x09- start index of line\x0a\x09- end index of line without line delimiter\x0a\x09- end index of line including line delimiter(s) CR, LF or CRLF\x22\x0a\x09\x0a\x09| cr lf start sz nextLF nextCR |\x0a\x09start := 1.\x0a\x09sz := self size.\x0a\x09cr := String cr.\x0a\x09nextCR := self indexOf: cr startingAt: 1.\x0a\x09lf := String lf.\x0a\x09nextLF := self indexOf: lf startingAt: 1.\x0a\x09[ start <= sz ] whileTrue: [ \x0a\x09\x09(nextLF = 0 and: [ nextCR = 0 ])\x0a\x09\x09\x09ifTrue: [ \x22No more CR, nor LF, the string is over\x22\x0a\x09\x09\x09\x09\x09aBlock value: start value: sz value: sz.\x0a\x09\x09\x09\x09\x09^ self ].\x0a\x09\x09(nextCR = 0 or: [ 0 < nextLF and: [ nextLF < nextCR ] ])\x0a\x09\x09\x09ifTrue: [ \x22Found a LF\x22\x0a\x09\x09\x09\x09\x09aBlock value: start value: nextLF - 1 value: nextLF.\x0a\x09\x09\x09\x09\x09start := 1 + nextLF.\x0a\x09\x09\x09\x09\x09nextLF := self indexOf: lf startingAt: start ]\x0a\x09\x09\x09ifFalse: [ 1 + nextCR = nextLF\x0a\x09\x09\x09\x09ifTrue: [ \x22Found a CR-LF pair\x22\x0a\x09\x09\x09\x09\x09aBlock value: start value: nextCR - 1 value: nextLF.\x0a\x09\x09\x09\x09\x09start := 1 + nextLF.\x0a\x09\x09\x09\x09\x09nextCR := self indexOf: cr startingAt: start.\x0a\x09\x09\x09\x09\x09nextLF := self indexOf: lf startingAt: start ]\x0a\x09\x09\x09\x09ifFalse: [ \x22Found a CR\x22\x0a\x09\x09\x09\x09\x09aBlock value: start value: nextCR - 1 value: nextCR.\x0a\x09\x09\x09\x09\x09start := 1 + nextCR.\x0a\x09\x09\x09\x09\x09nextCR := self indexOf: cr startingAt: start ] ]]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["size", "cr", "indexOf:startingAt:", "lf", "whileTrue:", "<=", "ifTrue:", "and:", "=", "value:value:value:", "ifTrue:ifFalse:", "or:", "<", "-", "+"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "lineNumber:",
+protocol: 'split join',
+fn: function (anIndex){
+var self=this;
+var lineCount;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3;
+var $early={};
+try {
+lineCount=(0);
+self._lineIndicesDo_((function(start,endWithoutDelimiters,end){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+lineCount=$recv(lineCount).__plus((1));
+$2=lineCount;
+$1=$recv($2).__eq(anIndex);
+if($core.assert($1)){
+$3=self._copyFrom_to_(start,endWithoutDelimiters);
+throw $early=[$3];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({start:start,endWithoutDelimiters:endWithoutDelimiters,end:end},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return nil;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lineNumber:",{anIndex:anIndex,lineCount:lineCount},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anIndex"],
+source: "lineNumber: anIndex\x0a\x09\x22Answer a string containing the characters in the given line number.\x22\x0a\x0a\x09| lineCount |\x0a\x09lineCount := 0.\x0a\x09self lineIndicesDo: [ :start :endWithoutDelimiters :end |\x0a\x09\x09(lineCount := lineCount + 1) = anIndex ifTrue: [ ^ self copyFrom: start to: endWithoutDelimiters ]].\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lineIndicesDo:", "ifTrue:", "=", "+", "copyFrom:to:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "lines",
+protocol: 'split join',
+fn: function (){
+var self=this;
+var lines;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+lines=$recv($Array())._new();
+self._linesDo_((function(aLine){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(lines)._add_(aLine);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({aLine:aLine},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=lines;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lines",{lines:lines},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lines\x0a\x09\x22Answer an array of lines composing this receiver without the line ending delimiters.\x22\x0a\x0a\x09| lines |\x0a\x09lines := Array new.\x0a\x09self linesDo: [ :aLine | lines add: aLine ].\x0a\x09^ lines",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["new", "linesDo:", "add:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "linesDo:",
+protocol: 'split join',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._lineIndicesDo_((function(start,endWithoutDelimiters,end){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_(self._copyFrom_to_(start,endWithoutDelimiters));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({start:start,endWithoutDelimiters:endWithoutDelimiters,end:end},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"linesDo:",{aBlock:aBlock},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "linesDo: aBlock\x0a\x09\x22Execute aBlock with each line in this string. The terminating line\x0a\x09delimiters CR, LF or CRLF pairs are not included in what is passed to aBlock\x22\x0a\x0a\x09self lineIndicesDo: [ :start :endWithoutDelimiters :end |\x0a\x09\x09aBlock value: (self copyFrom: start to: endWithoutDelimiters) ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lineIndicesDo:", "value:", "copyFrom:to:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "match:",
+protocol: 'regular expressions',
+fn: function (aRegexp){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.search(aRegexp) != -1;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"match:",{aRegexp:aRegexp},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aRegexp"],
+source: "match: aRegexp\x0a\x09<return self.search(aRegexp) != -1>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "matchesOf:",
+protocol: 'regular expressions',
+fn: function (aRegularExpression){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.match(aRegularExpression);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"matchesOf:",{aRegularExpression:aRegularExpression},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aRegularExpression"],
+source: "matchesOf: aRegularExpression\x0a\x09<return self.match(aRegularExpression)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "numericallyIndexable",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"numericallyIndexable",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "numericallyIndexable\x0a\x09<return String(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "printNl",
+protocol: 'printing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+console.log(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printNl",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "printNl\x0a\x09<console.log(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_("'");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream \x0a\x09\x09nextPutAll: '''';\x0a\x09\x09nextPutAll: self;\x0a\x09\x09nextPutAll: ''''",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "replace:with:",
+protocol: 'regular expressions',
+fn: function (aString,anotherString){
+var self=this;
+function $RegularExpression(){return $globals.RegularExpression||(typeof RegularExpression=="undefined"?nil:RegularExpression)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._replaceRegexp_with_($recv($RegularExpression())._fromString_flag_(aString,"g"),anotherString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"replace:with:",{aString:aString,anotherString:anotherString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString"],
+source: "replace: aString with: anotherString\x0a\x09^ self replaceRegexp: (RegularExpression fromString: aString flag: 'g') with: anotherString",
+referencedClasses: ["RegularExpression"],
+//>>excludeEnd("ide");
+messageSends: ["replaceRegexp:with:", "fromString:flag:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "replaceRegexp:with:",
+protocol: 'regular expressions',
+fn: function (aRegexp,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.replace(aRegexp, aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"replaceRegexp:with:",{aRegexp:aRegexp,aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aRegexp", "aString"],
+source: "replaceRegexp: aRegexp with: aString\x0a\x09<return self.replace(aRegexp, aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "reversed",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.split("").reverse().join("");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reversed",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "reversed\x0a\x09<return self.split(\x22\x22).reverse().join(\x22\x22)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._fromString_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shallowCopy",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09^ self class fromString: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromString:", "class"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.length;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09<return self.length>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "subStrings:",
+protocol: 'split join',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tokenize_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subStrings:",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "subStrings: aString\x0a\x09^ self tokenize: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tokenize:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "tokenize:",
+protocol: 'split join',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.split(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tokenize:",{aString:aString},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "tokenize: aString\x0a\x09<return self.split(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimBoth",
+protocol: 'regular expressions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._trimBoth_("\x5cs");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimBoth",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "trimBoth\x0a\x09^ self trimBoth: '\x5cs'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["trimBoth:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimBoth:",
+protocol: 'regular expressions',
+fn: function (separators){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._trimLeft_(separators))._trimRight_(separators);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimBoth:",{separators:separators},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["separators"],
+source: "trimBoth: separators\x0a\x09^ (self trimLeft: separators) trimRight: separators",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["trimRight:", "trimLeft:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimLeft",
+protocol: 'regular expressions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._trimLeft_("\x5cs");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimLeft",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "trimLeft\x0a\x09^ self trimLeft: '\x5cs'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["trimLeft:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimLeft:",
+protocol: 'regular expressions',
+fn: function (separators){
+var self=this;
+function $RegularExpression(){return $globals.RegularExpression||(typeof RegularExpression=="undefined"?nil:RegularExpression)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=$recv("^[".__comma(separators)).__comma("]+");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$2=$recv($RegularExpression())._fromString_flag_($3,"g");
+$1=self._replaceRegexp_with_($2,"");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimLeft:",{separators:separators},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["separators"],
+source: "trimLeft: separators\x0a\x09^ self replaceRegexp: (RegularExpression fromString: '^[', separators, ']+' flag: 'g') with: ''",
+referencedClasses: ["RegularExpression"],
+//>>excludeEnd("ide");
+messageSends: ["replaceRegexp:with:", "fromString:flag:", ","]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimRight",
+protocol: 'regular expressions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._trimRight_("\x5cs");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimRight",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "trimRight\x0a\x09^ self trimRight: '\x5cs'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["trimRight:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "trimRight:",
+protocol: 'regular expressions',
+fn: function (separators){
+var self=this;
+function $RegularExpression(){return $globals.RegularExpression||(typeof RegularExpression=="undefined"?nil:RegularExpression)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=$recv("[".__comma(separators)).__comma("]+$");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$2=$recv($RegularExpression())._fromString_flag_($3,"g");
+$1=self._replaceRegexp_with_($2,"");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"trimRight:",{separators:separators},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["separators"],
+source: "trimRight: separators\x0a\x09^ self replaceRegexp: (RegularExpression fromString: '[', separators, ']+$' flag: 'g') with: ''",
+referencedClasses: ["RegularExpression"],
+//>>excludeEnd("ide");
+messageSends: ["replaceRegexp:with:", "fromString:flag:", ","]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "unescaped",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return unescape(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"unescaped",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "unescaped\x0a\x09<return unescape(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "uriComponentDecoded",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return decodeURIComponent(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"uriComponentDecoded",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "uriComponentDecoded\x0a\x09<return decodeURIComponent(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "uriComponentEncoded",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return encodeURIComponent(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"uriComponentEncoded",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "uriComponentEncoded\x0a\x09<return encodeURIComponent(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "uriDecoded",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return decodeURI(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"uriDecoded",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "uriDecoded\x0a\x09<return decodeURI(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "uriEncoded",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return encodeURI(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"uriEncoded",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "uriEncoded\x0a\x09<return encodeURI(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'evaluating',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anObject)._perform_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{anObject:anObject},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "value: anObject \x0a\x09^ anObject perform: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["perform:"]
+}),
+$globals.String);
+
+
+$core.addMethod(
+$core.method({
+selector: "cr",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return '\r';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cr",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cr\x0a\x09<return '\x5cr'>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "crlf",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return '\r\n';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"crlf",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "crlf\x0a\x09<return '\x5cr\x5cn'>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "esc",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._fromCharCode_((27));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"esc",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "esc\x0a\x09^ self fromCharCode: 27",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromCharCode:"]
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromCharCode:",
+protocol: 'instance creation',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String.fromCharCode(anInteger);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromCharCode:",{anInteger:anInteger},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "fromCharCode: anInteger\x0a\x09<return String.fromCharCode(anInteger)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromString:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:",{aString:aString},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "fromString: aString\x0a\x09\x09<return String(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "lf",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return '\n';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lf",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lf\x0a\x09<return '\x5cn'>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "random",
+protocol: 'random',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return (Math.random()*(22/32)+(10/32)).toString(32).slice(2);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"random",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "random\x0a\x09\x22Returns random alphanumeric string beginning with letter\x22\x0a\x09<return (Math.random()*(22/32)+(10/32)).toString(32).slice(2);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "randomNotIn:",
+protocol: 'random',
+fn: function (aString){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+result=self._random();
+result;
+return $recv(aString)._includesSubString_(result);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue();
+$1=result;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"randomNotIn:",{aString:aString,result:result},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "randomNotIn: aString\x0a\x09| result |\x0a\x09[ result := self random. aString includesSubString: result ] whileTrue.\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileTrue", "random", "includesSubString:"]
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "space",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return ' ';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"space",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "space\x0a\x09<return ' '>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "streamClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $StringStream(){return $globals.StringStream||(typeof StringStream=="undefined"?nil:StringStream)}
+return $StringStream();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "streamClass\x0a\x09\x09^ StringStream",
+referencedClasses: ["StringStream"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "tab",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return '\t';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tab",{},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tab\x0a\x09<return '\x5ct'>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'instance creation',
+fn: function (aUTFCharCode){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return String.fromCharCode(aUTFCharCode);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{aUTFCharCode:aUTFCharCode},$globals.String.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aUTFCharCode"],
+source: "value: aUTFCharCode\x0a\x0a\x09<return String.fromCharCode(aUTFCharCode);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String.klass);
+
+
+$core.addClass('Set', $globals.Collection, ['defaultBucket', 'slowBucketStores', 'fastBuckets', 'size'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Set.comment="I represent an unordered set of objects without duplicates.\x0a\x0a## Implementation notes\x0a\x0aI put elements into different stores based on their type.\x0aThe goal is to store some elements into native JS object property names to be fast.\x0a\x0aIf an unboxed element has typeof 'string', 'boolean' or 'number', or an element is nil, null or undefined,\x0aI store it as a property name in an empty (== Object.create(null)) JS object, different for each type\x0a(for simplicity, nil/null/undefined is treated as one and included with the two booleans).\x0a\x0aIf element happen to be an object, I try to store them in `ArrayBucketStore`. I have two of them by default,\x0aone hashed using the Smalltalk class name, the other one using the JS constructor name. It is possible to have more or less\x0ainstances of `ArrayBucketStores`, see `#initializeSlowBucketStores`.\x0a\x0aAs a last resort, if none of the `ArrayBucketStore` instances can find a suitable bucket, the `defaultBucket` is used,\x0awhich is an `Array`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$4,$3,$5;
+var $early={};
+try {
+$2=self._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq($recv(aCollection)._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+if(!$core.assert($1)){
+return false;
+};
+$4=self._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__eq($recv(aCollection)._size());
+if(!$core.assert($3)){
+return false;
+};
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=$recv(aCollection)._includes_(each);
+if(!$core.assert($5)){
+throw $early=[false];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return true;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aCollection:aCollection},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "= aCollection\x0a\x09self class = aCollection class ifFalse: [ ^ false ].\x0a\x09self size = aCollection size ifFalse: [ ^ false ].\x0a\x09self do: [ :each | (aCollection includes: each) ifFalse: [ ^ false ] ].\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "=", "class", "size", "do:", "includes:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "add:",
+protocol: 'adding/removing',
+fn: function (anObject){
+var self=this;
+var bucket;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+bucket=self._bucketsOfElement_(anObject);
+$2=$recv(bucket)._second();
+if(($receiver = $2) == null || $receiver.isNil){
+var object,slowBucket;
+object=$recv(bucket)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+object;
+slowBucket=$recv(bucket)._third();
+slowBucket;
+$recv(slowBucket)._indexOf_ifAbsent_(object,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(slowBucket)._add_(object);
+self["@size"]=$recv(self["@size"]).__plus((1));
+return self["@size"];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$1=object;
+} else {
+var primitiveBucket;
+primitiveBucket=$receiver;
+$1=self._add_in_($recv(bucket)._first(),primitiveBucket);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:",{anObject:anObject,bucket:bucket},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "add: anObject\x0a\x09| bucket |\x0a\x09bucket := self bucketsOfElement: anObject.\x0a\x09^ bucket second\x0a\x09\x09ifNil: [\x0a\x09\x09\x09| object slowBucket |\x0a\x09\x09\x09object := bucket first.\x0a\x09\x09\x09slowBucket := bucket third.\x0a\x09\x09\x09slowBucket \x0a\x09\x09\x09\x09indexOf: object \x0a\x09\x09\x09\x09ifAbsent: [ \x0a\x09\x09\x09\x09\x09slowBucket add: object. \x0a\x09\x09\x09\x09\x09size := size + 1 ].\x0a\x09\x09\x09object ]\x0a\x09\x09ifNotNil: [ :primitiveBucket | \x0a\x09\x09\x09self \x0a\x09\x09\x09\x09add: bucket first \x0a\x09\x09\x09\x09in: primitiveBucket ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bucketsOfElement:", "ifNil:ifNotNil:", "second", "first", "third", "indexOf:ifAbsent:", "add:", "+", "add:in:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "add:in:",
+protocol: 'private',
+fn: function (anObject,anotherObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if (anObject in anotherObject.store) { return false; }
+		self['@size']++;
+		return anotherObject.store[anObject] = true;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"add:in:",{anObject:anObject,anotherObject:anotherObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anotherObject"],
+source: "add: anObject in: anotherObject\x0a\x09<\x0a\x09\x09if (anObject in anotherObject.store) { return false; }\x0a\x09\x09self['@size']++;\x0a\x09\x09return anotherObject.store[anObject] = true;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "bucketsOfElement:",
+protocol: 'private',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var type, bucket, prim = anObject == null ? (anObject = nil) : anObject.valueOf();
+		if ((type = typeof prim) === "object") {
+			if (anObject !== nil) {
+				bucket = null;
+				self['@slowBucketStores'].some(function (store) {
+					return bucket = store._bucketOfElement_(anObject);
+				});
+				return [ anObject, null, bucket || self['@defaultBucket'] ];
+			}
+			
+			// include nil to well-known objects under 'boolean' fastBucket
+			prim = null;
+			type = 'boolean';
+		}
+		return [ prim, self['@fastBuckets'][type] ];
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"bucketsOfElement:",{anObject:anObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "bucketsOfElement: anObject\x0a\x09\x22Find the appropriate bucket for `anObject`.\x0a\x09For optimization purposes, directly answer an array with: \x0a\x09- the object to be store\x0a\x09- the primitive bucket\x0a\x09- the slow bucket\x22\x0a\x09\x0a\x09<\x0a\x09\x09var type, bucket, prim = anObject == null ? (anObject = nil) : anObject.valueOf();\x0a\x09\x09if ((type = typeof prim) === \x22object\x22) {\x0a\x09\x09\x09if (anObject !== nil) {\x0a\x09\x09\x09\x09bucket = null;\x0a\x09\x09\x09\x09self['@slowBucketStores'].some(function (store) {\x0a\x09\x09\x09\x09\x09return bucket = store._bucketOfElement_(anObject);\x0a\x09\x09\x09\x09});\x0a\x09\x09\x09\x09return [ anObject, null, bucket || self['@defaultBucket'] ];\x0a\x09\x09\x09}\x0a\x09\x09\x09\x0a\x09\x09\x09// include nil to well-known objects under 'boolean' fastBucket\x0a\x09\x09\x09prim = null;\x0a\x09\x09\x09type = 'boolean';\x0a\x09\x09}\x0a\x09\x09return [ prim, self['@fastBuckets'][type] ];\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "classNameOf:",
+protocol: 'private',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return anObject.klass && anObject.klass.className;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classNameOf:",{anObject:anObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "classNameOf: anObject\x0a\x09\x22Answer the class name of `anObject`, or `undefined` \x0a\x09if `anObject` is not an Smalltalk object\x22\x0a\x09\x0a\x09<return anObject.klass && anObject.klass.className>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "collect:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var collection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+collection=$recv(self._class())._new();
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(collection)._add_($recv(aBlock)._value_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=collection;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"collect:",{aBlock:aBlock,collection:collection},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "collect: aBlock\x0a\x09| collection |\x0a\x09collection := self class new.\x0a\x09self do: [ :each | collection add: (aBlock value: each) ].\x0a\x09^ collection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "do:", "add:", "value:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "detect:ifNone:",
+protocol: 'enumerating',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(each);
+if($core.assert($1)){
+throw $early=[each];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv(anotherBlock)._value();
+return $2;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"detect:ifNone:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "detect: aBlock ifNone: anotherBlock\x0a\x09self do: [ :each | (aBlock value: each) ifTrue: [ ^each ] ].\x0a\x09^ anotherBlock value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifTrue:", "value:", "value"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var el, keys, i;
+		el = self['@fastBuckets'];
+		keys = Object.keys(el);
+		for (i = 0; i < keys.length; ++i) {
+			var fastBucket = el[keys[i]], fn = fastBucket.fn, store = Object.keys(fastBucket.store);
+			if (fn) { for (var j = 0; j < store.length; ++j) { aBlock._value_(fn(store[j])); } }
+			else { store._do_(aBlock); }
+		}
+		el = self['@slowBucketStores'];
+		for (i = 0; i < el.length; ++i) { el[i]._do_(aBlock); }
+		self['@defaultBucket']._do_(aBlock);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09<\x0a\x09\x09var el, keys, i;\x0a\x09\x09el = self['@fastBuckets'];\x0a\x09\x09keys = Object.keys(el);\x0a\x09\x09for (i = 0; i < keys.length; ++i) {\x0a\x09\x09\x09var fastBucket = el[keys[i]], fn = fastBucket.fn, store = Object.keys(fastBucket.store);\x0a\x09\x09\x09if (fn) { for (var j = 0; j < store.length; ++j) { aBlock._value_(fn(store[j])); } }\x0a\x09\x09\x09else { store._do_(aBlock); }\x0a\x09\x09}\x0a\x09\x09el = self['@slowBucketStores'];\x0a\x09\x09for (i = 0; i < el.length; ++i) { el[i]._do_(aBlock); }\x0a\x09\x09self['@defaultBucket']._do_(aBlock);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "includes:",
+protocol: 'testing',
+fn: function (anObject){
+var self=this;
+var bucket;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$1,$receiver;
+bucket=self._bucketsOfElement_(anObject);
+$2=$recv(bucket)._second();
+if(($receiver = $2) == null || $receiver.isNil){
+$3=$recv(bucket)._third();
+$4=$recv(bucket)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($3)._includes_($4);
+} else {
+var primitiveBucket;
+primitiveBucket=$receiver;
+$1=self._includes_in_($recv(bucket)._first(),primitiveBucket);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includes:",{anObject:anObject,bucket:bucket},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "includes: anObject\x0a\x09| bucket |\x0a\x09bucket := self bucketsOfElement: anObject.\x0a\x09^ bucket second\x0a\x09\x09ifNil: [ bucket third includes: bucket first ]\x0a\x09\x09ifNotNil: [ :primitiveBucket | self includes: bucket first in: primitiveBucket ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bucketsOfElement:", "ifNil:ifNotNil:", "second", "includes:", "third", "first", "includes:in:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "includes:in:",
+protocol: 'private',
+fn: function (anObject,anotherObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return anObject in anotherObject.store;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includes:in:",{anObject:anObject,anotherObject:anotherObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anotherObject"],
+source: "includes: anObject in: anotherObject\x0a\x09<return anObject in anotherObject.store>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Set.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@defaultBucket"]=[];
+self._initializeSlowBucketStores();
+$1=self._removeAll();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09\x0a\x09defaultBucket := #().\x0a\x09self\x0a\x09\x09initializeSlowBucketStores;\x0a\x09\x09removeAll",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "initializeSlowBucketStores", "removeAll"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "initializeSlowBucketStores",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $ArrayBucketStore(){return $globals.ArrayBucketStore||(typeof ArrayBucketStore=="undefined"?nil:ArrayBucketStore)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($ArrayBucketStore())._hashBlock_((function(x){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._classNameOf_(x);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({x:x},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["hashBlock:"]=1;
+//>>excludeEnd("ctx");
+self["@slowBucketStores"]=[$1,$recv($ArrayBucketStore())._hashBlock_((function(x){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._jsConstructorNameOf_(x);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({x:x},$ctx1,2)});
+//>>excludeEnd("ctx");
+}))];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeSlowBucketStores",{},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initializeSlowBucketStores\x0a\x09slowBucketStores := {\x0a\x09\x09ArrayBucketStore hashBlock: [ :x | self classNameOf: x ].\x0a\x09\x09ArrayBucketStore hashBlock: [ :x | self jsConstructorNameOf: x ]\x0a\x09}",
+referencedClasses: ["ArrayBucketStore"],
+//>>excludeEnd("ide");
+messageSends: ["hashBlock:", "classNameOf:", "jsConstructorNameOf:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "jsConstructorNameOf:",
+protocol: 'private',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return anObject.constructor && anObject.constructor.name;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jsConstructorNameOf:",{anObject:anObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "jsConstructorNameOf: anObject\x0a\x09<return anObject.constructor && anObject.constructor.name>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Set.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printOn:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(" (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+self._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._printOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09\x0a\x09aStream nextPutAll: ' ('.\x0a\x09self \x0a\x09\x09do: [ :each | each printOn: aStream ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ' ' ].\x0a\x09aStream nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "do:separatedBy:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "remove:ifAbsent:",
+protocol: 'adding/removing',
+fn: function (anObject,aBlock){
+var self=this;
+var bucket;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$5,$1,$receiver;
+var $early={};
+try {
+bucket=self._bucketsOfElement_(anObject);
+$2=$recv(bucket)._second();
+if(($receiver = $2) == null || $receiver.isNil){
+$3=$recv(bucket)._third();
+$4=$recv(bucket)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+$recv($3)._remove_ifAbsent_($4,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=$recv(aBlock)._value();
+throw $early=[$5];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+self["@size"]=$recv(self["@size"]).__minus((1));
+$1=self["@size"];
+} else {
+var primitiveBucket;
+primitiveBucket=$receiver;
+$1=self._remove_in_($recv(bucket)._first(),primitiveBucket);
+};
+return $1;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:ifAbsent:",{anObject:anObject,aBlock:aBlock,bucket:bucket},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aBlock"],
+source: "remove: anObject ifAbsent: aBlock\x0a\x09| bucket |\x0a\x09bucket := self bucketsOfElement: anObject.\x0a\x09^ bucket second\x0a\x09\x09ifNil: [ bucket third remove: bucket first ifAbsent: [ ^aBlock value ]. size := size - 1 ]\x0a\x09\x09ifNotNil: [ :primitiveBucket | self remove: bucket first in: primitiveBucket ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bucketsOfElement:", "ifNil:ifNotNil:", "second", "remove:ifAbsent:", "third", "first", "value", "-", "remove:in:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "remove:in:",
+protocol: 'private',
+fn: function (anObject,anotherObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+if (delete anotherObject.store[anObject]) self['@size']--;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"remove:in:",{anObject:anObject,anotherObject:anotherObject},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anotherObject"],
+source: "remove: anObject in: anotherObject\x0a\x09<if (delete anotherObject.store[anObject]) self['@size']-->",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "removeAll",
+protocol: 'adding/removing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self['@fastBuckets'] = {
+			'boolean': { store: Object.create(null), fn: function (x) { return {'true': true, 'false': false, 'null': null}[x]; } },
+			'number': { store: Object.create(null), fn: Number },
+			'string': { store: Object.create(null) }
+		};
+		self['@slowBucketStores'].forEach(function (x) { x._removeAll(); });
+		self['@defaultBucket']._removeAll();
+		self['@size'] = 0;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAll",{},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "removeAll\x0a\x09<\x0a\x09\x09self['@fastBuckets'] = {\x0a\x09\x09\x09'boolean': { store: Object.create(null), fn: function (x) { return {'true': true, 'false': false, 'null': null}[x]; } },\x0a\x09\x09\x09'number': { store: Object.create(null), fn: Number },\x0a\x09\x09\x09'string': { store: Object.create(null) }\x0a\x09\x09};\x0a\x09\x09self['@slowBucketStores'].forEach(function (x) { x._removeAll(); });\x0a\x09\x09self['@defaultBucket']._removeAll();\x0a\x09\x09self['@size'] = 0;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "select:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var collection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+collection=$recv(self._class())._new();
+self._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(aBlock)._value_(each);
+if($core.assert($1)){
+return $recv(collection)._add_(each);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=collection;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select:",{aBlock:aBlock,collection:collection},$globals.Set)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "select: aBlock\x0a\x09| collection |\x0a\x09collection := self class new.\x0a\x09self do: [ :each |\x0a\x09\x09(aBlock value: each) ifTrue: [\x0a\x09\x09\x09collection add: each ] ].\x0a\x09^ collection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "do:", "ifTrue:", "value:", "add:"]
+}),
+$globals.Set);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@size"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09^ size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Set);
+
+
+
+$core.addClass('Queue', $globals.Object, ['read', 'readIndex', 'write'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Queue.comment="I am a one-sided queue.\x0a\x0a## Usage\x0a\x0aUse `#nextPut:` to add items to the queue.\x0aUse `#next` or `#nextIfAbsent:` to get (and remove) the next item in the queue.\x0a\x0a## Implementation notes\x0a\x0aA Queue uses two OrderedCollections inside,\x0a`read` is at the front, is not modified and only read using `readIndex`.\x0a`write` is at the back and is appended new items.\x0aWhen `read` is exhausted, `write` is promoted to `read` and new `write` is created.\x0a\x0aAs a consequence, no data moving is done by me, write appending may do data moving\x0awhen growing `write`, but this is left to engine to implement as good as it chooses to.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Queue.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@read"]=$recv($OrderedCollection())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+self["@write"]=$recv($OrderedCollection())._new();
+self["@readIndex"]=(1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Queue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09read := OrderedCollection new.\x0a\x09write := OrderedCollection new.\x0a\x09readIndex := 1",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new"]
+}),
+$globals.Queue);
+
+$core.addMethod(
+$core.method({
+selector: "next",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._nextIfAbsent_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Cannot read from empty Queue.");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next",{},$globals.Queue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "next\x0a\x09^ self nextIfAbsent: [ self error: 'Cannot read from empty Queue.' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextIfAbsent:", "error:"]
+}),
+$globals.Queue);
+
+$core.addMethod(
+$core.method({
+selector: "nextIfAbsent:",
+protocol: 'accessing',
+fn: function (aBlock){
+var self=this;
+var result;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+var $early={};
+try {
+result=$recv(self["@read"])._at_ifAbsent_(self["@readIndex"],(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(self["@write"])._isEmpty();
+if($core.assert($1)){
+$2=$recv(self["@readIndex"]).__gt((1));
+if($core.assert($2)){
+self["@read"]=[];
+self["@read"];
+self["@readIndex"]=(1);
+self["@readIndex"];
+};
+$3=$recv(aBlock)._value();
+throw $early=[$3];
+};
+self["@read"]=self["@write"];
+self["@read"];
+self["@readIndex"]=(1);
+self["@readIndex"];
+self["@write"]=$recv($OrderedCollection())._new();
+self["@write"];
+return $recv(self["@read"])._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(self["@read"])._at_put_(self["@readIndex"],nil);
+self["@readIndex"]=$recv(self["@readIndex"]).__plus((1));
+$4=result;
+return $4;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextIfAbsent:",{aBlock:aBlock,result:result},$globals.Queue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextIfAbsent: aBlock\x0a\x09| result |\x0a\x09result := read at: readIndex ifAbsent: [\x0a\x09\x09write isEmpty ifTrue: [\x0a\x09\x09\x09readIndex > 1 ifTrue: [ read := #(). readIndex := 1 ].\x0a\x09\x09\x09^ aBlock value ].\x0a\x09\x09read := write.\x0a\x09\x09readIndex := 1.\x0a\x09\x09write := OrderedCollection new.\x0a\x09\x09read first ].\x0a\x09read at: readIndex put: nil.\x0a\x09readIndex := readIndex + 1.\x0a\x09^ result",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "ifTrue:", "isEmpty", ">", "value", "new", "first", "at:put:", "+"]
+}),
+$globals.Queue);
+
+$core.addMethod(
+$core.method({
+selector: "nextPut:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@write"])._add_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPut:",{anObject:anObject},$globals.Queue)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "nextPut: anObject\x0a\x09write add: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:"]
+}),
+$globals.Queue);
+
+
+
+$core.addClass('RegularExpression', $globals.Object, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.RegularExpression.comment="I represent a regular expression object. My instances are JavaScript `RegExp` object.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "compile:",
+protocol: 'evaluating',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.compile(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compile:",{aString:aString},$globals.RegularExpression)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compile: aString\x0a\x09<return self.compile(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.RegularExpression);
+
+$core.addMethod(
+$core.method({
+selector: "exec:",
+protocol: 'evaluating',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.exec(aString) || nil;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exec:",{aString:aString},$globals.RegularExpression)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "exec: aString\x0a\x09<return self.exec(aString) || nil>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.RegularExpression);
+
+$core.addMethod(
+$core.method({
+selector: "test:",
+protocol: 'evaluating',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.test(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"test:",{aString:aString},$globals.RegularExpression)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "test: aString\x0a\x09<return self.test(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.RegularExpression);
+
+
+$core.addMethod(
+$core.method({
+selector: "fromString:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._fromString_flag_(aString,"");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:",{aString:aString},$globals.RegularExpression.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "fromString: aString\x0a\x09\x09^ self fromString: aString flag: ''",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromString:flag:"]
+}),
+$globals.RegularExpression.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromString:flag:",
+protocol: 'instance creation',
+fn: function (aString,anotherString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return new RegExp(aString, anotherString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:flag:",{aString:aString,anotherString:anotherString},$globals.RegularExpression.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString"],
+source: "fromString: aString flag: anotherString\x0a\x09<return new RegExp(aString, anotherString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.RegularExpression.klass);
+
+
+$core.addClass('Stream', $globals.Object, ['collection', 'position', 'streamSize'], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Stream.comment="I represent an accessor for a sequence of objects. This sequence is referred to as my \x22contents\x22.\x0aMy instances are read/write streams to the contents sequence collection.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "<<",
+protocol: 'writing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._write_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<<",{anObject:anObject},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "<< anObject\x0a\x09self write: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["write:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "atEnd",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._position()).__eq(self._size());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atEnd",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atEnd\x0a\x09^ self position = self size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "position", "size"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "atStart",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._position()).__eq((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atStart",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atStart\x0a\x09^ self position = 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "position"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "close",
+protocol: 'actions',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "close",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "collection",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@collection"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "collection\x0a\x09^ collection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "contents",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._collection())._copyFrom_to_((1),self._streamSize());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contents",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "contents\x0a\x09^ self collection\x0a\x09\x09copyFrom: 1\x0a\x09\x09to: self streamSize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copyFrom:to:", "collection", "streamSize"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "do:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._atEnd();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._value_(self._next());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:",{aBlock:aBlock},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "do: aBlock\x0a\x09[ self atEnd ] whileFalse: [ aBlock value: self next ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "atEnd", "value:", "next"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "flush",
+protocol: 'actions',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "flush",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "isEmpty",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._size()).__eq((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isEmpty",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isEmpty\x0a\x09^ self size = 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "size"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "next",
+protocol: 'reading',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$4,$3,$1;
+$2=self._atEnd();
+if($core.assert($2)){
+$1=nil;
+} else {
+$4=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__plus((1));
+self._position_($3);
+$1=$recv(self["@collection"])._at_(self._position());
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "next\x0a\x09^ self atEnd\x0a\x09\x09ifTrue: [ nil ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09self position: self position + 1.\x0a\x09\x09\x09collection at: self position ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "atEnd", "position:", "+", "position", "at:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "next:",
+protocol: 'reading',
+fn: function (anInteger){
+var self=this;
+var tempCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+tempCollection=$recv($recv(self._collection())._class())._new();
+$recv(anInteger)._timesRepeat_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._atEnd();
+if(!$core.assert($1)){
+return $recv(tempCollection)._add_(self._next());
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=tempCollection;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next:",{anInteger:anInteger,tempCollection:tempCollection},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "next: anInteger\x0a\x09| tempCollection |\x0a\x09tempCollection := self collection class new.\x0a\x09anInteger timesRepeat: [\x0a\x09\x09self atEnd ifFalse: [\x0a\x09\x09tempCollection add: self next ]].\x0a\x09^ tempCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", "add:", "next"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPut:",
+protocol: 'writing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4;
+$2=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__plus((1));
+self._position_($1);
+$3=self._collection();
+$4=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=2;
+//>>excludeEnd("ctx");
+$recv($3)._at_put_($4,anObject);
+self._setStreamSize_($recv(self._streamSize())._max_(self._position()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPut:",{anObject:anObject},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "nextPut: anObject\x0a\x09self position: self position + 1.\x0a\x09self collection at: self position put: anObject.\x0a\x09self setStreamSize: (self streamSize max: self position)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["position:", "+", "position", "at:put:", "collection", "setStreamSize:", "max:", "streamSize"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutAll:",
+protocol: 'writing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._nextPut_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutAll:",{aCollection:aCollection},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "nextPutAll: aCollection\x0a\x09aCollection do: [ :each |\x0a\x09\x09self nextPut: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "nextPut:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutString:",
+protocol: 'writing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._nextPut_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutString:",{aString:aString},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPutString: aString\x0a\x09self nextPut: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPut:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "peek",
+protocol: 'reading',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._atEnd();
+if(!$core.assert($2)){
+$1=$recv(self._collection())._at_($recv(self._position()).__plus((1)));
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"peek",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "peek\x0a\x09^ self atEnd ifFalse: [\x0a\x09\x09self collection at: self position + 1 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "atEnd", "at:", "collection", "+", "position"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "position",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@position"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@position"]=(0);
+$1=self["@position"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"position",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "position\x0a\x09^ position ifNil: [ position := 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "position:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@position"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "position: anInteger\x0a\x09position := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "reset",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._position_((0));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reset",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "reset\x0a\x09self position: 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["position:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "resetContents",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._reset();
+self._setStreamSize_((0));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"resetContents",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "resetContents\x0a\x09self reset.\x0a\x09self setStreamSize: 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reset", "setStreamSize:"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "setCollection:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@collection"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "setCollection: aCollection\x0a\x09collection := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "setStreamSize:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@streamSize"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "setStreamSize: anInteger\x0a\x09streamSize := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "setToEnd",
+protocol: 'positioning',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._position_(self._size());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setToEnd",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setToEnd\x0a\x09self position: self size",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["position:", "size"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._streamSize();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09^ self streamSize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["streamSize"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "skip:",
+protocol: 'positioning',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._position_($recv($recv(self._position()).__plus(anInteger))._min_max_(self._size(),(0)));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"skip:",{anInteger:anInteger},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "skip: anInteger\x0a\x09self position: ((self position + anInteger) min: self size max: 0)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["position:", "min:max:", "+", "position", "size"]
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "streamSize",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@streamSize"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "streamSize\x0a\x09^ streamSize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Stream);
+
+$core.addMethod(
+$core.method({
+selector: "write:",
+protocol: 'writing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(anObject)._putOn_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"write:",{anObject:anObject},$globals.Stream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "write: anObject\x0a\x09anObject putOn: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["putOn:"]
+}),
+$globals.Stream);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._setCollection_(aCollection);
+$recv($2)._setStreamSize_($recv(aCollection)._size());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aCollection:aCollection},$globals.Stream.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "on: aCollection\x0a\x09\x09^ self new\x0a\x09\x09setCollection: aCollection;\x0a\x09\x09setStreamSize: aCollection size;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["setCollection:", "new", "setStreamSize:", "size", "yourself"]
+}),
+$globals.Stream.klass);
+
+
+$core.addClass('StringStream', $globals.Stream, [], 'Kernel-Collections');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.StringStream.comment="I am a Stream specific to `String` objects.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "cr",
+protocol: 'writing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._nextPutAll_($recv($String())._cr());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cr",{},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cr\x0a\x09^ self nextPutAll: String cr",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "cr"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "crlf",
+protocol: 'writing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._nextPutAll_($recv($String())._crlf());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"crlf",{},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "crlf\x0a\x09^ self nextPutAll: String crlf",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "crlf"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "lf",
+protocol: 'writing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._nextPutAll_($recv($String())._lf());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lf",{},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lf\x0a\x09^ self nextPutAll: String lf",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "next:",
+protocol: 'reading',
+fn: function (anInteger){
+var self=this;
+var tempCollection;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+tempCollection=$recv($recv(self._collection())._class())._new();
+$recv(anInteger)._timesRepeat_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._atEnd();
+if(!$core.assert($1)){
+tempCollection=$recv(tempCollection).__comma(self._next());
+return tempCollection;
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=tempCollection;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next:",{anInteger:anInteger,tempCollection:tempCollection},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "next: anInteger\x0a\x09| tempCollection |\x0a\x09tempCollection := self collection class new.\x0a\x09anInteger timesRepeat: [\x0a\x09\x09self atEnd ifFalse: [\x0a\x09\x09tempCollection := tempCollection, self next ]].\x0a\x09^ tempCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", ",", "next"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPut:",
+protocol: 'writing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._nextPutAll_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPut:",{aString:aString},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPut: aString\x0a\x09self nextPutAll: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutAll:",
+protocol: 'writing',
+fn: function (aString){
+var self=this;
+var pre,post;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$6,$9,$8,$10,$7,$11,$12,$14,$13;
+$1=self._atEnd();
+if($core.assert($1)){
+$3=self._collection();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["collection"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._setCollection_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["setCollection:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$4=self._collection();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["collection"]=2;
+//>>excludeEnd("ctx");
+$5=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=1;
+//>>excludeEnd("ctx");
+pre=$recv($4)._copyFrom_to_((1),$5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["copyFrom:to:"]=1;
+//>>excludeEnd("ctx");
+pre;
+$6=self._collection();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["collection"]=3;
+//>>excludeEnd("ctx");
+$9=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=2;
+//>>excludeEnd("ctx");
+$8=$recv($9).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=2;
+//>>excludeEnd("ctx");
+$10=$recv(aString)._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=1;
+//>>excludeEnd("ctx");
+$7=$recv($8).__plus($10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+$11=$recv(self._collection())._size();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["size"]=2;
+//>>excludeEnd("ctx");
+post=$recv($6)._copyFrom_to_($7,$11);
+post;
+$12=$recv($recv(pre).__comma(aString)).__comma(post);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+self._setCollection_($12);
+};
+$14=self._position();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["position"]=3;
+//>>excludeEnd("ctx");
+$13=$recv($14).__plus($recv(aString)._size());
+self._position_($13);
+self._setStreamSize_($recv(self._streamSize())._max_(self._position()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutAll:",{aString:aString,pre:pre,post:post},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPutAll: aString\x0a\x09| pre post |\x0a\x09self atEnd ifTrue: [ self setCollection: self collection, aString ] ifFalse: [\x0a\x09\x09pre := self collection copyFrom: 1 to: self position.\x0a\x09\x09post := self collection copyFrom: (self position + 1 + aString size) to: self collection size.\x0a\x09\x09self setCollection: pre, aString, post\x0a\x09].\x0a\x09self position: self position + aString size.\x0a\x09self setStreamSize: (self streamSize max: self position)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "atEnd", "setCollection:", ",", "collection", "copyFrom:to:", "position", "+", "size", "position:", "setStreamSize:", "max:", "streamSize"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "nextPutString:",
+protocol: 'writing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._nextPutAll_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextPutString:",{aString:aString},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "nextPutString: aString\x0a\x09self nextPutAll: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "space",
+protocol: 'writing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._nextPut_(" ");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"space",{},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "space\x0a\x09self nextPut: ' '",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPut:"]
+}),
+$globals.StringStream);
+
+$core.addMethod(
+$core.method({
+selector: "tab",
+protocol: 'writing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._nextPutAll_($recv($String())._tab());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tab",{},$globals.StringStream)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tab\x0a\x09^ self nextPutAll: String tab",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "tab"]
+}),
+$globals.StringStream);
+
+
+});

+ 2337 - 0
bower_components/amber/src/Kernel-Collections.st

@@ -0,0 +1,2337 @@
+Smalltalk createPackage: 'Kernel-Collections'!
+Object subclass: #Association
+	instanceVariableNames: 'key value'
+	package: 'Kernel-Collections'!
+!Association commentStamp!
+I represent a pair of associated objects, a key and a value. My instances can serve as entries in a dictionary.
+
+Instances can be created with the class-side method `#key:value:`!
+
+!Association methodsFor: 'accessing'!
+
+key
+	^ key
+!
+
+key: aKey
+	key := aKey
+!
+
+value
+	^ value
+!
+
+value: aValue
+	value := aValue
+! !
+
+!Association methodsFor: 'comparing'!
+
+= anAssociation
+	^ self class = anAssociation class and: [
+		self key = anAssociation key and: [
+		self value = anAssociation value ]]
+! !
+
+!Association methodsFor: 'printing'!
+
+printOn: aStream
+	self key printOn: aStream.
+	aStream nextPutAll: ' -> '.
+	self value printOn: aStream
+! !
+
+!Association class methodsFor: 'instance creation'!
+
+key: aKey value: aValue
+		^ self new
+		key: aKey;
+		value: aValue;
+		yourself
+! !
+
+Object subclass: #BucketStore
+	instanceVariableNames: 'buckets hashBlock'
+	package: 'Kernel-Collections'!
+!BucketStore commentStamp!
+I am an helper class for hash-based stores.
+
+I hold buckets which are selected by a hash, specified using `#hashBlock:`.
+The hash can be any object, and
+it is used as a JS property (that is, in ES5
+its toString() value counts).
+
+## API
+I maintain a list of buckets. Client code can use this API:
+ - `#bucketOfElement:` (to ask a bucket for element, I can return JS null if n/a)
+ - `#do:` (to enumerate all elements of all buckets)
+ - `#removeAll` (to remove all buckets)
+
+Client code itself should add/remove elements
+in a bucket. The `nil` object should not be put into any bucket.
+
+Types of buckets are the responsibility of subclasses via `#newBucket`.!
+
+!BucketStore methodsFor: 'accessing'!
+
+bucketOfElement: anObject
+	<
+		var hash = self['@hashBlock'](anObject);
+		if (!!hash) return null;
+		var buckets = self['@buckets'],
+			bucket = buckets[hash];
+		if (!!bucket) { bucket = buckets[hash] = self._newBucket(); }
+		return bucket;
+	>
+!
+
+hashBlock: aBlock
+	hashBlock := aBlock
+! !
+
+!BucketStore methodsFor: 'adding/removing'!
+
+removeAll
+	<self['@buckets'] = Object.create(null);>
+! !
+
+!BucketStore methodsFor: 'enumerating'!
+
+do: aBlock
+	<
+		var buckets = self['@buckets'];
+		var keys = Object.keys(buckets);
+		for (var i = 0; i < keys.length; ++i) { buckets[keys[i]]._do_(aBlock); }
+	>
+! !
+
+!BucketStore methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	self removeAll
+! !
+
+!BucketStore methodsFor: 'private'!
+
+newBucket
+	self subclassResponsibility
+! !
+
+!BucketStore class methodsFor: 'instance creation'!
+
+hashBlock: aBlock
+	^ self new
+		hashBlock: aBlock;
+		yourself
+! !
+
+BucketStore subclass: #ArrayBucketStore
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!ArrayBucketStore commentStamp!
+I am a concrete `BucketStore` with buckets being instance of `Array`.!
+
+!ArrayBucketStore methodsFor: 'private'!
+
+newBucket
+	^ #()
+! !
+
+Object subclass: #Collection
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!Collection commentStamp!
+I am the abstract superclass of all classes that represent a group of elements.
+
+I provide a set of useful methods to the Collection hierarchy such as enumerating and converting methods.!
+
+!Collection methodsFor: 'accessing'!
+
+occurrencesOf: anObject
+	"Answer how many of the receiver's elements are equal to anObject."
+
+	| tally |
+	tally := 0.
+	self do: [ :each | anObject = each ifTrue: [ tally := tally + 1 ]].
+	^ tally
+!
+
+size
+	self subclassResponsibility
+! !
+
+!Collection methodsFor: 'adding/removing'!
+
+add: anObject
+	self subclassResponsibility
+!
+
+addAll: aCollection
+	aCollection do: [ :each |
+		self add: each ].
+	^ aCollection
+!
+
+anyOne
+	"Answer a representative sample of the receiver. This method can
+	be helpful when needing to preinfer the nature of the contents of 
+	semi-homogeneous collections."
+
+	self ifEmpty: [ self error: 'Collection is empty' ].
+	self do: [ :each | ^ each ]
+!
+
+remove: anObject
+	^ self remove: anObject ifAbsent: [ self errorNotFound ]
+!
+
+remove: anObject ifAbsent: aBlock
+	self subclassResponsibility
+!
+
+removeAll
+	self subclassResponsibility
+! !
+
+!Collection methodsFor: 'converting'!
+
+asArray
+	^ Array withAll: self
+!
+
+asJSON
+	^ self asArray collect: [ :each | each asJSON ]
+!
+
+asOrderedCollection
+	^ self asArray
+!
+
+asSet
+	^ Set withAll: self
+! !
+
+!Collection methodsFor: 'copying'!
+
+, aCollection
+	^ self copy
+		addAll: aCollection;
+		yourself
+!
+
+copyWith: anObject
+	^ self copy add: anObject; yourself
+!
+
+copyWithAll: aCollection
+	^ self copy addAll: aCollection; yourself
+!
+
+copyWithoutAll: aCollection
+	"Answer a copy of the receiver that does not contain any elements
+	equal to those in aCollection."
+
+	^ self reject: [ :each | aCollection includes: each ]
+! !
+
+!Collection methodsFor: 'enumerating'!
+
+allSatisfy: aBlock
+	"Evaluate aBlock with the elements of the receiver.
+	If aBlock returns false for any element return false.
+	Otherwise return true."
+
+	self do: [ :each | (aBlock value: each) ifFalse: [ ^ false ] ].
+	^ true
+!
+
+anySatisfy: aBlock
+	"Evaluate aBlock with the elements of the receiver.
+	If aBlock returns true for any element return true.
+	Otherwise return false."
+
+	self do: [ :each | (aBlock value: each) ifTrue: [ ^ true ] ].
+	^ false
+!
+
+collect: aBlock
+	| stream |
+	stream := self class new writeStream.
+	self do: [ :each |
+		stream nextPut: (aBlock value: each) ].
+	^ stream contents
+!
+
+detect: aBlock
+	^ self detect: aBlock ifNone: [ self errorNotFound ]
+!
+
+detect: aBlock ifNone: anotherBlock
+	self subclassResponsibility
+!
+
+do: aBlock
+	self subclassResponsibility
+!
+
+do: aBlock separatedBy: anotherBlock
+	| actionBeforeElement |
+	actionBeforeElement := [ actionBeforeElement := anotherBlock ].
+	self do: [ :each |
+		actionBeforeElement value.
+		aBlock value: each ]
+!
+
+inject: anObject into: aBlock
+	| result |
+	result := anObject.
+	self do: [ :each |
+		result := aBlock value: result value: each ].
+	^ result
+!
+
+intersection: aCollection
+	"Answer the set theoretic intersection of two collections."
+
+	| set outputSet |
+	
+	set := self asSet.
+	outputSet := Set new.
+	
+	aCollection do: [ :each |
+		((set includes: each) and: [ (outputSet includes: each) not ])
+			ifTrue: [
+				outputSet add: each ]].
+		
+	^ self class withAll: outputSet asArray
+!
+
+noneSatisfy: aBlock
+	"Evaluate aBlock with the elements of the receiver.
+	If aBlock returns false for all elements return true.
+	Otherwise return false"
+
+	self do: [ :item | (aBlock value: item) ifTrue: [ ^ false ] ].
+	^ true
+!
+
+reject: aBlock
+	^ self select: [ :each | (aBlock value: each) = false ]
+!
+
+select: aBlock
+	| stream |
+	stream := self class new writeStream.
+	self do: [ :each |
+		(aBlock value: each) ifTrue: [
+		stream nextPut: each ] ].
+	^ stream contents
+!
+
+select: selectBlock thenCollect: collectBlock
+	| stream |
+	stream := self class new writeStream.
+	self do: [ :each |
+		(selectBlock value: each) ifTrue: [
+		stream nextPut: (collectBlock value: each) ] ].
+	^ stream contents
+! !
+
+!Collection methodsFor: 'error handling'!
+
+errorNotFound
+	self error: 'Object is not in the collection'
+! !
+
+!Collection methodsFor: 'streaming'!
+
+putOn: aStream
+	self do: [ :each | each putOn: aStream ]
+! !
+
+!Collection methodsFor: 'testing'!
+
+contains: aBlock
+	self deprecatedAPI.
+
+	^ self anySatisfy: aBlock
+!
+
+ifEmpty: aBlock
+	"Evaluate the given block with the receiver as argument, answering its value if the receiver is empty, otherwise answer the receiver. 
+	Note that the fact that this method returns its argument in case the receiver is not empty allows one to write expressions like the following ones: 
+		self classifyMethodAs:
+			(myProtocol ifEmpty: ['As yet unclassified'])"
+	^ self isEmpty
+		ifTrue: aBlock
+		ifFalse: [ self ]
+!
+
+ifEmpty: aBlock ifNotEmpty: anotherBlock
+	^ self isEmpty
+		ifTrue: aBlock
+		ifFalse: [ anotherBlock value: self ]
+!
+
+ifNotEmpty: aBlock
+	^ self notEmpty
+		ifTrue: [ aBlock value: self ]
+		ifFalse: [ self ]
+!
+
+ifNotEmpty: aBlock ifEmpty: anotherBlock
+	^ self notEmpty
+		ifTrue: [ aBlock value: self ]
+		ifFalse: anotherBlock
+!
+
+includes: anObject
+	^ self anySatisfy: [ :each | each = anObject ]
+!
+
+isEmpty
+	^ self size = 0
+!
+
+notEmpty
+	^ self isEmpty not
+! !
+
+!Collection class methodsFor: 'helios'!
+
+heliosClass
+	^ 'collection'
+! !
+
+!Collection class methodsFor: 'instance creation'!
+
+new: anInteger
+	^ self new
+!
+
+with: anObject
+		^ self new
+		add: anObject;
+		yourself
+!
+
+with: anObject with: anotherObject
+		^ self new
+		add: anObject;
+		add: anotherObject;
+		yourself
+!
+
+with: firstObject with: secondObject with: thirdObject
+		^ self new
+		add: firstObject;
+		add: secondObject;
+		add: thirdObject;
+		yourself
+!
+
+withAll: aCollection
+		^ self new
+		addAll: aCollection;
+		yourself
+! !
+
+Collection subclass: #IndexableCollection
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!IndexableCollection commentStamp!
+I am a key-value store collection, that is,
+I store values under indexes.
+
+As a rule of thumb, if a collection has `#at:` and `#at:put:`,
+it is an IndexableCollection.!
+
+!IndexableCollection methodsFor: 'accessing'!
+
+at: anIndex
+	"Lookup the given index in the receiver.
+	If it is present, answer the value stored at anIndex.
+	Otherwise, raise an error."
+
+	^ self at: anIndex ifAbsent: [ self errorNotFound ]
+!
+
+at: anIndex ifAbsent: aBlock
+	"Lookup the given index in the receiver.
+	If it is present, answer the value stored at anIndex.
+	Otherwise, answer the value of aBlock."
+
+	self subclassResponsibility
+!
+
+at: aKey ifAbsentPut: aBlock
+	^ self at: aKey ifAbsent: [
+		self at: aKey put: aBlock value ]
+!
+
+at: anIndex ifPresent: aBlock
+	"Lookup the given index in the receiver.
+	If it is present, answer the value of evaluating aBlock with the value stored at anIndex.
+	Otherwise, answer nil."
+
+	^ self at: anIndex ifPresent: aBlock ifAbsent: [ nil ]
+!
+
+at: anIndex ifPresent: aBlock ifAbsent: anotherBlock
+	"Lookup the given index in the receiver.
+	If it is present, answer the value of evaluating aBlock with the value stored at anIndex.
+	Otherwise, answer the value of anotherBlock."
+
+	self subclassResponsibility
+!
+
+at: anIndex put: anObject
+	"Store anObject under the given index in the receiver."
+
+	self subclassResponsibility
+!
+
+indexOf: anObject
+	"Lookup index at which anObject is stored in the receiver.
+	If not present, raise an error."
+
+	^ self indexOf: anObject ifAbsent: [ self errorNotFound ]
+!
+
+indexOf: anObject ifAbsent: aBlock
+	"Lookup index at which anObject is stored in the receiver.
+	If not present, return value of executing aBlock."
+
+	self subclassResponsibility
+! !
+
+!IndexableCollection methodsFor: 'enumerating'!
+
+with: anotherCollection do: aBlock
+	"Calls aBlock with every value from self
+	and with indetically-indexed value from anotherCollection"
+
+	self withIndexDo: [ :each :index |
+		aBlock value: each value: (anotherCollection at: index) ]
+!
+
+withIndexDo: aBlock
+	"Calls aBlock with every value from self
+	and with its index as the second argument"
+
+	self subclassResponsibility
+! !
+
+IndexableCollection subclass: #AssociativeCollection
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!AssociativeCollection commentStamp!
+I am a base class for object-indexed collections (Dictionary et.al.).!
+
+!AssociativeCollection methodsFor: 'accessing'!
+
+associations
+	| associations |
+	associations := #().
+	self associationsDo: [ :each | associations add: each ].
+	^ associations
+!
+
+at: aKey ifPresent: aBlock ifAbsent: anotherBlock
+	"Lookup the given key in the receiver.
+	If it is present, answer the value of evaluating the oneArgBlock 
+	with the value associated with the key, otherwise answer the value 
+	of absentBlock."
+	
+	^ (self includesKey: aKey)
+		ifTrue: [ aBlock value: (self at: aKey) ]
+		ifFalse: [ anotherBlock value ]
+!
+
+indexOf: anObject ifAbsent: aBlock
+	^ self keys 
+		detect: [ :each | (self at: each) = anObject ] 
+		ifNone: aBlock
+!
+
+keyAtValue: anObject
+	^ self keyAtValue: anObject ifAbsent: [ self errorNotFound ]
+!
+
+keyAtValue: anObject ifAbsent: aBlock
+	^ self indexOf: anObject ifAbsent: aBlock
+!
+
+keys
+	self subclassResponsibility
+!
+
+size
+	^ self keys size
+!
+
+values
+	self subclassResponsibility
+! !
+
+!AssociativeCollection methodsFor: 'adding/removing'!
+
+add: anAssociation
+	self at: anAssociation key put: anAssociation value
+!
+
+addAll: anAssociativeCollection
+	super addAll: anAssociativeCollection associations.
+	^ anAssociativeCollection
+!
+
+remove: aKey ifAbsent: aBlock
+	^ self removeKey: aKey ifAbsent: aBlock
+!
+
+removeAll
+	^ self keys do: [ :each | self removeKey: each ]
+!
+
+removeKey: aKey
+	^ self remove: aKey
+!
+
+removeKey: aKey ifAbsent: aBlock
+	self subclassResponsibility
+! !
+
+!AssociativeCollection methodsFor: 'comparing'!
+
+= anAssocitativeCollection
+	self class = anAssocitativeCollection class ifFalse: [ ^ false ].
+	self size = anAssocitativeCollection size ifFalse: [ ^ false ].
+	^ self associations = anAssocitativeCollection associations
+! !
+
+!AssociativeCollection methodsFor: 'converting'!
+
+asDictionary
+	^ Dictionary from: self associations
+!
+
+asHashedCollection
+	^ HashedCollection from: self associations
+!
+
+asJSON
+	| hash |
+	hash := HashedCollection new.
+	self keysAndValuesDo: [ :key :value |
+		hash at: key put: value asJSON ].
+	^ hash
+! !
+
+!AssociativeCollection methodsFor: 'copying'!
+
+deepCopy
+	| copy |
+	copy := self class new.
+	self keysAndValuesDo: [ :key :value |
+		copy at: key put: value deepCopy ].
+	^ copy
+!
+
+shallowCopy
+	| copy |
+	copy := self class new.
+	self keysAndValuesDo: [ :key :value |
+		copy at: key put: value ].
+	^ copy
+! !
+
+!AssociativeCollection methodsFor: 'enumerating'!
+
+associationsDo: aBlock
+	self keysAndValuesDo: [ :key :value |
+		aBlock value: (Association key: key value: value) ]
+!
+
+collect: aBlock
+	| newDict |
+	newDict := self class new.
+	self keysAndValuesDo: [ :key :value |
+		newDict at: key put: (aBlock value: value) ].
+	^ newDict
+!
+
+detect: aBlock ifNone: anotherBlock
+	^ self values detect: aBlock ifNone: anotherBlock
+!
+
+do: aBlock
+	self valuesDo: aBlock
+!
+
+includes: anObject
+	^ self values includes: anObject
+!
+
+keysAndValuesDo: aBlock
+	self keysDo: [ :each |
+		aBlock value: each value: (self at: each) ]
+!
+
+keysDo: aBlock
+	self subclassResponsibility
+!
+
+select: aBlock
+	| newDict |
+	newDict := self class new.
+	self keysAndValuesDo: [ :key :value |
+		(aBlock value: value) ifTrue: [ newDict at: key put: value ]].
+	^ newDict
+!
+
+valuesDo: aBlock
+	self subclassResponsibility
+!
+
+withIndexDo: aBlock
+	self keysAndValuesDo: [ :key :value | aBlock value: value value: key ]
+! !
+
+!AssociativeCollection methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	
+	aStream nextPutAll: ' ('.
+	self associations
+		do: [ :each | each printOn: aStream ]
+		separatedBy: [ aStream nextPutAll: ' , ' ].
+	aStream nextPutAll: ')'
+! !
+
+!AssociativeCollection methodsFor: 'testing'!
+
+includesKey: aKey
+	self subclassResponsibility
+! !
+
+!AssociativeCollection class methodsFor: 'instance creation'!
+
+from: aCollection
+	| newCollection |
+	newCollection := self new.
+	aCollection do: [ :each | newCollection add: each ].
+	^ newCollection
+!
+
+fromPairs: aCollection
+	"This message is poorly named and has been replaced by #from:"
+	^ self from: aCollection
+!
+
+newFromPairs: aCollection
+	"Accept an array of elements where every two elements form an 
+	association - the odd element being the key, and the even element the value."
+	
+	| newCollection |
+	
+	aCollection size even ifFalse: [ 
+		self error: '#newFromPairs only accepts arrays of an even length' ].
+		
+	newCollection := self new.
+	( 1 to: aCollection size by: 2 ) do: [ :each | 
+		newCollection at: (aCollection at: each) put: (aCollection at: each + 1) ].
+		
+	^ newCollection
+! !
+
+AssociativeCollection subclass: #Dictionary
+	instanceVariableNames: 'keys values'
+	package: 'Kernel-Collections'!
+!Dictionary commentStamp!
+I represent a set of elements that can be viewed from one of two perspectives: a set of associations,
+or a container of values that are externally named where the name can be any object that responds to `=`.
+
+The external name is referred to as the key.!
+
+!Dictionary methodsFor: 'accessing'!
+
+at: aKey ifAbsent: aBlock
+	<
+		var index = self._positionOfKey_(aKey);
+		return index >>=0 ? self['@values'][index] : aBlock._value();
+	>
+!
+
+at: aKey put: aValue
+	<
+		var index = self._positionOfKey_(aKey);
+		if(index === -1) {
+			var keys = self['@keys'];
+			index = keys.length;
+			keys.push(aKey);
+		}
+
+		return self['@values'][index] = aValue;
+	>
+!
+
+indexOf: anObject ifAbsent: aBlock
+	| index |
+	index := values 
+		indexOf: anObject 
+		ifAbsent: [ 0 ].
+	^ index = 0 
+		ifTrue: [ aBlock value ] 
+		ifFalse: [ keys at: index ]
+!
+
+keys
+	^ keys copy
+!
+
+values
+	^ values
+! !
+
+!Dictionary methodsFor: 'adding/removing'!
+
+removeAll
+	keys removeAll.
+	values removeAll
+!
+
+removeKey: aKey ifAbsent: aBlock
+	<
+		var index = self._positionOfKey_(aKey);
+		if(index === -1) {
+			return aBlock._value()
+		} else {
+			var keys = self['@keys'], values = self['@values'];
+			var value = values[index], l = keys.length;
+			keys[index] = keys[l-1];
+			keys.pop();
+			values[index] = values[l-1];
+			values.pop();
+			return value;
+		}
+	>
+! !
+
+!Dictionary methodsFor: 'enumerating'!
+
+keysAndValuesDo: aBlock
+	^ keys with: values do: aBlock
+!
+
+keysDo: aBlock
+	^ keys do: aBlock
+!
+
+valuesDo: aBlock
+	^ values do: aBlock
+! !
+
+!Dictionary methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	keys := #().
+	values := #()
+! !
+
+!Dictionary methodsFor: 'private'!
+
+positionOfKey: anObject
+	<
+		var keys = self['@keys'];
+		for(var i=0;i<keys.length;i++){
+			if(keys[i].__eq(anObject)) { return i;}
+		}
+		return -1;
+	>
+! !
+
+!Dictionary methodsFor: 'testing'!
+
+includesKey: aKey
+	< return self._positionOfKey_(aKey) >>= 0; >
+! !
+
+AssociativeCollection subclass: #HashedCollection
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!HashedCollection commentStamp!
+I am a traditional JavaScript object, or a Smalltalk `Dictionary`.
+
+Unlike a `Dictionary`, I can only have strings as keys.!
+
+!HashedCollection methodsFor: 'accessing'!
+
+at: aKey ifAbsent: aBlock
+	^ (self includesKey: aKey)
+		ifTrue: [ self basicAt: aKey ]
+		ifFalse: [ aBlock value ]
+!
+
+at: aKey put: aValue
+	^ self basicAt: aKey put: aValue
+!
+
+keys
+	<return Object.keys(self)>
+!
+
+values
+	<
+		return self._keys().map(function(key){
+			return self._at_(key);
+		});
+	>
+! !
+
+!HashedCollection methodsFor: 'adding/removing'!
+
+removeKey: aKey ifAbsent: aBlock
+	^ self
+		at: aKey
+		ifPresent: [ :removed | self basicDelete: aKey. removed ]
+		ifAbsent: [ aBlock value ]
+! !
+
+!HashedCollection methodsFor: 'enumerating'!
+
+keysDo: aBlock
+	self keys do: aBlock
+!
+
+valuesDo: aBlock
+	self values do: aBlock
+! !
+
+!HashedCollection methodsFor: 'testing'!
+
+includesKey: aKey
+	<return self.hasOwnProperty(aKey)>
+! !
+
+IndexableCollection subclass: #SequenceableCollection
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!SequenceableCollection commentStamp!
+I am an IndexableCollection
+with numeric indexes starting with 1.!
+
+!SequenceableCollection methodsFor: 'accessing'!
+
+allButFirst
+	^ self copyFrom: 2 to: self size
+!
+
+allButLast
+	^ self copyFrom: 1 to: self size - 1
+!
+
+atRandom
+	^ self at: self size atRandom
+!
+
+first
+	^ self at: 1
+!
+
+first: aNumber
+	"Answer the first `aNumber` elements of the receiver.
+	Raise an error if there are not enough elements in the receiver."
+
+	self size < aNumber ifTrue: [ self error: 'Invalid number of elements' ].
+
+	^ self copyFrom: 1 to: aNumber
+!
+
+fourth
+	^ self at: 4
+!
+
+indexOf: anObject ifAbsent: aBlock
+	<
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			if($recv(self[i]).__eq(anObject)) {return i+1}
+		};
+		return aBlock._value();
+	>
+!
+
+indexOf: anObject startingAt: start
+	"Answer the index of the first occurence of anElement after start
+	within the receiver. If the receiver does not contain anElement,
+	answer 0."
+	^ self indexOf: anObject startingAt: start ifAbsent: [ 0 ]
+!
+
+indexOf: anObject startingAt: start ifAbsent: aBlock
+	<
+		self = self._numericallyIndexable();
+		for(var i=start - 1; i < self.length; i++){
+			if($recv(self[i]).__eq(anObject)) {return i+1}
+		}
+		return aBlock._value();
+	>
+!
+
+last
+	^ self at: self size
+!
+
+last: aNumber
+	"Answer the last aNumber elements of the receiver.
+	Raise an error if there are not enough elements in the receiver."
+
+	self size < aNumber ifTrue: [ self error: 'Invalid number of elements' ].
+
+	^ self copyFrom: self size - aNumber + 1 to: self size
+!
+
+second
+	^ self at: 2
+!
+
+third
+	^ self at: 3
+! !
+
+!SequenceableCollection methodsFor: 'adding/removing'!
+
+addLast: anObject
+	self add: anObject
+!
+
+removeLast
+	^ self remove: self last
+! !
+
+!SequenceableCollection methodsFor: 'comparing'!
+
+= aCollection
+	(self class = aCollection class and: [
+		self size = aCollection size ]) ifFalse: [ ^ false ].
+	self withIndexDo: [ :each :i |
+				(aCollection at: i) = each ifFalse: [ ^ false ]].
+	^ true
+! !
+
+!SequenceableCollection methodsFor: 'converting'!
+
+reversed
+	self subclassResponsibility
+! !
+
+!SequenceableCollection methodsFor: 'copying'!
+
+copyFrom: anIndex to: anotherIndex
+	| range newCollection |
+	range := anIndex to: anotherIndex.
+	newCollection := self class new: range size.
+	range withIndexDo: [ :each :i |
+		newCollection at: i put: (self at: each) ].
+	^ newCollection
+!
+
+deepCopy
+	| newCollection |
+	newCollection := self class new: self size.
+	self withIndexDo: [ :each :index |
+		newCollection at: index put: each deepCopy ].
+	^ newCollection
+!
+
+shallowCopy
+	| newCollection |
+	newCollection := self class new: self size.
+	self withIndexDo: [ :each :index |
+		newCollection at: index put: each ].
+	^ newCollection
+! !
+
+!SequenceableCollection methodsFor: 'enumerating'!
+
+detect: aBlock ifNone: anotherBlock
+	<
+		self = self._numericallyIndexable();
+		for(var i = 0; i < self.length; i++)
+			if(aBlock._value_(self[i]))
+				return self[i];
+		return anotherBlock._value();
+	>
+!
+
+do: aBlock
+	<
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			aBlock._value_(self[i]);
+		}
+	>
+!
+
+with: anotherCollection do: aBlock
+	<
+		self = self._numericallyIndexable();
+		anotherCollection = anotherCollection._numericallyIndexable();
+		for(var i=0; i<self.length; i++) {
+			aBlock._value_value_(self[i], anotherCollection[i]);
+		}
+	>
+!
+
+withIndexDo: aBlock
+	<
+		self = self._numericallyIndexable();
+		for(var i=0; i < self.length; i++) {
+			aBlock._value_value_(self[i], i+1);
+		}
+	>
+! !
+
+!SequenceableCollection methodsFor: 'private'!
+
+numericallyIndexable
+	"This is an internal converting message.
+	It answeres a representation of the receiver
+	that can use foo[i] in JavaScript code.
+	
+	It fixes IE8, where boxed String is unable
+	to numerically index its characters,
+	but primitive string can."
+	
+	self subclassResponsibility
+! !
+
+!SequenceableCollection methodsFor: 'streaming'!
+
+newStream
+	^ self streamClass on: self
+!
+
+readStream
+	"For Pharo compatibility"
+	
+	^ self stream
+!
+
+stream
+	^ self newStream
+!
+
+streamClass
+	^ self class streamClass
+!
+
+writeStream
+	"For Pharo compatibility"
+	
+	^ self stream
+! !
+
+!SequenceableCollection methodsFor: 'testing'!
+
+beginsWith: prefix
+	self size < prefix size ifTrue: [ ^ false ].
+	^ (self first: prefix size) = prefix
+!
+
+endsWith: suffix
+	self size < suffix size ifTrue: [ ^ false ].
+	^ (self last: suffix size) = suffix
+!
+
+includes: anObject
+	^ (self indexOf: anObject ifAbsent: [ nil ]) notNil
+! !
+
+!SequenceableCollection class methodsFor: 'accessing'!
+
+streamClass
+		^ Stream
+! !
+
+!SequenceableCollection class methodsFor: 'streaming'!
+
+streamContents: aBlock
+	| stream |
+	stream := (self streamClass on: self new).
+	aBlock value: stream.
+	^ stream contents
+! !
+
+SequenceableCollection subclass: #Array
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!Array commentStamp!
+I represent a collection of objects ordered by the collector. The size of arrays is dynamic.
+
+I am directly mapped to JavaScript Number.
+
+*Note* In Amber, `OrderedCollection` is an alias for `Array`.!
+
+!Array methodsFor: 'accessing'!
+
+at: anIndex ifAbsent: aBlock
+	<
+		return anIndex >>= 1 && anIndex <= self.length
+			? self[anIndex - 1]
+			: aBlock._value()
+	>
+!
+
+at: anIndex ifPresent: aBlock ifAbsent: anotherBlock
+	<
+		return anIndex >>= 1 && anIndex <= self.length
+			? aBlock._value_(self[anIndex - 1])
+			: anotherBlock._value()
+	>
+!
+
+at: anIndex put: anObject
+	<return self[anIndex - 1] = anObject>
+!
+
+size
+	<return self.length>
+! !
+
+!Array methodsFor: 'adding/removing'!
+
+add: anObject
+	<self.push(anObject); return anObject;>
+!
+
+addFirst: anObject
+	<self.unshift(anObject); return anObject;>
+!
+
+remove: anObject ifAbsent: aBlock
+	| index |
+	index := self indexOf: anObject ifAbsent: [ 0 ].
+	^ index = 0
+		ifFalse: [ self removeIndex: index. anObject ]
+		ifTrue: [ aBlock value ]
+!
+
+removeAll
+	<self.length = 0>
+!
+
+removeFrom: aNumber to: anotherNumber
+	<self.splice(aNumber -1, anotherNumber - aNumber + 1)>
+!
+
+removeIndex: anInteger
+	<self.splice(anInteger - 1, 1)>
+!
+
+removeLast
+	<return self.pop();>
+! !
+
+!Array methodsFor: 'converting'!
+
+asJavascript
+	^ '[', ((self collect: [:each | each asJavascript ]) join: ', '), ']'
+!
+
+reversed
+	<return self._copy().reverse()>
+! !
+
+!Array methodsFor: 'enumerating'!
+
+collect: aBlock
+	"Optimized version"
+	
+	<return self.map(function(each) {return aBlock._value_(each)})>
+!
+
+join: aString
+	<return self.join(aString)>
+!
+
+select: aBlock
+	"Optimized version"
+	
+	<
+		var result = self.klass._new();
+		for(var i=0; i<self.length; i++) {
+			if(aBlock._value_(self[i])) {
+				result.push(self[i]);
+			}
+		}
+		return result;
+	>
+!
+
+sort
+	^ self sort: [ :a :b | a < b ]
+!
+
+sort: aBlock
+	<
+		return self.sort(function(a, b) {
+			if(aBlock._value_value_(a,b)) {return -1} else {return 1}
+		})
+	>
+!
+
+sorted
+	^ self copy sort
+!
+
+sorted: aBlock
+	^ self copy sort: aBlock
+! !
+
+!Array methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	
+	aStream nextPutAll: ' ('.
+	self 
+		do: [ :each | each printOn: aStream ]
+		separatedBy: [ aStream nextPutAll: ' ' ].
+	aStream nextPutAll: ')'
+! !
+
+!Array methodsFor: 'private'!
+
+numericallyIndexable
+	^ self
+! !
+
+!Array class methodsFor: 'instance creation'!
+
+new: anInteger
+	<return new Array(anInteger)>
+!
+
+with: anObject
+		^ (self new: 1)
+		at: 1 put: anObject;
+		yourself
+!
+
+with: anObject with: anObject2
+		^ (self new: 2)
+		at: 1 put: anObject;
+		at: 2 put: anObject2;
+		yourself
+!
+
+with: anObject with: anObject2 with: anObject3
+		^ (self new: 3)
+		at: 1 put: anObject;
+		at: 2 put: anObject2;
+		at: 3 put: anObject3;
+		yourself
+!
+
+withAll: aCollection
+	| instance index |
+	index := 1.
+	instance := self new: aCollection size.
+	aCollection do: [ :each |
+		instance at: index put: each.
+		index := index + 1 ].
+	^ instance
+! !
+
+SequenceableCollection subclass: #CharacterArray
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!CharacterArray commentStamp!
+I am the abstract superclass of string-like collections.!
+
+!CharacterArray methodsFor: 'accessing'!
+
+at: anIndex put: anObject
+	self errorReadOnly
+! !
+
+!CharacterArray methodsFor: 'adding/removing'!
+
+add: anObject
+	self errorReadOnly
+!
+
+remove: anObject
+	self errorReadOnly
+! !
+
+!CharacterArray methodsFor: 'converting'!
+
+asLowercase
+	^ self class fromString: self asString asLowercase
+!
+
+asNumber
+	^ self asString asNumber
+!
+
+asString
+	^ self subclassResponsibility
+!
+
+asSymbol
+	^ self asString
+!
+
+asUppercase
+	^ self class fromString: self asString asUppercase
+! !
+
+!CharacterArray methodsFor: 'copying'!
+
+, aString
+	^ self asString, aString asString
+! !
+
+!CharacterArray methodsFor: 'error handling'!
+
+errorReadOnly
+	self error: 'Object is read-only'
+! !
+
+!CharacterArray methodsFor: 'printing'!
+
+printOn: aStream
+	self asString printOn: aStream
+! !
+
+!CharacterArray methodsFor: 'streaming'!
+
+putOn: aStream
+	aStream nextPutString: self
+! !
+
+!CharacterArray class methodsFor: 'instance creation'!
+
+fromString: aString
+	self subclassResponsibility
+! !
+
+CharacterArray subclass: #String
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!String commentStamp!
+I am an indexed collection of Characters. Unlike most Smalltalk dialects, Amber doesn't provide the Character class. Instead, elements of a String are single character strings.
+
+String inherits many useful methods from its hierarchy, such as
+	`Collection >> #,`!
+
+!String methodsFor: 'accessing'!
+
+asciiValue
+	<return self.charCodeAt(0);>
+!
+
+at: anIndex ifAbsent: aBlock
+	<return String(self)[anIndex - 1] || aBlock._value()>
+!
+
+at: anIndex ifPresent: aBlock ifAbsent: anotherBlock
+	<
+		var result = String(self)[anIndex - 1];
+		return result ? aBlock._value_(result) : anotherBlock._value();
+	>
+!
+
+charCodeAt: anInteger
+	<return self.charCodeAt(anInteger - 1)>
+!
+
+identityHash
+	^ self, 's'
+!
+
+size
+	<return self.length>
+! !
+
+!String methodsFor: 'comparing'!
+
+< aString
+	<return String(self) < aString._asString()>
+!
+
+<= aString
+	<return String(self) <= aString._asString()>
+!
+
+= aString
+	<
+		return aString !!= null &&
+			typeof aString._isString === "function" &&
+			aString._isString() &&
+			String(self) === String(aString)
+	>
+!
+
+== aString
+	^ self = aString
+!
+
+> aString
+	<return String(self) >> aString._asString()>
+!
+
+>= aString
+	<return String(self) >>= aString._asString()>
+! !
+
+!String methodsFor: 'converting'!
+
+asJSON
+	^ self
+!
+
+asJavaScriptMethodName
+	<return $core.st2js(self)>
+!
+
+asJavascript
+	<
+		if(self.search(/^[a-zA-Z0-9_:.$ ]*$/) == -1)
+			return "\"" + self.replace(/[\x00-\x1f"\\\x7f-\x9f]/g, function(ch){var c=ch.charCodeAt(0);return "\\x"+("0"+c.toString(16)).slice(-2)}) + "\"";
+		else
+			return "\"" + self + "\"";
+	>
+!
+
+asLowercase
+	<return self.toLowerCase()>
+!
+
+asMutator
+	"Answer a setter selector. For example,
+	#name asMutator returns #name:"
+
+	self last = ':' ifFalse: [  ^ self, ':' ].
+	^ self
+!
+
+asNumber
+	<return Number(self)>
+!
+
+asRegexp
+	^ RegularExpression fromString: self
+!
+
+asSelector
+	self deprecatedAPI: 'Use #asJavaScriptMethodName'.
+	^ self asJavaScriptMethodName
+!
+
+asString
+	^ self
+!
+
+asSymbol
+	^ self
+!
+
+asUppercase
+	<return self.toUpperCase()>
+!
+
+capitalized
+	^ self isEmpty
+		ifTrue: [ self ]
+		ifFalse: [ self first asUppercase, self allButFirst ]
+!
+
+crlfSanitized
+	^ self lines join: String lf
+!
+
+escaped
+	<return escape(self)>
+!
+
+reversed
+	<return self.split("").reverse().join("")>
+!
+
+unescaped
+	<return unescape(self)>
+!
+
+uriComponentDecoded
+	<return decodeURIComponent(self)>
+!
+
+uriComponentEncoded
+	<return encodeURIComponent(self)>
+!
+
+uriDecoded
+	<return decodeURI(self)>
+!
+
+uriEncoded
+	<return encodeURI(self)>
+! !
+
+!String methodsFor: 'copying'!
+
+, aString
+	<return String(self) + aString>
+!
+
+copyFrom: anIndex to: anotherIndex
+	<return self.substring(anIndex - 1, anotherIndex)>
+!
+
+deepCopy
+	^ self shallowCopy
+!
+
+shallowCopy
+	^ self class fromString: self
+! !
+
+!String methodsFor: 'evaluating'!
+
+value: anObject 
+	^ anObject perform: self
+! !
+
+!String methodsFor: 'printing'!
+
+printNl
+	<console.log(self)>
+!
+
+printOn: aStream
+	aStream 
+		nextPutAll: '''';
+		nextPutAll: self;
+		nextPutAll: ''''
+! !
+
+!String methodsFor: 'private'!
+
+numericallyIndexable
+	<return String(self)>
+! !
+
+!String methodsFor: 'regular expressions'!
+
+match: aRegexp
+	<return self.search(aRegexp) !!= -1>
+!
+
+matchesOf: aRegularExpression
+	<return self.match(aRegularExpression)>
+!
+
+replace: aString with: anotherString
+	^ self replaceRegexp: (RegularExpression fromString: aString flag: 'g') with: anotherString
+!
+
+replaceRegexp: aRegexp with: aString
+	<return self.replace(aRegexp, aString)>
+!
+
+trimBoth
+	^ self trimBoth: '\s'
+!
+
+trimBoth: separators
+	^ (self trimLeft: separators) trimRight: separators
+!
+
+trimLeft
+	^ self trimLeft: '\s'
+!
+
+trimLeft: separators
+	^ self replaceRegexp: (RegularExpression fromString: '^[', separators, ']+' flag: 'g') with: ''
+!
+
+trimRight
+	^ self trimRight: '\s'
+!
+
+trimRight: separators
+	^ self replaceRegexp: (RegularExpression fromString: '[', separators, ']+$' flag: 'g') with: ''
+! !
+
+!String methodsFor: 'split join'!
+
+join: aCollection
+	^ String
+		streamContents: [ :stream | aCollection
+				do: [ :each | stream nextPutAll: each asString ]
+				separatedBy: [ stream nextPutAll: self ]]
+!
+
+lineIndicesDo: aBlock
+	"execute aBlock with 3 arguments for each line:
+	- start index of line
+	- end index of line without line delimiter
+	- end index of line including line delimiter(s) CR, LF or CRLF"
+	
+	| cr lf start sz nextLF nextCR |
+	start := 1.
+	sz := self size.
+	cr := String cr.
+	nextCR := self indexOf: cr startingAt: 1.
+	lf := String lf.
+	nextLF := self indexOf: lf startingAt: 1.
+	[ start <= sz ] whileTrue: [ 
+		(nextLF = 0 and: [ nextCR = 0 ])
+			ifTrue: [ "No more CR, nor LF, the string is over"
+					aBlock value: start value: sz value: sz.
+					^ self ].
+		(nextCR = 0 or: [ 0 < nextLF and: [ nextLF < nextCR ] ])
+			ifTrue: [ "Found a LF"
+					aBlock value: start value: nextLF - 1 value: nextLF.
+					start := 1 + nextLF.
+					nextLF := self indexOf: lf startingAt: start ]
+			ifFalse: [ 1 + nextCR = nextLF
+				ifTrue: [ "Found a CR-LF pair"
+					aBlock value: start value: nextCR - 1 value: nextLF.
+					start := 1 + nextLF.
+					nextCR := self indexOf: cr startingAt: start.
+					nextLF := self indexOf: lf startingAt: start ]
+				ifFalse: [ "Found a CR"
+					aBlock value: start value: nextCR - 1 value: nextCR.
+					start := 1 + nextCR.
+					nextCR := self indexOf: cr startingAt: start ] ]]
+!
+
+lineNumber: anIndex
+	"Answer a string containing the characters in the given line number."
+
+	| lineCount |
+	lineCount := 0.
+	self lineIndicesDo: [ :start :endWithoutDelimiters :end |
+		(lineCount := lineCount + 1) = anIndex ifTrue: [ ^ self copyFrom: start to: endWithoutDelimiters ]].
+	^ nil
+!
+
+lines
+	"Answer an array of lines composing this receiver without the line ending delimiters."
+
+	| lines |
+	lines := Array new.
+	self linesDo: [ :aLine | lines add: aLine ].
+	^ lines
+!
+
+linesDo: aBlock
+	"Execute aBlock with each line in this string. The terminating line
+	delimiters CR, LF or CRLF pairs are not included in what is passed to aBlock"
+
+	self lineIndicesDo: [ :start :endWithoutDelimiters :end |
+		aBlock value: (self copyFrom: start to: endWithoutDelimiters) ]
+!
+
+subStrings: aString
+	^ self tokenize: aString
+!
+
+tokenize: aString
+	<return self.split(aString)>
+! !
+
+!String methodsFor: 'testing'!
+
+includesSubString: subString
+	<return self.indexOf(subString) !!= -1>
+!
+
+isCapitalized
+	^ self first asUppercase == self first
+!
+
+isImmutable
+	^ true
+!
+
+isString
+	^ true
+!
+
+isVowel
+	"Answer true if the receiver is a one character string containing a voyel"
+	
+	^ self size = 1 and: [ 'aeiou' includes: self asLowercase ]
+! !
+
+!String class methodsFor: 'accessing'!
+
+cr
+	<return '\r'>
+!
+
+crlf
+	<return '\r\n'>
+!
+
+esc
+	^ self fromCharCode: 27
+!
+
+lf
+	<return '\n'>
+!
+
+space
+	<return ' '>
+!
+
+streamClass
+		^ StringStream
+!
+
+tab
+	<return '\t'>
+! !
+
+!String class methodsFor: 'instance creation'!
+
+fromCharCode: anInteger
+	<return String.fromCharCode(anInteger)>
+!
+
+fromString: aString
+		<return String(aString)>
+!
+
+value: aUTFCharCode
+
+	<return String.fromCharCode(aUTFCharCode);>
+! !
+
+!String class methodsFor: 'random'!
+
+random
+	"Returns random alphanumeric string beginning with letter"
+	<return (Math.random()*(22/32)+(10/32)).toString(32).slice(2);>
+!
+
+randomNotIn: aString
+	| result |
+	[ result := self random. aString includesSubString: result ] whileTrue.
+	^ result
+! !
+
+Collection subclass: #Set
+	instanceVariableNames: 'defaultBucket slowBucketStores fastBuckets size'
+	package: 'Kernel-Collections'!
+!Set commentStamp!
+I represent an unordered set of objects without duplicates.
+
+## Implementation notes
+
+I put elements into different stores based on their type.
+The goal is to store some elements into native JS object property names to be fast.
+
+If an unboxed element has typeof 'string', 'boolean' or 'number', or an element is nil, null or undefined,
+I store it as a property name in an empty (== Object.create(null)) JS object, different for each type
+(for simplicity, nil/null/undefined is treated as one and included with the two booleans).
+
+If element happen to be an object, I try to store them in `ArrayBucketStore`. I have two of them by default,
+one hashed using the Smalltalk class name, the other one using the JS constructor name. It is possible to have more or less
+instances of `ArrayBucketStores`, see `#initializeSlowBucketStores`.
+
+As a last resort, if none of the `ArrayBucketStore` instances can find a suitable bucket, the `defaultBucket` is used,
+which is an `Array`.!
+
+!Set methodsFor: 'accessing'!
+
+size
+	^ size
+! !
+
+!Set methodsFor: 'adding/removing'!
+
+add: anObject
+	| bucket |
+	bucket := self bucketsOfElement: anObject.
+	^ bucket second
+		ifNil: [
+			| object slowBucket |
+			object := bucket first.
+			slowBucket := bucket third.
+			slowBucket 
+				indexOf: object 
+				ifAbsent: [ 
+					slowBucket add: object. 
+					size := size + 1 ].
+			object ]
+		ifNotNil: [ :primitiveBucket | 
+			self 
+				add: bucket first 
+				in: primitiveBucket ]
+!
+
+remove: anObject ifAbsent: aBlock
+	| bucket |
+	bucket := self bucketsOfElement: anObject.
+	^ bucket second
+		ifNil: [ bucket third remove: bucket first ifAbsent: [ ^aBlock value ]. size := size - 1 ]
+		ifNotNil: [ :primitiveBucket | self remove: bucket first in: primitiveBucket ]
+!
+
+removeAll
+	<
+		self['@fastBuckets'] = {
+			'boolean': { store: Object.create(null), fn: function (x) { return {'true': true, 'false': false, 'null': null}[x]; } },
+			'number': { store: Object.create(null), fn: Number },
+			'string': { store: Object.create(null) }
+		};
+		self['@slowBucketStores'].forEach(function (x) { x._removeAll(); });
+		self['@defaultBucket']._removeAll();
+		self['@size'] = 0;
+	>
+! !
+
+!Set methodsFor: 'comparing'!
+
+= aCollection
+	self class = aCollection class ifFalse: [ ^ false ].
+	self size = aCollection size ifFalse: [ ^ false ].
+	self do: [ :each | (aCollection includes: each) ifFalse: [ ^ false ] ].
+	^ true
+! !
+
+!Set methodsFor: 'enumerating'!
+
+collect: aBlock
+	| collection |
+	collection := self class new.
+	self do: [ :each | collection add: (aBlock value: each) ].
+	^ collection
+!
+
+detect: aBlock ifNone: anotherBlock
+	self do: [ :each | (aBlock value: each) ifTrue: [ ^each ] ].
+	^ anotherBlock value
+!
+
+do: aBlock
+	<
+		var el, keys, i;
+		el = self['@fastBuckets'];
+		keys = Object.keys(el);
+		for (i = 0; i < keys.length; ++i) {
+			var fastBucket = el[keys[i]], fn = fastBucket.fn, store = Object.keys(fastBucket.store);
+			if (fn) { for (var j = 0; j < store.length; ++j) { aBlock._value_(fn(store[j])); } }
+			else { store._do_(aBlock); }
+		}
+		el = self['@slowBucketStores'];
+		for (i = 0; i < el.length; ++i) { el[i]._do_(aBlock); }
+		self['@defaultBucket']._do_(aBlock);
+	>
+!
+
+select: aBlock
+	| collection |
+	collection := self class new.
+	self do: [ :each |
+		(aBlock value: each) ifTrue: [
+			collection add: each ] ].
+	^ collection
+! !
+
+!Set methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	
+	defaultBucket := #().
+	self
+		initializeSlowBucketStores;
+		removeAll
+!
+
+initializeSlowBucketStores
+	slowBucketStores := {
+		ArrayBucketStore hashBlock: [ :x | self classNameOf: x ].
+		ArrayBucketStore hashBlock: [ :x | self jsConstructorNameOf: x ]
+	}
+! !
+
+!Set methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	
+	aStream nextPutAll: ' ('.
+	self 
+		do: [ :each | each printOn: aStream ]
+		separatedBy: [ aStream nextPutAll: ' ' ].
+	aStream nextPutAll: ')'
+! !
+
+!Set methodsFor: 'private'!
+
+add: anObject in: anotherObject
+	<
+		if (anObject in anotherObject.store) { return false; }
+		self['@size']++;
+		return anotherObject.store[anObject] = true;
+	>
+!
+
+bucketsOfElement: anObject
+	"Find the appropriate bucket for `anObject`.
+	For optimization purposes, directly answer an array with: 
+	- the object to be store
+	- the primitive bucket
+	- the slow bucket"
+	
+	<
+		var type, bucket, prim = anObject == null ? (anObject = nil) : anObject.valueOf();
+		if ((type = typeof prim) === "object") {
+			if (anObject !!== nil) {
+				bucket = null;
+				self['@slowBucketStores'].some(function (store) {
+					return bucket = store._bucketOfElement_(anObject);
+				});
+				return [ anObject, null, bucket || self['@defaultBucket'] ];
+			}
+			
+			// include nil to well-known objects under 'boolean' fastBucket
+			prim = null;
+			type = 'boolean';
+		}
+		return [ prim, self['@fastBuckets'][type] ];
+	>
+!
+
+classNameOf: anObject
+	"Answer the class name of `anObject`, or `undefined` 
+	if `anObject` is not an Smalltalk object"
+	
+	<return anObject.klass && anObject.klass.className>
+!
+
+includes: anObject in: anotherObject
+	<return anObject in anotherObject.store>
+!
+
+jsConstructorNameOf: anObject
+	<return anObject.constructor && anObject.constructor.name>
+!
+
+remove: anObject in: anotherObject
+	<if (delete anotherObject.store[anObject]) self['@size']-->
+! !
+
+!Set methodsFor: 'testing'!
+
+includes: anObject
+	| bucket |
+	bucket := self bucketsOfElement: anObject.
+	^ bucket second
+		ifNil: [ bucket third includes: bucket first ]
+		ifNotNil: [ :primitiveBucket | self includes: bucket first in: primitiveBucket ]
+! !
+
+Object subclass: #Queue
+	instanceVariableNames: 'read readIndex write'
+	package: 'Kernel-Collections'!
+!Queue commentStamp!
+I am a one-sided queue.
+
+## Usage
+
+Use `#nextPut:` to add items to the queue.
+Use `#next` or `#nextIfAbsent:` to get (and remove) the next item in the queue.
+
+## Implementation notes
+
+A Queue uses two OrderedCollections inside,
+`read` is at the front, is not modified and only read using `readIndex`.
+`write` is at the back and is appended new items.
+When `read` is exhausted, `write` is promoted to `read` and new `write` is created.
+
+As a consequence, no data moving is done by me, write appending may do data moving
+when growing `write`, but this is left to engine to implement as good as it chooses to.!
+
+!Queue methodsFor: 'accessing'!
+
+next
+	^ self nextIfAbsent: [ self error: 'Cannot read from empty Queue.' ]
+!
+
+nextIfAbsent: aBlock
+	| result |
+	result := read at: readIndex ifAbsent: [
+		write isEmpty ifTrue: [
+			readIndex > 1 ifTrue: [ read := #(). readIndex := 1 ].
+			^ aBlock value ].
+		read := write.
+		readIndex := 1.
+		write := OrderedCollection new.
+		read first ].
+	read at: readIndex put: nil.
+	readIndex := readIndex + 1.
+	^ result
+!
+
+nextPut: anObject
+	write add: anObject
+! !
+
+!Queue methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	read := OrderedCollection new.
+	write := OrderedCollection new.
+	readIndex := 1
+! !
+
+Object subclass: #RegularExpression
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!RegularExpression commentStamp!
+I represent a regular expression object. My instances are JavaScript `RegExp` object.!
+
+!RegularExpression methodsFor: 'evaluating'!
+
+compile: aString
+	<return self.compile(aString)>
+!
+
+exec: aString
+	<return self.exec(aString) || nil>
+!
+
+test: aString
+	<return self.test(aString)>
+! !
+
+!RegularExpression class methodsFor: 'instance creation'!
+
+fromString: aString
+		^ self fromString: aString flag: ''
+!
+
+fromString: aString flag: anotherString
+	<return new RegExp(aString, anotherString)>
+! !
+
+Object subclass: #Stream
+	instanceVariableNames: 'collection position streamSize'
+	package: 'Kernel-Collections'!
+!Stream commentStamp!
+I represent an accessor for a sequence of objects. This sequence is referred to as my "contents".
+My instances are read/write streams to the contents sequence collection.!
+
+!Stream methodsFor: 'accessing'!
+
+collection
+	^ collection
+!
+
+contents
+	^ self collection
+		copyFrom: 1
+		to: self streamSize
+!
+
+position
+	^ position ifNil: [ position := 0 ]
+!
+
+position: anInteger
+	position := anInteger
+!
+
+setCollection: aCollection
+	collection := aCollection
+!
+
+setStreamSize: anInteger
+	streamSize := anInteger
+!
+
+size
+	^ self streamSize
+!
+
+streamSize
+	^ streamSize
+! !
+
+!Stream methodsFor: 'actions'!
+
+close
+!
+
+flush
+!
+
+reset
+	self position: 0
+!
+
+resetContents
+	self reset.
+	self setStreamSize: 0
+! !
+
+!Stream methodsFor: 'enumerating'!
+
+do: aBlock
+	[ self atEnd ] whileFalse: [ aBlock value: self next ]
+! !
+
+!Stream methodsFor: 'positioning'!
+
+setToEnd
+	self position: self size
+!
+
+skip: anInteger
+	self position: ((self position + anInteger) min: self size max: 0)
+! !
+
+!Stream methodsFor: 'reading'!
+
+next
+	^ self atEnd
+		ifTrue: [ nil ]
+		ifFalse: [
+			self position: self position + 1.
+			collection at: self position ]
+!
+
+next: anInteger
+	| tempCollection |
+	tempCollection := self collection class new.
+	anInteger timesRepeat: [
+		self atEnd ifFalse: [
+		tempCollection add: self next ]].
+	^ tempCollection
+!
+
+peek
+	^ self atEnd ifFalse: [
+		self collection at: self position + 1 ]
+! !
+
+!Stream methodsFor: 'testing'!
+
+atEnd
+	^ self position = self size
+!
+
+atStart
+	^ self position = 0
+!
+
+isEmpty
+	^ self size = 0
+! !
+
+!Stream methodsFor: 'writing'!
+
+<< anObject
+	self write: anObject
+!
+
+nextPut: anObject
+	self position: self position + 1.
+	self collection at: self position put: anObject.
+	self setStreamSize: (self streamSize max: self position)
+!
+
+nextPutAll: aCollection
+	aCollection do: [ :each |
+		self nextPut: each ]
+!
+
+nextPutString: aString
+	self nextPut: aString
+!
+
+write: anObject
+	anObject putOn: self
+! !
+
+!Stream class methodsFor: 'instance creation'!
+
+on: aCollection
+		^ self new
+		setCollection: aCollection;
+		setStreamSize: aCollection size;
+		yourself
+! !
+
+Stream subclass: #StringStream
+	instanceVariableNames: ''
+	package: 'Kernel-Collections'!
+!StringStream commentStamp!
+I am a Stream specific to `String` objects.!
+
+!StringStream methodsFor: 'reading'!
+
+next: anInteger
+	| tempCollection |
+	tempCollection := self collection class new.
+	anInteger timesRepeat: [
+		self atEnd ifFalse: [
+		tempCollection := tempCollection, self next ]].
+	^ tempCollection
+! !
+
+!StringStream methodsFor: 'writing'!
+
+cr
+	^ self nextPutAll: String cr
+!
+
+crlf
+	^ self nextPutAll: String crlf
+!
+
+lf
+	^ self nextPutAll: String lf
+!
+
+nextPut: aString
+	self nextPutAll: aString
+!
+
+nextPutAll: aString
+	| pre post |
+	self atEnd ifTrue: [ self setCollection: self collection, aString ] ifFalse: [
+		pre := self collection copyFrom: 1 to: self position.
+		post := self collection copyFrom: (self position + 1 + aString size) to: self collection size.
+		self setCollection: pre, aString, post
+	].
+	self position: self position + aString size.
+	self setStreamSize: (self streamSize max: self position)
+!
+
+nextPutString: aString
+	self nextPutAll: aString
+!
+
+space
+	self nextPut: ' '
+!
+
+tab
+	^ self nextPutAll: String tab
+! !
+

+ 841 - 0
bower_components/amber/src/Kernel-Exceptions.js

@@ -0,0 +1,841 @@
+define("amber_core/Kernel-Exceptions", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Exceptions');
+$core.packages["Kernel-Exceptions"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('Error', $globals.Object, ['messageText'], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Error.comment="From the ANSI standard:\x0a\x0aThis protocol describes the behavior of instances of class `Error`.\x0aThese are used to represent error conditions that prevent the normal continuation of processing.\x0aActual error exceptions used by an application may be subclasses of this class.\x0aAs `Error` is explicitly specified to be subclassable, conforming implementations must implement its behavior in a non-fragile manner.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "beHandled",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.amberHandled = true;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beHandled",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "beHandled\x0a\x09<self.amberHandled = true>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "beUnhandled",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.amberHandled = false;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beUnhandled",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "beUnhandled\x0a\x09<self.amberHandled = false>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "context",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.context;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"context",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "context\x0a\x09<return self.context>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._messageText_("Errorclass: ".__comma($recv(self._class())._name()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09self messageText: 'Errorclass: ', (self class name).",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["messageText:", ",", "name", "class"]
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "isSmalltalkError",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.smalltalkError === true;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isSmalltalkError",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSmalltalkError\x0a\x09<return self.smalltalkError === true>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "jsStack",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.stack;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jsStack",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "jsStack\x0a\x09<return self.stack>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@messageText"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ messageText",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "messageText:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@messageText"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "messageText: aString\x0a\x09messageText := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "resignal",
+protocol: 'signaling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self.amberHandled = false;
+		throw(self);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"resignal",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "resignal\x0a\x09\x22Resignal the receiver without changing its exception context\x22\x0a\x09\x0a\x09<\x0a\x09\x09self.amberHandled = false;\x0a\x09\x09throw(self);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "signal",
+protocol: 'signaling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		self.amberHandled = false;
+		self.context = $core.getThisContext(); 
+		self.smalltalkError = true;
+		throw self;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signal",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "signal\x0a\x09<\x0a\x09\x09self.amberHandled = false;\x0a\x09\x09self.context = $core.getThisContext(); \x0a\x09\x09self.smalltalkError = true;\x0a\x09\x09throw self;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "signal:",
+protocol: 'signaling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._messageText_(aString);
+self._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signal:",{aString:aString},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "signal: aString\x0a\x09self messageText: aString.\x0a\x09self signal",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["messageText:", "signal"]
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "signalerContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._signalerContextFrom_(self._context());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signalerContext",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "signalerContext\x0a\x09^ self signalerContextFrom: self context",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["signalerContextFrom:", "context"]
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "signalerContextFrom:",
+protocol: 'accessing',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$1=$recv(aContext)._findContextSuchThat_((function(context){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(context)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__eq_eq(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["=="]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv(context)._receiver()).__eq_eq(self._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+return $recv($2)._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({context:context},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signalerContextFrom:",{aContext:aContext},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "signalerContextFrom: aContext\x0a\x09\x22Find the first sender of signal(:), the first context which is neither \x0a\x09for an instance method nor for a class side method of Exception (or subclass).\x0a\x09This will make sure that the same context is found for both, `Error signal` \x0a\x09and `Error new signal`\x22\x0a\x0a\x09^ aContext findContextSuchThat: [ :context |\x0a\x09\x09(context receiver == self \x0a\x09\x09or: [ context receiver == self class ]) not ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["findContextSuchThat:", "not", "or:", "==", "receiver", "class"]
+}),
+$globals.Error);
+
+$core.addMethod(
+$core.method({
+selector: "wasHandled",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.amberHandled || false;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"wasHandled",{},$globals.Error)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "wasHandled\x0a\x09<return self.amberHandled || false>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error);
+
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "exception";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'exception'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Error.klass);
+
+$core.addMethod(
+$core.method({
+selector: "signal",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._new())._signal();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signal",{},$globals.Error.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "signal\x0a\x09^ self new signal",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["signal", "new"]
+}),
+$globals.Error.klass);
+
+$core.addMethod(
+$core.method({
+selector: "signal:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._new())._signal_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signal:",{aString:aString},$globals.Error.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "signal: aString\x0a\x09^ self new\x0a\x09\x09signal: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["signal:", "new"]
+}),
+$globals.Error.klass);
+
+
+$core.addClass('Halt', $globals.Error, [], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Halt.comment="I am provided to support `Object>>#halt`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "Halt encountered";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ 'Halt encountered'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Halt);
+
+$core.addMethod(
+$core.method({
+selector: "signalerContextFrom:",
+protocol: 'accessing',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$1=$recv(aContext)._findContextSuchThat_((function(context){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(context)._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__eq_eq(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["=="]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv($recv($recv(context)._receiver()).__eq_eq(self._class()))._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv($recv($recv(context)._method())._selector()).__eq("halt");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({},$ctx3,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["or:"]=1;
+//>>excludeEnd("ctx");
+return $recv($2)._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({context:context},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signalerContextFrom:",{aContext:aContext},$globals.Halt)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "signalerContextFrom: aContext\x0a\x09\x22specialized version to find the proper context to open the debugger on.\x0a\x09This will find the first context whose method is no longer on `Halt` or \x0a\x09`Halt class` nor is `#halt` method itself.\x22\x0a\x09\x0a\x09^ aContext findContextSuchThat: [ :context |\x0a\x09\x09(context receiver == self \x0a\x09\x09or: [ (context receiver == self class) \x0a\x09\x09or: [ context method selector = #halt ]]) not ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["findContextSuchThat:", "not", "or:", "==", "receiver", "class", "=", "selector", "method"]
+}),
+$globals.Halt);
+
+
+
+$core.addClass('JavaScriptException', $globals.Error, ['exception'], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.JavaScriptException.comment="A JavaScriptException is thrown when a non-Smalltalk exception occurs while in the Smalltalk stack.\x0aSee `boot.js` `inContext()` and `BlockClosure >> on:do:`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (aMethodContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.context = aMethodContext;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"context:",{aMethodContext:aMethodContext},$globals.JavaScriptException)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethodContext"],
+source: "context: aMethodContext\x0a\x09\x22Set the context from the outside.\x0a\x09See boot.js `inContext()` exception handling\x22\x0a\x09\x0a\x09<self.context = aMethodContext>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JavaScriptException);
+
+$core.addMethod(
+$core.method({
+selector: "exception",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@exception"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "exception\x0a\x09^ exception",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JavaScriptException);
+
+$core.addMethod(
+$core.method({
+selector: "exception:",
+protocol: 'accessing',
+fn: function (anException){
+var self=this;
+self["@exception"]=anException;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anException"],
+source: "exception: anException\x0a\x09exception := anException",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JavaScriptException);
+
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return 'JavaScript exception: ' + self["@exception"].toString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageText",{},$globals.JavaScriptException)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09<return 'JavaScript exception: ' + self[\x22@exception\x22].toString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JavaScriptException);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (anException){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._exception_(anException);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{anException:anException},$globals.JavaScriptException.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anException"],
+source: "on: anException\x0a\x09^ self new\x0a\x09\x09exception: anException;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["exception:", "new", "yourself"]
+}),
+$globals.JavaScriptException.klass);
+
+$core.addMethod(
+$core.method({
+selector: "on:context:",
+protocol: 'instance creation',
+fn: function (anException,aMethodContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._exception_(anException);
+$recv($2)._context_(aMethodContext);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:context:",{anException:anException,aMethodContext:aMethodContext},$globals.JavaScriptException.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anException", "aMethodContext"],
+source: "on: anException context: aMethodContext\x0a\x09^ self new\x0a\x09\x09exception: anException;\x0a\x09\x09context: aMethodContext;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["exception:", "new", "context:", "yourself"]
+}),
+$globals.JavaScriptException.klass);
+
+
+$core.addClass('MessageNotUnderstood', $globals.Error, ['message', 'receiver'], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MessageNotUnderstood.comment="This exception is provided to support `Object>>doesNotUnderstand:`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "message",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@message"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "message\x0a\x09^ message",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageNotUnderstood);
+
+$core.addMethod(
+$core.method({
+selector: "message:",
+protocol: 'accessing',
+fn: function (aMessage){
+var self=this;
+self["@message"]=aMessage;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMessage"],
+source: "message: aMessage\x0a\x09message := aMessage",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageNotUnderstood);
+
+$core.addMethod(
+$core.method({
+selector: "messageText",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv(self._receiver())._asString()).__comma(" does not understand #")).__comma($recv(self._message())._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageText",{},$globals.MessageNotUnderstood)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageText\x0a\x09^ self receiver asString, ' does not understand #', self message selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "asString", "receiver", "selector", "message"]
+}),
+$globals.MessageNotUnderstood);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@receiver"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageNotUnderstood);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@receiver"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "receiver: anObject\x0a\x09receiver := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageNotUnderstood);
+
+
+
+$core.addClass('NonBooleanReceiver', $globals.Error, ['object'], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.NonBooleanReceiver.comment="NonBooleanReceiver exceptions may be thrown when executing inlined methods such as `#ifTrue:` with a non boolean receiver.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "object",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@object"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "object\x0a\x09^ object",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NonBooleanReceiver);
+
+$core.addMethod(
+$core.method({
+selector: "object:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@object"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "object: anObject\x0a\x09object := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NonBooleanReceiver);
+
+
+
+$core.addClass('PackageCommitError', $globals.Error, [], 'Kernel-Exceptions');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageCommitError.comment="I get signaled when an attempt to commit a package has failed.";
+//>>excludeEnd("ide");
+
+});

+ 227 - 0
bower_components/amber/src/Kernel-Exceptions.st

@@ -0,0 +1,227 @@
+Smalltalk createPackage: 'Kernel-Exceptions'!
+Object subclass: #Error
+	instanceVariableNames: 'messageText'
+	package: 'Kernel-Exceptions'!
+!Error commentStamp!
+From the ANSI standard:
+
+This protocol describes the behavior of instances of class `Error`.
+These are used to represent error conditions that prevent the normal continuation of processing.
+Actual error exceptions used by an application may be subclasses of this class.
+As `Error` is explicitly specified to be subclassable, conforming implementations must implement its behavior in a non-fragile manner.!
+
+!Error methodsFor: 'accessing'!
+
+beHandled
+	<self.amberHandled = true>
+!
+
+beUnhandled
+	<self.amberHandled = false>
+!
+
+context
+	<return self.context>
+!
+
+jsStack
+	<return self.stack>
+!
+
+messageText
+	^ messageText
+!
+
+messageText: aString
+	messageText := aString
+!
+
+signalerContext
+	^ self signalerContextFrom: self context
+!
+
+signalerContextFrom: aContext
+	"Find the first sender of signal(:), the first context which is neither 
+	for an instance method nor for a class side method of Exception (or subclass).
+	This will make sure that the same context is found for both, `Error signal` 
+	and `Error new signal`"
+
+	^ aContext findContextSuchThat: [ :context |
+		(context receiver == self 
+		or: [ context receiver == self class ]) not ]
+! !
+
+!Error methodsFor: 'initialization'!
+
+initialize
+	self messageText: 'Errorclass: ', (self class name).
+! !
+
+!Error methodsFor: 'signaling'!
+
+resignal
+	"Resignal the receiver without changing its exception context"
+	
+	<
+		self.amberHandled = false;
+		throw(self);
+	>
+!
+
+signal
+	<
+		self.amberHandled = false;
+		self.context = $core.getThisContext(); 
+		self.smalltalkError = true;
+		throw self;
+	>
+!
+
+signal: aString
+	self messageText: aString.
+	self signal
+! !
+
+!Error methodsFor: 'testing'!
+
+isSmalltalkError
+	<return self.smalltalkError === true>
+!
+
+wasHandled
+	<return self.amberHandled || false>
+! !
+
+!Error class methodsFor: 'helios'!
+
+heliosClass
+	^ 'exception'
+! !
+
+!Error class methodsFor: 'instance creation'!
+
+signal
+	^ self new signal
+!
+
+signal: aString
+	^ self new
+		signal: aString
+! !
+
+Error subclass: #Halt
+	instanceVariableNames: ''
+	package: 'Kernel-Exceptions'!
+!Halt commentStamp!
+I am provided to support `Object>>#halt`.!
+
+!Halt methodsFor: 'accessing'!
+
+messageText
+	^ 'Halt encountered'
+!
+
+signalerContextFrom: aContext
+	"specialized version to find the proper context to open the debugger on.
+	This will find the first context whose method is no longer on `Halt` or 
+	`Halt class` nor is `#halt` method itself."
+	
+	^ aContext findContextSuchThat: [ :context |
+		(context receiver == self 
+		or: [ (context receiver == self class) 
+		or: [ context method selector = #halt ]]) not ]
+! !
+
+Error subclass: #JavaScriptException
+	instanceVariableNames: 'exception'
+	package: 'Kernel-Exceptions'!
+!JavaScriptException commentStamp!
+A JavaScriptException is thrown when a non-Smalltalk exception occurs while in the Smalltalk stack.
+See `boot.js` `inContext()` and `BlockClosure >> on:do:`!
+
+!JavaScriptException methodsFor: 'accessing'!
+
+context: aMethodContext
+	"Set the context from the outside.
+	See boot.js `inContext()` exception handling"
+	
+	<self.context = aMethodContext>
+!
+
+exception
+	^ exception
+!
+
+exception: anException
+	exception := anException
+!
+
+messageText
+	<return 'JavaScript exception: ' + self["@exception"].toString()>
+! !
+
+!JavaScriptException class methodsFor: 'instance creation'!
+
+on: anException
+	^ self new
+		exception: anException;
+		yourself
+!
+
+on: anException context: aMethodContext
+	^ self new
+		exception: anException;
+		context: aMethodContext;
+		yourself
+! !
+
+Error subclass: #MessageNotUnderstood
+	instanceVariableNames: 'message receiver'
+	package: 'Kernel-Exceptions'!
+!MessageNotUnderstood commentStamp!
+This exception is provided to support `Object>>doesNotUnderstand:`.!
+
+!MessageNotUnderstood methodsFor: 'accessing'!
+
+message
+	^ message
+!
+
+message: aMessage
+	message := aMessage
+!
+
+messageText
+	^ self receiver asString, ' does not understand #', self message selector
+!
+
+receiver
+	^ receiver
+!
+
+receiver: anObject
+	receiver := anObject
+! !
+
+Error subclass: #NonBooleanReceiver
+	instanceVariableNames: 'object'
+	package: 'Kernel-Exceptions'!
+!NonBooleanReceiver commentStamp!
+NonBooleanReceiver exceptions may be thrown when executing inlined methods such as `#ifTrue:` with a non boolean receiver.!
+
+!NonBooleanReceiver methodsFor: 'accessing'!
+
+object
+	^ object
+!
+
+object: anObject
+	object := anObject
+! !
+
+Error subclass: #PackageCommitError
+	instanceVariableNames: ''
+	package: 'Kernel-Exceptions'!
+!PackageCommitError commentStamp!
+I get signaled when an attempt to commit a package has failed.!
+

+ 3886 - 0
bower_components/amber/src/Kernel-ImportExport.js

@@ -0,0 +1,3886 @@
+define("amber_core/Kernel-ImportExport", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-ImportExport');
+$core.packages["Kernel-ImportExport"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('AbstractExporter', $globals.Object, [], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AbstractExporter.comment="I am an abstract exporter for Amber source code.\x0a\x0a## API\x0a\x0aUse `#exportPackage:on:` to export a given package on a Stream.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "chunkEscape:",
+protocol: 'convenience',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aString)._replace_with_("!","!!"))._trimBoth();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"chunkEscape:",{aString:aString},$globals.AbstractExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "chunkEscape: aString\x0a\x09\x22Replace all occurrences of ! with !! and trim at both ends.\x22\x0a\x0a\x09^ (aString replace: '!' with: '!!') trimBoth",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["trimBoth", "replace:with:"]
+}),
+$globals.AbstractExporter);
+
+$core.addMethod(
+$core.method({
+selector: "classNameFor:",
+protocol: 'convenience',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$1;
+$2=$recv(aClass)._isMetaclass();
+if($core.assert($2)){
+$3=$recv($recv(aClass)._instanceClass())._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($3).__comma(" class");
+} else {
+$4=$recv(aClass)._isNil();
+if($core.assert($4)){
+$1="nil";
+} else {
+$1=$recv(aClass)._name();
+};
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classNameFor:",{aClass:aClass},$globals.AbstractExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "classNameFor: aClass\x0a\x09^ aClass isMetaclass\x0a\x09\x09ifTrue: [ aClass instanceClass name, ' class' ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09aClass isNil\x0a\x09\x09\x09\x09ifTrue: [ 'nil' ]\x0a\x09\x09\x09\x09ifFalse: [ aClass name ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isMetaclass", ",", "name", "instanceClass", "isNil"]
+}),
+$globals.AbstractExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackage:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackage:on:",{aPackage:aPackage,aStream:aStream},$globals.AbstractExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackage: aPackage on: aStream\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.AbstractExporter);
+
+$core.addMethod(
+$core.method({
+selector: "extensionMethodsOfPackage:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+var result;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+result=$recv($OrderedCollection())._new();
+$recv(self._extensionProtocolsOfPackage_(aPackage))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(result)._addAll_($recv(each)._methods());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=result;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"extensionMethodsOfPackage:",{aPackage:aPackage,result:result},$globals.AbstractExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "extensionMethodsOfPackage: aPackage\x0a\x09| result |\x0a\x09\x0a\x09result := OrderedCollection new.\x0a\x09\x0a\x09(self extensionProtocolsOfPackage: aPackage) do: [ :each |\x0a\x09\x09result addAll: each methods ].\x0a\x09\x09\x0a\x09^ result",
+referencedClasses: ["OrderedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "extensionProtocolsOfPackage:", "addAll:", "methods"]
+}),
+$globals.AbstractExporter);
+
+$core.addMethod(
+$core.method({
+selector: "extensionProtocolsOfPackage:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+var extensionName,result;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $ExportMethodProtocol(){return $globals.ExportMethodProtocol||(typeof ExportMethodProtocol=="undefined"?nil:ExportMethodProtocol)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$1=$recv(aPackage)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+extensionName="*".__comma($1);
+result=$recv($OrderedCollection())._new();
+$recv($recv($recv($recv($Smalltalk())._classes())._asArray())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(a)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name"]=2;
+//>>excludeEnd("ctx");
+return $recv($2).__lt($recv(b)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv([each,$recv(each)._class()])._do_((function(behavior){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$3=$recv($recv(behavior)._protocols())._includes_(extensionName);
+if($core.assert($3)){
+return $recv(result)._add_($recv($ExportMethodProtocol())._name_theClass_(extensionName,behavior));
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({behavior:behavior},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$4=result;
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"extensionProtocolsOfPackage:",{aPackage:aPackage,extensionName:extensionName,result:result},$globals.AbstractExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "extensionProtocolsOfPackage: aPackage\x0a\x09| extensionName result |\x0a\x09\x0a\x09extensionName := '*', aPackage name.\x0a\x09result := OrderedCollection new.\x0a\x09\x0a\x09\x22The classes must be loaded since it is extensions only.\x0a\x09Therefore topological sorting (dependency resolution) does not matter here.\x0a\x09Not sorting topologically improves the speed by a number of magnitude.\x0a\x09\x0a\x09Not to shuffle diffs, classes are sorted by their name.\x22\x0a\x09\x0a\x09(Smalltalk classes asArray sorted: [ :a :b | a name < b name ]) do: [ :each |\x0a\x09\x09{each. each class} do: [ :behavior |\x0a\x09\x09\x09(behavior protocols includes: extensionName) ifTrue: [\x0a\x09\x09\x09\x09result add: (ExportMethodProtocol name: extensionName theClass: behavior) ] ] ].\x0a\x0a\x09^ result",
+referencedClasses: ["OrderedCollection", "Smalltalk", "ExportMethodProtocol"],
+//>>excludeEnd("ide");
+messageSends: [",", "name", "new", "do:", "sorted:", "asArray", "classes", "<", "class", "ifTrue:", "includes:", "protocols", "add:", "name:theClass:"]
+}),
+$globals.AbstractExporter);
+
+
+
+$core.addClass('ChunkExporter', $globals.AbstractExporter, [], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ChunkExporter.comment="I am an exporter dedicated to outputting Amber source code in the classic Smalltalk chunk format.\x0a\x0aI do not output any compiled code.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "exportCategoryEpilogueOf:on:",
+protocol: 'output',
+fn: function (aCategory,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_(" !");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportCategoryEpilogueOf:on:",{aCategory:aCategory,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCategory", "aStream"],
+source: "exportCategoryEpilogueOf: aCategory on: aStream\x0a\x09aStream nextPutAll: ' !'; lf; lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportCategoryPrologueOf:on:",
+protocol: 'output',
+fn: function (aCategory,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2;
+$1="!".__comma(self._classNameFor_($recv(aCategory)._theClass()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(" methodsFor: '".__comma($recv(aCategory)._name())).__comma("'!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$2=$recv(aStream)._nextPutAll_($3);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportCategoryPrologueOf:on:",{aCategory:aCategory,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCategory", "aStream"],
+source: "exportCategoryPrologueOf: aCategory on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '!', (self classNameFor: aCategory theClass);\x0a\x09\x09nextPutAll: ' methodsFor: ''', aCategory name, '''!'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", ",", "classNameFor:", "theClass", "name"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportDefinitionOf:on:",
+protocol: 'output',
+fn: function (aClass,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$6,$5,$7,$9,$8,$11,$10,$12;
+$1=self._classNameFor_($recv(aClass)._superclass());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["classNameFor:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$3=self._classNameFor_(aClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["classNameFor:"]=2;
+//>>excludeEnd("ctx");
+$2=" subclass: #".__comma($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["tab"]=1;
+//>>excludeEnd("ctx");
+$4=$recv(aStream)._nextPutAll_("instanceVariableNames: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv($recv(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._tab();
+$6="package: '".__comma($recv(aClass)._category());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$5=$recv($6).__comma("'!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$7=$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$9=$recv(aClass)._comment();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["comment"]=1;
+//>>excludeEnd("ctx");
+$8=$recv($9)._notEmpty();
+if($core.assert($8)){
+$11="!".__comma(self._classNameFor_(aClass));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$10=$recv($11).__comma(" commentStamp!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(self._chunkEscape_($recv(aClass)._comment())).__comma("!"));
+$12=$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=5;
+//>>excludeEnd("ctx");
+$12;
+};
+$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aStream"],
+source: "exportDefinitionOf: aClass on: aStream\x0a\x09\x22Chunk format.\x22\x0a\x0a\x09aStream\x0a\x09\x09nextPutAll: (self classNameFor: aClass superclass);\x0a\x09\x09nextPutAll: ' subclass: #', (self classNameFor: aClass); lf;\x0a\x09\x09tab; nextPutAll: 'instanceVariableNames: '''.\x0a\x09aClass instanceVariableNames\x0a\x09\x09do: [ :each | aStream nextPutAll: each ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ' ' ].\x0a\x09aStream\x0a\x09\x09nextPutAll: ''''; lf;\x0a\x09\x09tab; nextPutAll: 'package: ''', aClass category, '''!'; lf.\x0a\x09aClass comment notEmpty ifTrue: [\x0a\x09\x09aStream\x0a\x09\x09nextPutAll: '!', (self classNameFor: aClass), ' commentStamp!';lf;\x0a\x09\x09nextPutAll: (self chunkEscape: aClass comment), '!';lf ].\x0a\x09aStream lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "classNameFor:", "superclass", ",", "lf", "tab", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "notEmpty", "comment", "chunkEscape:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportMetaDefinitionOf:on:",
+protocol: 'output',
+fn: function (aClass,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$5,$4,$6,$7;
+$3=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._instanceVariableNames();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instanceVariableNames"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isEmpty();
+if(!$core.assert($1)){
+$5=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=2;
+//>>excludeEnd("ctx");
+$4=self._classNameFor_($5);
+$recv(aStream)._nextPutAll_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(aStream)._nextPutAll_(" instanceVariableNames: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$6;
+$recv($recv($recv(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(" ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_("'!");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$7=$recv(aStream)._lf();
+$7;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aStream"],
+source: "exportMetaDefinitionOf: aClass on: aStream\x0a\x0a\x09aClass class instanceVariableNames isEmpty ifFalse: [\x0a\x09\x09aStream\x0a\x09\x09\x09nextPutAll: (self classNameFor: aClass class);\x0a\x09\x09\x09nextPutAll: ' instanceVariableNames: '''.\x0a\x09\x09aClass class instanceVariableNames\x0a\x09\x09\x09do: [ :each | aStream nextPutAll: each ]\x0a\x09\x09\x09separatedBy: [ aStream nextPutAll: ' ' ].\x0a\x09\x09aStream\x0a\x09\x09\x09nextPutAll: '''!'; lf; lf ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isEmpty", "instanceVariableNames", "class", "nextPutAll:", "classNameFor:", "do:separatedBy:", "lf"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportMethod:on:",
+protocol: 'output',
+fn: function (aMethod,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._chunkEscape_($recv(aMethod)._source()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+$1=$recv(aStream)._nextPutAll_("!");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aStream"],
+source: "exportMethod: aMethod on: aStream\x0a\x09aStream\x0a\x09\x09lf; lf; nextPutAll: (self chunkEscape: aMethod source); lf;\x0a\x09\x09nextPutAll: '!'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lf", "nextPutAll:", "chunkEscape:", "source"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackage:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._exportPackageDefinitionOf_on_(aPackage,aStream);
+$recv($recv(aPackage)._sortedClasses())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._exportDefinitionOf_on_(each,aStream);
+$1=self._ownMethodProtocolsOfClass_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["ownMethodProtocolsOfClass:"]=1;
+//>>excludeEnd("ctx");
+self._exportProtocols_on_($1,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["exportProtocols:on:"]=1;
+//>>excludeEnd("ctx");
+self._exportMetaDefinitionOf_on_(each,aStream);
+return self._exportProtocols_on_(self._ownMethodProtocolsOfClass_($recv(each)._class()),aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["exportProtocols:on:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self._exportProtocols_on_(self._extensionProtocolsOfPackage_(aPackage),aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackage:on:",{aPackage:aPackage,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackage: aPackage on: aStream\x0a\x0a\x09self exportPackageDefinitionOf: aPackage on: aStream.\x0a\x09\x0a\x09aPackage sortedClasses do: [ :each |\x0a\x09\x09self exportDefinitionOf: each on: aStream.\x0a\x09\x09\x0a\x09\x09self \x0a\x09\x09\x09exportProtocols: (self ownMethodProtocolsOfClass: each)\x0a\x09\x09\x09on: aStream.\x0a\x09\x09\x09\x0a\x09\x09self exportMetaDefinitionOf: each on: aStream.\x0a\x09\x09\x0a\x09\x09self \x0a\x09\x09\x09exportProtocols: (self ownMethodProtocolsOfClass: each class)\x0a\x09\x09\x09on: aStream ].\x0a\x09\x09\x09\x0a\x09self \x0a\x09\x09exportProtocols: (self extensionProtocolsOfPackage: aPackage)\x0a\x09\x09on: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["exportPackageDefinitionOf:on:", "do:", "sortedClasses", "exportDefinitionOf:on:", "exportProtocols:on:", "ownMethodProtocolsOfClass:", "exportMetaDefinitionOf:on:", "class", "extensionProtocolsOfPackage:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageDefinitionOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv("Smalltalk createPackage: '".__comma($recv(aPackage)._name())).__comma("'!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+$2=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{aPackage:aPackage,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageDefinitionOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: 'Smalltalk createPackage: ''', aPackage name, '''!';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", ",", "name", "lf"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportProtocol:on:",
+protocol: 'output',
+fn: function (aProtocol,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._exportProtocolPrologueOf_on_(aProtocol,aStream);
+$recv($recv(aProtocol)._methods())._do_((function(method){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._exportMethod_on_(method,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({method:method},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+self._exportProtocolEpilogueOf_on_(aProtocol,aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportProtocol:on:",{aProtocol:aProtocol,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aProtocol", "aStream"],
+source: "exportProtocol: aProtocol on: aStream\x0a\x09self exportProtocolPrologueOf: aProtocol on: aStream.\x0a\x09aProtocol methods do: [ :method | \x0a\x09\x09self exportMethod: method on: aStream ].\x0a\x09self exportProtocolEpilogueOf: aProtocol on: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["exportProtocolPrologueOf:on:", "do:", "methods", "exportMethod:on:", "exportProtocolEpilogueOf:on:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportProtocolEpilogueOf:on:",
+protocol: 'output',
+fn: function (aProtocol,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_(" !");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportProtocolEpilogueOf:on:",{aProtocol:aProtocol,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aProtocol", "aStream"],
+source: "exportProtocolEpilogueOf: aProtocol on: aStream\x0a\x09aStream nextPutAll: ' !'; lf; lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportProtocolPrologueOf:on:",
+protocol: 'output',
+fn: function (aProtocol,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2;
+$1="!".__comma(self._classNameFor_($recv(aProtocol)._theClass()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(" methodsFor: '".__comma($recv(aProtocol)._name())).__comma("'!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$2=$recv(aStream)._nextPutAll_($3);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportProtocolPrologueOf:on:",{aProtocol:aProtocol,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aProtocol", "aStream"],
+source: "exportProtocolPrologueOf: aProtocol on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '!', (self classNameFor: aProtocol theClass);\x0a\x09\x09nextPutAll: ' methodsFor: ''', aProtocol name, '''!'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", ",", "classNameFor:", "theClass", "name"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportProtocols:on:",
+protocol: 'output',
+fn: function (aCollection,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aCollection)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._exportProtocol_on_(each,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportProtocols:on:",{aCollection:aCollection,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection", "aStream"],
+source: "exportProtocols: aCollection on: aStream\x0a\x09aCollection do: [ :each |\x0a\x09\x09self exportProtocol: each on: aStream ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "exportProtocol:on:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "extensionCategoriesOfPackage:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+var name,map,result;
+function $OrderedCollection(){return $globals.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
+function $Package(){return $globals.Package||(typeof Package=="undefined"?nil:Package)}
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+function $MethodCategory(){return $globals.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+name=$recv(aPackage)._name();
+result=$recv($OrderedCollection())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+$recv($recv($Package())._sortedClasses_($recv($Smalltalk())._classes()))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv([each,$recv(each)._class()])._do_((function(aClass){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+map=$recv($Dictionary())._new();
+map;
+$recv(aClass)._protocolsDo_((function(category,methods){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$1=$recv(category).__eq("*".__comma(name));
+if($core.assert($1)){
+return $recv(map)._at_put_(category,methods);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({category:category,methods:methods},$ctx3,3)});
+//>>excludeEnd("ctx");
+}));
+return $recv(result)._addAll_($recv($recv($recv(map)._keys())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv(a).__lt_eq(b);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({a:a,b:b},$ctx3,5)});
+//>>excludeEnd("ctx");
+})))._collect_((function(category){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+return $recv($MethodCategory())._name_theClass_methods_(category,aClass,$recv(map)._at_(category));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx4) {$ctx4.fillBlock({category:category},$ctx3,6)});
+//>>excludeEnd("ctx");
+})));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({aClass:aClass},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$2=result;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"extensionCategoriesOfPackage:",{aPackage:aPackage,name:name,map:map,result:result},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "extensionCategoriesOfPackage: aPackage\x0a\x09\x22Issue #143: sort protocol alphabetically\x22\x0a\x0a\x09| name map result |\x0a\x09name := aPackage name.\x0a\x09result := OrderedCollection new.\x0a\x09(Package sortedClasses: Smalltalk classes) do: [ :each |\x0a\x09\x09{each. each class} do: [ :aClass |\x0a\x09\x09\x09map := Dictionary new.\x0a\x09\x09\x09aClass protocolsDo: [ :category :methods |\x0a\x09\x09\x09\x09category = ('*', name) ifTrue: [ map at: category put: methods ] ].\x0a\x09\x09\x09result addAll: ((map keys sorted: [ :a :b | a <= b ]) collect: [ :category |\x0a\x09\x09\x09\x09MethodCategory name: category theClass: aClass methods: (map at: category) ]) ] ].\x0a\x09^ result",
+referencedClasses: ["OrderedCollection", "Package", "Smalltalk", "Dictionary", "MethodCategory"],
+//>>excludeEnd("ide");
+messageSends: ["name", "new", "do:", "sortedClasses:", "classes", "class", "protocolsDo:", "ifTrue:", "=", ",", "at:put:", "addAll:", "collect:", "sorted:", "keys", "<=", "name:theClass:methods:", "at:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "ownCategoriesOfClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+var map;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+function $MethodCategory(){return $globals.MethodCategory||(typeof MethodCategory=="undefined"?nil:MethodCategory)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+map=$recv($Dictionary())._new();
+$recv(aClass)._protocolsDo_((function(each,methods){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(each)._match_("^\x5c*");
+if(!$core.assert($1)){
+return $recv(map)._at_put_(each,methods);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,methods:methods},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv($recv($recv(map)._keys())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(a).__lt_eq(b);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,3)});
+//>>excludeEnd("ctx");
+})))._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($MethodCategory())._name_theClass_methods_(each,aClass,$recv(map)._at_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfClass:",{aClass:aClass,map:map},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "ownCategoriesOfClass: aClass\x0a\x09\x22Answer the protocols of aClass that are not package extensions\x22\x0a\x09\x0a\x09\x22Issue #143: sort protocol alphabetically\x22\x0a\x0a\x09| map |\x0a\x09map := Dictionary new.\x0a\x09aClass protocolsDo: [ :each :methods |\x0a\x09\x09(each match: '^\x5c*') ifFalse: [ map at: each put: methods ] ].\x0a\x09^ (map keys sorted: [ :a :b | a <= b ]) collect: [ :each |\x0a\x09\x09MethodCategory name: each theClass: aClass methods: (map at: each) ]",
+referencedClasses: ["Dictionary", "MethodCategory"],
+//>>excludeEnd("ide");
+messageSends: ["new", "protocolsDo:", "ifFalse:", "match:", "at:put:", "collect:", "sorted:", "keys", "<=", "name:theClass:methods:", "at:"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "ownCategoriesOfMetaClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ownCategoriesOfClass_($recv(aClass)._class());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownCategoriesOfMetaClass:",{aClass:aClass},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "ownCategoriesOfMetaClass: aClass\x0a\x09\x22Issue #143: sort protocol alphabetically\x22\x0a\x0a\x09^ self ownCategoriesOfClass: aClass class",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ownCategoriesOfClass:", "class"]
+}),
+$globals.ChunkExporter);
+
+$core.addMethod(
+$core.method({
+selector: "ownMethodProtocolsOfClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+function $ExportMethodProtocol(){return $globals.ExportMethodProtocol||(typeof ExportMethodProtocol=="undefined"?nil:ExportMethodProtocol)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aClass)._ownProtocols())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($ExportMethodProtocol())._name_theClass_(each,aClass);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownMethodProtocolsOfClass:",{aClass:aClass},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "ownMethodProtocolsOfClass: aClass\x0a\x09\x22Answer a collection of ExportMethodProtocol object of aClass that are not package extensions\x22\x0a\x09\x0a\x09^ aClass ownProtocols collect: [ :each |\x0a\x09\x09ExportMethodProtocol name: each theClass: aClass ]",
+referencedClasses: ["ExportMethodProtocol"],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "ownProtocols", "name:theClass:"]
+}),
+$globals.ChunkExporter);
+
+
+
+$core.addClass('Exporter', $globals.AbstractExporter, [], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Exporter.comment="I am responsible for outputting Amber code into a JavaScript string.\x0a\x0aThe generated output is enough to reconstruct the exported data, including Smalltalk source code and other metadata.\x0a\x0a## Use case\x0a\x0aI am typically used to save code outside of the Amber runtime (committing to disk, etc.).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "exportDefinitionOf:on:",
+protocol: 'output',
+fn: function (aClass,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3,$4,$6,$5,$7,$9,$8,$10;
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("$core.addClass(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$2="'".__comma(self._classNameFor_(aClass));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma("', ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$3=self._jsClassNameFor_($recv(aClass)._superclass());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["jsClassNameFor:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$4=$recv(aStream)._nextPutAll_(", [");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv($recv(aClass)._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$6="'".__comma(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$5=$recv($6).__comma("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(", ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_("], '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv($recv(aClass)._category()).__comma("'"));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$7=$recv(aStream)._nextPutAll_(");");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+$9=$recv(aClass)._comment();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["comment"]=1;
+//>>excludeEnd("ctx");
+$8=$recv($9)._notEmpty();
+if($core.assert($8)){
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("//>>excludeStart(\x22ide\x22, pragmas.excludeIdeData);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._jsClassNameFor_(aClass));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=11;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(".comment=");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=12;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv($recv($recv(aClass)._comment())._crlfSanitized())._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=13;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(";");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=14;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$10=$recv(aStream)._nextPutAll_("//>>excludeEnd(\x22ide\x22);");
+$10;
+};
+$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportDefinitionOf:on:",{aClass:aClass,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aStream"],
+source: "exportDefinitionOf: aClass on: aStream\x0a\x09aStream\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: '$core.addClass(';\x0a\x09\x09nextPutAll: '''', (self classNameFor: aClass), ''', ';\x0a\x09\x09nextPutAll: (self jsClassNameFor: aClass superclass);\x0a\x09\x09nextPutAll: ', ['.\x0a\x09aClass instanceVariableNames\x0a\x09\x09do: [ :each | aStream nextPutAll: '''', each, '''' ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ', ' ].\x0a\x09aStream\x0a\x09\x09nextPutAll: '], ''';\x0a\x09\x09nextPutAll: aClass category, '''';\x0a\x09\x09nextPutAll: ');'.\x0a\x09aClass comment notEmpty ifTrue: [\x0a\x09\x09aStream\x0a\x09\x09\x09lf;\x0a\x09\x09\x09nextPutAll: '//>>excludeStart(\x22ide\x22, pragmas.excludeIdeData);';\x0a\x09\x09\x09lf;\x0a\x09\x09\x09nextPutAll: (self jsClassNameFor: aClass);\x0a\x09\x09\x09nextPutAll: '.comment=';\x0a\x09\x09\x09nextPutAll: aClass comment crlfSanitized asJavascript;\x0a\x09\x09\x09nextPutAll: ';';\x0a\x09\x09\x09lf;\x0a\x09\x09\x09nextPutAll: '//>>excludeEnd(\x22ide\x22);' ].\x0a\x09aStream lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["lf", "nextPutAll:", ",", "classNameFor:", "jsClassNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "notEmpty", "comment", "asJavascript", "crlfSanitized"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportMetaDefinitionOf:on:",
+protocol: 'output',
+fn: function (aClass,aStream){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$5,$4,$6,$8,$7;
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$3=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._instanceVariableNames();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["instanceVariableNames"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._isEmpty();
+if(!$core.assert($1)){
+$5=$recv(aClass)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=2;
+//>>excludeEnd("ctx");
+$4=self._jsClassNameFor_($5);
+$recv(aStream)._nextPutAll_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$6=$recv(aStream)._nextPutAll_(".iVarNames = [");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$6;
+$recv($recv($recv(aClass)._class())._instanceVariableNames())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$8="'".__comma(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$7=$recv($8).__comma("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aStream)._nextPutAll_(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(aStream)._nextPutAll_("];".__comma($recv($String())._lf()));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportMetaDefinitionOf:on:",{aClass:aClass,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aStream"],
+source: "exportMetaDefinitionOf: aClass on: aStream\x0a\x09aStream lf.\x0a\x09aClass class instanceVariableNames isEmpty ifFalse: [\x0a\x09\x09aStream\x0a\x09\x09nextPutAll: (self jsClassNameFor: aClass class);\x0a\x09\x09nextPutAll: '.iVarNames = ['.\x0a\x09\x09aClass class instanceVariableNames\x0a\x09\x09do: [ :each | aStream nextPutAll: '''', each, '''' ]\x0a\x09\x09separatedBy: [ aStream nextPutAll: ',' ].\x0a\x09\x09aStream nextPutAll: '];', String lf ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["lf", "ifFalse:", "isEmpty", "instanceVariableNames", "class", "nextPutAll:", "jsClassNameFor:", "do:separatedBy:", ","]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportMethod:on:",
+protocol: 'output',
+fn: function (aMethod,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1,$5,$4,$7,$6,$10,$9,$8,$13,$12,$11,$16,$15,$14,$17;
+$recv(aStream)._nextPutAll_("$core.addMethod(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("$core.method({");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($recv(aMethod)._selector())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=1;
+//>>excludeEnd("ctx");
+$2="selector: ".__comma($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=3;
+//>>excludeEnd("ctx");
+$5="protocol: '".__comma($recv(aMethod)._protocol());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$4=$recv($5).__comma("',");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=4;
+//>>excludeEnd("ctx");
+$7="fn: ".__comma($recv($recv(aMethod)._fn())._compiledSource());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=6;
+//>>excludeEnd("ctx");
+$6=$recv($7).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=5;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("//>>excludeStart(\x22ide\x22, pragmas.excludeIdeData);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=6;
+//>>excludeEnd("ctx");
+$10=$recv($recv(aMethod)._arguments())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=2;
+//>>excludeEnd("ctx");
+$9="args: ".__comma($10);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=8;
+//>>excludeEnd("ctx");
+$8=$recv($9).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=7;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=7;
+//>>excludeEnd("ctx");
+$13=$recv($recv(aMethod)._source())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=3;
+//>>excludeEnd("ctx");
+$12="source: ".__comma($13);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=10;
+//>>excludeEnd("ctx");
+$11=$recv($12).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=9;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($11);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=8;
+//>>excludeEnd("ctx");
+$16=$recv($recv(aMethod)._referencedClasses())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asJavascript"]=4;
+//>>excludeEnd("ctx");
+$15="referencedClasses: ".__comma($16);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=12;
+//>>excludeEnd("ctx");
+$14=$recv($15).__comma(",");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=11;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($14);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=9;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("//>>excludeEnd(\x22ide\x22);");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=10;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=10;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("messageSends: ".__comma($recv($recv(aMethod)._messageSends())._asJavascript()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=11;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=11;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("}),");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=12;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=12;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._jsClassNameFor_($recv(aMethod)._methodClass()));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=13;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(");");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=13;
+//>>excludeEnd("ctx");
+$17=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportMethod:on:",{aMethod:aMethod,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aStream"],
+source: "exportMethod: aMethod on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '$core.addMethod(';lf;\x0a\x09\x09nextPutAll: '$core.method({';lf;\x0a\x09\x09nextPutAll: 'selector: ', aMethod selector asJavascript, ',';lf;\x0a\x09\x09nextPutAll: 'protocol: ''', aMethod protocol, ''',';lf;\x0a\x09\x09nextPutAll: 'fn: ', aMethod fn compiledSource, ',';lf;\x0a\x09\x09nextPutAll: '//>>excludeStart(\x22ide\x22, pragmas.excludeIdeData);';lf;\x0a\x09\x09nextPutAll: 'args: ', aMethod arguments asJavascript, ','; lf;\x0a\x09\x09nextPutAll: 'source: ', aMethod source asJavascript, ',';lf;\x0a\x09\x09nextPutAll: 'referencedClasses: ', aMethod referencedClasses asJavascript, ',';lf;\x0a\x09\x09nextPutAll: '//>>excludeEnd(\x22ide\x22);';lf;\x0a\x09\x09nextPutAll: 'messageSends: ', aMethod messageSends asJavascript;lf;\x0a\x09\x09nextPutAll: '}),';lf;\x0a\x09\x09nextPutAll: (self jsClassNameFor: aMethod methodClass);\x0a\x09\x09nextPutAll: ');';lf;lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf", ",", "asJavascript", "selector", "protocol", "compiledSource", "fn", "arguments", "source", "referencedClasses", "messageSends", "jsClassNameFor:", "methodClass"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackage:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._exportPackagePrologueOf_on_(aPackage,aStream);
+self._exportPackageDefinitionOf_on_(aPackage,aStream);
+$1=self._exportPackageTransportOf_on_(aPackage,aStream);
+$recv($recv(aPackage)._sortedClasses())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._exportDefinitionOf_on_(each,aStream);
+$2=$recv(each)._ownMethods();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["ownMethods"]=1;
+//>>excludeEnd("ctx");
+$recv($2)._do_((function(method){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._exportMethod_on_(method,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["exportMethod:on:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({method:method},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["do:"]=2;
+//>>excludeEnd("ctx");
+self._exportMetaDefinitionOf_on_(each,aStream);
+return $recv($recv($recv(each)._class())._ownMethods())._do_((function(method){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._exportMethod_on_(method,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["exportMethod:on:"]=2;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({method:method},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["do:"]=3;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$recv(self._extensionMethodsOfPackage_(aPackage))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._exportMethod_on_(each,aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+self._exportPackageEpilogueOf_on_(aPackage,aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackage:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackage: aPackage on: aStream\x0a\x09\x0a\x09self \x0a\x09\x09exportPackagePrologueOf: aPackage on: aStream;\x0a\x09\x09exportPackageDefinitionOf: aPackage on: aStream;\x0a\x09\x09exportPackageTransportOf: aPackage on: aStream.\x0a\x09\x0a\x09aPackage sortedClasses do: [ :each |\x0a\x09\x09self exportDefinitionOf: each on: aStream.\x0a\x09\x09each ownMethods do: [ :method |\x0a\x09\x09\x09self exportMethod: method on: aStream ].\x0a\x09\x09\x09\x0a\x09\x09self exportMetaDefinitionOf: each on: aStream.\x0a\x09\x09each class ownMethods do: [ :method |\x0a\x09\x09\x09self exportMethod: method on: aStream ] ].\x0a\x09\x09\x09\x0a\x09(self extensionMethodsOfPackage: aPackage) do: [ :each |\x0a\x09\x09self exportMethod: each on: aStream ].\x0a\x09\x09\x0a\x09self exportPackageEpilogueOf: aPackage on: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["exportPackagePrologueOf:on:", "exportPackageDefinitionOf:on:", "exportPackageTransportOf:on:", "do:", "sortedClasses", "exportDefinitionOf:on:", "ownMethods", "exportMethod:on:", "exportMetaDefinitionOf:on:", "class", "extensionMethodsOfPackage:", "exportPackageEpilogueOf:on:"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageDefinitionOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$recv(aStream)._nextPutAll_("$core.addPackage(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$1=$recv("'".__comma($recv(aPackage)._name())).__comma("');");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+$2=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageDefinitionOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageDefinitionOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '$core.addPackage(';\x0a\x09\x09nextPutAll: '''', aPackage name, ''');';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", ",", "name", "lf"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageEpilogueOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("})(global_smalltalk,global_nil,global__st);");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageEpilogueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageEpilogueOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '})(global_smalltalk,global_nil,global__st);';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackagePrologueOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("(function(smalltalk,nil,_st){");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackagePrologueOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '(function(smalltalk,nil,_st){';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageTransportOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("$core.packages[");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv($recv(aPackage)._name())._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("].transport = ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv($recv(aPackage)._transport())._asJSONString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(";");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageTransportOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageTransportOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '$core.packages[';\x0a\x09\x09nextPutAll: aPackage name asJavascript;\x0a\x09\x09nextPutAll: '].transport = ';\x0a\x09\x09nextPutAll: aPackage transport asJSONString;\x0a\x09\x09nextPutAll: ';';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "asJavascript", "name", "asJSONString", "transport", "lf"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "jsClassNameFor:",
+protocol: 'convenience',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=$recv(aClass)._isMetaclass();
+if($core.assert($2)){
+$1=$recv(self._jsClassNameFor_($recv(aClass)._instanceClass())).__comma(".klass");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+} else {
+if(($receiver = aClass) == null || $receiver.isNil){
+$1="null";
+} else {
+$1="$globals.".__comma($recv(aClass)._name());
+};
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"jsClassNameFor:",{aClass:aClass},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "jsClassNameFor: aClass\x0a\x09^ aClass isMetaclass\x0a\x09\x09ifTrue: [ (self jsClassNameFor: aClass instanceClass), '.klass' ]\x0a\x09\x09ifFalse: [\x0a\x09\x09\x09aClass\x0a\x09\x09\x09\x09ifNil: [ 'null' ]\x0a\x09\x09\x09\x09ifNotNil: [ '$globals.', aClass name ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isMetaclass", ",", "jsClassNameFor:", "instanceClass", "ifNil:ifNotNil:", "name"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "ownMethodsOfClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv($recv($recv($recv(aClass)._methodDictionary())._values())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(a)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+return $recv($2).__lt_eq($recv(b)._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._reject_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(each)._protocol())._match_("^\x5c*");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownMethodsOfClass:",{aClass:aClass},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "ownMethodsOfClass: aClass\x0a\x09\x22Issue #143: sort methods alphabetically\x22\x0a\x0a\x09^ ((aClass methodDictionary values) sorted: [ :a :b | a selector <= b selector ])\x0a\x09\x09reject: [ :each | (each protocol match: '^\x5c*') ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["reject:", "sorted:", "values", "methodDictionary", "<=", "selector", "match:", "protocol"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "ownMethodsOfMetaClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ownMethodsOfClass_($recv(aClass)._class());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ownMethodsOfMetaClass:",{aClass:aClass},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "ownMethodsOfMetaClass: aClass\x0a\x09\x22Issue #143: sort methods alphabetically\x22\x0a\x0a\x09^ self ownMethodsOfClass: aClass class",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ownMethodsOfClass:", "class"]
+}),
+$globals.Exporter);
+
+
+
+$core.addClass('AmdExporter', $globals.Exporter, ['namespace'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AmdExporter.comment="I am used to export Packages in an AMD (Asynchronous Module Definition) JavaScript format.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "amdNamesOfPackages:",
+protocol: 'private',
+fn: function (anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv($recv(anArray)._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._amdNamespaceOfPackage_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["amdNamespaceOfPackage:"]=1;
+//>>excludeEnd("ctx");
+return $recv($2)._notNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv(self._amdNamespaceOfPackage_(each)).__comma("/")).__comma($recv(each)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"amdNamesOfPackages:",{anArray:anArray},$globals.AmdExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArray"],
+source: "amdNamesOfPackages: anArray\x0a\x09^ (anArray\x0a\x09\x09select: [ :each | (self amdNamespaceOfPackage: each) notNil ])\x0a\x09\x09collect: [ :each | (self amdNamespaceOfPackage: each), '/', each name ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "select:", "notNil", "amdNamespaceOfPackage:", ",", "name"]
+}),
+$globals.AmdExporter);
+
+$core.addMethod(
+$core.method({
+selector: "amdNamespaceOfPackage:",
+protocol: 'private',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$1;
+$4=$recv(aPackage)._transport();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["transport"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._type();
+$2=$recv($3).__eq("amd");
+if($core.assert($2)){
+$1=$recv($recv(aPackage)._transport())._namespace();
+} else {
+$1=nil;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"amdNamespaceOfPackage:",{aPackage:aPackage},$globals.AmdExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "amdNamespaceOfPackage: aPackage\x0a\x09^ (aPackage transport type = 'amd')\x0a\x09\x09ifTrue: [ aPackage transport namespace ]\x0a\x09\x09ifFalse: [ nil ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "=", "type", "transport", "namespace"]
+}),
+$globals.AmdExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageEpilogueOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("});");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageEpilogueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.AmdExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageEpilogueOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '});';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "lf"]
+}),
+$globals.AmdExporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackagePrologueOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aStream)._nextPutAll_("define(\x22");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._amdNamespaceOfPackage_(aPackage));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("/");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(aPackage)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("\x22, ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(["amber/boot"].__comma(self._amdNamesOfPackages_($recv(aPackage)._loadDependencies())))._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(", function($boot){");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv(aStream)._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("var smalltalk=$core,_st=$recv,globals=$globals;");
+$1=$recv(aStream)._lf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.AmdExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackagePrologueOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: 'define(\x22';\x0a\x09\x09nextPutAll: (self amdNamespaceOfPackage: aPackage);\x0a\x09\x09nextPutAll: '/';\x0a\x09\x09nextPutAll: aPackage name;\x0a\x09\x09nextPutAll: '\x22, ';\x0a\x09\x09nextPutAll: (#('amber/boot'), (self amdNamesOfPackages: aPackage loadDependencies)) asJavascript;\x0a\x09\x09nextPutAll: ', function($boot){';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: 'var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: 'var smalltalk=$core,_st=$recv,globals=$globals;';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "amdNamespaceOfPackage:", "name", "asJavascript", ",", "amdNamesOfPackages:", "loadDependencies", "lf"]
+}),
+$globals.AmdExporter);
+
+
+
+$core.addClass('ChunkParser', $globals.Object, ['stream', 'last'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ChunkParser.comment="I am responsible for parsing aStream contents in the chunk format.\x0a\x0a## API\x0a\x0a    ChunkParser new\x0a        stream: aStream;\x0a        nextChunk";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "last",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@last"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "last\x0a\x09^ last",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ChunkParser);
+
+$core.addMethod(
+$core.method({
+selector: "nextChunk",
+protocol: 'reading',
+fn: function (){
+var self=this;
+var char,result,chunk;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+var $early={};
+try {
+result=""._writeStream();
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+char=$recv(self["@stream"])._next();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["next"]=1;
+//>>excludeEnd("ctx");
+char;
+return $recv(char)._notNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(char).__eq("!");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+if($core.assert($1)){
+$2=$recv($recv(self["@stream"])._peek()).__eq("!");
+if($core.assert($2)){
+$recv(self["@stream"])._next();
+} else {
+self["@last"]=$recv($recv(result)._contents())._trimBoth();
+$3=self["@last"];
+throw $early=[$3];
+};
+};
+return $recv(result)._nextPut_(char);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+self["@last"]=nil;
+$4=self["@last"];
+return $4;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextChunk",{char:char,result:result,chunk:chunk},$globals.ChunkParser)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nextChunk\x0a\x09\x22The chunk format (Smalltalk Interchange Format or Fileout format)\x0a\x09is a trivial format but can be a bit tricky to understand:\x0a\x09\x09- Uses the exclamation mark as delimiter of chunks.\x0a\x09\x09- Inside a chunk a normal exclamation mark must be doubled.\x0a\x09\x09- A non empty chunk must be a valid Smalltalk expression.\x0a\x09\x09- A chunk on top level with a preceding empty chunk is an instruction chunk:\x0a\x09\x09\x09- The object created by the expression then takes over reading chunks.\x0a\x0a\x09This method returns next chunk as a String (trimmed), empty String (all whitespace) or nil.\x22\x0a\x0a\x09| char result chunk |\x0a\x09result := '' writeStream.\x0a\x09\x09[ char := stream next.\x0a\x09\x09char notNil ] whileTrue: [\x0a\x09\x09\x09\x09char = '!' ifTrue: [\x0a\x09\x09\x09\x09\x09\x09stream peek = '!'\x0a\x09\x09\x09\x09\x09\x09\x09\x09ifTrue: [ stream next \x22skipping the escape double\x22 ]\x0a\x09\x09\x09\x09\x09\x09\x09\x09ifFalse: [ ^ last := result contents trimBoth \x22chunk end marker found\x22 ]].\x0a\x09\x09\x09\x09result nextPut: char ].\x0a\x09^ last := nil \x22a chunk needs to end with !\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["writeStream", "whileTrue:", "next", "notNil", "ifTrue:", "=", "ifTrue:ifFalse:", "peek", "trimBoth", "contents", "nextPut:"]
+}),
+$globals.ChunkParser);
+
+$core.addMethod(
+$core.method({
+selector: "stream:",
+protocol: 'accessing',
+fn: function (aStream){
+var self=this;
+self["@stream"]=aStream;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "stream: aStream\x0a\x09stream := aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ChunkParser);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._new())._stream_(aStream);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aStream:aStream},$globals.ChunkParser.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "on: aStream\x0a\x09^ self new stream: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["stream:", "new"]
+}),
+$globals.ChunkParser.klass);
+
+
+$core.addClass('ExportMethodProtocol', $globals.Object, ['name', 'theClass'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ExportMethodProtocol.comment="I am an abstraction for a method protocol in a class / metaclass.\x0a\x0aI know of my class, name and methods.\x0aI am used when exporting a package.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "methods",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv($recv(self._theClass())._methodsInProtocol_(self._name()))._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(a)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+return $recv($2).__lt_eq($recv(b)._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methods",{},$globals.ExportMethodProtocol)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methods\x0a\x09^ (self theClass methodsInProtocol: self name)\x0a\x09\x09sorted: [ :a :b | a selector <= b selector ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sorted:", "methodsInProtocol:", "theClass", "name", "<=", "selector"]
+}),
+$globals.ExportMethodProtocol);
+
+$core.addMethod(
+$core.method({
+selector: "name",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@name"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "name\x0a\x09^ name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ExportMethodProtocol);
+
+$core.addMethod(
+$core.method({
+selector: "name:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@name"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "name: aString\x0a\x09name := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ExportMethodProtocol);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@theClass"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09^ theClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ExportMethodProtocol);
+
+$core.addMethod(
+$core.method({
+selector: "theClass:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+self["@theClass"]=aClass;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "theClass: aClass\x0a\x09theClass := aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ExportMethodProtocol);
+
+
+$core.addMethod(
+$core.method({
+selector: "name:theClass:",
+protocol: 'instance creation',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._name_(aString);
+$recv($2)._theClass_(aClass);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"name:theClass:",{aString:aString,aClass:aClass},$globals.ExportMethodProtocol.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "name: aString theClass: aClass\x0a\x09^ self new\x0a\x09\x09name: aString;\x0a\x09\x09theClass: aClass;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["name:", "new", "theClass:", "yourself"]
+}),
+$globals.ExportMethodProtocol.klass);
+
+
+$core.addClass('Importer', $globals.Object, ['lastSection', 'lastChunk'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Importer.comment="I can import Amber code from a string in the chunk format.\x0a\x0a## API\x0a\x0a    Importer new import: aString";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "import:",
+protocol: 'fileIn',
+fn: function (aStream){
+var self=this;
+var chunk,result,parser,lastEmpty;
+function $ChunkParser(){return $globals.ChunkParser||(typeof ChunkParser=="undefined"?nil:ChunkParser)}
+function $Compiler(){return $globals.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+parser=$recv($ChunkParser())._on_(aStream);
+lastEmpty=false;
+self["@lastSection"]="n/a, not started";
+self["@lastChunk"]=nil;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+chunk=$recv(parser)._nextChunk();
+chunk;
+return $recv(chunk)._isNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$1=$recv(chunk)._isEmpty();
+if($core.assert($1)){
+lastEmpty=true;
+return lastEmpty;
+} else {
+self["@lastSection"]=chunk;
+self["@lastSection"];
+result=$recv($recv($Compiler())._new())._evaluateExpression_(chunk);
+result;
+$2=lastEmpty;
+if($core.assert($2)){
+lastEmpty=false;
+lastEmpty;
+return $recv(result)._scanFrom_(parser);
+};
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+self["@lastSection"]="n/a, finished";
+return self["@lastSection"];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(e){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self["@lastChunk"]=$recv(parser)._last();
+self["@lastChunk"];
+return $recv(e)._signal();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({e:e},$ctx1,7)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"import:",{aStream:aStream,chunk:chunk,result:result,parser:parser,lastEmpty:lastEmpty},$globals.Importer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "import: aStream\x0a\x09| chunk result parser lastEmpty |\x0a\x09parser := ChunkParser on: aStream.\x0a\x09lastEmpty := false.\x0a\x09lastSection := 'n/a, not started'.\x0a\x09lastChunk := nil.\x0a\x09[\x0a\x09[ chunk := parser nextChunk.\x0a\x09chunk isNil ] whileFalse: [\x0a\x09\x09chunk isEmpty\x0a\x09\x09\x09ifTrue: [ lastEmpty := true ]\x0a\x09\x09\x09ifFalse: [\x0a\x09\x09\x09\x09lastSection := chunk.\x0a\x09\x09\x09\x09result := Compiler new evaluateExpression: chunk.\x0a\x09\x09\x09\x09lastEmpty\x0a\x09\x09\x09\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09\x09\x09\x09\x09\x09lastEmpty := false.\x0a\x09\x09\x09\x09\x09\x09\x09\x09\x09result scanFrom: parser ]] ].\x0a\x09lastSection := 'n/a, finished'\x0a\x09] on: Error do: [:e | lastChunk := parser last. e signal ].",
+referencedClasses: ["ChunkParser", "Compiler", "Error"],
+//>>excludeEnd("ide");
+messageSends: ["on:", "on:do:", "whileFalse:", "nextChunk", "isNil", "ifTrue:ifFalse:", "isEmpty", "evaluateExpression:", "new", "ifTrue:", "scanFrom:", "last", "signal"]
+}),
+$globals.Importer);
+
+$core.addMethod(
+$core.method({
+selector: "lastChunk",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@lastChunk"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lastChunk\x0a\x09^ lastChunk",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Importer);
+
+$core.addMethod(
+$core.method({
+selector: "lastSection",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@lastSection"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lastSection\x0a\x09^ lastSection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Importer);
+
+
+
+$core.addClass('PackageHandler', $globals.InterfacingObject, [], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageHandler.comment="I am responsible for handling package loading and committing.\x0a\x0aI should not be used directly. Instead, use the corresponding `Package` methods.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "ajaxPutAt:data:onSuccess:onError:",
+protocol: 'private',
+fn: function (aURL,aString,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._ajax_($globals.HashedCollection._newFromPairs_(["url",aURL,"type","PUT","data",aString,"contentType","text/plain;charset=UTF-8","success",aBlock,"error",anotherBlock]));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ajaxPutAt:data:onSuccess:onError:",{aURL:aURL,aString:aString,aBlock:aBlock,anotherBlock:anotherBlock},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aURL", "aString", "aBlock", "anotherBlock"],
+source: "ajaxPutAt: aURL data: aString onSuccess: aBlock onError: anotherBlock\x0a\x09self\x0a\x09\x09ajax: #{\x0a\x09\x09\x09'url' -> aURL.\x0a\x09\x09\x09'type' -> 'PUT'.\x0a\x09\x09\x09'data' -> aString.\x0a\x09\x09\x09'contentType' -> 'text/plain;charset=UTF-8'.\x0a\x09\x09\x09'success' -> aBlock.\x0a\x09\x09\x09'error' -> anotherBlock\x0a\x09\x09}",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ajax:"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "chunkContentsFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($String())._streamContents_((function(str){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._chunkExporter())._exportPackage_on_(aPackage,str);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"chunkContentsFor:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "chunkContentsFor: aPackage\x0a\x09^ String streamContents: [ :str |\x0a\x09\x09self chunkExporter exportPackage: aPackage on: str ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "exportPackage:on:", "chunkExporter"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "chunkExporter",
+protocol: 'factory',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._chunkExporterClass())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"chunkExporter",{},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "chunkExporter\x0a\x09^ self chunkExporterClass new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "chunkExporterClass"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "chunkExporterClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $ChunkExporter(){return $globals.ChunkExporter||(typeof ChunkExporter=="undefined"?nil:ChunkExporter)}
+return $ChunkExporter();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "chunkExporterClass\x0a\x09^ ChunkExporter",
+referencedClasses: ["ChunkExporter"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commit:",
+protocol: 'committing',
+fn: function (aPackage){
+var self=this;
+function $PackageCommitError(){return $globals.PackageCommitError||(typeof PackageCommitError=="undefined"?nil:PackageCommitError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+self._commit_onSuccess_onError_(aPackage,(function(){
+
+}),(function(error){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv($PackageCommitError())._new();
+$2=$1;
+$3=$recv("Commiting failed with reason: \x22".__comma($recv(error)._responseText())).__comma("\x22");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($2)._messageText_($3);
+$4=$recv($1)._signal();
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({error:error},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commit:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "commit: aPackage\x0a\x09self \x0a\x09\x09commit: aPackage\x0a\x09\x09onSuccess: []\x0a\x09\x09onError: [ :error |\x0a\x09\x09\x09PackageCommitError new\x0a\x09\x09\x09\x09messageText: 'Commiting failed with reason: \x22' , (error responseText) , '\x22';\x0a\x09\x09\x09\x09signal ]",
+referencedClasses: ["PackageCommitError"],
+//>>excludeEnd("ide");
+messageSends: ["commit:onSuccess:onError:", "messageText:", "new", ",", "responseText", "signal"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commit:onSuccess:onError:",
+protocol: 'committing',
+fn: function (aPackage,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._commitJsFileFor_onSuccess_onError_(aPackage,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._commitStFileFor_onSuccess_onError_(aPackage,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$recv(aPackage)._beClean();
+return $recv(aBlock)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}),anotherBlock);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),anotherBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commit:onSuccess:onError:",{aPackage:aPackage,aBlock:aBlock,anotherBlock:anotherBlock},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aBlock", "anotherBlock"],
+source: "commit: aPackage onSuccess: aBlock onError: anotherBlock\x0a\x09self \x0a\x09\x09commitJsFileFor: aPackage \x0a\x09\x09onSuccess: [\x0a\x09\x09\x09self \x0a\x09\x09\x09\x09commitStFileFor: aPackage \x0a\x09\x09\x09\x09onSuccess: [ aPackage beClean. aBlock value ]\x0a\x09\x09\x09\x09onError: anotherBlock ] \x0a\x09\x09onError: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commitJsFileFor:onSuccess:onError:", "commitStFileFor:onSuccess:onError:", "beClean", "value"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commitJsFileFor:onSuccess:onError:",
+protocol: 'committing',
+fn: function (aPackage,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv($recv(self._commitPathJsFor_(aPackage)).__comma("/")).__comma($recv(aPackage)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma(".js");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._ajaxPutAt_data_onSuccess_onError_($1,self._contentsFor_(aPackage),aBlock,anotherBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitJsFileFor:onSuccess:onError:",{aPackage:aPackage,aBlock:aBlock,anotherBlock:anotherBlock},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aBlock", "anotherBlock"],
+source: "commitJsFileFor: aPackage onSuccess: aBlock onError: anotherBlock\x0a\x09self \x0a\x09\x09ajaxPutAt: (self commitPathJsFor: aPackage), '/', aPackage name, '.js'\x0a\x09\x09data: (self contentsFor: aPackage)\x0a\x09\x09onSuccess: aBlock\x0a\x09\x09onError: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ajaxPutAt:data:onSuccess:onError:", ",", "commitPathJsFor:", "name", "contentsFor:"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commitPathJsFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitPathJsFor:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "commitPathJsFor: aPackage\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commitPathStFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitPathStFor:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "commitPathStFor: aPackage\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commitStFileFor:onSuccess:onError:",
+protocol: 'committing',
+fn: function (aPackage,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv($recv(self._commitPathStFor_(aPackage)).__comma("/")).__comma($recv(aPackage)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($2).__comma(".st");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._ajaxPutAt_data_onSuccess_onError_($1,self._chunkContentsFor_(aPackage),aBlock,anotherBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitStFileFor:onSuccess:onError:",{aPackage:aPackage,aBlock:aBlock,anotherBlock:anotherBlock},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aBlock", "anotherBlock"],
+source: "commitStFileFor: aPackage onSuccess: aBlock onError: anotherBlock\x0a\x09self \x0a\x09\x09ajaxPutAt: (self commitPathStFor: aPackage), '/', aPackage name, '.st'\x0a\x09\x09data: (self chunkContentsFor: aPackage)\x0a\x09\x09onSuccess: aBlock\x0a\x09\x09onError: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ajaxPutAt:data:onSuccess:onError:", ",", "commitPathStFor:", "name", "chunkContentsFor:"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "contentsFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($String())._streamContents_((function(str){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._exporter())._exportPackage_on_(aPackage,str);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contentsFor:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "contentsFor: aPackage\x0a\x09^ String streamContents: [ :str |\x0a\x09\x09self exporter exportPackage: aPackage on: str ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "exportPackage:on:", "exporter"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "exporter",
+protocol: 'factory',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._exporterClass())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exporter",{},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "exporter\x0a\x09^ self exporterClass new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "exporterClass"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "exporterClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Exporter(){return $globals.Exporter||(typeof Exporter=="undefined"?nil:Exporter)}
+return $Exporter();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "exporterClass\x0a\x09^ Exporter",
+referencedClasses: ["Exporter"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "load:",
+protocol: 'loading',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load:",{aPackage:aPackage},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "load: aPackage\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.PackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "onCommitError:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+function $PackageCommitError(){return $globals.PackageCommitError||(typeof PackageCommitError=="undefined"?nil:PackageCommitError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+$1=$recv($PackageCommitError())._new();
+$2=$1;
+$3=$recv("Commiting failed with reason: \x22".__comma($recv(anError)._responseText())).__comma("\x22");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($2)._messageText_($3);
+$4=$recv($1)._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onCommitError:",{anError:anError},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "onCommitError: anError\x0a\x09PackageCommitError new\x0a\x09\x09messageText: 'Commiting failed with reason: \x22' , (anError responseText) , '\x22';\x0a\x09\x09signal",
+referencedClasses: ["PackageCommitError"],
+//>>excludeEnd("ide");
+messageSends: ["messageText:", "new", ",", "responseText", "signal"]
+}),
+$globals.PackageHandler);
+
+
+
+$core.addClass('AmdPackageHandler', $globals.PackageHandler, [], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AmdPackageHandler.comment="I am responsible for handling package loading and committing.\x0a\x0aI should not be used directly. Instead, use the corresponding `Package` methods.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "commitPathJsFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._toUrl_(self._namespaceFor_(aPackage));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitPathJsFor:",{aPackage:aPackage},$globals.AmdPackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "commitPathJsFor: aPackage\x0a\x09^ self toUrl: (self namespaceFor: aPackage)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["toUrl:", "namespaceFor:"]
+}),
+$globals.AmdPackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "commitPathStFor:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+var path,pathWithout;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2;
+$1=$recv(self._namespaceFor_(aPackage)).__comma("/_source");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+path=self._toUrl_($1);
+pathWithout=self._commitPathJsFor_(aPackage);
+$3=$recv(path).__eq($recv(pathWithout).__comma("/_source"));
+if($core.assert($3)){
+$2=pathWithout;
+} else {
+$2=path;
+};
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitPathStFor:",{aPackage:aPackage,path:path,pathWithout:pathWithout},$globals.AmdPackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "commitPathStFor: aPackage\x0a\x09\x22If _source is not mapped, .st will be committed to .js path.\x0a\x09It is recommended not to use _source as it can be deprecated.\x22\x0a\x09\x0a\x09| path pathWithout |\x0a\x09path := self toUrl: (self namespaceFor: aPackage), '/_source'.\x0a\x09pathWithout := self commitPathJsFor: aPackage.\x0a\x09^ path = (pathWithout, '/_source') ifTrue: [ pathWithout ] ifFalse: [ path ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["toUrl:", ",", "namespaceFor:", "commitPathJsFor:", "ifTrue:ifFalse:", "="]
+}),
+$globals.AmdPackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "exporterClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $AmdExporter(){return $globals.AmdExporter||(typeof AmdExporter=="undefined"?nil:AmdExporter)}
+return $AmdExporter();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "exporterClass\x0a\x09^ AmdExporter",
+referencedClasses: ["AmdExporter"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AmdPackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "load:",
+protocol: 'loading',
+fn: function (aPackage){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$receiver;
+$1=$recv($Smalltalk())._amdRequire();
+if(($receiver = $1) == null || $receiver.isNil){
+self._error_("AMD loader not present");
+} else {
+var require;
+require=$receiver;
+$3=$recv($recv(self._namespaceFor_(aPackage)).__comma("/")).__comma($recv(aPackage)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$2=$recv($Array())._with_($3);
+$recv(require)._value_($2);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load:",{aPackage:aPackage},$globals.AmdPackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "load: aPackage\x0a\x09Smalltalk amdRequire\x0a\x09\x09ifNil: [ self error: 'AMD loader not present' ]\x0a\x09\x09ifNotNil: [ :require |\x0a\x09\x09\x09require value: (Array with: (self namespaceFor: aPackage), '/', aPackage name ) ]",
+referencedClasses: ["Smalltalk", "Array"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "amdRequire", "error:", "value:", "with:", ",", "namespaceFor:", "name"]
+}),
+$globals.AmdPackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "namespaceFor:",
+protocol: 'committing',
+fn: function (aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aPackage)._transport())._namespace();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"namespaceFor:",{aPackage:aPackage},$globals.AmdPackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "namespaceFor: aPackage\x0a\x09^ aPackage transport namespace",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["namespace", "transport"]
+}),
+$globals.AmdPackageHandler);
+
+$core.addMethod(
+$core.method({
+selector: "toUrl:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=$recv($Smalltalk())._amdRequire();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("AMD loader not present");
+} else {
+var require;
+require=$receiver;
+$1=$recv($recv(require)._basicAt_("toUrl"))._value_(aString);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"toUrl:",{aString:aString},$globals.AmdPackageHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "toUrl: aString\x0a\x09^ Smalltalk amdRequire\x0a\x09\x09ifNil: [ self error: 'AMD loader not present' ]\x0a\x09\x09ifNotNil: [ :require | (require basicAt: 'toUrl') value: aString ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "amdRequire", "error:", "value:", "basicAt:"]
+}),
+$globals.AmdPackageHandler);
+
+
+$core.addMethod(
+$core.method({
+selector: "defaultNamespace",
+protocol: 'commit paths',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._defaultAmdNamespace();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultNamespace",{},$globals.AmdPackageHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultNamespace\x0a\x09^ Smalltalk defaultAmdNamespace",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["defaultAmdNamespace"]
+}),
+$globals.AmdPackageHandler.klass);
+
+$core.addMethod(
+$core.method({
+selector: "defaultNamespace:",
+protocol: 'commit paths',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Smalltalk())._defaultAmdNamespace_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultNamespace:",{aString:aString},$globals.AmdPackageHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "defaultNamespace: aString\x0a\x09Smalltalk defaultAmdNamespace: aString",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["defaultAmdNamespace:"]
+}),
+$globals.AmdPackageHandler.klass);
+
+
+$core.addClass('PackageTransport', $globals.Object, ['package'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageTransport.comment="I represent the transport mechanism used to commit a package.\x0a\x0aMy concrete subclasses have a `#handler` to which committing is delegated.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$globals.HashedCollection._newFromPairs_(["type",self._type()]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSON",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ #{ 'type' -> self type }",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["type"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "commit",
+protocol: 'committing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._commitHandler())._commit_(self._package());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commit",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commit\x0a\x09self commitHandler commit: self package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commit:", "commitHandler", "package"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "commitHandler",
+protocol: 'factory',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._commitHandlerClass())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitHandler",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commitHandler\x0a\x09^ self commitHandlerClass new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "commitHandlerClass"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "commitHandlerClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitHandlerClass",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commitHandlerClass\x0a\x09self subclassResponsibility",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclassResponsibility"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "commitOnSuccess:onError:",
+protocol: 'committing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._commitHandler())._commit_onSuccess_onError_(self._package(),aBlock,anotherBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitOnSuccess:onError:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "commitOnSuccess: aBlock onError: anotherBlock\x0a\x09self commitHandler \x0a\x09\x09commit: self package\x0a\x09\x09onSuccess: aBlock\x0a\x09\x09onError: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commit:onSuccess:onError:", "commitHandler", "package"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ ''",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "load",
+protocol: 'loading',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._commitHandler())._load_(self._package());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "load\x0a\x09self commitHandler load: self package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["load:", "commitHandler", "package"]
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@package"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x09^ package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "package:",
+protocol: 'accessing',
+fn: function (aPackage){
+var self=this;
+self["@package"]=aPackage;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage"],
+source: "package: aPackage\x0a\x09package := aPackage",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "setupFromJson:",
+protocol: 'initialization',
+fn: function (anObject){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "setupFromJson: anObject\x0a\x09\x22no op. override if needed in subclasses\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "type",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._type();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"type",{},$globals.PackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "type\x0a\x09^ self class type",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["type", "class"]
+}),
+$globals.PackageTransport);
+
+
+$globals.PackageTransport.klass.iVarNames = ['registry'];
+$core.addMethod(
+$core.method({
+selector: "classRegisteredFor:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@registry"])._at_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classRegisteredFor:",{aString:aString},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "classRegisteredFor: aString\x0a\x09^ registry at: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "defaultType",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $AmdPackageTransport(){return $globals.AmdPackageTransport||(typeof AmdPackageTransport=="undefined"?nil:AmdPackageTransport)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($AmdPackageTransport())._type();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultType",{},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultType\x0a\x09^ AmdPackageTransport type",
+referencedClasses: ["AmdPackageTransport"],
+//>>excludeEnd("ide");
+messageSends: ["type"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "for:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._classRegisteredFor_(aString))._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"for:",{aString:aString},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "for: aString\x0a\x09^ (self classRegisteredFor: aString) new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new", "classRegisteredFor:"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromJson:",
+protocol: 'instance creation',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$4,$2,$receiver;
+if(($receiver = anObject) == null || $receiver.isNil){
+$1=self._for_(self._defaultType());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["for:"]=1;
+//>>excludeEnd("ctx");
+return $1;
+} else {
+anObject;
+};
+$3=self._for_($recv(anObject)._type());
+$recv($3)._setupFromJson_(anObject);
+$4=$recv($3)._yourself();
+$2=$4;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromJson:",{anObject:anObject},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "fromJson: anObject\x0a\x09anObject ifNil: [ ^ self for: self defaultType ].\x0a\x09\x0a\x09^ (self for: anObject type)\x0a\x09\x09setupFromJson: anObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "for:", "defaultType", "setupFromJson:", "type", "yourself"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.PackageTransport.klass.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@registry"]=$globals.HashedCollection._newFromPairs_([]);
+self._register();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09registry := #{}.\x0a\x09self register",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "register"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "register",
+protocol: 'registration',
+fn: function (){
+var self=this;
+function $PackageTransport(){return $globals.PackageTransport||(typeof PackageTransport=="undefined"?nil:PackageTransport)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($PackageTransport())._register_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"register",{},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "register\x0a\x09PackageTransport register: self",
+referencedClasses: ["PackageTransport"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "register:",
+protocol: 'registration',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(aClass)._type();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["type"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$recv(self["@registry"])._at_put_($recv(aClass)._type(),aClass);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"register:",{aClass:aClass},$globals.PackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "register: aClass\x0a\x09aClass type ifNotNil: [\x0a\x09\x09registry at: aClass type put: aClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "type", "at:put:"]
+}),
+$globals.PackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "type",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return nil;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "type\x0a\x09\x22Override in subclasses\x22\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PackageTransport.klass);
+
+
+$core.addClass('AmdPackageTransport', $globals.PackageTransport, ['namespace'], 'Kernel-ImportExport');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.AmdPackageTransport.comment="I am the default transport for committing packages.\x0a\x0aSee `AmdExporter` and `AmdPackageHandler`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AmdPackageTransport.superclass.fn.prototype._asJSON.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv($2)._at_put_("amdNamespace",self._namespace());
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSON",{},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ super asJSON\x0a\x09\x09at: 'amdNamespace' put: self namespace;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "asJSON", "namespace", "yourself"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "commitHandlerClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $AmdPackageHandler(){return $globals.AmdPackageHandler||(typeof AmdPackageHandler=="undefined"?nil:AmdPackageHandler)}
+return $AmdPackageHandler();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commitHandlerClass\x0a\x09^ AmdPackageHandler",
+referencedClasses: ["AmdPackageHandler"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "defaultNamespace",
+protocol: 'defaults',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._defaultAmdNamespace();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultNamespace",{},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultNamespace\x0a\x09^ Smalltalk defaultAmdNamespace",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["defaultAmdNamespace"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($recv(self._class())._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(" namespace: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$3=$recv("'".__comma(self._namespace())).__comma("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$2=$recv(stream)._nextPutAll_($3);
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"definition",{},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream \x0a\x09\x09\x09nextPutAll: self class name;\x0a\x09\x09\x09nextPutAll: ' namespace: ';\x0a\x09\x09\x09nextPutAll: '''', self namespace, '''' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", "name", "class", ",", "namespace"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "namespace",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@namespace"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._defaultNamespace();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"namespace",{},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "namespace\x0a\x09^ namespace ifNil: [ self defaultNamespace ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "defaultNamespace"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "namespace:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@namespace"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "namespace: aString\x0a\x09namespace := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.AmdPackageTransport.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aStream)._nextPutAll_(" (AMD Namespace: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._namespace());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09aStream\x0a\x09\x09nextPutAll: ' (AMD Namespace: ';\x0a\x09\x09nextPutAll: self namespace;\x0a\x09\x09nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "namespace"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "setPath:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(require)._basicAt_("config"))._value_($globals.HashedCollection._newFromPairs_(["paths",$globals.HashedCollection._newFromPairs_([self._namespace(),aString])]));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setPath:",{aString:aString},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "setPath: aString\x0a\x09\x22Set the path the the receiver's `namespace`\x22\x0a\x09\x0a\x09(require basicAt: 'config') value: #{\x0a\x09\x09'paths' -> #{\x0a\x09\x09\x09self namespace -> aString\x0a\x09\x09}\x0a\x09}.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:", "basicAt:", "namespace"]
+}),
+$globals.AmdPackageTransport);
+
+$core.addMethod(
+$core.method({
+selector: "setupFromJson:",
+protocol: 'initialization',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._namespace_($recv(anObject)._at_("amdNamespace"));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setupFromJson:",{anObject:anObject},$globals.AmdPackageTransport)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "setupFromJson: anObject\x0a\x09self namespace: (anObject at: 'amdNamespace')",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["namespace:", "at:"]
+}),
+$globals.AmdPackageTransport);
+
+
+$core.addMethod(
+$core.method({
+selector: "namespace:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._namespace_(aString);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"namespace:",{aString:aString},$globals.AmdPackageTransport.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "namespace: aString\x0a\x09^ self new\x0a\x09\x09namespace: aString;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["namespace:", "new", "yourself"]
+}),
+$globals.AmdPackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "type",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "amd";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "type\x0a\x09^ 'amd'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.AmdPackageTransport.klass);
+
+$core.addMethod(
+$core.method({
+selector: "commit",
+protocol: '*Kernel-ImportExport',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._transport())._commit();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commit",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "commit\x0a\x09^ self transport commit",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commit", "transport"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "load",
+protocol: '*Kernel-ImportExport',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._transport())._load();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "load\x0a\x09^ self transport load",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["load", "transport"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "loadFromNamespace:",
+protocol: '*Kernel-ImportExport',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._transport();
+$recv($2)._namespace_(aString);
+$3=$recv($2)._load();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"loadFromNamespace:",{aString:aString},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "loadFromNamespace: aString\x0a\x09^ self transport\x0a\x09\x09namespace: aString;\x0a\x09\x09load",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["namespace:", "transport", "load"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "load:",
+protocol: '*Kernel-ImportExport',
+fn: function (aPackageName){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._named_(aPackageName))._load();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load:",{aPackageName:aPackageName},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName"],
+source: "load: aPackageName\x0a\x09(self named: aPackageName) load",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["load", "named:"]
+}),
+$globals.Package.klass);
+
+$core.addMethod(
+$core.method({
+selector: "load:fromNamespace:",
+protocol: '*Kernel-ImportExport',
+fn: function (aPackageName,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._named_(aPackageName))._loadFromNamespace_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"load:fromNamespace:",{aPackageName:aPackageName,aString:aString},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName", "aString"],
+source: "load: aPackageName fromNamespace: aString\x0a\x09(self named: aPackageName) loadFromNamespace: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["loadFromNamespace:", "named:"]
+}),
+$globals.Package.klass);
+
+});

+ 954 - 0
bower_components/amber/src/Kernel-ImportExport.st

@@ -0,0 +1,954 @@
+Smalltalk createPackage: 'Kernel-ImportExport'!
+Object subclass: #AbstractExporter
+	instanceVariableNames: ''
+	package: 'Kernel-ImportExport'!
+!AbstractExporter commentStamp!
+I am an abstract exporter for Amber source code.
+
+## API
+
+Use `#exportPackage:on:` to export a given package on a Stream.!
+
+!AbstractExporter methodsFor: 'accessing'!
+
+extensionMethodsOfPackage: aPackage
+	| result |
+	
+	result := OrderedCollection new.
+	
+	(self extensionProtocolsOfPackage: aPackage) do: [ :each |
+		result addAll: each methods ].
+		
+	^ result
+!
+
+extensionProtocolsOfPackage: aPackage
+	| extensionName result |
+	
+	extensionName := '*', aPackage name.
+	result := OrderedCollection new.
+	
+	"The classes must be loaded since it is extensions only.
+	Therefore topological sorting (dependency resolution) does not matter here.
+	Not sorting topologically improves the speed by a number of magnitude.
+	
+	Not to shuffle diffs, classes are sorted by their name."
+	
+	(Smalltalk classes asArray sorted: [ :a :b | a name < b name ]) do: [ :each |
+		{each. each class} do: [ :behavior |
+			(behavior protocols includes: extensionName) ifTrue: [
+				result add: (ExportMethodProtocol name: extensionName theClass: behavior) ] ] ].
+
+	^ result
+! !
+
+!AbstractExporter methodsFor: 'convenience'!
+
+chunkEscape: aString
+	"Replace all occurrences of !! with !!!! and trim at both ends."
+
+	^ (aString replace: '!!' with: '!!!!') trimBoth
+!
+
+classNameFor: aClass
+	^ aClass isMetaclass
+		ifTrue: [ aClass instanceClass name, ' class' ]
+		ifFalse: [
+			aClass isNil
+				ifTrue: [ 'nil' ]
+				ifFalse: [ aClass name ] ]
+! !
+
+!AbstractExporter methodsFor: 'output'!
+
+exportPackage: aPackage on: aStream
+	self subclassResponsibility
+! !
+
+AbstractExporter subclass: #ChunkExporter
+	instanceVariableNames: ''
+	package: 'Kernel-ImportExport'!
+!ChunkExporter commentStamp!
+I am an exporter dedicated to outputting Amber source code in the classic Smalltalk chunk format.
+
+I do not output any compiled code.!
+
+!ChunkExporter methodsFor: 'accessing'!
+
+extensionCategoriesOfPackage: aPackage
+	"Issue #143: sort protocol alphabetically"
+
+	| name map result |
+	name := aPackage name.
+	result := OrderedCollection new.
+	(Package sortedClasses: Smalltalk classes) do: [ :each |
+		{each. each class} do: [ :aClass |
+			map := Dictionary new.
+			aClass protocolsDo: [ :category :methods |
+				category = ('*', name) ifTrue: [ map at: category put: methods ] ].
+			result addAll: ((map keys sorted: [ :a :b | a <= b ]) collect: [ :category |
+				MethodCategory name: category theClass: aClass methods: (map at: category) ]) ] ].
+	^ result
+!
+
+ownCategoriesOfClass: aClass
+	"Answer the protocols of aClass that are not package extensions"
+	
+	"Issue #143: sort protocol alphabetically"
+
+	| map |
+	map := Dictionary new.
+	aClass protocolsDo: [ :each :methods |
+		(each match: '^\*') ifFalse: [ map at: each put: methods ] ].
+	^ (map keys sorted: [ :a :b | a <= b ]) collect: [ :each |
+		MethodCategory name: each theClass: aClass methods: (map at: each) ]
+!
+
+ownCategoriesOfMetaClass: aClass
+	"Issue #143: sort protocol alphabetically"
+
+	^ self ownCategoriesOfClass: aClass class
+!
+
+ownMethodProtocolsOfClass: aClass
+	"Answer a collection of ExportMethodProtocol object of aClass that are not package extensions"
+	
+	^ aClass ownProtocols collect: [ :each |
+		ExportMethodProtocol name: each theClass: aClass ]
+! !
+
+!ChunkExporter methodsFor: 'output'!
+
+exportCategoryEpilogueOf: aCategory on: aStream
+	aStream nextPutAll: ' !!'; lf; lf
+!
+
+exportCategoryPrologueOf: aCategory on: aStream
+	aStream
+		nextPutAll: '!!', (self classNameFor: aCategory theClass);
+		nextPutAll: ' methodsFor: ''', aCategory name, '''!!'
+!
+
+exportDefinitionOf: aClass on: aStream
+	"Chunk format."
+
+	aStream
+		nextPutAll: (self classNameFor: aClass superclass);
+		nextPutAll: ' subclass: #', (self classNameFor: aClass); lf;
+		tab; nextPutAll: 'instanceVariableNames: '''.
+	aClass instanceVariableNames
+		do: [ :each | aStream nextPutAll: each ]
+		separatedBy: [ aStream nextPutAll: ' ' ].
+	aStream
+		nextPutAll: ''''; lf;
+		tab; nextPutAll: 'package: ''', aClass category, '''!!'; lf.
+	aClass comment notEmpty ifTrue: [
+		aStream
+		nextPutAll: '!!', (self classNameFor: aClass), ' commentStamp!!';lf;
+		nextPutAll: (self chunkEscape: aClass comment), '!!';lf ].
+	aStream lf
+!
+
+exportMetaDefinitionOf: aClass on: aStream
+
+	aClass class instanceVariableNames isEmpty ifFalse: [
+		aStream
+			nextPutAll: (self classNameFor: aClass class);
+			nextPutAll: ' instanceVariableNames: '''.
+		aClass class instanceVariableNames
+			do: [ :each | aStream nextPutAll: each ]
+			separatedBy: [ aStream nextPutAll: ' ' ].
+		aStream
+			nextPutAll: '''!!'; lf; lf ]
+!
+
+exportMethod: aMethod on: aStream
+	aStream
+		lf; lf; nextPutAll: (self chunkEscape: aMethod source); lf;
+		nextPutAll: '!!'
+!
+
+exportPackage: aPackage on: aStream
+
+	self exportPackageDefinitionOf: aPackage on: aStream.
+	
+	aPackage sortedClasses do: [ :each |
+		self exportDefinitionOf: each on: aStream.
+		
+		self 
+			exportProtocols: (self ownMethodProtocolsOfClass: each)
+			on: aStream.
+			
+		self exportMetaDefinitionOf: each on: aStream.
+		
+		self 
+			exportProtocols: (self ownMethodProtocolsOfClass: each class)
+			on: aStream ].
+			
+	self 
+		exportProtocols: (self extensionProtocolsOfPackage: aPackage)
+		on: aStream
+!
+
+exportPackageDefinitionOf: aPackage on: aStream
+	aStream
+		nextPutAll: 'Smalltalk createPackage: ''', aPackage name, '''!!';
+		lf
+!
+
+exportProtocol: aProtocol on: aStream
+	self exportProtocolPrologueOf: aProtocol on: aStream.
+	aProtocol methods do: [ :method | 
+		self exportMethod: method on: aStream ].
+	self exportProtocolEpilogueOf: aProtocol on: aStream
+!
+
+exportProtocolEpilogueOf: aProtocol on: aStream
+	aStream nextPutAll: ' !!'; lf; lf
+!
+
+exportProtocolPrologueOf: aProtocol on: aStream
+	aStream
+		nextPutAll: '!!', (self classNameFor: aProtocol theClass);
+		nextPutAll: ' methodsFor: ''', aProtocol name, '''!!'
+!
+
+exportProtocols: aCollection on: aStream
+	aCollection do: [ :each |
+		self exportProtocol: each on: aStream ]
+! !
+
+AbstractExporter subclass: #Exporter
+	instanceVariableNames: ''
+	package: 'Kernel-ImportExport'!
+!Exporter commentStamp!
+I am responsible for outputting Amber code into a JavaScript string.
+
+The generated output is enough to reconstruct the exported data, including Smalltalk source code and other metadata.
+
+## Use case
+
+I am typically used to save code outside of the Amber runtime (committing to disk, etc.).!
+
+!Exporter methodsFor: 'accessing'!
+
+ownMethodsOfClass: aClass
+	"Issue #143: sort methods alphabetically"
+
+	^ ((aClass methodDictionary values) sorted: [ :a :b | a selector <= b selector ])
+		reject: [ :each | (each protocol match: '^\*') ]
+!
+
+ownMethodsOfMetaClass: aClass
+	"Issue #143: sort methods alphabetically"
+
+	^ self ownMethodsOfClass: aClass class
+! !
+
+!Exporter methodsFor: 'convenience'!
+
+jsClassNameFor: aClass
+	^ aClass isMetaclass
+		ifTrue: [ (self jsClassNameFor: aClass instanceClass), '.klass' ]
+		ifFalse: [
+			aClass
+				ifNil: [ 'null' ]
+				ifNotNil: [ '$globals.', aClass name ] ]
+! !
+
+!Exporter methodsFor: 'output'!
+
+exportDefinitionOf: aClass on: aStream
+	aStream
+		lf;
+		nextPutAll: '$core.addClass(';
+		nextPutAll: '''', (self classNameFor: aClass), ''', ';
+		nextPutAll: (self jsClassNameFor: aClass superclass);
+		nextPutAll: ', ['.
+	aClass instanceVariableNames
+		do: [ :each | aStream nextPutAll: '''', each, '''' ]
+		separatedBy: [ aStream nextPutAll: ', ' ].
+	aStream
+		nextPutAll: '], ''';
+		nextPutAll: aClass category, '''';
+		nextPutAll: ');'.
+	aClass comment notEmpty ifTrue: [
+		aStream
+			lf;
+			nextPutAll: '//>>excludeStart("ide", pragmas.excludeIdeData);';
+			lf;
+			nextPutAll: (self jsClassNameFor: aClass);
+			nextPutAll: '.comment=';
+			nextPutAll: aClass comment crlfSanitized asJavascript;
+			nextPutAll: ';';
+			lf;
+			nextPutAll: '//>>excludeEnd("ide");' ].
+	aStream lf
+!
+
+exportMetaDefinitionOf: aClass on: aStream
+	aStream lf.
+	aClass class instanceVariableNames isEmpty ifFalse: [
+		aStream
+		nextPutAll: (self jsClassNameFor: aClass class);
+		nextPutAll: '.iVarNames = ['.
+		aClass class instanceVariableNames
+		do: [ :each | aStream nextPutAll: '''', each, '''' ]
+		separatedBy: [ aStream nextPutAll: ',' ].
+		aStream nextPutAll: '];', String lf ]
+!
+
+exportMethod: aMethod on: aStream
+	aStream
+		nextPutAll: '$core.addMethod(';lf;
+		nextPutAll: '$core.method({';lf;
+		nextPutAll: 'selector: ', aMethod selector asJavascript, ',';lf;
+		nextPutAll: 'protocol: ''', aMethod protocol, ''',';lf;
+		nextPutAll: 'fn: ', aMethod fn compiledSource, ',';lf;
+		nextPutAll: '//>>excludeStart("ide", pragmas.excludeIdeData);';lf;
+		nextPutAll: 'args: ', aMethod arguments asJavascript, ','; lf;
+		nextPutAll: 'source: ', aMethod source asJavascript, ',';lf;
+		nextPutAll: 'referencedClasses: ', aMethod referencedClasses asJavascript, ',';lf;
+		nextPutAll: '//>>excludeEnd("ide");';lf;
+		nextPutAll: 'messageSends: ', aMethod messageSends asJavascript;lf;
+		nextPutAll: '}),';lf;
+		nextPutAll: (self jsClassNameFor: aMethod methodClass);
+		nextPutAll: ');';lf;lf
+!
+
+exportPackage: aPackage on: aStream
+	
+	self 
+		exportPackagePrologueOf: aPackage on: aStream;
+		exportPackageDefinitionOf: aPackage on: aStream;
+		exportPackageTransportOf: aPackage on: aStream.
+	
+	aPackage sortedClasses do: [ :each |
+		self exportDefinitionOf: each on: aStream.
+		each ownMethods do: [ :method |
+			self exportMethod: method on: aStream ].
+			
+		self exportMetaDefinitionOf: each on: aStream.
+		each class ownMethods do: [ :method |
+			self exportMethod: method on: aStream ] ].
+			
+	(self extensionMethodsOfPackage: aPackage) do: [ :each |
+		self exportMethod: each on: aStream ].
+		
+	self exportPackageEpilogueOf: aPackage on: aStream
+!
+
+exportPackageDefinitionOf: aPackage on: aStream
+	aStream
+		nextPutAll: '$core.addPackage(';
+		nextPutAll: '''', aPackage name, ''');';
+		lf
+!
+
+exportPackageEpilogueOf: aPackage on: aStream
+	aStream
+		nextPutAll: '})(global_smalltalk,global_nil,global__st);';
+		lf
+!
+
+exportPackagePrologueOf: aPackage on: aStream
+	aStream
+		nextPutAll: '(function(smalltalk,nil,_st){';
+		lf
+!
+
+exportPackageTransportOf: aPackage on: aStream
+	aStream
+		nextPutAll: '$core.packages[';
+		nextPutAll: aPackage name asJavascript;
+		nextPutAll: '].transport = ';
+		nextPutAll: aPackage transport asJSONString;
+		nextPutAll: ';';
+		lf
+! !
+
+Exporter subclass: #AmdExporter
+	instanceVariableNames: 'namespace'
+	package: 'Kernel-ImportExport'!
+!AmdExporter commentStamp!
+I am used to export Packages in an AMD (Asynchronous Module Definition) JavaScript format.!
+
+!AmdExporter methodsFor: 'output'!
+
+exportPackageEpilogueOf: aPackage on: aStream
+	aStream
+		nextPutAll: '});';
+		lf
+!
+
+exportPackagePrologueOf: aPackage on: aStream
+	aStream
+		nextPutAll: 'define("';
+		nextPutAll: (self amdNamespaceOfPackage: aPackage);
+		nextPutAll: '/';
+		nextPutAll: aPackage name;
+		nextPutAll: '", ';
+		nextPutAll: (#('amber/boot'), (self amdNamesOfPackages: aPackage loadDependencies)) asJavascript;
+		nextPutAll: ', function($boot){';
+		lf;
+		nextPutAll: 'var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;';
+		lf;
+		nextPutAll: 'var smalltalk=$core,_st=$recv,globals=$globals;';
+		lf
+! !
+
+!AmdExporter methodsFor: 'private'!
+
+amdNamesOfPackages: anArray
+	^ (anArray
+		select: [ :each | (self amdNamespaceOfPackage: each) notNil ])
+		collect: [ :each | (self amdNamespaceOfPackage: each), '/', each name ]
+!
+
+amdNamespaceOfPackage: aPackage
+	^ (aPackage transport type = 'amd')
+		ifTrue: [ aPackage transport namespace ]
+		ifFalse: [ nil ]
+! !
+
+Object subclass: #ChunkParser
+	instanceVariableNames: 'stream last'
+	package: 'Kernel-ImportExport'!
+!ChunkParser commentStamp!
+I am responsible for parsing aStream contents in the chunk format.
+
+## API
+
+    ChunkParser new
+        stream: aStream;
+        nextChunk!
+
+!ChunkParser methodsFor: 'accessing'!
+
+last
+	^ last
+!
+
+stream: aStream
+	stream := aStream
+! !
+
+!ChunkParser methodsFor: 'reading'!
+
+nextChunk
+	"The chunk format (Smalltalk Interchange Format or Fileout format)
+	is a trivial format but can be a bit tricky to understand:
+		- Uses the exclamation mark as delimiter of chunks.
+		- Inside a chunk a normal exclamation mark must be doubled.
+		- A non empty chunk must be a valid Smalltalk expression.
+		- A chunk on top level with a preceding empty chunk is an instruction chunk:
+			- The object created by the expression then takes over reading chunks.
+
+	This method returns next chunk as a String (trimmed), empty String (all whitespace) or nil."
+
+	| char result chunk |
+	result := '' writeStream.
+		[ char := stream next.
+		char notNil ] whileTrue: [
+				char = '!!' ifTrue: [
+						stream peek = '!!'
+								ifTrue: [ stream next "skipping the escape double" ]
+								ifFalse: [ ^ last := result contents trimBoth "chunk end marker found" ]].
+				result nextPut: char ].
+	^ last := nil "a chunk needs to end with !!"
+! !
+
+!ChunkParser class methodsFor: 'instance creation'!
+
+on: aStream
+	^ self new stream: aStream
+! !
+
+Object subclass: #ExportMethodProtocol
+	instanceVariableNames: 'name theClass'
+	package: 'Kernel-ImportExport'!
+!ExportMethodProtocol commentStamp!
+I am an abstraction for a method protocol in a class / metaclass.
+
+I know of my class, name and methods.
+I am used when exporting a package.!
+
+!ExportMethodProtocol methodsFor: 'accessing'!
+
+methods
+	^ (self theClass methodsInProtocol: self name)
+		sorted: [ :a :b | a selector <= b selector ]
+!
+
+name
+	^ name
+!
+
+name: aString
+	name := aString
+!
+
+theClass
+	^ theClass
+!
+
+theClass: aClass
+	theClass := aClass
+! !
+
+!ExportMethodProtocol class methodsFor: 'instance creation'!
+
+name: aString theClass: aClass
+	^ self new
+		name: aString;
+		theClass: aClass;
+		yourself
+! !
+
+Object subclass: #Importer
+	instanceVariableNames: 'lastSection lastChunk'
+	package: 'Kernel-ImportExport'!
+!Importer commentStamp!
+I can import Amber code from a string in the chunk format.
+
+## API
+
+    Importer new import: aString!
+
+!Importer methodsFor: 'accessing'!
+
+lastChunk
+	^ lastChunk
+!
+
+lastSection
+	^ lastSection
+! !
+
+!Importer methodsFor: 'fileIn'!
+
+import: aStream
+	| chunk result parser lastEmpty |
+	parser := ChunkParser on: aStream.
+	lastEmpty := false.
+	lastSection := 'n/a, not started'.
+	lastChunk := nil.
+	[
+	[ chunk := parser nextChunk.
+	chunk isNil ] whileFalse: [
+		chunk isEmpty
+			ifTrue: [ lastEmpty := true ]
+			ifFalse: [
+				lastSection := chunk.
+				result := Compiler new evaluateExpression: chunk.
+				lastEmpty
+						ifTrue: [
+									lastEmpty := false.
+									result scanFrom: parser ]] ].
+	lastSection := 'n/a, finished'
+	] on: Error do: [:e | lastChunk := parser last. e signal ].
+! !
+
+InterfacingObject subclass: #PackageHandler
+	instanceVariableNames: ''
+	package: 'Kernel-ImportExport'!
+!PackageHandler commentStamp!
+I am responsible for handling package loading and committing.
+
+I should not be used directly. Instead, use the corresponding `Package` methods.!
+
+!PackageHandler methodsFor: 'accessing'!
+
+chunkContentsFor: aPackage
+	^ String streamContents: [ :str |
+		self chunkExporter exportPackage: aPackage on: str ]
+!
+
+chunkExporterClass
+	^ ChunkExporter
+!
+
+commitPathJsFor: aPackage
+	self subclassResponsibility
+!
+
+commitPathStFor: aPackage
+	self subclassResponsibility
+!
+
+contentsFor: aPackage
+	^ String streamContents: [ :str |
+		self exporter exportPackage: aPackage on: str ]
+!
+
+exporterClass
+	^ Exporter
+! !
+
+!PackageHandler methodsFor: 'committing'!
+
+commit: aPackage
+	self 
+		commit: aPackage
+		onSuccess: []
+		onError: [ :error |
+			PackageCommitError new
+				messageText: 'Commiting failed with reason: "' , (error responseText) , '"';
+				signal ]
+!
+
+commit: aPackage onSuccess: aBlock onError: anotherBlock
+	self 
+		commitJsFileFor: aPackage 
+		onSuccess: [
+			self 
+				commitStFileFor: aPackage 
+				onSuccess: [ aPackage beClean. aBlock value ]
+				onError: anotherBlock ] 
+		onError: anotherBlock
+!
+
+commitJsFileFor: aPackage onSuccess: aBlock onError: anotherBlock
+	self 
+		ajaxPutAt: (self commitPathJsFor: aPackage), '/', aPackage name, '.js'
+		data: (self contentsFor: aPackage)
+		onSuccess: aBlock
+		onError: anotherBlock
+!
+
+commitStFileFor: aPackage onSuccess: aBlock onError: anotherBlock
+	self 
+		ajaxPutAt: (self commitPathStFor: aPackage), '/', aPackage name, '.st'
+		data: (self chunkContentsFor: aPackage)
+		onSuccess: aBlock
+		onError: anotherBlock
+! !
+
+!PackageHandler methodsFor: 'error handling'!
+
+onCommitError: anError
+	PackageCommitError new
+		messageText: 'Commiting failed with reason: "' , (anError responseText) , '"';
+		signal
+! !
+
+!PackageHandler methodsFor: 'factory'!
+
+chunkExporter
+	^ self chunkExporterClass new
+!
+
+exporter
+	^ self exporterClass new
+! !
+
+!PackageHandler methodsFor: 'loading'!
+
+load: aPackage
+	self subclassResponsibility
+! !
+
+!PackageHandler methodsFor: 'private'!
+
+ajaxPutAt: aURL data: aString onSuccess: aBlock onError: anotherBlock
+	self
+		ajax: #{
+			'url' -> aURL.
+			'type' -> 'PUT'.
+			'data' -> aString.
+			'contentType' -> 'text/plain;charset=UTF-8'.
+			'success' -> aBlock.
+			'error' -> anotherBlock
+		}
+! !
+
+PackageHandler subclass: #AmdPackageHandler
+	instanceVariableNames: ''
+	package: 'Kernel-ImportExport'!
+!AmdPackageHandler commentStamp!
+I am responsible for handling package loading and committing.
+
+I should not be used directly. Instead, use the corresponding `Package` methods.!
+
+!AmdPackageHandler methodsFor: 'accessing'!
+
+commitPathJsFor: aPackage
+	^ self toUrl: (self namespaceFor: aPackage)
+!
+
+commitPathStFor: aPackage
+	"If _source is not mapped, .st will be committed to .js path.
+	It is recommended not to use _source as it can be deprecated."
+	
+	| path pathWithout |
+	path := self toUrl: (self namespaceFor: aPackage), '/_source'.
+	pathWithout := self commitPathJsFor: aPackage.
+	^ path = (pathWithout, '/_source') ifTrue: [ pathWithout ] ifFalse: [ path ]
+!
+
+exporterClass
+	^ AmdExporter
+! !
+
+!AmdPackageHandler methodsFor: 'committing'!
+
+namespaceFor: aPackage
+	^ aPackage transport namespace
+! !
+
+!AmdPackageHandler methodsFor: 'loading'!
+
+load: aPackage
+	Smalltalk amdRequire
+		ifNil: [ self error: 'AMD loader not present' ]
+		ifNotNil: [ :require |
+			require value: (Array with: (self namespaceFor: aPackage), '/', aPackage name ) ]
+! !
+
+!AmdPackageHandler methodsFor: 'private'!
+
+toUrl: aString
+	^ Smalltalk amdRequire
+		ifNil: [ self error: 'AMD loader not present' ]
+		ifNotNil: [ :require | (require basicAt: 'toUrl') value: aString ]
+! !
+
+!AmdPackageHandler class methodsFor: 'commit paths'!
+
+defaultNamespace
+	^ Smalltalk defaultAmdNamespace
+!
+
+defaultNamespace: aString
+	Smalltalk defaultAmdNamespace: aString
+! !
+
+Object subclass: #PackageTransport
+	instanceVariableNames: 'package'
+	package: 'Kernel-ImportExport'!
+!PackageTransport commentStamp!
+I represent the transport mechanism used to commit a package.
+
+My concrete subclasses have a `#handler` to which committing is delegated.!
+
+!PackageTransport methodsFor: 'accessing'!
+
+commitHandlerClass
+	self subclassResponsibility
+!
+
+definition
+	^ ''
+!
+
+package
+	^ package
+!
+
+package: aPackage
+	package := aPackage
+!
+
+type
+	^ self class type
+! !
+
+!PackageTransport methodsFor: 'committing'!
+
+commit
+	self commitHandler commit: self package
+!
+
+commitOnSuccess: aBlock onError: anotherBlock
+	self commitHandler 
+		commit: self package
+		onSuccess: aBlock
+		onError: anotherBlock
+! !
+
+!PackageTransport methodsFor: 'converting'!
+
+asJSON
+	^ #{ 'type' -> self type }
+! !
+
+!PackageTransport methodsFor: 'factory'!
+
+commitHandler
+	^ self commitHandlerClass new
+! !
+
+!PackageTransport methodsFor: 'initialization'!
+
+setupFromJson: anObject
+	"no op. override if needed in subclasses"
+! !
+
+!PackageTransport methodsFor: 'loading'!
+
+load
+	self commitHandler load: self package
+! !
+
+PackageTransport class instanceVariableNames: 'registry'!
+
+!PackageTransport class methodsFor: 'accessing'!
+
+classRegisteredFor: aString
+	^ registry at: aString
+!
+
+defaultType
+	^ AmdPackageTransport type
+!
+
+type
+	"Override in subclasses"
+	^ nil
+! !
+
+!PackageTransport class methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	registry := #{}.
+	self register
+! !
+
+!PackageTransport class methodsFor: 'instance creation'!
+
+for: aString
+	^ (self classRegisteredFor: aString) new
+!
+
+fromJson: anObject
+	anObject ifNil: [ ^ self for: self defaultType ].
+	
+	^ (self for: anObject type)
+		setupFromJson: anObject;
+		yourself
+! !
+
+!PackageTransport class methodsFor: 'registration'!
+
+register
+	PackageTransport register: self
+!
+
+register: aClass
+	aClass type ifNotNil: [
+		registry at: aClass type put: aClass ]
+! !
+
+PackageTransport subclass: #AmdPackageTransport
+	instanceVariableNames: 'namespace'
+	package: 'Kernel-ImportExport'!
+!AmdPackageTransport commentStamp!
+I am the default transport for committing packages.
+
+See `AmdExporter` and `AmdPackageHandler`.!
+
+!AmdPackageTransport methodsFor: 'accessing'!
+
+commitHandlerClass
+	^ AmdPackageHandler
+!
+
+definition
+	^ String streamContents: [ :stream |
+		stream 
+			nextPutAll: self class name;
+			nextPutAll: ' namespace: ';
+			nextPutAll: '''', self namespace, '''' ]
+!
+
+namespace
+	^ namespace ifNil: [ self defaultNamespace ]
+!
+
+namespace: aString
+	namespace := aString
+! !
+
+!AmdPackageTransport methodsFor: 'actions'!
+
+setPath: aString
+	"Set the path the the receiver's `namespace`"
+	
+	(require basicAt: 'config') value: #{
+		'paths' -> #{
+			self namespace -> aString
+		}
+	}.
+! !
+
+!AmdPackageTransport methodsFor: 'converting'!
+
+asJSON
+	^ super asJSON
+		at: 'amdNamespace' put: self namespace;
+		yourself
+! !
+
+!AmdPackageTransport methodsFor: 'defaults'!
+
+defaultNamespace
+	^ Smalltalk defaultAmdNamespace
+! !
+
+!AmdPackageTransport methodsFor: 'initialization'!
+
+setupFromJson: anObject
+	self namespace: (anObject at: 'amdNamespace')
+! !
+
+!AmdPackageTransport methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	aStream
+		nextPutAll: ' (AMD Namespace: ';
+		nextPutAll: self namespace;
+		nextPutAll: ')'
+! !
+
+!AmdPackageTransport class methodsFor: 'accessing'!
+
+type
+	^ 'amd'
+! !
+
+!AmdPackageTransport class methodsFor: 'instance creation'!
+
+namespace: aString
+	^ self new
+		namespace: aString;
+		yourself
+! !
+
+!Package methodsFor: '*Kernel-ImportExport'!
+
+commit
+	^ self transport commit
+!
+
+load
+	^ self transport load
+!
+
+loadFromNamespace: aString
+	^ self transport
+		namespace: aString;
+		load
+! !
+
+!Package class methodsFor: '*Kernel-ImportExport'!
+
+load: aPackageName
+	(self named: aPackageName) load
+!
+
+load: aPackageName fromNamespace: aString
+	(self named: aPackageName) loadFromNamespace: aString
+! !
+

+ 5408 - 0
bower_components/amber/src/Kernel-Infrastructure.js

@@ -0,0 +1,5408 @@
+define("amber_core/Kernel-Infrastructure", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Collections"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Infrastructure');
+$core.packages["Kernel-Infrastructure"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ConsoleErrorHandler', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ConsoleErrorHandler.comment="I am manage Smalltalk errors, displaying the stack in the console.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "handleError:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(anError)._context();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+self._logErrorContext_($recv(anError)._context());
+};
+self._logError_(anError);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"handleError:",{anError:anError},$globals.ConsoleErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "handleError: anError\x0a\x09anError context ifNotNil: [ self logErrorContext: anError context ].\x0a\x09self logError: anError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "context", "logErrorContext:", "logError:"]
+}),
+$globals.ConsoleErrorHandler);
+
+$core.addMethod(
+$core.method({
+selector: "log:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(console)._log_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"log:",{aString:aString},$globals.ConsoleErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "log: aString\x0a\x09console log: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["log:"]
+}),
+$globals.ConsoleErrorHandler);
+
+$core.addMethod(
+$core.method({
+selector: "logContext:",
+protocol: 'private',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(aContext)._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+self._logContext_($recv(aContext)._home());
+};
+self._log_($recv(aContext)._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"logContext:",{aContext:aContext},$globals.ConsoleErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "logContext: aContext\x0a\x09aContext home ifNotNil: [\x0a\x09\x09self logContext: aContext home ].\x0a\x09self log: aContext asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "home", "logContext:", "log:", "asString"]
+}),
+$globals.ConsoleErrorHandler);
+
+$core.addMethod(
+$core.method({
+selector: "logError:",
+protocol: 'private',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._log_($recv(anError)._messageText());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"logError:",{anError:anError},$globals.ConsoleErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "logError: anError\x0a\x09self log: anError messageText",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["log:", "messageText"]
+}),
+$globals.ConsoleErrorHandler);
+
+$core.addMethod(
+$core.method({
+selector: "logErrorContext:",
+protocol: 'private',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+if(($receiver = aContext) == null || $receiver.isNil){
+aContext;
+} else {
+$1=$recv(aContext)._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+self._logContext_($recv(aContext)._home());
+};
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"logErrorContext:",{aContext:aContext},$globals.ConsoleErrorHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "logErrorContext: aContext\x0a\x09aContext ifNotNil: [\x0a\x09\x09aContext home ifNotNil: [\x0a\x09\x09\x09self logContext: aContext home ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "home", "logContext:"]
+}),
+$globals.ConsoleErrorHandler);
+
+
+$globals.ConsoleErrorHandler.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $ErrorHandler(){return $globals.ErrorHandler||(typeof ErrorHandler=="undefined"?nil:ErrorHandler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ErrorHandler())._registerIfNone_(self._new());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ConsoleErrorHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09ErrorHandler registerIfNone: self new",
+referencedClasses: ["ErrorHandler"],
+//>>excludeEnd("ide");
+messageSends: ["registerIfNone:", "new"]
+}),
+$globals.ConsoleErrorHandler.klass);
+
+
+$core.addClass('InterfacingObject', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.InterfacingObject.comment="I am superclass of all object that interface with user or environment. `Widget` and a few other classes are subclasses of me. I delegate all of the above APIs to `PlatformInterface`.\x0a\x0a## API\x0a\x0a    self alert: 'Hey, there is a problem'.\x0a    self confirm: 'Affirmative?'.\x0a    self prompt: 'Your name:'.\x0a\x0a    self ajax: #{\x0a        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'\x0a    }.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "ajax:",
+protocol: 'actions',
+fn: function (anObject){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._ajax_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ajax:",{anObject:anObject},$globals.InterfacingObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "ajax: anObject\x0a\x09^ PlatformInterface ajax: anObject",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["ajax:"]
+}),
+$globals.InterfacingObject);
+
+$core.addMethod(
+$core.method({
+selector: "alert:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._alert_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alert:",{aString:aString},$globals.InterfacingObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "alert: aString\x0a\x09^ PlatformInterface alert: aString",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["alert:"]
+}),
+$globals.InterfacingObject);
+
+$core.addMethod(
+$core.method({
+selector: "confirm:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._confirm_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"confirm:",{aString:aString},$globals.InterfacingObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "confirm: aString\x0a\x09^ PlatformInterface confirm: aString",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["confirm:"]
+}),
+$globals.InterfacingObject);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._prompt_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:",{aString:aString},$globals.InterfacingObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "prompt: aString\x0a\x09^ PlatformInterface prompt: aString",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["prompt:"]
+}),
+$globals.InterfacingObject);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:default:",
+protocol: 'actions',
+fn: function (aString,defaultString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._prompt_default_(aString,defaultString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:default:",{aString:aString,defaultString:defaultString},$globals.InterfacingObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "defaultString"],
+source: "prompt: aString default: defaultString\x0a\x09^ PlatformInterface prompt: aString default: defaultString",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["prompt:default:"]
+}),
+$globals.InterfacingObject);
+
+
+
+$core.addClass('Environment', $globals.InterfacingObject, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Environment.comment="I provide an unified entry point to manipulate Amber packages, classes and methods.\x0a\x0aTypical use cases include IDEs, remote access and restricting browsing.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addInstVarNamed:to:",
+protocol: 'compiling',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4,$5;
+$1=self._classBuilder();
+$2=$recv(aClass)._superclass();
+$3=$recv(aClass)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($recv(aClass)._instanceVariableNames())._copy();
+$recv($4)._add_(aString);
+$5=$recv($4)._yourself();
+$recv($1)._addSubclassOf_named_instanceVariableNames_package_($2,$3,$5,$recv($recv(aClass)._package())._name());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addInstVarNamed:to:",{aString:aString,aClass:aClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "addInstVarNamed: aString to: aClass\x0a\x09self classBuilder\x0a\x09\x09addSubclassOf: aClass superclass \x0a\x09\x09named: aClass name \x0a\x09\x09instanceVariableNames: (aClass instanceVariableNames copy add: aString; yourself)\x0a\x09\x09package: aClass package name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "classBuilder", "superclass", "name", "add:", "copy", "instanceVariableNames", "yourself", "package"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "allSelectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Smalltalk())._core())._allSelectors();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allSelectors",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allSelectors\x0a\x09^ Smalltalk core allSelectors",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["allSelectors", "core"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "availableClassNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Smalltalk())._classes())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"availableClassNames",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "availableClassNames\x0a\x09^ Smalltalk classes \x0a\x09\x09collect: [ :each | each name ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "classes", "name"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "availablePackageNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Smalltalk())._packages())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"availablePackageNames",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "availablePackageNames\x0a\x09^ Smalltalk packages \x0a\x09\x09collect: [ :each | each name ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "packages", "name"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "availableProtocolsFor:",
+protocol: 'accessing',
+fn: function (aClass){
+var self=this;
+var protocols;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+protocols=$recv(aClass)._protocols();
+$1=$recv(aClass)._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$recv(protocols)._addAll_(self._availableProtocolsFor_($recv(aClass)._superclass()));
+};
+$2=$recv($recv($recv(protocols)._asSet())._asArray())._sort();
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"availableProtocolsFor:",{aClass:aClass,protocols:protocols},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "availableProtocolsFor: aClass\x0a\x09| protocols |\x0a\x09\x0a\x09protocols := aClass protocols.\x0a\x09aClass superclass ifNotNil: [ protocols addAll: (self availableProtocolsFor: aClass superclass) ].\x0a\x09^ protocols asSet asArray sort",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["protocols", "ifNotNil:", "superclass", "addAll:", "availableProtocolsFor:", "sort", "asArray", "asSet"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "classBuilder",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($ClassBuilder())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classBuilder",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classBuilder\x0a\x09^ ClassBuilder new",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "classNamed:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=$recv($recv($Smalltalk())._globals())._at_($recv(aString)._asSymbol());
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("Invalid class name");
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classNamed:",{aString:aString},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "classNamed: aString\x0a\x09^ (Smalltalk globals at: aString asSymbol)\x0a\x09\x09ifNil: [ self error: 'Invalid class name' ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "at:", "globals", "asSymbol", "error:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "classes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._classes();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classes",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classes\x0a\x09^ Smalltalk classes",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["classes"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "commitPackage:onSuccess:onError:",
+protocol: 'actions',
+fn: function (aPackage,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aPackage)._transport())._commitOnSuccess_onError_(aBlock,anotherBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"commitPackage:onSuccess:onError:",{aPackage:aPackage,aBlock:aBlock,anotherBlock:anotherBlock},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aBlock", "anotherBlock"],
+source: "commitPackage: aPackage onSuccess: aBlock onError: anotherBlock\x0a\x09aPackage transport\x0a\x09\x09commitOnSuccess: aBlock\x0a\x09\x09onError: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["commitOnSuccess:onError:", "transport"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "compileClassComment:for:",
+protocol: 'compiling',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aClass)._comment_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileClassComment:for:",{aString:aString,aClass:aClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "compileClassComment: aString for: aClass\x0a\x09aClass comment: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["comment:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "compileClassDefinition:",
+protocol: 'compiling',
+fn: function (aString){
+var self=this;
+function $DoIt(){return $globals.DoIt||(typeof DoIt=="undefined"?nil:DoIt)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._evaluate_for_(aString,$recv($DoIt())._new());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(error){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._alert_($recv(error)._messageText());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({error:error},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileClassDefinition:",{aString:aString},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "compileClassDefinition: aString\x0a\x09[ self evaluate: aString for: DoIt new ]\x0a\x09\x09on: Error\x0a\x09\x09do: [ :error | self alert: error messageText ]",
+referencedClasses: ["DoIt", "Error"],
+//>>excludeEnd("ide");
+messageSends: ["on:do:", "evaluate:for:", "new", "alert:", "messageText"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "compileMethod:for:protocol:",
+protocol: 'compiling',
+fn: function (sourceCode,class_,protocol){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(class_)._compile_protocol_(sourceCode,protocol);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compileMethod:for:protocol:",{sourceCode:sourceCode,class_:class_,protocol:protocol},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["sourceCode", "class", "protocol"],
+source: "compileMethod: sourceCode for: class protocol: protocol\x0a\x09^ class\x0a\x09\x09compile: sourceCode\x0a\x09\x09protocol: protocol",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["compile:protocol:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "copyClass:to:",
+protocol: 'actions',
+fn: function (aClass,aClassName){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=$recv($recv($Smalltalk())._globals())._at_(aClassName);
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$2=$recv("A class named ".__comma(aClassName)).__comma(" already exists");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._error_($2);
+};
+$recv($recv($ClassBuilder())._new())._copyClass_named_(aClass,aClassName);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copyClass:to:",{aClass:aClass,aClassName:aClassName},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aClassName"],
+source: "copyClass: aClass to: aClassName\x0a\x09(Smalltalk globals at: aClassName)\x0a\x09\x09ifNotNil: [ self error: 'A class named ', aClassName, ' already exists' ].\x0a\x09\x09\x0a\x09ClassBuilder new copyClass: aClass named: aClassName",
+referencedClasses: ["Smalltalk", "ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "at:", "globals", "error:", ",", "copyClass:named:", "new"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "doItReceiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $DoIt(){return $globals.DoIt||(typeof DoIt=="undefined"?nil:DoIt)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($DoIt())._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"doItReceiver",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "doItReceiver\x0a\x09^ DoIt new",
+referencedClasses: ["DoIt"],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:for:",
+protocol: 'evaluating',
+fn: function (aString,anObject){
+var self=this;
+function $Evaluator(){return $globals.Evaluator||(typeof Evaluator=="undefined"?nil:Evaluator)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Evaluator())._evaluate_for_(aString,anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:for:",{aString:aString,anObject:anObject},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "evaluate: aString for: anObject\x0a\x09^ Evaluator evaluate: aString for: anObject",
+referencedClasses: ["Evaluator"],
+//>>excludeEnd("ide");
+messageSends: ["evaluate:for:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:on:do:",
+protocol: 'error handling',
+fn: function (aBlock,anErrorClass,exceptionBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(aBlock)._tryCatch_((function(exception){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(exception)._isKindOf_(self._classNamed_($recv(anErrorClass)._name()));
+if($core.assert($1)){
+return $recv(exceptionBlock)._value_(exception);
+} else {
+return $recv(exception)._signal();
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({exception:exception},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:on:do:",{aBlock:aBlock,anErrorClass:anErrorClass,exceptionBlock:exceptionBlock},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anErrorClass", "exceptionBlock"],
+source: "evaluate: aBlock on: anErrorClass do: exceptionBlock\x0a\x09\x22Evaluate a block and catch exceptions happening on the environment stack\x22\x0a\x09\x0a\x09aBlock tryCatch: [ :exception | \x0a\x09\x09(exception isKindOf: (self classNamed: anErrorClass name))\x0a\x09\x09\x09ifTrue: [ exceptionBlock value: exception ]\x0a \x09\x09\x09ifFalse: [ exception signal ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tryCatch:", "ifTrue:ifFalse:", "isKindOf:", "classNamed:", "name", "value:", "signal"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "inspect:",
+protocol: 'actions',
+fn: function (anObject){
+var self=this;
+function $Inspector(){return $globals.Inspector||(typeof Inspector=="undefined"?nil:Inspector)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Inspector())._inspect_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "inspect: anObject\x0a\x09Inspector inspect: anObject",
+referencedClasses: ["Inspector"],
+//>>excludeEnd("ide");
+messageSends: ["inspect:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "moveClass:toPackage:",
+protocol: 'actions',
+fn: function (aClass,aPackageName){
+var self=this;
+var package_;
+function $Package(){return $globals.Package||(typeof Package=="undefined"?nil:Package)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+package_=$recv($Package())._named_(aPackageName);
+$1=package_;
+if(($receiver = $1) == null || $receiver.isNil){
+self._error_("Invalid package name");
+} else {
+$1;
+};
+$2=$recv(package_).__eq_eq($recv(aClass)._package());
+if($core.assert($2)){
+return self;
+};
+$recv(aClass)._package_(package_);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"moveClass:toPackage:",{aClass:aClass,aPackageName:aPackageName,package_:package_},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aPackageName"],
+source: "moveClass: aClass toPackage: aPackageName\x0a\x09| package |\x0a\x09\x0a\x09package := Package named: aPackageName.\x0a\x09package ifNil: [ self error: 'Invalid package name' ].\x0a\x09package == aClass package ifTrue: [ ^ self ].\x0a\x09\x0a\x09aClass package: package",
+referencedClasses: ["Package"],
+//>>excludeEnd("ide");
+messageSends: ["named:", "ifNil:", "error:", "ifTrue:", "==", "package", "package:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "moveMethod:toClass:",
+protocol: 'actions',
+fn: function (aMethod,aClassName){
+var self=this;
+var destinationClass;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1,$5,$4;
+destinationClass=self._classNamed_(aClassName);
+$2=destinationClass;
+$3=$recv(aMethod)._methodClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodClass"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq_eq($3);
+if($core.assert($1)){
+return self;
+};
+$5=$recv(aMethod)._methodClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodClass"]=2;
+//>>excludeEnd("ctx");
+$4=$recv($5)._isMetaclass();
+if($core.assert($4)){
+destinationClass=$recv(destinationClass)._class();
+destinationClass;
+};
+$recv(destinationClass)._compile_protocol_($recv(aMethod)._source(),$recv(aMethod)._protocol());
+$recv($recv(aMethod)._methodClass())._removeCompiledMethod_(aMethod);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"moveMethod:toClass:",{aMethod:aMethod,aClassName:aClassName,destinationClass:destinationClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aClassName"],
+source: "moveMethod: aMethod toClass: aClassName\x0a\x09| destinationClass |\x0a\x09\x0a\x09destinationClass := self classNamed: aClassName.\x0a\x09destinationClass == aMethod methodClass ifTrue: [ ^ self ].\x0a\x09\x0a\x09aMethod methodClass isMetaclass ifTrue: [ \x0a\x09\x09destinationClass := destinationClass class ].\x0a\x09\x0a\x09destinationClass \x0a\x09\x09compile: aMethod source\x0a\x09\x09protocol: aMethod protocol.\x0a\x09aMethod methodClass \x0a\x09\x09removeCompiledMethod: aMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["classNamed:", "ifTrue:", "==", "methodClass", "isMetaclass", "class", "compile:protocol:", "source", "protocol", "removeCompiledMethod:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "moveMethod:toProtocol:",
+protocol: 'actions',
+fn: function (aMethod,aProtocol){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aMethod)._protocol_(aProtocol);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"moveMethod:toProtocol:",{aMethod:aMethod,aProtocol:aProtocol},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod", "aProtocol"],
+source: "moveMethod: aMethod toProtocol: aProtocol\x0a\x09aMethod protocol: aProtocol",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["protocol:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "packages",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._packages();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"packages",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "packages\x0a\x09^ Smalltalk packages",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["packages"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "registerErrorHandler:",
+protocol: 'services',
+fn: function (anErrorHandler){
+var self=this;
+function $ErrorHandler(){return $globals.ErrorHandler||(typeof ErrorHandler=="undefined"?nil:ErrorHandler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ErrorHandler())._register_(anErrorHandler);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerErrorHandler:",{anErrorHandler:anErrorHandler},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anErrorHandler"],
+source: "registerErrorHandler: anErrorHandler\x0a\x09ErrorHandler register: anErrorHandler",
+referencedClasses: ["ErrorHandler"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "registerFinder:",
+protocol: 'services',
+fn: function (aFinder){
+var self=this;
+function $Finder(){return $globals.Finder||(typeof Finder=="undefined"?nil:Finder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Finder())._register_(aFinder);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerFinder:",{aFinder:aFinder},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aFinder"],
+source: "registerFinder: aFinder\x0a\x09Finder register: aFinder",
+referencedClasses: ["Finder"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "registerInspector:",
+protocol: 'services',
+fn: function (anInspector){
+var self=this;
+function $Inspector(){return $globals.Inspector||(typeof Inspector=="undefined"?nil:Inspector)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Inspector())._register_(anInspector);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerInspector:",{anInspector:anInspector},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInspector"],
+source: "registerInspector: anInspector\x0a\x09Inspector register: anInspector",
+referencedClasses: ["Inspector"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "registerProgressHandler:",
+protocol: 'services',
+fn: function (aProgressHandler){
+var self=this;
+function $ProgressHandler(){return $globals.ProgressHandler||(typeof ProgressHandler=="undefined"?nil:ProgressHandler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ProgressHandler())._register_(aProgressHandler);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerProgressHandler:",{aProgressHandler:aProgressHandler},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aProgressHandler"],
+source: "registerProgressHandler: aProgressHandler\x0a\x09ProgressHandler register: aProgressHandler",
+referencedClasses: ["ProgressHandler"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "registerTranscript:",
+protocol: 'services',
+fn: function (aTranscript){
+var self=this;
+function $Transcript(){return $globals.Transcript||(typeof Transcript=="undefined"?nil:Transcript)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Transcript())._register_(aTranscript);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerTranscript:",{aTranscript:aTranscript},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTranscript"],
+source: "registerTranscript: aTranscript\x0a\x09Transcript register: aTranscript",
+referencedClasses: ["Transcript"],
+//>>excludeEnd("ide");
+messageSends: ["register:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "removeClass:",
+protocol: 'actions',
+fn: function (aClass){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Smalltalk())._removeClass_(aClass);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeClass:",{aClass:aClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "removeClass: aClass\x0a\x09Smalltalk removeClass: aClass",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["removeClass:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "removeMethod:",
+protocol: 'actions',
+fn: function (aMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aMethod)._methodClass())._removeCompiledMethod_(aMethod);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeMethod:",{aMethod:aMethod},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMethod"],
+source: "removeMethod: aMethod\x0a\x09aMethod methodClass removeCompiledMethod: aMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["removeCompiledMethod:", "methodClass"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "removeProtocol:from:",
+protocol: 'actions',
+fn: function (aString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aClass)._methodsInProtocol_(aString))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aClass)._removeCompiledMethod_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeProtocol:from:",{aString:aString,aClass:aClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aClass"],
+source: "removeProtocol: aString from: aClass\x0a\x09(aClass methodsInProtocol: aString)\x0a\x09\x09do: [ :each | aClass removeCompiledMethod: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "methodsInProtocol:", "removeCompiledMethod:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "renameClass:to:",
+protocol: 'actions',
+fn: function (aClass,aClassName){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+$1=$recv($recv($Smalltalk())._globals())._at_(aClassName);
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$2=$recv("A class named ".__comma(aClassName)).__comma(" already exists");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+self._error_($2);
+};
+$recv($recv($ClassBuilder())._new())._renameClass_to_(aClass,aClassName);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"renameClass:to:",{aClass:aClass,aClassName:aClassName},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aClassName"],
+source: "renameClass: aClass to: aClassName\x0a\x09(Smalltalk globals at: aClassName)\x0a\x09\x09ifNotNil: [ self error: 'A class named ', aClassName, ' already exists' ].\x0a\x09\x09\x0a\x09ClassBuilder new renameClass: aClass to: aClassName",
+referencedClasses: ["Smalltalk", "ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "at:", "globals", "error:", ",", "renameClass:to:", "new"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "renameProtocol:to:in:",
+protocol: 'actions',
+fn: function (aString,anotherString,aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(aClass)._methodsInProtocol_(aString))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._protocol_(anotherString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"renameProtocol:to:in:",{aString:aString,anotherString:anotherString,aClass:aClass},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString", "aClass"],
+source: "renameProtocol: aString to: anotherString in: aClass\x0a\x09(aClass methodsInProtocol: aString)\x0a\x09\x09do: [ :each | each protocol: anotherString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "methodsInProtocol:", "protocol:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "setClassCommentOf:to:",
+protocol: 'actions',
+fn: function (aClass,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aClass)._comment_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setClassCommentOf:to:",{aClass:aClass,aString:aString},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass", "aString"],
+source: "setClassCommentOf: aClass to: aString\x0a\x09aClass comment: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["comment:"]
+}),
+$globals.Environment);
+
+$core.addMethod(
+$core.method({
+selector: "systemAnnouncer",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv($Smalltalk())._globals())._at_("SystemAnnouncer"))._current();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"systemAnnouncer",{},$globals.Environment)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "systemAnnouncer\x0a\x09^ (Smalltalk globals at: #SystemAnnouncer) current",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["current", "at:", "globals"]
+}),
+$globals.Environment);
+
+
+
+$core.addClass('JSObjectProxy', $globals.ProtoObject, ['jsObject'], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.JSObjectProxy.comment="I handle sending messages to JavaScript objects, making  JavaScript object accessing from Amber fully transparent.\x0aMy instances make intensive use of `#doesNotUnderstand:`.\x0a\x0aMy instances are automatically created by Amber whenever a message is sent to a JavaScript object.\x0a\x0a## Usage examples\x0a\x0aJSObjectProxy objects are instanciated by Amber when a Smalltalk message is sent to a JavaScript object.\x0a\x0a\x09window alert: 'hello world'.\x0a\x09window inspect.\x0a\x09(window jQuery: 'body') append: 'hello world'\x0a\x0aAmber messages sends are converted to JavaScript function calls or object property access _(in this order)_. If n one of them match, a `MessageNotUnderstood` error will be thrown.\x0a\x0a## Message conversion rules\x0a\x0a- `someUser name` becomes `someUser.name`\x0a- `someUser name: 'John'` becomes `someUser name = \x22John\x22`\x0a- `console log: 'hello world'` becomes `console.log('hello world')`\x0a- `(window jQuery: 'foo') css: 'background' color: 'red'` becomes `window.jQuery('foo').css('background', 'red')`\x0a\x0a__Note:__ For keyword-based messages, only the first keyword is kept: `window foo: 1 bar: 2` is equivalent to `window foo: 1 baz: 2`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$3;
+$2=$recv(anObject)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq_eq(self._class());
+if(!$core.assert($1)){
+return false;
+};
+$3=self._compareJSObjectWith_($recv(anObject)._jsObject());
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{anObject:anObject},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "= anObject\x0a\x09anObject class == self class ifFalse: [ ^ false ].\x0a\x09^ self compareJSObjectWith: anObject jsObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "==", "class", "compareJSObjectWith:", "jsObject"]
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "addObjectVariablesTo:",
+protocol: 'proxy',
+fn: function (aDictionary){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		for(var i in self['@jsObject']) {
+			aDictionary._at_put_(i, self['@jsObject'][i]);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addObjectVariablesTo:",{aDictionary:aDictionary},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDictionary"],
+source: "addObjectVariablesTo: aDictionary\x0a\x09<\x0a\x09\x09for(var i in self['@jsObject']) {\x0a\x09\x09\x09aDictionary._at_put_(i, self['@jsObject'][i]);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'enumerating',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@jsObject"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09\x22Answers the receiver in a stringyfy-friendly fashion\x22\x0a\x0a\x09^ jsObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "at:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self['@jsObject'][aString];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:",{aString:aString},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "at: aString\x0a\x09<return self['@jsObject'][aString]>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (aString,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var obj = self['@jsObject'];
+		return aString in obj ? obj[aString] : aBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aString:aString,aBlock:aBlock},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock"],
+source: "at: aString ifAbsent: aBlock\x0a\x09\x22return the aString property or evaluate aBlock if the property is not defined on the object\x22\x0a\x09<\x0a\x09\x09var obj = self['@jsObject'];\x0a\x09\x09return aString in obj ? obj[aString] : aBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:",
+protocol: 'accessing',
+fn: function (aString,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var obj = self['@jsObject'];
+		return aString in obj ? aBlock._value_(obj[aString]) : nil;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:",{aString:aString,aBlock:aBlock},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock"],
+source: "at: aString ifPresent: aBlock\x0a\x09\x22return the evaluation of aBlock with the value if the property is defined or return nil\x22\x0a\x09<\x0a\x09\x09var obj = self['@jsObject'];\x0a\x09\x09return aString in obj ? aBlock._value_(obj[aString]) : nil;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifPresent:ifAbsent:",
+protocol: 'accessing',
+fn: function (aString,aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var obj = self['@jsObject'];
+		return aString in obj ? aBlock._value_(obj[aString]) : anotherBlock._value();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifPresent:ifAbsent:",{aString:aString,aBlock:aBlock,anotherBlock:anotherBlock},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock", "anotherBlock"],
+source: "at: aString ifPresent: aBlock ifAbsent: anotherBlock\x0a\x09\x22return the evaluation of aBlock with the value if the property is defined\x0a\x09or return value of anotherBlock\x22\x0a\x09<\x0a\x09\x09var obj = self['@jsObject'];\x0a\x09\x09return aString in obj ? aBlock._value_(obj[aString]) : anotherBlock._value();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self['@jsObject'][aString] = anObject;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{aString:aString,anObject:anObject},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "at: aString put: anObject\x0a\x09<return self['@jsObject'][aString] = anObject>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "compareJSObjectWith:",
+protocol: 'private',
+fn: function (aJSObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self["@jsObject"] === aJSObject;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compareJSObjectWith:",{aJSObject:aJSObject},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJSObject"],
+source: "compareJSObjectWith: aJSObject\x0a \x09<return self[\x22@jsObject\x22] === aJSObject>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "doesNotUnderstand:",
+protocol: 'proxy',
+fn: function (aMessage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._lookupProperty_($recv($recv(aMessage)._selector())._asJavaScriptPropertyName());
+if(($receiver = $2) == null || $receiver.isNil){
+$1=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.JSObjectProxy.superclass.fn.prototype._doesNotUnderstand_.apply($recv(self), [aMessage]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+} else {
+var jsSelector;
+jsSelector=$receiver;
+$1=self._forwardMessage_withArguments_(jsSelector,$recv(aMessage)._arguments());
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"doesNotUnderstand:",{aMessage:aMessage},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMessage"],
+source: "doesNotUnderstand: aMessage\x0a\x09^ (self lookupProperty: aMessage selector asJavaScriptPropertyName)\x0a\x09\x09ifNil: [ super doesNotUnderstand: aMessage ]\x0a\x09\x09ifNotNil: [ :jsSelector | \x0a\x09\x09\x09self \x0a\x09\x09\x09\x09forwardMessage: jsSelector \x0a\x09\x09\x09\x09withArguments: aMessage arguments ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "lookupProperty:", "asJavaScriptPropertyName", "selector", "doesNotUnderstand:", "forwardMessage:withArguments:", "arguments"]
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "forwardMessage:withArguments:",
+protocol: 'proxy',
+fn: function (aString,anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return $core.accessJavaScript(self._jsObject(), aString, anArray);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"forwardMessage:withArguments:",{aString:aString,anArray:anArray},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anArray"],
+source: "forwardMessage: aString withArguments: anArray\x0a\x09<\x0a\x09\x09return $core.accessJavaScript(self._jsObject(), aString, anArray);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "inspectOn:",
+protocol: 'proxy',
+fn: function (anInspector){
+var self=this;
+var variables;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+variables=$recv($Dictionary())._new();
+$recv(variables)._at_put_("#self",self._jsObject());
+$recv(anInspector)._setLabel_(self._printString());
+self._addObjectVariablesTo_(variables);
+$recv(anInspector)._setVariables_(variables);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspectOn:",{anInspector:anInspector,variables:variables},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInspector"],
+source: "inspectOn: anInspector\x0a\x09| variables |\x0a\x09variables := Dictionary new.\x0a\x09variables at: '#self' put: self jsObject.\x0a\x09anInspector setLabel: self printString.\x0a\x09self addObjectVariablesTo: variables.\x0a\x09anInspector setVariables: variables",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["new", "at:put:", "jsObject", "setLabel:", "printString", "addObjectVariablesTo:", "setVariables:"]
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "jsObject",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@jsObject"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "jsObject\x0a\x09^ jsObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "jsObject:",
+protocol: 'accessing',
+fn: function (aJSObject){
+var self=this;
+self["@jsObject"]=aJSObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJSObject"],
+source: "jsObject: aJSObject\x0a\x09jsObject := aJSObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "keysAndValuesDo:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var o = self['@jsObject'];
+		for(var i in o) {
+			aBlock._value_value_(i, o[i]);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"keysAndValuesDo:",{aBlock:aBlock},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "keysAndValuesDo: aBlock\x0a\x09<\x0a\x09\x09var o = self['@jsObject'];\x0a\x09\x09for(var i in o) {\x0a\x09\x09\x09aBlock._value_value_(i, o[i]);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "lookupProperty:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return aString in self._jsObject() ? aString : nil;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"lookupProperty:",{aString:aString},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "lookupProperty: aString\x0a\x09\x22Looks up a property in JS object.\x0a\x09Answer the property if it is present, or nil if it is not present.\x22\x0a\x09\x0a\x09<return aString in self._jsObject() ? aString : nil>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._printString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: self printString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "printString"]
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "printString",
+protocol: 'printing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var js = self['@jsObject'];
+		return js.toString
+			? js.toString()
+			: Object.prototype.toString.call(js)
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printString",{},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "printString\x0a\x09<\x0a\x09\x09var js = self['@jsObject'];\x0a\x09\x09return js.toString\x0a\x09\x09\x09? js.toString()\x0a\x09\x09\x09: Object.prototype.toString.call(js)\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aJSObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._jsObject_(aJSObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aJSObject:aJSObject},$globals.JSObjectProxy.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJSObject"],
+source: "on: aJSObject\x0a\x09^ self new\x0a\x09\x09jsObject: aJSObject;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["jsObject:", "new", "yourself"]
+}),
+$globals.JSObjectProxy.klass);
+
+
+$core.addClass('NullProgressHandler', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.NullProgressHandler.comment="I am the default progress handler. I do not display any progress, and simply iterate over the collection.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "do:on:displaying:",
+protocol: 'progress handling',
+fn: function (aBlock,aCollection,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aCollection)._do_(aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:on:displaying:",{aBlock:aBlock,aCollection:aCollection,aString:aString},$globals.NullProgressHandler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "aCollection", "aString"],
+source: "do: aBlock on: aCollection displaying: aString\x0a\x09aCollection do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:"]
+}),
+$globals.NullProgressHandler);
+
+
+$globals.NullProgressHandler.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $ProgressHandler(){return $globals.ProgressHandler||(typeof ProgressHandler=="undefined"?nil:ProgressHandler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ProgressHandler())._registerIfNone_(self._new());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.NullProgressHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09ProgressHandler registerIfNone: self new",
+referencedClasses: ["ProgressHandler"],
+//>>excludeEnd("ide");
+messageSends: ["registerIfNone:", "new"]
+}),
+$globals.NullProgressHandler.klass);
+
+
+$core.addClass('Organizer', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Organizer.comment="I represent categorization information. \x0a\x0a## API\x0a\x0aUse `#addElement:` and `#removeElement:` to manipulate instances.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addElement:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.elements.addElement(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addElement:",{anObject:anObject},$globals.Organizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "addElement: anObject\x0a\x09<self.elements.addElement(anObject)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Organizer);
+
+$core.addMethod(
+$core.method({
+selector: "elements",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._basicAt_("elements"))._copy();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"elements",{},$globals.Organizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "elements\x0a\x09^ (self basicAt: 'elements') copy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copy", "basicAt:"]
+}),
+$globals.Organizer);
+
+$core.addMethod(
+$core.method({
+selector: "removeElement:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.elements.removeElement(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeElement:",{anObject:anObject},$globals.Organizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "removeElement: anObject\x0a\x09<self.elements.removeElement(anObject)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Organizer);
+
+
+
+$core.addClass('ClassOrganizer', $globals.Organizer, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ClassOrganizer.comment="I am an organizer specific to classes. I hold method categorization information for classes.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addElement:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ProtocolAdded(){return $globals.ProtocolAdded||(typeof ProtocolAdded=="undefined"?nil:ProtocolAdded)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ClassOrganizer.superclass.fn.prototype._addElement_.apply($recv(self), [aString]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($ProtocolAdded())._new();
+$recv($1)._protocol_(aString);
+$recv($1)._theClass_(self._theClass());
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addElement:",{aString:aString},$globals.ClassOrganizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "addElement: aString\x0a\x09super addElement: aString.\x0a\x0a\x09SystemAnnouncer current announce: (ProtocolAdded new\x0a\x09\x09protocol: aString;\x0a\x09\x09theClass: self theClass;\x0a\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ProtocolAdded"],
+//>>excludeEnd("ide");
+messageSends: ["addElement:", "announce:", "current", "protocol:", "new", "theClass:", "theClass", "yourself"]
+}),
+$globals.ClassOrganizer);
+
+$core.addMethod(
+$core.method({
+selector: "removeElement:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ProtocolRemoved(){return $globals.ProtocolRemoved||(typeof ProtocolRemoved=="undefined"?nil:ProtocolRemoved)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ClassOrganizer.superclass.fn.prototype._removeElement_.apply($recv(self), [aString]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($ProtocolRemoved())._new();
+$recv($1)._protocol_(aString);
+$recv($1)._theClass_(self._theClass());
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeElement:",{aString:aString},$globals.ClassOrganizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "removeElement: aString\x0a\x09super removeElement: aString.\x0a\x0a\x09SystemAnnouncer current announce: (ProtocolRemoved new\x0a\x09\x09protocol: aString;\x0a\x09\x09theClass: self theClass;\x0a\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ProtocolRemoved"],
+//>>excludeEnd("ide");
+messageSends: ["removeElement:", "announce:", "current", "protocol:", "new", "theClass:", "theClass", "yourself"]
+}),
+$globals.ClassOrganizer);
+
+$core.addMethod(
+$core.method({
+selector: "theClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return self.theClass ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"theClass",{},$globals.ClassOrganizer)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theClass\x0a\x09< return self.theClass >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ClassOrganizer);
+
+
+
+$core.addClass('PackageOrganizer', $globals.Organizer, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageOrganizer.comment="I am an organizer specific to packages. I hold classes categorization information.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('Package', $globals.Object, ['transport', 'dirty'], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Package.comment="I am similar to a \x22class category\x22 typically found in other Smalltalks like Pharo or Squeak. Amber does not have class categories anymore, it had in the beginning but now each class in the system knows which package it belongs to.\x0a\x0aEach package has a name and can be queried for its classes, but it will then resort to a reverse scan of all classes to find them.\x0a\x0a## API\x0a\x0aPackages are manipulated through \x22Smalltalk current\x22, like for example finding one based on a name or with `Package class >> #name` directly:\x0a\x0a    Smalltalk current packageAt: 'Kernel'\x0a    Package named: 'Kernel'\x0a\x0aA package differs slightly from a Monticello package which can span multiple class categories using a naming convention based on hyphenation. But just as in Monticello a package supports \x22class extensions\x22 so a package can define behaviors in foreign classes using a naming convention for method categories where the category starts with an asterisk and then the name of the owning package follows.\x0a\x0aYou can fetch a package from the server:\x0a\x0a\x09Package load: 'Additional-Examples'";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "basicName:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.pkgName = aString;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicName:",{aString:aString},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicName: aString\x0a\x09<self.pkgName = aString>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "basicTransport",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.transport;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicTransport",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "basicTransport\x0a\x09\x22Answer the transport literal JavaScript object as setup in the JavaScript file, if any\x22\x0a\x09\x0a\x09<return self.transport>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "beClean",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $PackageClean(){return $globals.PackageClean||(typeof PackageClean=="undefined"?nil:PackageClean)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self["@dirty"]=false;
+$1=$recv($PackageClean())._new();
+$recv($1)._package_(self);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beClean",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "beClean\x0a\x09dirty := false.\x0a\x09\x0a\x09SystemAnnouncer current announce: (PackageClean new\x0a\x09\x09package: self;\x0a\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "PackageClean"],
+//>>excludeEnd("ide");
+messageSends: ["announce:", "current", "package:", "new", "yourself"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "beDirty",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $PackageDirty(){return $globals.PackageDirty||(typeof PackageDirty=="undefined"?nil:PackageDirty)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self["@dirty"]=true;
+$1=$recv($PackageDirty())._new();
+$recv($1)._package_(self);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"beDirty",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "beDirty\x0a\x09dirty := true.\x0a\x09\x0a\x09SystemAnnouncer current announce: (PackageDirty new\x0a\x09\x09package: self;\x0a\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "PackageDirty"],
+//>>excludeEnd("ide");
+messageSends: ["announce:", "current", "package:", "new", "yourself"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "classTemplate",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$4,$2,$5,$6,$7,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("Object");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(" subclass: #NameOfSubclass");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$5=$recv(stream)._nextPutAll_("instanceVariableNames: ''");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$5;
+$6=$recv("'".__comma($recv($String())._lf())).__comma($recv($String())._tab());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("package: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(self._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$7=$recv(stream)._nextPutAll_("'");
+return $7;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classTemplate",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classTemplate\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream\x0a\x09\x09\x09nextPutAll: 'Object';\x0a\x09\x09\x09nextPutAll: ' subclass: #NameOfSubclass';\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll: 'instanceVariableNames: '''''.\x0a\x09\x09stream\x0a\x09\x09\x09nextPutAll: '''', String lf, String tab;\x0a\x09\x09\x09nextPutAll: 'package: ''';\x0a\x09\x09\x09nextPutAll: self name;\x0a\x09\x09\x09nextPutAll: '''' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", ",", "lf", "tab", "name"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "classes",
+protocol: 'classes',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._organization())._elements();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classes",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classes\x0a\x09^ self organization elements",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["elements", "organization"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "definition",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$4,$5,$3,$7,$6,$8,$9,$1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(self._class())._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($3);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(" named: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$7="'".__comma(self._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$6=$recv($7).__comma("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$8=$recv($recv($String())._lf()).__comma($recv($String())._tab());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($8);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=5;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_(" transport: (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=6;
+//>>excludeEnd("ctx");
+$9=$recv(stream)._nextPutAll_($recv($recv(self._transport())._definition()).__comma(")"));
+return $9;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"definition",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "definition\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream \x0a\x09\x09\x09nextPutAll: self class name;\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll: ' named: ';\x0a\x09\x09\x09nextPutAll: '''', self name, '''';\x0a\x09\x09\x09nextPutAll: String lf, String tab;\x0a\x09\x09\x09nextPutAll:  ' transport: (';\x0a\x09\x09\x09nextPutAll: self transport definition, ')' ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "nextPutAll:", "name", "class", ",", "lf", "tab", "definition", "transport"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "isDirty",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@dirty"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=false;
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isDirty",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isDirty\x0a\x09^ dirty ifNil: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "isPackage",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isPackage\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "loadDependencies",
+protocol: 'dependencies',
+fn: function (){
+var self=this;
+var classes,packages;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+classes=self._loadDependencyClasses();
+$2=$recv($recv(classes)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._package();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._asSet();
+$recv($2)._remove_ifAbsent_(self,(function(){
+
+}));
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"loadDependencies",{classes:classes,packages:packages},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "loadDependencies\x0a\x09\x22Returns list of packages that need to be loaded\x0a\x09before loading this package.\x22\x0a\x09\x0a\x09| classes packages |\x0a\x09classes := self loadDependencyClasses.\x0a\x09^ (classes collect: [ :each | each package ]) asSet\x0a\x09\x09remove: self ifAbsent: [];\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["loadDependencyClasses", "remove:ifAbsent:", "asSet", "collect:", "package", "yourself"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "loadDependencyClasses",
+protocol: 'dependencies',
+fn: function (){
+var self=this;
+var starCategoryName;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$2,$6,$5,$7,$1;
+starCategoryName="*".__comma(self._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$4=self._classes();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["classes"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=$recv($3)._asSet();
+$recv($2)._remove_ifAbsent_(nil,(function(){
+
+}));
+$recv($2)._addAll_($recv($recv($Smalltalk())._classes())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$6=$recv(each)._protocols();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["protocols"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6).__comma($recv($recv(each)._class())._protocols());
+return $recv($5)._includes_(starCategoryName);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,3)});
+//>>excludeEnd("ctx");
+})));
+$7=$recv($2)._yourself();
+$1=$7;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"loadDependencyClasses",{starCategoryName:starCategoryName},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "loadDependencyClasses\x0a\x09\x22Returns classes needed at the time of loading a package.\x0a\x09These are all that are used to subclass\x0a\x09and to define an extension method\x22\x0a\x09\x0a\x09| starCategoryName |\x0a\x09starCategoryName := '*', self name.\x0a\x09^ (self classes collect: [ :each | each superclass ]) asSet\x0a\x09\x09remove: nil ifAbsent: [];\x0a\x09\x09addAll: (Smalltalk classes select: [ :each | each protocols, each class protocols includes: starCategoryName ]);\x0a\x09\x09yourself",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: [",", "name", "remove:ifAbsent:", "asSet", "collect:", "classes", "superclass", "addAll:", "select:", "includes:", "protocols", "class", "yourself"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "name",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.pkgName;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"name",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "name\x0a\x09<return self.pkgName>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "name:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicName_(aString);
+self._beDirty();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"name:",{aString:aString},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "name: aString\x0a\x09self basicName: aString.\x0a\x09self beDirty",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicName:", "beDirty"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "organization",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("organization");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"organization",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "organization\x0a\x09^ self basicAt: 'organization'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Package.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aStream)._nextPutAll_(" (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09aStream \x0a\x09\x09nextPutAll: ' (';\x0a\x09\x09nextPutAll: self name;\x0a\x09\x09nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "name"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "setupClasses",
+protocol: 'classes',
+fn: function (){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._classes();
+$recv($1)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv($ClassBuilder())._new())._setupClass_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($1)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._initialize();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setupClasses",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setupClasses\x0a\x09self classes\x0a\x09\x09do: [ :each | ClassBuilder new setupClass: each ];\x0a\x09\x09do: [ :each | each initialize ]",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["do:", "classes", "setupClass:", "new", "initialize"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "sortedClasses",
+protocol: 'classes',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._sortedClasses_(self._classes());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sortedClasses",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sortedClasses\x0a\x09\x22Answer all classes in the receiver, sorted by superclass/subclasses and by class name for common subclasses (Issue #143).\x22\x0a\x0a\x09^ self class sortedClasses: self classes",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sortedClasses:", "class", "classes"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "transport",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $PackageTransport(){return $globals.PackageTransport||(typeof PackageTransport=="undefined"?nil:PackageTransport)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$4,$1,$receiver;
+$2=self["@transport"];
+if(($receiver = $2) == null || $receiver.isNil){
+$3=$recv($PackageTransport())._fromJson_(self._basicTransport());
+$recv($3)._package_(self);
+$4=$recv($3)._yourself();
+self["@transport"]=$4;
+$1=self["@transport"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"transport",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "transport\x0a\x09^ transport ifNil: [ \x0a\x09\x09transport := (PackageTransport fromJson: self basicTransport)\x0a\x09\x09\x09package: self;\x0a\x09\x09\x09yourself ]",
+referencedClasses: ["PackageTransport"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "package:", "fromJson:", "basicTransport", "yourself"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "transport:",
+protocol: 'accessing',
+fn: function (aPackageTransport){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@transport"]=aPackageTransport;
+$recv(aPackageTransport)._package_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"transport:",{aPackageTransport:aPackageTransport},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageTransport"],
+source: "transport: aPackageTransport\x0a\x09transport := aPackageTransport.\x0a\x09aPackageTransport package: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["package:"]
+}),
+$globals.Package);
+
+
+$globals.Package.klass.iVarNames = ['defaultCommitPathJs','defaultCommitPathSt'];
+$core.addMethod(
+$core.method({
+selector: "named:",
+protocol: 'accessing',
+fn: function (aPackageName){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._packageAt_ifAbsent_(aPackageName,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($Smalltalk())._createPackage_(aPackageName);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"named:",{aPackageName:aPackageName},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName"],
+source: "named: aPackageName\x0a\x09^ Smalltalk \x0a\x09\x09packageAt: aPackageName\x0a\x09\x09ifAbsent: [ \x0a\x09\x09\x09Smalltalk createPackage: aPackageName ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["packageAt:ifAbsent:", "createPackage:"]
+}),
+$globals.Package.klass);
+
+$core.addMethod(
+$core.method({
+selector: "named:ifAbsent:",
+protocol: 'accessing',
+fn: function (aPackageName,aBlock){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Smalltalk())._packageAt_ifAbsent_(aPackageName,aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"named:ifAbsent:",{aPackageName:aPackageName,aBlock:aBlock},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName", "aBlock"],
+source: "named: aPackageName ifAbsent: aBlock\x0a\x09^ Smalltalk packageAt: aPackageName ifAbsent: aBlock",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["packageAt:ifAbsent:"]
+}),
+$globals.Package.klass);
+
+$core.addMethod(
+$core.method({
+selector: "named:transport:",
+protocol: 'accessing',
+fn: function (aPackageName,aTransport){
+var self=this;
+var package_;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+package_=self._named_(aPackageName);
+$recv(package_)._transport_(aTransport);
+$1=package_;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"named:transport:",{aPackageName:aPackageName,aTransport:aTransport,package_:package_},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName", "aTransport"],
+source: "named: aPackageName transport: aTransport\x0a\x09| package |\x0a\x09\x0a\x09package := self named: aPackageName.\x0a\x09package transport: aTransport.\x0a\x09\x0a\x09^ package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["named:", "transport:"]
+}),
+$globals.Package.klass);
+
+$core.addMethod(
+$core.method({
+selector: "sortedClasses:",
+protocol: 'sorting',
+fn: function (classes){
+var self=this;
+var children,others,nodes,expandedClasses;
+function $ClassSorterNode(){return $globals.ClassSorterNode||(typeof ClassSorterNode=="undefined"?nil:ClassSorterNode)}
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4;
+children=[];
+others=[];
+$recv(classes)._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(classes)._includes_($recv(each)._superclass());
+if($core.assert($1)){
+return $recv(others)._add_(each);
+} else {
+return $recv(children)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["do:"]=1;
+//>>excludeEnd("ctx");
+nodes=$recv(children)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($ClassSorterNode())._on_classes_level_(each,others,(0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+nodes=$recv(nodes)._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=$recv(a)._theClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["theClass"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+return $recv($2).__lt_eq($recv($recv(b)._theClass())._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,5)});
+//>>excludeEnd("ctx");
+}));
+expandedClasses=$recv($Array())._new();
+$recv(nodes)._do_((function(aNode){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aNode)._traverseClassesWith_(expandedClasses);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({aNode:aNode},$ctx1,6)});
+//>>excludeEnd("ctx");
+}));
+$4=expandedClasses;
+return $4;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sortedClasses:",{classes:classes,children:children,others:others,nodes:nodes,expandedClasses:expandedClasses},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["classes"],
+source: "sortedClasses: classes\x0a\x09\x22Answer classes, sorted by superclass/subclasses and by class name for common subclasses (Issue #143)\x22\x0a\x0a\x09| children others nodes expandedClasses |\x0a\x09children := #().\x0a\x09others := #().\x0a\x09classes do: [ :each |\x0a\x09\x09(classes includes: each superclass)\x0a\x09\x09\x09ifFalse: [ children add: each ]\x0a\x09\x09\x09ifTrue: [ others add: each ]].\x0a\x09nodes := children collect: [ :each |\x0a\x09\x09ClassSorterNode on: each classes: others level: 0 ].\x0a\x09nodes := nodes sorted: [ :a :b | a theClass name <= b theClass name ].\x0a\x09expandedClasses := Array new.\x0a\x09nodes do: [ :aNode |\x0a\x09\x09aNode traverseClassesWith: expandedClasses ].\x0a\x09^ expandedClasses",
+referencedClasses: ["ClassSorterNode", "Array"],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifFalse:ifTrue:", "includes:", "superclass", "add:", "collect:", "on:classes:level:", "sorted:", "<=", "name", "theClass", "new", "traverseClassesWith:"]
+}),
+$globals.Package.klass);
+
+
+$core.addClass('PackageStateObserver', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PackageStateObserver.comment="My current instance listens for any changes in the system that might affect the state of a package (being dirty).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "announcer",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($SystemAnnouncer())._current();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"announcer",{},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "announcer\x0a\x09^ SystemAnnouncer current",
+referencedClasses: ["SystemAnnouncer"],
+//>>excludeEnd("ide");
+messageSends: ["current"]
+}),
+$globals.PackageStateObserver);
+
+$core.addMethod(
+$core.method({
+selector: "observeSystem",
+protocol: 'actions',
+fn: function (){
+var self=this;
+function $PackageAdded(){return $globals.PackageAdded||(typeof PackageAdded=="undefined"?nil:PackageAdded)}
+function $ClassAnnouncement(){return $globals.ClassAnnouncement||(typeof ClassAnnouncement=="undefined"?nil:ClassAnnouncement)}
+function $MethodAnnouncement(){return $globals.MethodAnnouncement||(typeof MethodAnnouncement=="undefined"?nil:MethodAnnouncement)}
+function $ProtocolAnnouncement(){return $globals.ProtocolAnnouncement||(typeof ProtocolAnnouncement=="undefined"?nil:ProtocolAnnouncement)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._announcer();
+$recv($1)._on_send_to_($PackageAdded(),"onPackageAdded:",self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["on:send:to:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._on_send_to_($ClassAnnouncement(),"onClassModification:",self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["on:send:to:"]=2;
+//>>excludeEnd("ctx");
+$recv($1)._on_send_to_($MethodAnnouncement(),"onMethodModification:",self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["on:send:to:"]=3;
+//>>excludeEnd("ctx");
+$2=$recv($1)._on_send_to_($ProtocolAnnouncement(),"onProtocolModification:",self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"observeSystem",{},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "observeSystem\x0a\x09self announcer\x0a\x09\x09on: PackageAdded\x0a\x09\x09send: #onPackageAdded:\x0a\x09\x09to: self;\x0a\x09\x09\x0a\x09\x09on: ClassAnnouncement\x0a\x09\x09send: #onClassModification:\x0a\x09\x09to: self;\x0a\x09\x09\x0a\x09\x09on: MethodAnnouncement\x0a\x09\x09send: #onMethodModification:\x0a\x09\x09to: self;\x0a\x09\x09\x0a\x09\x09on: ProtocolAnnouncement\x0a\x09\x09send: #onProtocolModification:\x0a\x09\x09to: self",
+referencedClasses: ["PackageAdded", "ClassAnnouncement", "MethodAnnouncement", "ProtocolAnnouncement"],
+//>>excludeEnd("ide");
+messageSends: ["on:send:to:", "announcer"]
+}),
+$globals.PackageStateObserver);
+
+$core.addMethod(
+$core.method({
+selector: "onClassModification:",
+protocol: 'reactions',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(anAnnouncement)._theClass();
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+var theClass;
+theClass=$receiver;
+$recv($recv(theClass)._package())._beDirty();
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onClassModification:",{anAnnouncement:anAnnouncement},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "onClassModification: anAnnouncement\x0a\x09anAnnouncement theClass ifNotNil: [ :theClass | theClass package beDirty ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "theClass", "beDirty", "package"]
+}),
+$globals.PackageStateObserver);
+
+$core.addMethod(
+$core.method({
+selector: "onMethodModification:",
+protocol: 'reactions',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv($recv(anAnnouncement)._method())._package();
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+var package_;
+package_=$receiver;
+$recv(package_)._beDirty();
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMethodModification:",{anAnnouncement:anAnnouncement},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "onMethodModification: anAnnouncement\x0a\x09anAnnouncement method package ifNotNil: [ :package | package beDirty ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "package", "method", "beDirty"]
+}),
+$globals.PackageStateObserver);
+
+$core.addMethod(
+$core.method({
+selector: "onPackageAdded:",
+protocol: 'reactions',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv(anAnnouncement)._package())._beDirty();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onPackageAdded:",{anAnnouncement:anAnnouncement},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "onPackageAdded: anAnnouncement\x0a\x09anAnnouncement package beDirty",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["beDirty", "package"]
+}),
+$globals.PackageStateObserver);
+
+$core.addMethod(
+$core.method({
+selector: "onProtocolModification:",
+protocol: 'reactions',
+fn: function (anAnnouncement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=$recv(anAnnouncement)._package();
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+var package_;
+package_=$receiver;
+$recv(package_)._beDirty();
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onProtocolModification:",{anAnnouncement:anAnnouncement},$globals.PackageStateObserver)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anAnnouncement"],
+source: "onProtocolModification: anAnnouncement\x0a\x09anAnnouncement package ifNotNil: [ :package | package beDirty ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "package", "beDirty"]
+}),
+$globals.PackageStateObserver);
+
+
+$globals.PackageStateObserver.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@current"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@current"]=self._new();
+$1=self["@current"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"current",{},$globals.PackageStateObserver.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09^ current ifNil: [ current := self new ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.PackageStateObserver.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._observeSystem();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.PackageStateObserver.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09self current observeSystem",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["observeSystem", "current"]
+}),
+$globals.PackageStateObserver.klass);
+
+
+$core.addClass('PlatformInterface', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.PlatformInterface.comment="I am single entry point to UI and environment interface.\x0aMy `initialize` tries several options (for now, browser environment only) to set myself up.\x0a\x0a## API\x0a\x0a    PlatformInterface alert: 'Hey, there is a problem'.\x0a    PlatformInterface confirm: 'Affirmative?'.\x0a    PlatformInterface prompt: 'Your name:'.\x0a\x0a    PlatformInterface ajax: #{\x0a        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'\x0a    }.";
+//>>excludeEnd("ide");
+
+$globals.PlatformInterface.klass.iVarNames = ['worker'];
+$core.addMethod(
+$core.method({
+selector: "ajax:",
+protocol: 'actions',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@worker"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("ajax: not available");
+} else {
+$1=$recv(self["@worker"])._ajax_(anObject);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ajax:",{anObject:anObject},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "ajax: anObject\x0a\x09^ worker\x0a\x09\x09ifNotNil: [ worker ajax: anObject ]\x0a\x09\x09ifNil: [ self error: 'ajax: not available' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:ifNil:", "ajax:", "error:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "alert:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@worker"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("alert: not available");
+} else {
+$1=$recv(self["@worker"])._alert_(aString);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alert:",{aString:aString},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "alert: aString\x0a\x09^ worker\x0a\x09\x09ifNotNil: [ worker alert: aString ]\x0a\x09\x09ifNil: [ self error: 'alert: not available' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:ifNil:", "alert:", "error:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "confirm:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@worker"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("confirm: not available");
+} else {
+$1=$recv(self["@worker"])._confirm_(aString);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"confirm:",{aString:aString},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "confirm: aString\x0a\x09^ worker\x0a\x09\x09ifNotNil: [ worker confirm: aString ]\x0a\x09\x09ifNil: [ self error: 'confirm: not available' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:ifNil:", "confirm:", "error:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "existsGlobal:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($PlatformInterface())._globals())._at_ifPresent_ifAbsent_(aString,(function(){
+return true;
+
+}),(function(){
+return false;
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"existsGlobal:",{aString:aString},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "existsGlobal: aString\x0a\x09^ PlatformInterface globals \x0a\x09\x09at: aString \x0a\x09\x09ifPresent: [ true ] \x0a\x09\x09ifAbsent: [ false ]",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifPresent:ifAbsent:", "globals"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "globals",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return (new Function('return this'))();;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"globals",{},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "globals\x0a\x09<return (new Function('return this'))();>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+var candidate;
+function $BrowserInterface(){return $globals.BrowserInterface||(typeof BrowserInterface=="undefined"?nil:BrowserInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.PlatformInterface.klass.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+if(($receiver = $BrowserInterface()) == null || $receiver.isNil){
+$BrowserInterface();
+} else {
+candidate=$recv($BrowserInterface())._new();
+candidate;
+$1=$recv(candidate)._isAvailable();
+if($core.assert($1)){
+self._setWorker_(candidate);
+return self;
+};
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{candidate:candidate},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09| candidate |\x0a\x09\x0a\x09super initialize.\x0a\x09\x0a\x09BrowserInterface ifNotNil: [\x0a\x09\x09candidate := BrowserInterface new.\x0a\x09\x09candidate isAvailable ifTrue: [ self setWorker: candidate. ^ self ]\x0a\x09]",
+referencedClasses: ["BrowserInterface"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "ifNotNil:", "new", "ifTrue:", "isAvailable", "setWorker:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@worker"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("prompt: not available");
+} else {
+$1=$recv(self["@worker"])._prompt_(aString);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:",{aString:aString},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "prompt: aString\x0a\x09^ worker\x0a\x09\x09ifNotNil: [ worker prompt: aString ]\x0a\x09\x09ifNil: [ self error: 'prompt: not available' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:ifNil:", "prompt:", "error:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:default:",
+protocol: 'actions',
+fn: function (aString,defaultString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@worker"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._error_("prompt: not available");
+} else {
+$1=$recv(self["@worker"])._prompt_default_(aString,defaultString);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:default:",{aString:aString,defaultString:defaultString},$globals.PlatformInterface.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "defaultString"],
+source: "prompt: aString default: defaultString\x0a\x09^ worker\x0a\x09\x09ifNotNil: [ worker prompt: aString default: defaultString ]\x0a\x09\x09ifNil: [ self error: 'prompt: not available' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:ifNil:", "prompt:default:", "error:"]
+}),
+$globals.PlatformInterface.klass);
+
+$core.addMethod(
+$core.method({
+selector: "setWorker:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@worker"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "setWorker: anObject\x0a\x09worker := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.PlatformInterface.klass);
+
+
+$core.addClass('Service', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Service.comment="I implement the basic behavior for class registration to a service.\x0a\x0aSee the `Transcript` class for a concrete service.\x0a\x0a## API\x0a\x0aUse class-side methods `#register:` and `#registerIfNone:` to register classes to a specific service.";
+//>>excludeEnd("ide");
+
+$globals.Service.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@current"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09^ current",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Service.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.Service.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.Service.klass);
+
+$core.addMethod(
+$core.method({
+selector: "register:",
+protocol: 'registration',
+fn: function (anObject){
+var self=this;
+self["@current"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "register: anObject\x0a\x09current := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Service.klass);
+
+$core.addMethod(
+$core.method({
+selector: "registerIfNone:",
+protocol: 'registration',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=self._current();
+if(($receiver = $1) == null || $receiver.isNil){
+self._register_(anObject);
+} else {
+$1;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"registerIfNone:",{anObject:anObject},$globals.Service.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "registerIfNone: anObject\x0a\x09self current ifNil: [ self register: anObject ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "current", "register:"]
+}),
+$globals.Service.klass);
+
+
+$core.addClass('ErrorHandler', $globals.Service, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ErrorHandler.comment="I am the service used to handle Smalltalk errors.\x0aSee `boot.js` `handleError()` function.\x0a\x0aRegistered service instances must implement `#handleError:` to perform an action on the thrown exception.";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "handleError:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._handleUnhandledError_(anError);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"handleError:",{anError:anError},$globals.ErrorHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "handleError: anError\x0a\x09self handleUnhandledError: anError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["handleUnhandledError:"]
+}),
+$globals.ErrorHandler.klass);
+
+$core.addMethod(
+$core.method({
+selector: "handleUnhandledError:",
+protocol: 'error handling',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(anError)._wasHandled();
+if($core.assert($1)){
+return self;
+};
+$2=$recv(self._current())._handleError_(anError);
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"handleUnhandledError:",{anError:anError},$globals.ErrorHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "handleUnhandledError: anError\x0a\x09anError wasHandled ifTrue: [ ^ self ].\x0a\x09\x0a\x09^ self current handleError: anError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "wasHandled", "handleError:", "current"]
+}),
+$globals.ErrorHandler.klass);
+
+
+$core.addClass('Finder', $globals.Service, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Finder.comment="I am the service responsible for finding classes/methods.\x0a__There is no default finder.__\x0a\x0a## API\x0a\x0aUse `#browse` on an object to find it.";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "findClass:",
+protocol: 'finding',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._current())._findClass_(aClass);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"findClass:",{aClass:aClass},$globals.Finder.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "findClass: aClass\x0a\x09^ self current findClass: aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["findClass:", "current"]
+}),
+$globals.Finder.klass);
+
+$core.addMethod(
+$core.method({
+selector: "findMethod:",
+protocol: 'finding',
+fn: function (aCompiledMethod){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._current())._findMethod_(aCompiledMethod);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"findMethod:",{aCompiledMethod:aCompiledMethod},$globals.Finder.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCompiledMethod"],
+source: "findMethod: aCompiledMethod\x0a\x09^ self current findMethod: aCompiledMethod",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["findMethod:", "current"]
+}),
+$globals.Finder.klass);
+
+$core.addMethod(
+$core.method({
+selector: "findString:",
+protocol: 'finding',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._current())._findString_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"findString:",{aString:aString},$globals.Finder.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "findString: aString\x0a\x09^ self current findString: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["findString:", "current"]
+}),
+$globals.Finder.klass);
+
+
+$core.addClass('Inspector', $globals.Service, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Inspector.comment="I am the service responsible for inspecting objects.\x0a\x0aThe default inspector object is the transcript.";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "inspect:",
+protocol: 'inspecting',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._current())._inspect_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},$globals.Inspector.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "inspect: anObject\x0a\x09^ self current inspect: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["inspect:", "current"]
+}),
+$globals.Inspector.klass);
+
+
+$core.addClass('ProgressHandler', $globals.Service, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ProgressHandler.comment="I am used to manage progress in collection iterations, see `SequenceableCollection >> #do:displayingProgress:`.\x0a\x0aRegistered instances must implement `#do:on:displaying:`.\x0a\x0aThe default behavior is to simply iterate over the collection, using `NullProgressHandler`.";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "do:on:displaying:",
+protocol: 'progress handling',
+fn: function (aBlock,aCollection,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._do_on_displaying_(aBlock,aCollection,aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:on:displaying:",{aBlock:aBlock,aCollection:aCollection,aString:aString},$globals.ProgressHandler.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "aCollection", "aString"],
+source: "do: aBlock on: aCollection displaying: aString\x0a\x09self current do: aBlock on: aCollection displaying: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:on:displaying:", "current"]
+}),
+$globals.ProgressHandler.klass);
+
+
+$core.addClass('Transcript', $globals.Service, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Transcript.comment="I am a facade for Transcript actions.\x0a\x0aI delegate actions to the currently registered transcript.\x0a\x0a## API\x0a\x0a    Transcript \x0a        show: 'hello world';\x0a        cr;\x0a        show: anObject.";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "clear",
+protocol: 'printing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._clear();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"clear",{},$globals.Transcript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "clear\x0a\x09self current clear",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["clear", "current"]
+}),
+$globals.Transcript.klass);
+
+$core.addMethod(
+$core.method({
+selector: "cr",
+protocol: 'printing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._show_($recv($String())._cr());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cr",{},$globals.Transcript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cr\x0a\x09self current show: String cr",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["show:", "current", "cr"]
+}),
+$globals.Transcript.klass);
+
+$core.addMethod(
+$core.method({
+selector: "inspect:",
+protocol: 'printing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._show_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspect:",{anObject:anObject},$globals.Transcript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "inspect: anObject\x0a\x09self show: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["show:"]
+}),
+$globals.Transcript.klass);
+
+$core.addMethod(
+$core.method({
+selector: "open",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._open();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"open",{},$globals.Transcript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "open\x0a\x09self current open",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["open", "current"]
+}),
+$globals.Transcript.klass);
+
+$core.addMethod(
+$core.method({
+selector: "show:",
+protocol: 'printing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._current())._show_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"show:",{anObject:anObject},$globals.Transcript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "show: anObject\x0a\x09self current show: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["show:", "current"]
+}),
+$globals.Transcript.klass);
+
+
+$core.addClass('Setting', $globals.Object, ['key', 'value', 'defaultValue'], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Setting.comment="I represent a setting **stored** at `Smalltalk settings`. \x0aIn the current implementation, `Smalltalk settings` is an object persisted in the localStorage.\x0a\x0a## API\x0a\x0aA `Setting` value can be read using `value` and set using `value:`.\x0a\x0aSettings are accessed with `'key' asSetting` or `'key' asSettingIfAbsent: aDefaultValue`.\x0a\x0aTo read the value of a setting you can also use the convenience:\x0a\x0a`theValueSet :=  'any.characteristic' settingValue` \x0a\x0aor with a default using:\x0a\x0a `theEnsuredValueSet := 'any.characteristic' settingValueIfAbsent: true`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "defaultValue",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@defaultValue"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultValue\x0a\x09^ defaultValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Setting);
+
+$core.addMethod(
+$core.method({
+selector: "defaultValue:",
+protocol: 'accessing',
+fn: function (aStringifiableObject){
+var self=this;
+self["@defaultValue"]=aStringifiableObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStringifiableObject"],
+source: "defaultValue: aStringifiableObject\x0a\x09defaultValue := aStringifiableObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Setting);
+
+$core.addMethod(
+$core.method({
+selector: "key",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@key"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "key\x0a\x09^ key",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Setting);
+
+$core.addMethod(
+$core.method({
+selector: "key:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@key"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "key: aString\x0a\x09key := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Setting);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Smalltalk())._settings())._at_ifAbsent_(self._key(),(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._defaultValue();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.Setting)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ Smalltalk settings at: self key ifAbsent: [ self defaultValue ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "settings", "key", "defaultValue"]
+}),
+$globals.Setting);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'accessing',
+fn: function (aStringifiableObject){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($Smalltalk())._settings())._at_put_(self._key(),aStringifiableObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{aStringifiableObject:aStringifiableObject},$globals.Setting)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStringifiableObject"],
+source: "value: aStringifiableObject\x0a\x09^ Smalltalk settings at: self key put: aStringifiableObject",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "settings", "key"]
+}),
+$globals.Setting);
+
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'instance creation',
+fn: function (aString,aDefaultValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Setting.klass.superclass.fn.prototype._new.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv($2)._key_(aString);
+$recv($2)._defaultValue_(aDefaultValue);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aString:aString,aDefaultValue:aDefaultValue},$globals.Setting.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aDefaultValue"],
+source: "at: aString ifAbsent: aDefaultValue\x0a\x09\x0a\x09^ super new\x0a\x09\x09key: aString;\x0a\x09\x09defaultValue: aDefaultValue;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["key:", "new", "defaultValue:", "yourself"]
+}),
+$globals.Setting.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.Setting.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.Setting.klass);
+
+
+$core.addClass('SmalltalkImage', $globals.Object, [], 'Kernel-Infrastructure');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.SmalltalkImage.comment="I represent the Smalltalk system, wrapping\x0aoperations of variable `$core` declared in `support/boot.js`.\x0a\x0a## API\x0a\x0aI have only one instance, accessed with global variable `Smalltalk`.\x0a\x0a## Classes\x0a\x0aClasses can be accessed using the following methods:\x0a\x0a- `#classes` answers the full list of Smalltalk classes in the system\x0a- `#globals #at:` answers a specific global (usually, a class) or `nil`\x0a\x0a## Packages\x0a\x0aPackages can be accessed using the following methods:\x0a\x0a- `#packages` answers the full list of packages\x0a- `#packageAt:` answers a specific package or `nil`\x0a\x0a## Parsing\x0a\x0aThe `#parse:` method is used to parse Amber source code.\x0aIt requires the `Compiler` package and the `support/parser.js` parser file in order to work.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addGlobalJsVariable:",
+protocol: 'globals',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._globalJsVariables())._add_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addGlobalJsVariable:",{aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "addGlobalJsVariable: aString\x0a\x09self globalJsVariables add: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "globalJsVariables"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "amdRequire",
+protocol: 'accessing amd',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._core())._at_("amdRequire");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"amdRequire",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "amdRequire\x0a\x09^ self core at: 'amdRequire'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "core"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "asSmalltalkException:",
+protocol: 'error handling',
+fn: function (anObject){
+var self=this;
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+function $JavaScriptException(){return $globals.JavaScriptException||(typeof JavaScriptException=="undefined"?nil:JavaScriptException)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv(self._isSmalltalkObject_(anObject))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(anObject)._isKindOf_($Error());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($2)){
+$1=anObject;
+} else {
+$1=$recv($JavaScriptException())._on_(anObject);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSmalltalkException:",{anObject:anObject},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "asSmalltalkException: anObject\x0a\x09\x22A JavaScript exception may be thrown.\x0a\x09We then need to convert it back to a Smalltalk object\x22\x0a\x09\x0a\x09^ ((self isSmalltalkObject: anObject) and: [ anObject isKindOf: Error ])\x0a\x09\x09ifTrue: [ anObject ]\x0a\x09\x09ifFalse: [ JavaScriptException on: anObject ]",
+referencedClasses: ["Error", "JavaScriptException"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "and:", "isSmalltalkObject:", "isKindOf:", "on:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "at:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=$recv(self._globals())._at_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:",{aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "at: aString\x0a\x09self deprecatedAPI.\x0a\x09^ self globals at: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "at:", "globals"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'accessing',
+fn: function (aKey,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=$recv(self._globals())._at_ifAbsent_(aKey,aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey", "aBlock"],
+source: "at: aKey ifAbsent: aBlock\x0a\x09self deprecatedAPI.\x0a\x09^ self globals at: aKey ifAbsent: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "at:ifAbsent:", "globals"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'accessing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=$recv(self._globals())._at_put_(aString,anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{aString:aString,anObject:anObject},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "at: aString put: anObject\x0a\x09self deprecatedAPI.\x0a\x09^ self globals at: aString put: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "at:put:", "globals"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "basicCreatePackage:",
+protocol: 'private',
+fn: function (packageName){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.addPackage(packageName);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicCreatePackage:",{packageName:packageName},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName"],
+source: "basicCreatePackage: packageName\x0a\x09\x22Create and bind a new bare package with given name and return it.\x22\x0a\x09<return $core.addPackage(packageName)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "basicParse:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+function $SmalltalkParser(){return $globals.SmalltalkParser||(typeof SmalltalkParser=="undefined"?nil:SmalltalkParser)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($SmalltalkParser())._parse_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicParse:",{aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicParse: aString\x0a\x09^ SmalltalkParser parse: aString",
+referencedClasses: ["SmalltalkParser"],
+//>>excludeEnd("ide");
+messageSends: ["parse:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "classes",
+protocol: 'classes',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.classes();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"classes",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classes\x0a\x09<return $core.classes()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "core",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"core",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "core\x0a\x09<return $core>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "createPackage:",
+protocol: 'packages',
+fn: function (packageName){
+var self=this;
+var package_,announcement;
+function $PackageAdded(){return $globals.PackageAdded||(typeof PackageAdded=="undefined"?nil:PackageAdded)}
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+package_=self._basicCreatePackage_(packageName);
+$1=$recv($PackageAdded())._new();
+$recv($1)._package_(package_);
+$2=$recv($1)._yourself();
+announcement=$2;
+$recv($recv($SystemAnnouncer())._current())._announce_(announcement);
+$3=package_;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"createPackage:",{packageName:packageName,package_:package_,announcement:announcement},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName"],
+source: "createPackage: packageName\x0a\x09| package announcement |\x0a\x09\x0a\x09package := self basicCreatePackage: packageName.\x0a\x09\x0a\x09announcement := PackageAdded new\x0a\x09\x09package: package;\x0a\x09\x09yourself.\x0a\x09\x09\x0a\x09SystemAnnouncer current announce: announcement.\x0a\x09\x0a\x09^ package",
+referencedClasses: ["PackageAdded", "SystemAnnouncer"],
+//>>excludeEnd("ide");
+messageSends: ["basicCreatePackage:", "package:", "new", "yourself", "announce:", "current"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "createPackage:properties:",
+protocol: 'private',
+fn: function (packageName,aDict){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+self._deprecatedAPI();
+$1=$recv(aDict)._isEmpty();
+if(!$core.assert($1)){
+self._error_("createPackage:properties: called with nonempty properties");
+};
+$2=self._createPackage_(packageName);
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"createPackage:properties:",{packageName:packageName,aDict:aDict},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName", "aDict"],
+source: "createPackage: packageName properties: aDict\x0a\x09\x22Needed to import .st files: they begin with this call.\x22\x0a\x09self deprecatedAPI.\x0a\x09\x0a\x09aDict isEmpty ifFalse: [ self error: 'createPackage:properties: called with nonempty properties' ].\x0a\x09^ self createPackage: packageName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "ifFalse:", "isEmpty", "error:", "createPackage:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._deprecatedAPI();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"current",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09\x22Backward compatibility for Smalltalk current ...\x22\x0a\x09self deprecatedAPI.\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "defaultAmdNamespace",
+protocol: 'accessing amd',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1="transport.defaultAmdNamespace"._settingValue();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultAmdNamespace",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultAmdNamespace\x0a\x09^ 'transport.defaultAmdNamespace' settingValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["settingValue"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "defaultAmdNamespace:",
+protocol: 'accessing amd',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+"transport.defaultAmdNamespace"._settingValue_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultAmdNamespace:",{aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "defaultAmdNamespace: aString\x0a\x09'transport.defaultAmdNamespace' settingValue: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["settingValue:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "deleteClass:",
+protocol: 'private',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$core.removeClass(aClass);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deleteClass:",{aClass:aClass},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "deleteClass: aClass\x0a\x09\x22Deletes a class by deleting its binding only. Use #removeClass instead\x22\x0a\x09\x0a\x09<$core.removeClass(aClass)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "deleteGlobalJsVariable:",
+protocol: 'globals',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._globalJsVariables())._remove_ifAbsent_(aString,(function(){
+
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deleteGlobalJsVariable:",{aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "deleteGlobalJsVariable: aString\x0a\x09self globalJsVariables remove: aString ifAbsent:[]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:ifAbsent:", "globalJsVariables"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "deletePackage:",
+protocol: 'private',
+fn: function (packageName){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+delete $core.packages[packageName];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deletePackage:",{packageName:packageName},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName"],
+source: "deletePackage: packageName\x0a\x09\x22Deletes a package by deleting its binding, but does not check if it contains classes etc.\x0a\x09To remove a package, use #removePackage instead.\x22\x0a\x0a\x09<delete $core.packages[packageName]>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "globalJsVariables",
+protocol: 'globals',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.globalJsVariables;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"globalJsVariables",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "globalJsVariables\x0a\x09\x22Array of global JavaScript variables\x22\x0a\x09<return $core.globalJsVariables>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "globals",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $globals;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"globals",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "globals\x0a\x09<return $globals>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "includesKey:",
+protocol: 'accessing',
+fn: function (aKey){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.hasOwnProperty(aKey);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"includesKey:",{aKey:aKey},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aKey"],
+source: "includesKey: aKey\x0a\x09<return $core.hasOwnProperty(aKey)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "isSmalltalkObject:",
+protocol: 'testing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return typeof anObject.klass !== 'undefined';
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isSmalltalkObject:",{anObject:anObject},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "isSmalltalkObject: anObject\x0a\x09\x22Consider anObject a Smalltalk object if it has a 'klass' property.\x0a\x09Note that this may be unaccurate\x22\x0a\x09\x0a\x09<return typeof anObject.klass !== 'undefined'>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "packageAt:",
+protocol: 'packages',
+fn: function (packageName){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.packages[packageName];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"packageAt:",{packageName:packageName},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName"],
+source: "packageAt: packageName\x0a\x09<return $core.packages[packageName]>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "packageAt:ifAbsent:",
+protocol: 'packages',
+fn: function (packageName,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._packageAt_(packageName);
+$1=$recv($2)._ifNil_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"packageAt:ifAbsent:",{packageName:packageName,aBlock:aBlock},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName", "aBlock"],
+source: "packageAt: packageName ifAbsent: aBlock\x0a\x09^ (self packageAt: packageName) ifNil: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "packageAt:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "packages",
+protocol: 'packages',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Object.keys($core.packages).map(function(k) {
+			return $core.packages[k];
+		})
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"packages",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "packages\x0a\x09\x22Return all Package instances in the system.\x22\x0a\x0a\x09<\x0a\x09\x09return Object.keys($core.packages).map(function(k) {\x0a\x09\x09\x09return $core.packages[k];\x0a\x09\x09})\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "parse:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+result=self._basicParse_(aString);
+return result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._tryCatch_((function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._parseError_parsing_(ex,aString))._signal();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$2=result;
+$recv($2)._source_(aString);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parse:",{aString:aString,result:result},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "parse: aString\x0a\x09| result |\x0a\x09\x0a\x09[ result := self basicParse: aString ] \x0a\x09\x09tryCatch: [ :ex | (self parseError: ex parsing: aString) signal ].\x0a\x09\x09\x0a\x09^ result\x0a\x09\x09source: aString;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tryCatch:", "basicParse:", "signal", "parseError:parsing:", "source:", "yourself"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "parseError:parsing:",
+protocol: 'error handling',
+fn: function (anException,aString){
+var self=this;
+function $ParseError(){return $globals.ParseError||(typeof ParseError=="undefined"?nil:ParseError)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$8,$7,$6,$9,$5,$4,$3,$1;
+$2=$recv($ParseError())._new();
+$8=$recv(anException)._basicAt_("line");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["basicAt:"]=1;
+//>>excludeEnd("ctx");
+$7="Parse error on line ".__comma($8);
+$6=$recv($7).__comma(" column ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$9=$recv(anException)._basicAt_("column");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["basicAt:"]=2;
+//>>excludeEnd("ctx");
+$5=$recv($6).__comma($9);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$4=$recv($5).__comma(" : Unexpected character ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma($recv(anException)._basicAt_("found"));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._messageText_($3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"parseError:parsing:",{anException:anException,aString:aString},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anException", "aString"],
+source: "parseError: anException parsing: aString\x0a\x09^ ParseError new messageText: 'Parse error on line ', (anException basicAt: 'line') ,' column ' , (anException basicAt: 'column') ,' : Unexpected character ', (anException basicAt: 'found')",
+referencedClasses: ["ParseError"],
+//>>excludeEnd("ide");
+messageSends: ["messageText:", "new", ",", "basicAt:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "pseudoVariableNames",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=["self", "super", "nil", "true", "false", "thisContext"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pseudoVariableNames\x0a\x09^ #('self' 'super' 'nil' 'true' 'false' 'thisContext')",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "readJSObject:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.readJSObject(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"readJSObject:",{anObject:anObject},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "readJSObject: anObject\x0a\x09<return $core.readJSObject(anObject)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "removeClass:",
+protocol: 'classes',
+fn: function (aClass){
+var self=this;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $ClassRemoved(){return $globals.ClassRemoved||(typeof ClassRemoved=="undefined"?nil:ClassRemoved)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+$1=$recv(aClass)._isMetaclass();
+if($core.assert($1)){
+self._error_($recv($recv(aClass)._asString()).__comma(" is a Metaclass and cannot be removed!"));
+};
+self._deleteClass_(aClass);
+$2=$recv($ClassRemoved())._new();
+$recv($2)._theClass_(aClass);
+$3=$recv($2)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($3);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeClass:",{aClass:aClass},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "removeClass: aClass\x0a\x09aClass isMetaclass ifTrue: [ self error: aClass asString, ' is a Metaclass and cannot be removed!' ].\x0a\x09\x0a\x09self deleteClass: aClass.\x0a\x09\x0a\x09SystemAnnouncer current\x0a\x09\x09announce: (ClassRemoved new\x0a\x09\x09\x09theClass: aClass;\x0a\x09\x09\x09yourself)",
+referencedClasses: ["SystemAnnouncer", "ClassRemoved"],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isMetaclass", "error:", ",", "asString", "deleteClass:", "announce:", "current", "theClass:", "new", "yourself"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "removePackage:",
+protocol: 'packages',
+fn: function (packageName){
+var self=this;
+var pkg;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+pkg=self._packageAt_ifAbsent_(packageName,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Missing package: ".__comma(packageName));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv($recv(pkg)._classes())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._removeClass_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+self._deletePackage_(packageName);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removePackage:",{packageName:packageName,pkg:pkg},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName"],
+source: "removePackage: packageName\x0a\x09\x22Removes a package and all its classes.\x22\x0a\x0a\x09| pkg |\x0a\x09pkg := self packageAt: packageName ifAbsent: [ self error: 'Missing package: ', packageName ].\x0a\x09pkg classes do: [ :each |\x0a\x09\x09\x09self removeClass: each ].\x0a\x09self deletePackage: packageName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["packageAt:ifAbsent:", "error:", ",", "do:", "classes", "removeClass:", "deletePackage:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "renamePackage:to:",
+protocol: 'packages',
+fn: function (packageName,newName){
+var self=this;
+var pkg;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$receiver;
+pkg=self._packageAt_ifAbsent_(packageName,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1="Missing package: ".__comma(packageName);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return self._error_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["error:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$2=self._packageAt_(newName);
+if(($receiver = $2) == null || $receiver.isNil){
+$2;
+} else {
+self._error_("Already exists a package called: ".__comma(newName));
+};
+$recv(self._at_("packages"))._at_put_(newName,pkg);
+$recv(pkg)._name_(newName);
+self._deletePackage_(packageName);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"renamePackage:to:",{packageName:packageName,newName:newName,pkg:pkg},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["packageName", "newName"],
+source: "renamePackage: packageName to: newName\x0a\x09\x22Rename a package.\x22\x0a\x0a\x09| pkg |\x0a\x09pkg := self packageAt: packageName ifAbsent: [ self error: 'Missing package: ', packageName ].\x0a\x09(self packageAt: newName) ifNotNil: [ self error: 'Already exists a package called: ', newName ].\x0a\x09(self at: 'packages') at: newName put: pkg.\x0a\x09pkg name: newName.\x0a\x09self deletePackage: packageName.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["packageAt:ifAbsent:", "error:", ",", "ifNotNil:", "packageAt:", "at:put:", "at:", "name:", "deletePackage:"]
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "reservedWords",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.reservedWords;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"reservedWords",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "reservedWords\x0a\x09\x22JavaScript reserved words\x22\x0a\x09<return $core.reservedWords>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "settings",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $SmalltalkSettings(){return $globals.SmalltalkSettings||(typeof SmalltalkSettings=="undefined"?nil:SmalltalkSettings)}
+return $SmalltalkSettings();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "settings\x0a\x09^ SmalltalkSettings",
+referencedClasses: ["SmalltalkSettings"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "version",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "0.13.3";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "version\x0a\x09\x22Answer the version string of Amber\x22\x0a\x09\x0a\x09^ '0.13.3'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
+$core.addMethod(
+$core.method({
+selector: "vm",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI_("Use #core");
+$1=self._core();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"vm",{},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "vm\x0a\x09self deprecatedAPI: 'Use #core'.\x0a\x09^self core",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI:", "core"]
+}),
+$globals.SmalltalkImage);
+
+
+$globals.SmalltalkImage.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@current"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@current"]=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.SmalltalkImage.klass.superclass.fn.prototype._new.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=self["@current"];
+} else {
+self._deprecatedAPI();
+$1=self["@current"];
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"current",{},$globals.SmalltalkImage.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09^ current ifNil: [ current := super new ] ifNotNil: [ self deprecatedAPI. current ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:", "new", "deprecatedAPI"]
+}),
+$globals.SmalltalkImage.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+var st;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+st=self._current();
+$recv($recv(st)._globals())._at_put_("Smalltalk",st);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{st:st},$globals.SmalltalkImage.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09| st |\x0a\x09st := self current.\x0a\x09st globals at: 'Smalltalk' put: st",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["current", "at:put:", "globals"]
+}),
+$globals.SmalltalkImage.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.SmalltalkImage.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.SmalltalkImage.klass);
+
+$core.addMethod(
+$core.method({
+selector: "do:displayingProgress:",
+protocol: '*Kernel-Infrastructure',
+fn: function (aBlock,aString){
+var self=this;
+function $ProgressHandler(){return $globals.ProgressHandler||(typeof ProgressHandler=="undefined"?nil:ProgressHandler)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($ProgressHandler())._do_on_displaying_(aBlock,self,aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"do:displayingProgress:",{aBlock:aBlock,aString:aString},$globals.SequenceableCollection)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "aString"],
+source: "do: aBlock displayingProgress: aString\x0a\x09ProgressHandler \x0a\x09\x09do: aBlock \x0a\x09\x09on: self \x0a\x09\x09displaying: aString",
+referencedClasses: ["ProgressHandler"],
+//>>excludeEnd("ide");
+messageSends: ["do:on:displaying:"]
+}),
+$globals.SequenceableCollection);
+
+$core.addMethod(
+$core.method({
+selector: "asJavaScriptPropertyName",
+protocol: '*Kernel-Infrastructure',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.st2prop(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavaScriptPropertyName",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavaScriptPropertyName\x0a<return $core.st2prop(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJavaScriptSelector",
+protocol: '*Kernel-Infrastructure',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._asJavaScriptPropertyName();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavaScriptSelector",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavaScriptSelector\x0a\x09\x22Cannot add next line as it breaks commit:\x0a\x09self deprecatedAPI: 'Use #asJavaScriptPropertyName'.\x22\x0a\x09^ self asJavaScriptPropertyName",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asJavaScriptPropertyName"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asSetting",
+protocol: '*Kernel-Infrastructure',
+fn: function (){
+var self=this;
+function $Setting(){return $globals.Setting||(typeof Setting=="undefined"?nil:Setting)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Setting())._at_ifAbsent_(self,nil);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSetting",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSetting\x0a\x09\x22Answer aSetting dedicated to locally store a value using this string as key.\x0a\x09Nil will be the default value.\x22\x0a\x09^ Setting at: self ifAbsent: nil",
+referencedClasses: ["Setting"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asSettingIfAbsent:",
+protocol: '*Kernel-Infrastructure',
+fn: function (aDefaultValue){
+var self=this;
+function $Setting(){return $globals.Setting||(typeof Setting=="undefined"?nil:Setting)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Setting())._at_ifAbsent_(self,aDefaultValue);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSettingIfAbsent:",{aDefaultValue:aDefaultValue},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDefaultValue"],
+source: "asSettingIfAbsent: aDefaultValue\x0a\x09\x22Answer aSetting dedicated to locally store a value using this string as key.\x0a\x09Make this setting to have aDefaultValue.\x22\x0a\x09^ Setting at: self ifAbsent: aDefaultValue",
+referencedClasses: ["Setting"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "settingValue",
+protocol: '*Kernel-Infrastructure',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asSetting())._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"settingValue",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "settingValue\x0a\x09^ self asSetting value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value", "asSetting"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "settingValue:",
+protocol: '*Kernel-Infrastructure',
+fn: function (aValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asSetting())._value_(aValue);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"settingValue:",{aValue:aValue},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aValue"],
+source: "settingValue: aValue\x0a\x09\x22Sets the value of the setting that will be locally stored using this string as key.\x0a\x09Note that aValue can be any object that can be stringifyed\x22\x0a\x09^ self asSetting value: aValue",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:", "asSetting"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "settingValueIfAbsent:",
+protocol: '*Kernel-Infrastructure',
+fn: function (aDefaultValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asSettingIfAbsent_(aDefaultValue))._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"settingValueIfAbsent:",{aDefaultValue:aDefaultValue},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDefaultValue"],
+source: "settingValueIfAbsent: aDefaultValue\x0a\x09\x22Answer the value of the locally stored setting using this string as key.\x0a\x09Use aDefaultValue in case no setting is found\x22\x0a\x09^ (self asSettingIfAbsent: aDefaultValue) value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value", "asSettingIfAbsent:"]
+}),
+$globals.String);
+
+});

+ 1426 - 0
bower_components/amber/src/Kernel-Infrastructure.st

@@ -0,0 +1,1426 @@
+Smalltalk createPackage: 'Kernel-Infrastructure'!
+Object subclass: #ConsoleErrorHandler
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!ConsoleErrorHandler commentStamp!
+I am manage Smalltalk errors, displaying the stack in the console.!
+
+!ConsoleErrorHandler methodsFor: 'error handling'!
+
+handleError: anError
+	anError context ifNotNil: [ self logErrorContext: anError context ].
+	self logError: anError
+! !
+
+!ConsoleErrorHandler methodsFor: 'private'!
+
+log: aString
+	console log: aString
+!
+
+logContext: aContext
+	aContext home ifNotNil: [
+		self logContext: aContext home ].
+	self log: aContext asString
+!
+
+logError: anError
+	self log: anError messageText
+!
+
+logErrorContext: aContext
+	aContext ifNotNil: [
+		aContext home ifNotNil: [
+			self logContext: aContext home ]]
+! !
+
+ConsoleErrorHandler class instanceVariableNames: 'current'!
+
+!ConsoleErrorHandler class methodsFor: 'initialization'!
+
+initialize
+	ErrorHandler registerIfNone: self new
+! !
+
+Object subclass: #InterfacingObject
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!InterfacingObject commentStamp!
+I am superclass of all object that interface with user or environment. `Widget` and a few other classes are subclasses of me. I delegate all of the above APIs to `PlatformInterface`.
+
+## API
+
+    self alert: 'Hey, there is a problem'.
+    self confirm: 'Affirmative?'.
+    self prompt: 'Your name:'.
+
+    self ajax: #{
+        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'
+    }.!
+
+!InterfacingObject methodsFor: 'actions'!
+
+ajax: anObject
+	^ PlatformInterface ajax: anObject
+!
+
+alert: aString
+	^ PlatformInterface alert: aString
+!
+
+confirm: aString
+	^ PlatformInterface confirm: aString
+!
+
+prompt: aString
+	^ PlatformInterface prompt: aString
+!
+
+prompt: aString default: defaultString
+	^ PlatformInterface prompt: aString default: defaultString
+! !
+
+InterfacingObject subclass: #Environment
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Environment commentStamp!
+I provide an unified entry point to manipulate Amber packages, classes and methods.
+
+Typical use cases include IDEs, remote access and restricting browsing.!
+
+!Environment methodsFor: 'accessing'!
+
+allSelectors
+	^ Smalltalk core allSelectors
+!
+
+availableClassNames
+	^ Smalltalk classes 
+		collect: [ :each | each name ]
+!
+
+availablePackageNames
+	^ Smalltalk packages 
+		collect: [ :each | each name ]
+!
+
+availableProtocolsFor: aClass
+	| protocols |
+	
+	protocols := aClass protocols.
+	aClass superclass ifNotNil: [ protocols addAll: (self availableProtocolsFor: aClass superclass) ].
+	^ protocols asSet asArray sort
+!
+
+classBuilder
+	^ ClassBuilder new
+!
+
+classNamed: aString
+	^ (Smalltalk globals at: aString asSymbol)
+		ifNil: [ self error: 'Invalid class name' ]
+!
+
+classes
+	^ Smalltalk classes
+!
+
+doItReceiver
+	^ DoIt new
+!
+
+packages
+	^ Smalltalk packages
+!
+
+systemAnnouncer
+	^ (Smalltalk globals at: #SystemAnnouncer) current
+! !
+
+!Environment methodsFor: 'actions'!
+
+commitPackage: aPackage onSuccess: aBlock onError: anotherBlock
+	aPackage transport
+		commitOnSuccess: aBlock
+		onError: anotherBlock
+!
+
+copyClass: aClass to: aClassName
+	(Smalltalk globals at: aClassName)
+		ifNotNil: [ self error: 'A class named ', aClassName, ' already exists' ].
+		
+	ClassBuilder new copyClass: aClass named: aClassName
+!
+
+inspect: anObject
+	Inspector inspect: anObject
+!
+
+moveClass: aClass toPackage: aPackageName
+	| package |
+	
+	package := Package named: aPackageName.
+	package ifNil: [ self error: 'Invalid package name' ].
+	package == aClass package ifTrue: [ ^ self ].
+	
+	aClass package: package
+!
+
+moveMethod: aMethod toClass: aClassName
+	| destinationClass |
+	
+	destinationClass := self classNamed: aClassName.
+	destinationClass == aMethod methodClass ifTrue: [ ^ self ].
+	
+	aMethod methodClass isMetaclass ifTrue: [ 
+		destinationClass := destinationClass class ].
+	
+	destinationClass 
+		compile: aMethod source
+		protocol: aMethod protocol.
+	aMethod methodClass 
+		removeCompiledMethod: aMethod
+!
+
+moveMethod: aMethod toProtocol: aProtocol
+	aMethod protocol: aProtocol
+!
+
+removeClass: aClass
+	Smalltalk removeClass: aClass
+!
+
+removeMethod: aMethod
+	aMethod methodClass removeCompiledMethod: aMethod
+!
+
+removeProtocol: aString from: aClass
+	(aClass methodsInProtocol: aString)
+		do: [ :each | aClass removeCompiledMethod: each ]
+!
+
+renameClass: aClass to: aClassName
+	(Smalltalk globals at: aClassName)
+		ifNotNil: [ self error: 'A class named ', aClassName, ' already exists' ].
+		
+	ClassBuilder new renameClass: aClass to: aClassName
+!
+
+renameProtocol: aString to: anotherString in: aClass
+	(aClass methodsInProtocol: aString)
+		do: [ :each | each protocol: anotherString ]
+!
+
+setClassCommentOf: aClass to: aString
+	aClass comment: aString
+! !
+
+!Environment methodsFor: 'compiling'!
+
+addInstVarNamed: aString to: aClass
+	self classBuilder
+		addSubclassOf: aClass superclass 
+		named: aClass name 
+		instanceVariableNames: (aClass instanceVariableNames copy add: aString; yourself)
+		package: aClass package name
+!
+
+compileClassComment: aString for: aClass
+	aClass comment: aString
+!
+
+compileClassDefinition: aString
+	[ self evaluate: aString for: DoIt new ]
+		on: Error
+		do: [ :error | self alert: error messageText ]
+!
+
+compileMethod: sourceCode for: class protocol: protocol
+	^ class
+		compile: sourceCode
+		protocol: protocol
+! !
+
+!Environment methodsFor: 'error handling'!
+
+evaluate: aBlock on: anErrorClass do: exceptionBlock
+	"Evaluate a block and catch exceptions happening on the environment stack"
+	
+	aBlock tryCatch: [ :exception | 
+		(exception isKindOf: (self classNamed: anErrorClass name))
+			ifTrue: [ exceptionBlock value: exception ]
+ 			ifFalse: [ exception signal ] ]
+! !
+
+!Environment methodsFor: 'evaluating'!
+
+evaluate: aString for: anObject
+	^ Evaluator evaluate: aString for: anObject
+! !
+
+!Environment methodsFor: 'services'!
+
+registerErrorHandler: anErrorHandler
+	ErrorHandler register: anErrorHandler
+!
+
+registerFinder: aFinder
+	Finder register: aFinder
+!
+
+registerInspector: anInspector
+	Inspector register: anInspector
+!
+
+registerProgressHandler: aProgressHandler
+	ProgressHandler register: aProgressHandler
+!
+
+registerTranscript: aTranscript
+	Transcript register: aTranscript
+! !
+
+ProtoObject subclass: #JSObjectProxy
+	instanceVariableNames: 'jsObject'
+	package: 'Kernel-Infrastructure'!
+!JSObjectProxy commentStamp!
+I handle sending messages to JavaScript objects, making  JavaScript object accessing from Amber fully transparent.
+My instances make intensive use of `#doesNotUnderstand:`.
+
+My instances are automatically created by Amber whenever a message is sent to a JavaScript object.
+
+## Usage examples
+
+JSObjectProxy objects are instanciated by Amber when a Smalltalk message is sent to a JavaScript object.
+
+	window alert: 'hello world'.
+	window inspect.
+	(window jQuery: 'body') append: 'hello world'
+
+Amber messages sends are converted to JavaScript function calls or object property access _(in this order)_. If n one of them match, a `MessageNotUnderstood` error will be thrown.
+
+## Message conversion rules
+
+- `someUser name` becomes `someUser.name`
+- `someUser name: 'John'` becomes `someUser name = "John"`
+- `console log: 'hello world'` becomes `console.log('hello world')`
+- `(window jQuery: 'foo') css: 'background' color: 'red'` becomes `window.jQuery('foo').css('background', 'red')`
+
+__Note:__ For keyword-based messages, only the first keyword is kept: `window foo: 1 bar: 2` is equivalent to `window foo: 1 baz: 2`.!
+
+!JSObjectProxy methodsFor: 'accessing'!
+
+at: aString
+	<return self['@jsObject'][aString]>
+!
+
+at: aString ifAbsent: aBlock
+	"return the aString property or evaluate aBlock if the property is not defined on the object"
+	<
+		var obj = self['@jsObject'];
+		return aString in obj ? obj[aString] : aBlock._value();
+	>
+!
+
+at: aString ifPresent: aBlock
+	"return the evaluation of aBlock with the value if the property is defined or return nil"
+	<
+		var obj = self['@jsObject'];
+		return aString in obj ? aBlock._value_(obj[aString]) : nil;
+	>
+!
+
+at: aString ifPresent: aBlock ifAbsent: anotherBlock
+	"return the evaluation of aBlock with the value if the property is defined
+	or return value of anotherBlock"
+	<
+		var obj = self['@jsObject'];
+		return aString in obj ? aBlock._value_(obj[aString]) : anotherBlock._value();
+	>
+!
+
+at: aString put: anObject
+	<return self['@jsObject'][aString] = anObject>
+!
+
+jsObject
+	^ jsObject
+!
+
+jsObject: aJSObject
+	jsObject := aJSObject
+!
+
+lookupProperty: aString
+	"Looks up a property in JS object.
+	Answer the property if it is present, or nil if it is not present."
+	
+	<return aString in self._jsObject() ? aString : nil>
+! !
+
+!JSObjectProxy methodsFor: 'comparing'!
+
+= anObject
+	anObject class == self class ifFalse: [ ^ false ].
+	^ self compareJSObjectWith: anObject jsObject
+! !
+
+!JSObjectProxy methodsFor: 'enumerating'!
+
+asJSON
+	"Answers the receiver in a stringyfy-friendly fashion"
+
+	^ jsObject
+!
+
+keysAndValuesDo: aBlock
+	<
+		var o = self['@jsObject'];
+		for(var i in o) {
+			aBlock._value_value_(i, o[i]);
+		}
+	>
+! !
+
+!JSObjectProxy methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: self printString
+!
+
+printString
+	<
+		var js = self['@jsObject'];
+		return js.toString
+			? js.toString()
+			: Object.prototype.toString.call(js)
+	>
+! !
+
+!JSObjectProxy methodsFor: 'private'!
+
+compareJSObjectWith: aJSObject
+ 	<return self["@jsObject"] === aJSObject>
+! !
+
+!JSObjectProxy methodsFor: 'proxy'!
+
+addObjectVariablesTo: aDictionary
+	<
+		for(var i in self['@jsObject']) {
+			aDictionary._at_put_(i, self['@jsObject'][i]);
+		}
+	>
+!
+
+doesNotUnderstand: aMessage
+	^ (self lookupProperty: aMessage selector asJavaScriptPropertyName)
+		ifNil: [ super doesNotUnderstand: aMessage ]
+		ifNotNil: [ :jsSelector | 
+			self 
+				forwardMessage: jsSelector 
+				withArguments: aMessage arguments ]
+!
+
+forwardMessage: aString withArguments: anArray
+	<
+		return $core.accessJavaScript(self._jsObject(), aString, anArray);
+	>
+!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self jsObject.
+	anInspector setLabel: self printString.
+	self addObjectVariablesTo: variables.
+	anInspector setVariables: variables
+! !
+
+!JSObjectProxy class methodsFor: 'instance creation'!
+
+on: aJSObject
+	^ self new
+		jsObject: aJSObject;
+		yourself
+! !
+
+Object subclass: #NullProgressHandler
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!NullProgressHandler commentStamp!
+I am the default progress handler. I do not display any progress, and simply iterate over the collection.!
+
+!NullProgressHandler methodsFor: 'progress handling'!
+
+do: aBlock on: aCollection displaying: aString
+	aCollection do: aBlock
+! !
+
+NullProgressHandler class instanceVariableNames: 'current'!
+
+!NullProgressHandler class methodsFor: 'initialization'!
+
+initialize
+	ProgressHandler registerIfNone: self new
+! !
+
+Object subclass: #Organizer
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Organizer commentStamp!
+I represent categorization information. 
+
+## API
+
+Use `#addElement:` and `#removeElement:` to manipulate instances.!
+
+!Organizer methodsFor: 'accessing'!
+
+addElement: anObject
+	<self.elements.addElement(anObject)>
+!
+
+elements
+	^ (self basicAt: 'elements') copy
+!
+
+removeElement: anObject
+	<self.elements.removeElement(anObject)>
+! !
+
+Organizer subclass: #ClassOrganizer
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!ClassOrganizer commentStamp!
+I am an organizer specific to classes. I hold method categorization information for classes.!
+
+!ClassOrganizer methodsFor: 'accessing'!
+
+addElement: aString
+	super addElement: aString.
+
+	SystemAnnouncer current announce: (ProtocolAdded new
+		protocol: aString;
+		theClass: self theClass;
+		yourself)
+!
+
+removeElement: aString
+	super removeElement: aString.
+
+	SystemAnnouncer current announce: (ProtocolRemoved new
+		protocol: aString;
+		theClass: self theClass;
+		yourself)
+!
+
+theClass
+	< return self.theClass >
+! !
+
+Organizer subclass: #PackageOrganizer
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!PackageOrganizer commentStamp!
+I am an organizer specific to packages. I hold classes categorization information.!
+
+Object subclass: #Package
+	instanceVariableNames: 'transport dirty'
+	package: 'Kernel-Infrastructure'!
+!Package commentStamp!
+I am similar to a "class category" typically found in other Smalltalks like Pharo or Squeak. Amber does not have class categories anymore, it had in the beginning but now each class in the system knows which package it belongs to.
+
+Each package has a name and can be queried for its classes, but it will then resort to a reverse scan of all classes to find them.
+
+## API
+
+Packages are manipulated through "Smalltalk current", like for example finding one based on a name or with `Package class >> #name` directly:
+
+    Smalltalk current packageAt: 'Kernel'
+    Package named: 'Kernel'
+
+A package differs slightly from a Monticello package which can span multiple class categories using a naming convention based on hyphenation. But just as in Monticello a package supports "class extensions" so a package can define behaviors in foreign classes using a naming convention for method categories where the category starts with an asterisk and then the name of the owning package follows.
+
+You can fetch a package from the server:
+
+	Package load: 'Additional-Examples'!
+
+!Package methodsFor: 'accessing'!
+
+beClean
+	dirty := false.
+	
+	SystemAnnouncer current announce: (PackageClean new
+		package: self;
+		yourself)
+!
+
+beDirty
+	dirty := true.
+	
+	SystemAnnouncer current announce: (PackageDirty new
+		package: self;
+		yourself)
+!
+
+classTemplate
+	^ String streamContents: [ :stream |
+		stream
+			nextPutAll: 'Object';
+			nextPutAll: ' subclass: #NameOfSubclass';
+			nextPutAll: String lf, String tab;
+			nextPutAll: 'instanceVariableNames: '''''.
+		stream
+			nextPutAll: '''', String lf, String tab;
+			nextPutAll: 'package: ''';
+			nextPutAll: self name;
+			nextPutAll: '''' ]
+!
+
+definition
+	^ String streamContents: [ :stream |
+		stream 
+			nextPutAll: self class name;
+			nextPutAll: String lf, String tab;
+			nextPutAll: ' named: ';
+			nextPutAll: '''', self name, '''';
+			nextPutAll: String lf, String tab;
+			nextPutAll:  ' transport: (';
+			nextPutAll: self transport definition, ')' ]
+!
+
+name
+	<return self.pkgName>
+!
+
+name: aString
+	self basicName: aString.
+	self beDirty
+!
+
+organization
+	^ self basicAt: 'organization'
+!
+
+transport
+	^ transport ifNil: [ 
+		transport := (PackageTransport fromJson: self basicTransport)
+			package: self;
+			yourself ]
+!
+
+transport: aPackageTransport
+	transport := aPackageTransport.
+	aPackageTransport package: self
+! !
+
+!Package methodsFor: 'classes'!
+
+classes
+	^ self organization elements
+!
+
+setupClasses
+	self classes
+		do: [ :each | ClassBuilder new setupClass: each ];
+		do: [ :each | each initialize ]
+!
+
+sortedClasses
+	"Answer all classes in the receiver, sorted by superclass/subclasses and by class name for common subclasses (Issue #143)."
+
+	^ self class sortedClasses: self classes
+! !
+
+!Package methodsFor: 'dependencies'!
+
+loadDependencies
+	"Returns list of packages that need to be loaded
+	before loading this package."
+	
+	| classes packages |
+	classes := self loadDependencyClasses.
+	^ (classes collect: [ :each | each package ]) asSet
+		remove: self ifAbsent: [];
+		yourself
+!
+
+loadDependencyClasses
+	"Returns classes needed at the time of loading a package.
+	These are all that are used to subclass
+	and to define an extension method"
+	
+	| starCategoryName |
+	starCategoryName := '*', self name.
+	^ (self classes collect: [ :each | each superclass ]) asSet
+		remove: nil ifAbsent: [];
+		addAll: (Smalltalk classes select: [ :each | each protocols, each class protocols includes: starCategoryName ]);
+		yourself
+! !
+
+!Package methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	aStream 
+		nextPutAll: ' (';
+		nextPutAll: self name;
+		nextPutAll: ')'
+! !
+
+!Package methodsFor: 'private'!
+
+basicName: aString
+	<self.pkgName = aString>
+!
+
+basicTransport
+	"Answer the transport literal JavaScript object as setup in the JavaScript file, if any"
+	
+	<return self.transport>
+! !
+
+!Package methodsFor: 'testing'!
+
+isDirty
+	^ dirty ifNil: [ false ]
+!
+
+isPackage
+	^ true
+! !
+
+Package class instanceVariableNames: 'defaultCommitPathJs defaultCommitPathSt'!
+
+!Package class methodsFor: 'accessing'!
+
+named: aPackageName
+	^ Smalltalk 
+		packageAt: aPackageName
+		ifAbsent: [ 
+			Smalltalk createPackage: aPackageName ]
+!
+
+named: aPackageName ifAbsent: aBlock
+	^ Smalltalk packageAt: aPackageName ifAbsent: aBlock
+!
+
+named: aPackageName transport: aTransport
+	| package |
+	
+	package := self named: aPackageName.
+	package transport: aTransport.
+	
+	^ package
+! !
+
+!Package class methodsFor: 'sorting'!
+
+sortedClasses: classes
+	"Answer classes, sorted by superclass/subclasses and by class name for common subclasses (Issue #143)"
+
+	| children others nodes expandedClasses |
+	children := #().
+	others := #().
+	classes do: [ :each |
+		(classes includes: each superclass)
+			ifFalse: [ children add: each ]
+			ifTrue: [ others add: each ]].
+	nodes := children collect: [ :each |
+		ClassSorterNode on: each classes: others level: 0 ].
+	nodes := nodes sorted: [ :a :b | a theClass name <= b theClass name ].
+	expandedClasses := Array new.
+	nodes do: [ :aNode |
+		aNode traverseClassesWith: expandedClasses ].
+	^ expandedClasses
+! !
+
+Object subclass: #PackageStateObserver
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!PackageStateObserver commentStamp!
+My current instance listens for any changes in the system that might affect the state of a package (being dirty).!
+
+!PackageStateObserver methodsFor: 'accessing'!
+
+announcer
+	^ SystemAnnouncer current
+! !
+
+!PackageStateObserver methodsFor: 'actions'!
+
+observeSystem
+	self announcer
+		on: PackageAdded
+		send: #onPackageAdded:
+		to: self;
+		
+		on: ClassAnnouncement
+		send: #onClassModification:
+		to: self;
+		
+		on: MethodAnnouncement
+		send: #onMethodModification:
+		to: self;
+		
+		on: ProtocolAnnouncement
+		send: #onProtocolModification:
+		to: self
+! !
+
+!PackageStateObserver methodsFor: 'reactions'!
+
+onClassModification: anAnnouncement
+	anAnnouncement theClass ifNotNil: [ :theClass | theClass package beDirty ]
+!
+
+onMethodModification: anAnnouncement
+	anAnnouncement method package ifNotNil: [ :package | package beDirty ]
+!
+
+onPackageAdded: anAnnouncement
+	anAnnouncement package beDirty
+!
+
+onProtocolModification: anAnnouncement
+	anAnnouncement package ifNotNil: [ :package | package beDirty ]
+! !
+
+PackageStateObserver class instanceVariableNames: 'current'!
+
+!PackageStateObserver class methodsFor: 'accessing'!
+
+current
+	^ current ifNil: [ current := self new ]
+! !
+
+!PackageStateObserver class methodsFor: 'initialization'!
+
+initialize
+	self current observeSystem
+! !
+
+Object subclass: #PlatformInterface
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!PlatformInterface commentStamp!
+I am single entry point to UI and environment interface.
+My `initialize` tries several options (for now, browser environment only) to set myself up.
+
+## API
+
+    PlatformInterface alert: 'Hey, there is a problem'.
+    PlatformInterface confirm: 'Affirmative?'.
+    PlatformInterface prompt: 'Your name:'.
+
+    PlatformInterface ajax: #{
+        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'
+    }.!
+
+PlatformInterface class instanceVariableNames: 'worker'!
+
+!PlatformInterface class methodsFor: 'accessing'!
+
+globals
+	<return (new Function('return this'))();>
+!
+
+setWorker: anObject
+	worker := anObject
+! !
+
+!PlatformInterface class methodsFor: 'actions'!
+
+ajax: anObject
+	^ worker
+		ifNotNil: [ worker ajax: anObject ]
+		ifNil: [ self error: 'ajax: not available' ]
+!
+
+alert: aString
+	^ worker
+		ifNotNil: [ worker alert: aString ]
+		ifNil: [ self error: 'alert: not available' ]
+!
+
+confirm: aString
+	^ worker
+		ifNotNil: [ worker confirm: aString ]
+		ifNil: [ self error: 'confirm: not available' ]
+!
+
+existsGlobal: aString
+	^ PlatformInterface globals 
+		at: aString 
+		ifPresent: [ true ] 
+		ifAbsent: [ false ]
+!
+
+prompt: aString
+	^ worker
+		ifNotNil: [ worker prompt: aString ]
+		ifNil: [ self error: 'prompt: not available' ]
+!
+
+prompt: aString default: defaultString
+	^ worker
+		ifNotNil: [ worker prompt: aString default: defaultString ]
+		ifNil: [ self error: 'prompt: not available' ]
+! !
+
+!PlatformInterface class methodsFor: 'initialization'!
+
+initialize
+	| candidate |
+	
+	super initialize.
+	
+	BrowserInterface ifNotNil: [
+		candidate := BrowserInterface new.
+		candidate isAvailable ifTrue: [ self setWorker: candidate. ^ self ]
+	]
+! !
+
+Object subclass: #Service
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Service commentStamp!
+I implement the basic behavior for class registration to a service.
+
+See the `Transcript` class for a concrete service.
+
+## API
+
+Use class-side methods `#register:` and `#registerIfNone:` to register classes to a specific service.!
+
+Service class instanceVariableNames: 'current'!
+
+!Service class methodsFor: 'accessing'!
+
+current
+	^ current
+! !
+
+!Service class methodsFor: 'instance creation'!
+
+new
+	self shouldNotImplement
+! !
+
+!Service class methodsFor: 'registration'!
+
+register: anObject
+	current := anObject
+!
+
+registerIfNone: anObject
+	self current ifNil: [ self register: anObject ]
+! !
+
+Service subclass: #ErrorHandler
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!ErrorHandler commentStamp!
+I am the service used to handle Smalltalk errors.
+See `boot.js` `handleError()` function.
+
+Registered service instances must implement `#handleError:` to perform an action on the thrown exception.!
+
+!ErrorHandler class methodsFor: 'error handling'!
+
+handleError: anError
+	self handleUnhandledError: anError
+!
+
+handleUnhandledError: anError
+	anError wasHandled ifTrue: [ ^ self ].
+	
+	^ self current handleError: anError
+! !
+
+Service subclass: #Finder
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Finder commentStamp!
+I am the service responsible for finding classes/methods.
+__There is no default finder.__
+
+## API
+
+Use `#browse` on an object to find it.!
+
+!Finder class methodsFor: 'finding'!
+
+findClass: aClass
+	^ self current findClass: aClass
+!
+
+findMethod: aCompiledMethod
+	^ self current findMethod: aCompiledMethod
+!
+
+findString: aString
+	^ self current findString: aString
+! !
+
+Service subclass: #Inspector
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Inspector commentStamp!
+I am the service responsible for inspecting objects.
+
+The default inspector object is the transcript.!
+
+!Inspector class methodsFor: 'inspecting'!
+
+inspect: anObject
+	^ self current inspect: anObject
+! !
+
+Service subclass: #ProgressHandler
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!ProgressHandler commentStamp!
+I am used to manage progress in collection iterations, see `SequenceableCollection >> #do:displayingProgress:`.
+
+Registered instances must implement `#do:on:displaying:`.
+
+The default behavior is to simply iterate over the collection, using `NullProgressHandler`.!
+
+!ProgressHandler class methodsFor: 'progress handling'!
+
+do: aBlock on: aCollection displaying: aString
+	self current do: aBlock on: aCollection displaying: aString
+! !
+
+Service subclass: #Transcript
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!Transcript commentStamp!
+I am a facade for Transcript actions.
+
+I delegate actions to the currently registered transcript.
+
+## API
+
+    Transcript 
+        show: 'hello world';
+        cr;
+        show: anObject.!
+
+!Transcript class methodsFor: 'instance creation'!
+
+open
+	self current open
+! !
+
+!Transcript class methodsFor: 'printing'!
+
+clear
+	self current clear
+!
+
+cr
+	self current show: String cr
+!
+
+inspect: anObject
+	self show: anObject
+!
+
+show: anObject
+	self current show: anObject
+! !
+
+Object subclass: #Setting
+	instanceVariableNames: 'key value defaultValue'
+	package: 'Kernel-Infrastructure'!
+!Setting commentStamp!
+I represent a setting **stored** at `Smalltalk settings`. 
+In the current implementation, `Smalltalk settings` is an object persisted in the localStorage.
+
+## API
+
+A `Setting` value can be read using `value` and set using `value:`.
+
+Settings are accessed with `'key' asSetting` or `'key' asSettingIfAbsent: aDefaultValue`.
+
+To read the value of a setting you can also use the convenience:
+
+`theValueSet :=  'any.characteristic' settingValue` 
+
+or with a default using:
+
+ `theEnsuredValueSet := 'any.characteristic' settingValueIfAbsent: true`!
+
+!Setting methodsFor: 'accessing'!
+
+defaultValue
+	^ defaultValue
+!
+
+defaultValue: aStringifiableObject
+	defaultValue := aStringifiableObject
+!
+
+key
+	^ key
+!
+
+key: aString
+	key := aString
+!
+
+value
+	^ Smalltalk settings at: self key ifAbsent: [ self defaultValue ]
+!
+
+value: aStringifiableObject
+	^ Smalltalk settings at: self key put: aStringifiableObject
+! !
+
+!Setting class methodsFor: 'instance creation'!
+
+at: aString ifAbsent: aDefaultValue
+	
+	^ super new
+		key: aString;
+		defaultValue: aDefaultValue;
+		yourself
+!
+
+new
+	self shouldNotImplement
+! !
+
+Object subclass: #SmalltalkImage
+	instanceVariableNames: ''
+	package: 'Kernel-Infrastructure'!
+!SmalltalkImage commentStamp!
+I represent the Smalltalk system, wrapping
+operations of variable `$core` declared in `support/boot.js`.
+
+## API
+
+I have only one instance, accessed with global variable `Smalltalk`.
+
+## Classes
+
+Classes can be accessed using the following methods:
+
+- `#classes` answers the full list of Smalltalk classes in the system
+- `#globals #at:` answers a specific global (usually, a class) or `nil`
+
+## Packages
+
+Packages can be accessed using the following methods:
+
+- `#packages` answers the full list of packages
+- `#packageAt:` answers a specific package or `nil`
+
+## Parsing
+
+The `#parse:` method is used to parse Amber source code.
+It requires the `Compiler` package and the `support/parser.js` parser file in order to work.!
+
+!SmalltalkImage methodsFor: 'accessing'!
+
+at: aString
+	self deprecatedAPI.
+	^ self globals at: aString
+!
+
+at: aKey ifAbsent: aBlock
+	self deprecatedAPI.
+	^ self globals at: aKey ifAbsent: aBlock
+!
+
+at: aString put: anObject
+	self deprecatedAPI.
+	^ self globals at: aString put: anObject
+!
+
+core
+	<return $core>
+!
+
+current
+	"Backward compatibility for Smalltalk current ..."
+	self deprecatedAPI.
+	^ self
+!
+
+globals
+	<return $globals>
+!
+
+includesKey: aKey
+	<return $core.hasOwnProperty(aKey)>
+!
+
+parse: aString
+	| result |
+	
+	[ result := self basicParse: aString ] 
+		tryCatch: [ :ex | (self parseError: ex parsing: aString) signal ].
+		
+	^ result
+		source: aString;
+		yourself
+!
+
+pseudoVariableNames
+	^ #('self' 'super' 'nil' 'true' 'false' 'thisContext')
+!
+
+readJSObject: anObject
+	<return $core.readJSObject(anObject)>
+!
+
+reservedWords
+	"JavaScript reserved words"
+	<return $core.reservedWords>
+!
+
+settings
+	^ SmalltalkSettings
+!
+
+version
+	"Answer the version string of Amber"
+	
+	^ '0.13.3'
+!
+
+vm
+	self deprecatedAPI: 'Use #core'.
+	^self core
+! !
+
+!SmalltalkImage methodsFor: 'accessing amd'!
+
+amdRequire
+	^ self core at: 'amdRequire'
+!
+
+defaultAmdNamespace
+	^ 'transport.defaultAmdNamespace' settingValue
+!
+
+defaultAmdNamespace: aString
+	'transport.defaultAmdNamespace' settingValue: aString
+! !
+
+!SmalltalkImage methodsFor: 'classes'!
+
+classes
+	<return $core.classes()>
+!
+
+removeClass: aClass
+	aClass isMetaclass ifTrue: [ self error: aClass asString, ' is a Metaclass and cannot be removed!!' ].
+	
+	self deleteClass: aClass.
+	
+	SystemAnnouncer current
+		announce: (ClassRemoved new
+			theClass: aClass;
+			yourself)
+! !
+
+!SmalltalkImage methodsFor: 'error handling'!
+
+asSmalltalkException: anObject
+	"A JavaScript exception may be thrown.
+	We then need to convert it back to a Smalltalk object"
+	
+	^ ((self isSmalltalkObject: anObject) and: [ anObject isKindOf: Error ])
+		ifTrue: [ anObject ]
+		ifFalse: [ JavaScriptException on: anObject ]
+!
+
+parseError: anException parsing: aString
+	^ ParseError new messageText: 'Parse error on line ', (anException basicAt: 'line') ,' column ' , (anException basicAt: 'column') ,' : Unexpected character ', (anException basicAt: 'found')
+! !
+
+!SmalltalkImage methodsFor: 'globals'!
+
+addGlobalJsVariable: aString
+	self globalJsVariables add: aString
+!
+
+deleteGlobalJsVariable: aString
+	self globalJsVariables remove: aString ifAbsent:[]
+!
+
+globalJsVariables
+	"Array of global JavaScript variables"
+	<return $core.globalJsVariables>
+! !
+
+!SmalltalkImage methodsFor: 'packages'!
+
+createPackage: packageName
+	| package announcement |
+	
+	package := self basicCreatePackage: packageName.
+	
+	announcement := PackageAdded new
+		package: package;
+		yourself.
+		
+	SystemAnnouncer current announce: announcement.
+	
+	^ package
+!
+
+packageAt: packageName
+	<return $core.packages[packageName]>
+!
+
+packageAt: packageName ifAbsent: aBlock
+	^ (self packageAt: packageName) ifNil: aBlock
+!
+
+packages
+	"Return all Package instances in the system."
+
+	<
+		return Object.keys($core.packages).map(function(k) {
+			return $core.packages[k];
+		})
+	>
+!
+
+removePackage: packageName
+	"Removes a package and all its classes."
+
+	| pkg |
+	pkg := self packageAt: packageName ifAbsent: [ self error: 'Missing package: ', packageName ].
+	pkg classes do: [ :each |
+			self removeClass: each ].
+	self deletePackage: packageName
+!
+
+renamePackage: packageName to: newName
+	"Rename a package."
+
+	| pkg |
+	pkg := self packageAt: packageName ifAbsent: [ self error: 'Missing package: ', packageName ].
+	(self packageAt: newName) ifNotNil: [ self error: 'Already exists a package called: ', newName ].
+	(self at: 'packages') at: newName put: pkg.
+	pkg name: newName.
+	self deletePackage: packageName.
+! !
+
+!SmalltalkImage methodsFor: 'private'!
+
+basicCreatePackage: packageName
+	"Create and bind a new bare package with given name and return it."
+	<return $core.addPackage(packageName)>
+!
+
+basicParse: aString
+	^ SmalltalkParser parse: aString
+!
+
+createPackage: packageName properties: aDict
+	"Needed to import .st files: they begin with this call."
+	self deprecatedAPI.
+	
+	aDict isEmpty ifFalse: [ self error: 'createPackage:properties: called with nonempty properties' ].
+	^ self createPackage: packageName
+!
+
+deleteClass: aClass
+	"Deletes a class by deleting its binding only. Use #removeClass instead"
+	
+	<$core.removeClass(aClass)>
+!
+
+deletePackage: packageName
+	"Deletes a package by deleting its binding, but does not check if it contains classes etc.
+	To remove a package, use #removePackage instead."
+
+	<delete $core.packages[packageName]>
+! !
+
+!SmalltalkImage methodsFor: 'testing'!
+
+isSmalltalkObject: anObject
+	"Consider anObject a Smalltalk object if it has a 'klass' property.
+	Note that this may be unaccurate"
+	
+	<return typeof anObject.klass !!== 'undefined'>
+! !
+
+SmalltalkImage class instanceVariableNames: 'current'!
+
+!SmalltalkImage class methodsFor: 'initialization'!
+
+initialize
+	| st |
+	st := self current.
+	st globals at: 'Smalltalk' put: st
+! !
+
+!SmalltalkImage class methodsFor: 'instance creation'!
+
+current
+	^ current ifNil: [ current := super new ] ifNotNil: [ self deprecatedAPI. current ]
+!
+
+new
+	self shouldNotImplement
+! !
+
+!SequenceableCollection methodsFor: '*Kernel-Infrastructure'!
+
+do: aBlock displayingProgress: aString
+	ProgressHandler 
+		do: aBlock 
+		on: self 
+		displaying: aString
+! !
+
+!String methodsFor: '*Kernel-Infrastructure'!
+
+asJavaScriptPropertyName
+<return $core.st2prop(self)>
+!
+
+asJavaScriptSelector
+	"Cannot add next line as it breaks commit:
+	self deprecatedAPI: 'Use #asJavaScriptPropertyName'."
+	^ self asJavaScriptPropertyName
+!
+
+asSetting
+	"Answer aSetting dedicated to locally store a value using this string as key.
+	Nil will be the default value."
+	^ Setting at: self ifAbsent: nil
+!
+
+asSettingIfAbsent: aDefaultValue
+	"Answer aSetting dedicated to locally store a value using this string as key.
+	Make this setting to have aDefaultValue."
+	^ Setting at: self ifAbsent: aDefaultValue
+!
+
+settingValue
+	^ self asSetting value
+!
+
+settingValue: aValue
+	"Sets the value of the setting that will be locally stored using this string as key.
+	Note that aValue can be any object that can be stringifyed"
+	^ self asSetting value: aValue
+!
+
+settingValueIfAbsent: aDefaultValue
+	"Answer the value of the locally stored setting using this string as key.
+	Use aDefaultValue in case no setting is found"
+	^ (self asSettingIfAbsent: aDefaultValue) value
+! !
+

+ 2996 - 0
bower_components/amber/src/Kernel-Methods.js

@@ -0,0 +1,2996 @@
+define("amber_core/Kernel-Methods", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Methods');
+$core.packages["Kernel-Methods"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('BlockClosure', $globals.Object, [], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.BlockClosure.comment="I represent a lexical closure.\x0aI am is directly mapped to JavaScript Function.\x0a\x0a## API\x0a\x0a1. Evaluation\x0a\x0a    My instances get evaluated with the `#value*` methods in the 'evaluating' protocol.\x0a\x0a    Example: ` [ :x | x + 1 ] value: 3 \x22Answers 4\x22 `\x0a\x0a2. Control structures\x0a\x0a    Blocks are used (together with `Boolean`) for control structures (methods in the `controlling` protocol).\x0a\x0a    Example: `aBlock whileTrue: [ ... ]`\x0a\x0a3. Error handling\x0a\x0a    I provide the `#on:do:` method for handling exceptions.\x0a\x0a    Example: ` aBlock on: MessageNotUnderstood do: [ :ex | ... ] `";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "applyTo:arguments:",
+protocol: 'evaluating',
+fn: function (anObject,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.apply(anObject, aCollection);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"applyTo:arguments:",{anObject:anObject,aCollection:aCollection},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aCollection"],
+source: "applyTo: anObject arguments: aCollection\x0a\x09<return self.apply(anObject, aCollection)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "asCompiledMethod:",
+protocol: 'converting',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.method({selector:aString, fn:self});;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asCompiledMethod:",{aString:aString},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "asCompiledMethod: aString\x0a\x09<return $core.method({selector:aString, fn:self});>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "compiledSource",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"compiledSource",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "compiledSource\x0a\x09<return self.toString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "currySelf",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return function () {
+			var args = [ this ];
+			args.push.apply(args, arguments);
+			return self.apply(null, args);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"currySelf",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "currySelf\x0a\x09\x22Transforms [ :selfarg :x :y | stcode ] block\x0a\x09which represents JS function (selfarg, x, y, ...) {jscode}\x0a\x09into function (x, y, ...) {jscode} that takes selfarg from 'this'.\x0a\x09IOW, it is usable as JS method and first arg takes the receiver.\x22\x0a\x09\x0a\x09<\x0a\x09\x09return function () {\x0a\x09\x09\x09var args = [ this ];\x0a\x09\x09\x09args.push.apply(args, arguments);\x0a\x09\x09\x09return self.apply(null, args);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "ensure:",
+protocol: 'evaluating',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+try{return self._value()}finally{aBlock._value()};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ensure:",{aBlock:aBlock},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ensure: aBlock\x0a\x09<try{return self._value()}finally{aBlock._value()}>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "fork",
+protocol: 'timeout/interval',
+fn: function (){
+var self=this;
+function $ForkPool(){return $globals.ForkPool||(typeof ForkPool=="undefined"?nil:ForkPool)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($ForkPool())._default())._fork_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fork",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fork\x0a\x09ForkPool default fork: self",
+referencedClasses: ["ForkPool"],
+//>>excludeEnd("ide");
+messageSends: ["fork:", "default"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return new self();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09\x22Use the receiver as a JS constructor.\x0a\x09*Do not* use this method to instanciate Smalltalk objects!\x22\x0a\x09<return new self()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "newValue:",
+protocol: 'evaluating',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newWithValues_([anObject]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newValue:",{anObject:anObject},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "newValue: anObject\x0a\x09^ self newWithValues: { anObject }",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["newWithValues:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "newValue:value:",
+protocol: 'evaluating',
+fn: function (anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newWithValues_([anObject,anObject2]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newValue:value:",{anObject:anObject,anObject2:anObject2},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anObject2"],
+source: "newValue: anObject value: anObject2\x0a\x09^ self newWithValues: { anObject. anObject2 }.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["newWithValues:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "newValue:value:value:",
+protocol: 'evaluating',
+fn: function (anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._newWithValues_([anObject,anObject2,anObject3]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newValue:value:value:",{anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "anObject2", "anObject3"],
+source: "newValue: anObject value: anObject2 value: anObject3\x0a\x09^ self newWithValues: { anObject. anObject2. anObject3 }.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["newWithValues:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "newWithValues:",
+protocol: 'evaluating',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var object = Object.create(self.prototype);
+		var result = self.apply(object, aCollection);
+		return typeof result === "object" ? result : object;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newWithValues:",{aCollection:aCollection},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "newWithValues: aCollection\x0a\x09\x22Simulates JS new operator by combination of Object.create and .apply\x22\x0a\x09<\x0a\x09\x09var object = Object.create(self.prototype);\x0a\x09\x09var result = self.apply(object, aCollection);\x0a\x09\x09return typeof result === \x22object\x22 ? result : object;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "numArgs",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.length;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"numArgs",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "numArgs\x0a\x09<return self.length>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "on:do:",
+protocol: 'error handling',
+fn: function (anErrorClass,aBlock){
+var self=this;
+function $Smalltalk(){return $globals.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=self._tryCatch_((function(error){
+var smalltalkError;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+smalltalkError=$recv($Smalltalk())._asSmalltalkException_(error);
+smalltalkError;
+$2=$recv(smalltalkError)._isKindOf_(anErrorClass);
+if($core.assert($2)){
+return $recv(aBlock)._value_(smalltalkError);
+} else {
+return $recv(smalltalkError)._resignal();
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({error:error,smalltalkError:smalltalkError},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:do:",{anErrorClass:anErrorClass,aBlock:aBlock},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anErrorClass", "aBlock"],
+source: "on: anErrorClass do: aBlock\x0a\x09\x22All exceptions thrown in the Smalltalk stack are cought.\x0a\x09Convert all JS exceptions to JavaScriptException instances.\x22\x0a\x09\x0a\x09^ self tryCatch: [ :error | | smalltalkError |\x0a\x09\x09smalltalkError := Smalltalk asSmalltalkException: error.\x0a\x09\x09(smalltalkError isKindOf: anErrorClass)\x0a\x09\x09ifTrue: [ aBlock value: smalltalkError ]\x0a\x09\x09ifFalse: [ smalltalkError resignal ] ]",
+referencedClasses: ["Smalltalk"],
+//>>excludeEnd("ide");
+messageSends: ["tryCatch:", "asSmalltalkException:", "ifTrue:ifFalse:", "isKindOf:", "value:", "resignal"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return nil;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "timeToRun",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+function $Date(){return $globals.Date||(typeof Date=="undefined"?nil:Date)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Date())._millisecondsToRun_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"timeToRun",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "timeToRun\x0a\x09\x22Answer the number of milliseconds taken to execute this block.\x22\x0a\x0a\x09^ Date millisecondsToRun: self",
+referencedClasses: ["Date"],
+//>>excludeEnd("ide");
+messageSends: ["millisecondsToRun:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "tryCatch:",
+protocol: 'error handling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		try {
+			return self._value();
+		} catch(error) {
+			return aBlock._value_(error);
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tryCatch:",{aBlock:aBlock},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "tryCatch: aBlock\x0a\x09<\x0a\x09\x09try {\x0a\x09\x09\x09return self._value();\x0a\x09\x09} catch(error) {\x0a\x09\x09\x09return aBlock._value_(error);\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self();;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09<return self();>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'evaluating',
+fn: function (anArg){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self(anArg);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{anArg:anArg},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArg"],
+source: "value: anArg\x0a\x09<return self(anArg);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:",
+protocol: 'evaluating',
+fn: function (firstArg,secondArg){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self(firstArg, secondArg);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:",{firstArg:firstArg,secondArg:secondArg},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArg", "secondArg"],
+source: "value: firstArg value: secondArg\x0a\x09<return self(firstArg, secondArg);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:value:",
+protocol: 'evaluating',
+fn: function (firstArg,secondArg,thirdArg){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self(firstArg, secondArg, thirdArg);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:value:",{firstArg:firstArg,secondArg:secondArg,thirdArg:thirdArg},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArg", "secondArg", "thirdArg"],
+source: "value: firstArg value: secondArg value: thirdArg\x0a\x09<return self(firstArg, secondArg, thirdArg);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "valueWithInterval:",
+protocol: 'timeout/interval',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var interval = setInterval(self, aNumber);
+		return $globals.Timeout._on_(interval);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueWithInterval:",{aNumber:aNumber},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "valueWithInterval: aNumber\x0a\x09<\x0a\x09\x09var interval = setInterval(self, aNumber);\x0a\x09\x09return $globals.Timeout._on_(interval);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "valueWithPossibleArguments:",
+protocol: 'evaluating',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.apply(null, aCollection);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueWithPossibleArguments:",{aCollection:aCollection},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "valueWithPossibleArguments: aCollection\x0a\x09<return self.apply(null, aCollection);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "valueWithTimeout:",
+protocol: 'timeout/interval',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var timeout = setTimeout(self, aNumber);
+		return $globals.Timeout._on_(timeout);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueWithTimeout:",{aNumber:aNumber},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "valueWithTimeout: aNumber\x0a\x09<\x0a\x09\x09var timeout = setTimeout(self, aNumber);\x0a\x09\x09return $globals.Timeout._on_(timeout);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "whileFalse",
+protocol: 'controlling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._whileFalse_((function(){
+
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"whileFalse",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "whileFalse\x0a\x09self whileFalse: []",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "whileFalse:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+while(!$core.assert(self._value())) {aBlock._value()};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"whileFalse:",{aBlock:aBlock},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "whileFalse: aBlock\x0a\x09<while(!$core.assert(self._value())) {aBlock._value()}>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "whileTrue",
+protocol: 'controlling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._whileTrue_((function(){
+
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"whileTrue",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "whileTrue\x0a\x09self whileTrue: []",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileTrue:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "whileTrue:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+while($core.assert(self._value())) {aBlock._value()};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"whileTrue:",{aBlock:aBlock},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "whileTrue: aBlock\x0a\x09<while($core.assert(self._value())) {aBlock._value()}>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BlockClosure);
+
+
+
+$core.addClass('CompiledMethod', $globals.Object, [], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.CompiledMethod.comment="I represent a class method of the system. I hold the source and compiled code of a class method.\x0a\x0a## API\x0aMy instances can be accessed using `Behavior >> #methodAt:`\x0a\x0a    Object methodAt: 'asString'\x0a\x0aSource code access:\x0a\x0a\x09(String methodAt: 'lines') source\x0a\x0aReferenced classes:\x0a\x0a\x09(String methodAt: 'lines') referencedClasses\x0a\x0aMessages sent from an instance:\x0a\x09\x0a\x09(String methodAt: 'lines') messageSends";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.args || [];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09<return self.args || []>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "browse",
+protocol: 'browsing',
+fn: function (){
+var self=this;
+function $Finder(){return $globals.Finder||(typeof Finder=="undefined"?nil:Finder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Finder())._findMethod_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"browse",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "browse\x0a\x09Finder findMethod: self",
+referencedClasses: ["Finder"],
+//>>excludeEnd("ide");
+messageSends: ["findMethod:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "category",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._protocol();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"category",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "category\x0a\x09^ self protocol",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["protocol"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "defaultProtocol",
+protocol: 'defaults',
+fn: function (){
+var self=this;
+return "as yet unclassified";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultProtocol\x0a\x09^ 'as yet unclassified'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "fn",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("fn");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fn",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fn\x0a\x09^ self basicAt: 'fn'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "fn:",
+protocol: 'accessing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicAt_put_("fn",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fn:",{aBlock:aBlock},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "fn: aBlock\x0a\x09self basicAt: 'fn' put: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "isCompiledMethod",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCompiledMethod\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "isOverridden",
+protocol: 'testing',
+fn: function (){
+var self=this;
+var selector;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+var $early={};
+try {
+selector=self._selector();
+$recv(self._methodClass())._allSubclassesDo_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(each)._includesSelector_(selector);
+if($core.assert($1)){
+throw $early=[true];
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return false;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isOverridden",{selector:selector},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isOverridden\x0a\x09| selector |\x0a    \x0a    selector := self selector.\x0a    self methodClass allSubclassesDo: [ :each |\x0a\x09    (each includesSelector: selector)\x0a        \x09ifTrue: [ ^ true ] ].\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["selector", "allSubclassesDo:", "methodClass", "ifTrue:", "includesSelector:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "isOverride",
+protocol: 'testing',
+fn: function (){
+var self=this;
+var superclass;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$receiver;
+$1=self._methodClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodClass"]=1;
+//>>excludeEnd("ctx");
+superclass=$recv($1)._superclass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["superclass"]=1;
+//>>excludeEnd("ctx");
+$2=superclass;
+if(($receiver = $2) == null || $receiver.isNil){
+return false;
+} else {
+$2;
+};
+$3=$recv($recv($recv(self._methodClass())._superclass())._lookupSelector_(self._selector()))._notNil();
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isOverride",{superclass:superclass},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isOverride\x0a\x09| superclass |\x0a    \x0a    superclass := self methodClass superclass.\x0a\x09superclass ifNil: [ ^ false ].\x0a\x09\x0a    ^ (self methodClass superclass lookupSelector: self selector) notNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["superclass", "methodClass", "ifNil:", "notNil", "lookupSelector:", "selector"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "messageSends",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("messageSends");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"messageSends",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "messageSends\x0a\x09^ self basicAt: 'messageSends'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "methodClass",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("methodClass");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodClass",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodClass\x0a\x09^ self basicAt: 'methodClass'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "package",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $Package(){return $globals.Package||(typeof Package=="undefined"?nil:Package)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$5,$receiver;
+$1=self._methodClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodClass"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+return nil;
+} else {
+$1;
+};
+$3=self._protocol();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["protocol"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._beginsWith_("*");
+if(!$core.assert($2)){
+$4=$recv(self._methodClass())._package();
+return $4;
+};
+$5=$recv($Package())._named_ifAbsent_($recv(self._protocol())._allButFirst(),(function(){
+return nil;
+
+}));
+return $5;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"package",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "package\x0a\x09\x22Answer the package the receiver belongs to:\x0a\x09- if it is an extension method, answer the corresponding package\x0a\x09- else answer the `methodClass` package\x22\x0a\x09\x0a\x09self methodClass ifNil: [ ^ nil ].\x0a\x09\x0a\x09(self protocol beginsWith: '*') ifFalse: [\x0a\x09\x09^ self methodClass package ].\x0a\x09\x09\x0a\x09^ Package \x0a\x09\x09named: self protocol allButFirst\x0a\x09\x09ifAbsent: [ nil ]",
+referencedClasses: ["Package"],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "methodClass", "ifFalse:", "beginsWith:", "protocol", "package", "named:ifAbsent:", "allButFirst"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "protocol",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._basicAt_("protocol");
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._defaultProtocol();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"protocol",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "protocol\x0a\x09^ (self basicAt: 'protocol') ifNil: [ self defaultProtocol ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "basicAt:", "defaultProtocol"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "protocol:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+var oldProtocol;
+function $SystemAnnouncer(){return $globals.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $MethodMoved(){return $globals.MethodMoved||(typeof MethodMoved=="undefined"?nil:MethodMoved)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$receiver;
+oldProtocol=self._protocol();
+self._basicAt_put_("protocol",aString);
+$1=$recv($MethodMoved())._new();
+$recv($1)._method_(self);
+$recv($1)._oldProtocol_(oldProtocol);
+$2=$recv($1)._yourself();
+$recv($recv($SystemAnnouncer())._current())._announce_($2);
+$3=self._methodClass();
+if(($receiver = $3) == null || $receiver.isNil){
+$3;
+} else {
+var methodClass;
+methodClass=$receiver;
+$recv($recv(methodClass)._organization())._addElement_(aString);
+$recv(methodClass)._removeProtocolIfEmpty_(oldProtocol);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"protocol:",{aString:aString,oldProtocol:oldProtocol},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "protocol: aString\x0a\x09| oldProtocol |\x0a\x09oldProtocol := self protocol.\x0a\x09self basicAt: 'protocol' put: aString.\x0a\x0a\x09SystemAnnouncer current announce: (MethodMoved new\x0a\x09\x09method: self;\x0a\x09\x09oldProtocol: oldProtocol;\x0a\x09\x09yourself).\x0a\x0a\x09self methodClass ifNotNil: [ :methodClass |\x0a\x09\x09methodClass organization addElement: aString.\x0a\x09\x09methodClass removeProtocolIfEmpty: oldProtocol ]",
+referencedClasses: ["SystemAnnouncer", "MethodMoved"],
+//>>excludeEnd("ide");
+messageSends: ["protocol", "basicAt:put:", "announce:", "current", "method:", "new", "oldProtocol:", "yourself", "ifNotNil:", "methodClass", "addElement:", "organization", "removeProtocolIfEmpty:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "referencedClasses",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("referencedClasses");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"referencedClasses",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "referencedClasses\x0a\x09^ self basicAt: 'referencedClasses'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicAt_("selector");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ self basicAt: 'selector'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicAt_put_("selector",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector:",{aString:aString},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09self basicAt: 'selector' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "sendTo:arguments:",
+protocol: 'evaluating',
+fn: function (anObject,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._fn())._applyTo_arguments_(anObject,aCollection);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendTo:arguments:",{anObject:anObject,aCollection:aCollection},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject", "aCollection"],
+source: "sendTo: anObject arguments: aCollection\x0a\x09^ self fn applyTo: anObject arguments: aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["applyTo:arguments:", "fn"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self._basicAt_("source");
+if(($receiver = $2) == null || $receiver.isNil){
+$1="";
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source",{},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ (self basicAt: 'source') ifNil: [ '' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "basicAt:"]
+}),
+$globals.CompiledMethod);
+
+$core.addMethod(
+$core.method({
+selector: "source:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._basicAt_put_("source",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source:",{aString:aString},$globals.CompiledMethod)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "source: aString\x0a\x09self basicAt: 'source' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:"]
+}),
+$globals.CompiledMethod);
+
+
+
+$core.addClass('ForkPool', $globals.Object, ['poolSize', 'maxPoolSize', 'queue', 'worker'], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ForkPool.comment="I am responsible for handling forked blocks.\x0aThe pool size sets the maximum concurrent forked blocks.\x0a\x0a## API\x0a\x0aThe default instance is accessed with `#default`.\x0aThe maximum concurrent forked blocks can be set with `#maxPoolSize:`.\x0a\x0aForking is done via `BlockClosure >> #fork`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addWorker",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@worker"])._valueWithTimeout_((0));
+self["@poolSize"]=$recv(self["@poolSize"]).__plus((1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addWorker",{},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "addWorker\x0a\x09worker valueWithTimeout: 0.\x0a\x09poolSize := poolSize + 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["valueWithTimeout:", "+"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "defaultMaxPoolSize",
+protocol: 'defaults',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._defaultMaxPoolSize();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"defaultMaxPoolSize",{},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultMaxPoolSize\x0a\x09^ self class defaultMaxPoolSize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["defaultMaxPoolSize", "class"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "fork:",
+protocol: 'actions',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@poolSize"]).__lt(self._maxPoolSize());
+if($core.assert($1)){
+self._addWorker();
+};
+$recv(self["@queue"])._nextPut_(aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fork:",{aBlock:aBlock},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "fork: aBlock\x0a\x09poolSize < self maxPoolSize ifTrue: [ self addWorker ].\x0a\x09queue nextPut: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "<", "maxPoolSize", "addWorker", "nextPut:"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Queue(){return $globals.Queue||(typeof Queue=="undefined"?nil:Queue)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ForkPool.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@poolSize"]=(0);
+self["@queue"]=$recv($Queue())._new();
+self["@worker"]=self._makeWorker();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09\x0a\x09poolSize := 0.\x0a\x09queue := Queue new.\x0a\x09worker := self makeWorker",
+referencedClasses: ["Queue"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new", "makeWorker"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "makeWorker",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+var sentinel;
+function $Object(){return $globals.Object||(typeof Object=="undefined"?nil:Object)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+sentinel=$recv($Object())._new();
+$1=(function(){
+var block;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self["@poolSize"]=$recv(self["@poolSize"]).__minus((1));
+self["@poolSize"];
+block=$recv(self["@queue"])._nextIfAbsent_((function(){
+return sentinel;
+
+}));
+block;
+$2=$recv(block).__eq_eq(sentinel);
+if(!$core.assert($2)){
+return $recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(block)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,4)});
+//>>excludeEnd("ctx");
+}))._ensure_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._addWorker();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,5)});
+//>>excludeEnd("ctx");
+}));
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({block:block},$ctx1,1)});
+//>>excludeEnd("ctx");
+});
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"makeWorker",{sentinel:sentinel},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "makeWorker\x0a\x09| sentinel |\x0a\x09sentinel := Object new.\x0a\x09^ [ | block |\x0a\x09\x09poolSize := poolSize - 1.\x0a\x09\x09block := queue nextIfAbsent: [ sentinel ].\x0a\x09\x09block == sentinel ifFalse: [\x0a\x09\x09\x09[ block value ] ensure: [ self addWorker ] ]]",
+referencedClasses: ["Object"],
+//>>excludeEnd("ide");
+messageSends: ["new", "-", "nextIfAbsent:", "ifFalse:", "==", "ensure:", "value", "addWorker"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "maxPoolSize",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@maxPoolSize"];
+if(($receiver = $2) == null || $receiver.isNil){
+$1=self._defaultMaxPoolSize();
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"maxPoolSize",{},$globals.ForkPool)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "maxPoolSize\x0a\x09^ maxPoolSize ifNil: [ self defaultMaxPoolSize ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "defaultMaxPoolSize"]
+}),
+$globals.ForkPool);
+
+$core.addMethod(
+$core.method({
+selector: "maxPoolSize:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+self["@maxPoolSize"]=anInteger;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "maxPoolSize: anInteger\x0a\x09maxPoolSize := anInteger",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ForkPool);
+
+
+$globals.ForkPool.klass.iVarNames = ['default'];
+$core.addMethod(
+$core.method({
+selector: "default",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@default"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@default"]=self._new();
+$1=self["@default"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"default",{},$globals.ForkPool.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "default\x0a\x09^ default ifNil: [ default := self new ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "new"]
+}),
+$globals.ForkPool.klass);
+
+$core.addMethod(
+$core.method({
+selector: "defaultMaxPoolSize",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return (100);
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "defaultMaxPoolSize\x0a\x09^ 100",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ForkPool.klass);
+
+$core.addMethod(
+$core.method({
+selector: "resetDefault",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+self["@default"]=nil;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "resetDefault\x0a\x09default := nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ForkPool.klass);
+
+
+$core.addClass('Message', $globals.Object, ['selector', 'arguments'], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Message.comment="In general, the system does not use instances of me for efficiency reasons.\x0aHowever, when a message is not understood by its receiver, the interpreter will make up an instance of it in order to capture the information involved in an actual message transmission.\x0aThis instance is sent it as an argument with the message `#doesNotUnderstand:` to the receiver.\x0a\x0aSee boot.js, `messageNotUnderstood` and its counterpart `Object >> #doesNotUnderstand:`\x0a\x0a## API\x0a\x0aBesides accessing methods, `#sendTo:` provides a convenient way to send a message to an object.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@arguments"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ arguments",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Message);
+
+$core.addMethod(
+$core.method({
+selector: "arguments:",
+protocol: 'accessing',
+fn: function (anArray){
+var self=this;
+self["@arguments"]=anArray;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArray"],
+source: "arguments: anArray\x0a\x09arguments := anArray",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Message);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.Message.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aStream)._nextPutAll_("(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Message)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09aStream\x0a\x09\x09nextPutAll: '(';\x0a\x09\x09nextPutAll: self selector;\x0a\x09\x09nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "selector"]
+}),
+$globals.Message);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@selector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Message);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+self["@selector"]=aString;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09selector := aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Message);
+
+$core.addMethod(
+$core.method({
+selector: "sendTo:",
+protocol: 'actions',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anObject)._perform_withArguments_(self._selector(),self._arguments());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendTo:",{anObject:anObject},$globals.Message)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "sendTo: anObject\x0a\x09^ anObject perform: self selector withArguments: self arguments",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["perform:withArguments:", "selector", "arguments"]
+}),
+$globals.Message);
+
+
+$core.addMethod(
+$core.method({
+selector: "selector:arguments:",
+protocol: 'instance creation',
+fn: function (aString,anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._selector_(aString);
+$recv($2)._arguments_(anArray);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector:arguments:",{aString:aString,anArray:anArray},$globals.Message.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anArray"],
+source: "selector: aString arguments: anArray\x0a\x09^ self new\x0a\x09\x09selector: aString;\x0a\x09\x09arguments: anArray;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["selector:", "new", "arguments:", "yourself"]
+}),
+$globals.Message.klass);
+
+
+$core.addClass('MessageSend', $globals.Object, ['receiver', 'message'], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MessageSend.comment="I encapsulate message sends to objects. Arguments can be either predefined or supplied when the message send is performed. \x0a\x0a## API\x0a\x0aUse `#value` to perform a message send with its predefined arguments and `#value:*` if additonal arguments have to supplied.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "arguments",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@message"])._arguments();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments",{},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arguments\x0a\x09^ message arguments",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "arguments:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@message"])._arguments_(aCollection);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arguments:",{aCollection:aCollection},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "arguments: aCollection\x0a\x09message arguments: aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments:"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Message(){return $globals.Message||(typeof Message=="undefined"?nil:Message)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.MessageSend.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@message"]=$recv($Message())._new();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09message := Message new",
+referencedClasses: ["Message"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.MessageSend.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aStream)._nextPutAll_("(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._receiver());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(" >> ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09aStream\x0a\x09\x09nextPutAll: '(';\x0a\x09\x09nextPutAll: self receiver;\x0a\x09\x09nextPutAll: ' >> ';\x0a\x09\x09nextPutAll: self selector;\x0a\x09\x09nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "receiver", "selector"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@receiver"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "receiver:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@receiver"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "receiver: anObject\x0a\x09receiver := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@message"])._selector();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector",{},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ message selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["selector"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@message"])._selector_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector:",{aString:aString},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "selector: aString\x0a\x09message selector: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["selector:"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'evaluating',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@message"])._sendTo_(self._receiver());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09^ message sendTo: self receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sendTo:", "receiver"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'evaluating',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self["@message"];
+$recv($2)._arguments_([anObject]);
+$3=$recv($2)._sendTo_(self._receiver());
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{anObject:anObject},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "value: anObject\x0a\x09^ message \x0a\x09\x09arguments: { anObject };\x0a\x09\x09sendTo: self receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments:", "sendTo:", "receiver"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:",
+protocol: 'evaluating',
+fn: function (firstArgument,secondArgument){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self["@message"];
+$recv($2)._arguments_([firstArgument,secondArgument]);
+$3=$recv($2)._sendTo_(self._receiver());
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:",{firstArgument:firstArgument,secondArgument:secondArgument},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArgument", "secondArgument"],
+source: "value: firstArgument value: secondArgument\x0a\x09^ message \x0a\x09\x09arguments: { firstArgument. secondArgument };\x0a\x09\x09sendTo: self receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments:", "sendTo:", "receiver"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "value:value:value:",
+protocol: 'evaluating',
+fn: function (firstArgument,secondArgument,thirdArgument){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self["@message"];
+$recv($2)._arguments_([firstArgument,secondArgument,thirdArgument]);
+$3=$recv($2)._sendTo_(self._receiver());
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:value:value:",{firstArgument:firstArgument,secondArgument:secondArgument,thirdArgument:thirdArgument},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["firstArgument", "secondArgument", "thirdArgument"],
+source: "value: firstArgument value: secondArgument value: thirdArgument\x0a\x09^ message \x0a\x09\x09arguments: { firstArgument. secondArgument. thirdArgument };\x0a\x09\x09sendTo: self receiver",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments:", "sendTo:", "receiver"]
+}),
+$globals.MessageSend);
+
+$core.addMethod(
+$core.method({
+selector: "valueWithPossibleArguments:",
+protocol: 'evaluating',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._arguments_(aCollection);
+$1=self._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valueWithPossibleArguments:",{aCollection:aCollection},$globals.MessageSend)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "valueWithPossibleArguments: aCollection\x0a\x09self arguments: aCollection.\x0a\x09^ self value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["arguments:", "value"]
+}),
+$globals.MessageSend);
+
+
+
+$core.addClass('MethodContext', $globals.Object, [], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.MethodContext.comment="I hold all the dynamic state associated with the execution of either a method activation resulting from a message send. I am used to build the call stack while debugging.\x0a\x0aMy instances are JavaScript `SmalltalkMethodContext` objects defined in `boot.js`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$5,$7,$6,$4,$11,$10,$9,$8,$12,$16,$15,$14,$13,$1;
+$2=self._isBlockContext();
+if($core.assert($2)){
+$3="a block (in ".__comma($recv(self._methodContext())._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$1=$recv($3).__comma(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+} else {
+var methodClass;
+methodClass=$recv(self._method())._methodClass();
+methodClass;
+$5=methodClass;
+$7=self._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__eq($6);
+if($core.assert($4)){
+$11=self._receiver();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["receiver"]=2;
+//>>excludeEnd("ctx");
+$10=$recv($11)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=2;
+//>>excludeEnd("ctx");
+$9=$recv($10)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$8=$recv($9).__comma(" >> ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=4;
+//>>excludeEnd("ctx");
+$12=self._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($8).__comma($12);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+} else {
+$16=$recv($recv(self._receiver())._class())._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=2;
+//>>excludeEnd("ctx");
+$15=$recv($16).__comma("(");
+$14=$recv($15).__comma($recv(methodClass)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=7;
+//>>excludeEnd("ctx");
+$13=$recv($14).__comma(") >> ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=6;
+//>>excludeEnd("ctx");
+$1=$recv($13).__comma(self._selector());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+};
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09^ self isBlockContext\x0a\x09\x09ifTrue: [ 'a block (in ', self methodContext asString, ')' ]\x0a\x09\x09ifFalse: [ \x0a\x09\x09\x09| methodClass |\x0a\x09\x09\x09methodClass := self method methodClass.\x0a\x09\x09\x09methodClass = self receiver class \x0a\x09\x09\x09\x09ifTrue: [ self receiver class name, ' >> ', self selector ]\x0a\x09\x09\x09\x09ifFalse: [ self receiver class name, '(', methodClass name, ') >> ', self selector ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isBlockContext", ",", "asString", "methodContext", "methodClass", "method", "=", "class", "receiver", "name", "selector"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "basicReceiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.receiver;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicReceiver",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "basicReceiver\x0a\x09<return self.receiver>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "evaluatedSelector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.evaluatedSelector;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluatedSelector",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "evaluatedSelector\x0a\x09<return self.evaluatedSelector>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "findContextSuchThat:",
+protocol: 'accessing',
+fn: function (testBlock){
+var self=this;
+var context;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+var $early={};
+try {
+context=self;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(context)._isNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(testBlock)._value_(context);
+if($core.assert($1)){
+$2=context;
+throw $early=[$2];
+};
+context=$recv(context)._outerContext();
+return context;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return nil;
+}
+catch(e) {if(e===$early)return e[0]; throw e}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"findContextSuchThat:",{testBlock:testBlock,context:context},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["testBlock"],
+source: "findContextSuchThat: testBlock\x0a\x09\x22Search self and my sender chain for first one that satisfies `testBlock`.  \x0a\x09Answer `nil` if none satisfy\x22\x0a\x0a\x09| context |\x0a\x09\x0a\x09context := self.\x0a\x09[ context isNil] whileFalse: [\x0a\x09\x09(testBlock value: context) \x0a\x09\x09\x09ifTrue: [ ^ context ].\x0a\x09\x09context := context outerContext ].\x0a\x0a\x09^ nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", "isNil", "ifTrue:", "value:", "outerContext"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "home",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.homeContext;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"home",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "home\x0a\x09<return self.homeContext>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "index",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.index || 0;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"index",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "index\x0a\x09<return self.index || 0>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "isBlockContext",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._selector())._isNil();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isBlockContext",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBlockContext\x0a\x09\x22Block context do not have selectors.\x22\x0a\x09\x0a\x09^ self selector isNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["isNil", "selector"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "locals",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.locals || {};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"locals",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "locals\x0a\x09<return self.locals || {}>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "method",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var method,lookupClass,receiverClass,supercall;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$4,$6,$5,$7,$9,$8,$receiver;
+$1=self._methodContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodContext"]=1;
+//>>excludeEnd("ctx");
+if(($receiver = $1) == null || $receiver.isNil){
+return nil;
+} else {
+$1;
+};
+$3=self._methodContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodContext"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3)._receiver();
+receiverClass=$recv($2)._class();
+$4=receiverClass;
+$6=self._methodContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["methodContext"]=3;
+//>>excludeEnd("ctx");
+$5=$recv($6)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["selector"]=1;
+//>>excludeEnd("ctx");
+method=$recv($4)._lookupSelector_($5);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["lookupSelector:"]=1;
+//>>excludeEnd("ctx");
+$7=self._outerContext();
+if(($receiver = $7) == null || $receiver.isNil){
+supercall=false;
+} else {
+var outer;
+outer=$receiver;
+supercall=$recv(outer)._supercall();
+};
+$9=supercall;
+if($core.assert($9)){
+$8=$recv($recv($recv(method)._methodClass())._superclass())._lookupSelector_($recv(self._methodContext())._selector());
+} else {
+$8=method;
+};
+return $8;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"method",{method:method,lookupClass:lookupClass,receiverClass:receiverClass,supercall:supercall},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "method\x0a\x09| method lookupClass receiverClass supercall |\x0a\x09\x0a\x09self methodContext ifNil: [ ^ nil ].\x0a\x0a\x09receiverClass := self methodContext receiver class.\x0a\x09method := receiverClass lookupSelector: self methodContext selector.\x0a\x09supercall := self outerContext \x0a\x09\x09ifNil: [ false ]\x0a\x09\x09ifNotNil: [ :outer | outer supercall ].\x0a\x0a\x09^ supercall\x0a\x09\x09ifFalse: [ method ]\x0a\x09\x09ifTrue: [ method methodClass superclass lookupSelector: self methodContext selector ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "methodContext", "class", "receiver", "lookupSelector:", "selector", "ifNil:ifNotNil:", "outerContext", "supercall", "ifFalse:ifTrue:", "superclass", "methodClass"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "methodContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$3,$2,$receiver;
+$1=self._isBlockContext();
+if(!$core.assert($1)){
+return self;
+};
+$3=self._outerContext();
+if(($receiver = $3) == null || $receiver.isNil){
+$2=$3;
+} else {
+var outer;
+outer=$receiver;
+$2=$recv(outer)._methodContext();
+};
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodContext",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "methodContext\x0a\x09self isBlockContext ifFalse: [ ^ self ].\x0a\x09\x0a\x09^ self outerContext ifNotNil: [ :outer |\x0a\x09\x09outer methodContext ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isBlockContext", "ifNotNil:", "outerContext", "methodContext"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "outerContext",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.outerContext || self.homeContext;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"outerContext",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "outerContext\x0a\x09<return self.outerContext || self.homeContext>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.MethodContext.superclass.fn.prototype._printOn_.apply($recv(self), [aStream]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv(aStream)._nextPutAll_("(");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._asString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$1=$recv(aStream)._nextPutAll_(")");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09super printOn: aStream.\x0a\x09aStream \x0a\x09\x09nextPutAll: '(';\x0a\x09\x09nextPutAll: self asString;\x0a\x09\x09nextPutAll: ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "asString"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "receiver",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$2=$recv(self._isBlockContext())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=self._outerContext();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["outerContext"]=1;
+//>>excludeEnd("ctx");
+return $recv($3)._notNil();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($2)){
+$1=$recv(self._outerContext())._receiver();
+} else {
+$1=self._basicReceiver();
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"receiver",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "receiver\x0a\x09^ (self isBlockContext and: [ self outerContext notNil ])\x0a\x09\x09ifTrue: [ self outerContext receiver ]\x0a\x09\x09ifFalse: [ self basicReceiver ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "and:", "isBlockContext", "notNil", "outerContext", "receiver", "basicReceiver"]
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self.selector) {
+			return $core.js2st(self.selector);
+		} else {
+			return nil;
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09<\x0a\x09\x09if(self.selector) {\x0a\x09\x09\x09return $core.js2st(self.selector);\x0a\x09\x09} else {\x0a\x09\x09\x09return nil;\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexAt:",
+protocol: 'accessing',
+fn: function (aSelector){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.sendIdx[aSelector] || 0;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendIndexAt:",{aSelector:aSelector},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSelector"],
+source: "sendIndexAt: aSelector\x0a\x09<return self.sendIdx[aSelector] || 0>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "sendIndexes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.sendIdx;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sendIndexes",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sendIndexes\x0a\x09<return self.sendIdx>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "supercall",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.supercall == true;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"supercall",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "supercall\x0a\x09<return self.supercall == true>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.MethodContext);
+
+$core.addMethod(
+$core.method({
+selector: "temps",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=self._locals();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"temps",{},$globals.MethodContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "temps\x0a\x09self deprecatedAPI.\x0a\x09\x0a\x09^ self locals",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "locals"]
+}),
+$globals.MethodContext);
+
+
+
+$core.addClass('NativeFunction', $globals.Object, [], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.NativeFunction.comment="I am a wrapper around native functions, such as `WebSocket`.\x0aFor 'normal' functions (whose constructor is the JavaScript `Function` object), use `BlockClosure`.\x0a\x0a## API\x0a\x0aSee the class-side `instance creation` methods for instance creation.\x0a\x0aCreated instances will most probably be instance of `JSObjectProxy`.\x0a\x0a## Usage example:\x0a\x0a\x09| ws |\x0a\x09ws := NativeFunction constructor: 'WebSocket' value: 'ws://localhost'.\x0a\x09ws at: 'onopen' put: [ ws send: 'hey there from Amber' ]";
+//>>excludeEnd("ide");
+
+$core.addMethod(
+$core.method({
+selector: "constructor:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=eval(aString);
+		return new nativeFunc();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructor:",{aString:aString},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "constructor: aString\x0a\x09<\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructor:value:",
+protocol: 'instance creation',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructor:value:",{aString:aString,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "constructor: aString value:anObject\x0a\x09<\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc(anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructor:value:value:",
+protocol: 'instance creation',
+fn: function (aString,anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructor:value:value:",{aString:aString,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "anObject2"],
+source: "constructor: aString value:anObject value: anObject2\x0a\x09<\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc(anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructor:value:value:value:",
+protocol: 'instance creation',
+fn: function (aString,anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructor:value:value:value:",{aString:aString,anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "anObject2", "anObject3"],
+source: "constructor: aString value:anObject value: anObject2 value:anObject3\x0a\x09<\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc(anObject,anObject2, anObject3);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "exists:",
+protocol: 'testing',
+fn: function (aString){
+var self=this;
+function $PlatformInterface(){return $globals.PlatformInterface||(typeof PlatformInterface=="undefined"?nil:PlatformInterface)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($PlatformInterface())._existsGlobal_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exists:",{aString:aString},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "exists: aString\x0a\x09^ PlatformInterface existsGlobal: aString",
+referencedClasses: ["PlatformInterface"],
+//>>excludeEnd("ide");
+messageSends: ["existsGlobal:"]
+}),
+$globals.NativeFunction.klass);
+
+
+$core.addClass('Timeout', $globals.Object, ['rawTimeout'], 'Kernel-Methods');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Timeout.comment="I am wrapping the returns from `set{Timeout,Interval}`.\x0a\x0a## Motivation\x0a\x0aNumber suffices in browsers, but node.js returns an object.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "clearInterval",
+protocol: 'timeout/interval',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var interval = self["@rawTimeout"];
+		clearInterval(interval);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"clearInterval",{},$globals.Timeout)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "clearInterval\x0a\x09<\x0a\x09\x09var interval = self[\x22@rawTimeout\x22];\x0a\x09\x09clearInterval(interval);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Timeout);
+
+$core.addMethod(
+$core.method({
+selector: "clearTimeout",
+protocol: 'timeout/interval',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var timeout = self["@rawTimeout"];
+		clearTimeout(timeout);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"clearTimeout",{},$globals.Timeout)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "clearTimeout\x0a\x09<\x0a\x09\x09var timeout = self[\x22@rawTimeout\x22];\x0a\x09\x09clearTimeout(timeout);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Timeout);
+
+$core.addMethod(
+$core.method({
+selector: "rawTimeout:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+self["@rawTimeout"]=anObject;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "rawTimeout: anObject\x0a\x09rawTimeout := anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Timeout);
+
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._rawTimeout_(anObject);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{anObject:anObject},$globals.Timeout.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "on: anObject\x0a\x09^ self new rawTimeout: anObject; yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["rawTimeout:", "new", "yourself"]
+}),
+$globals.Timeout.klass);
+
+});

+ 784 - 0
bower_components/amber/src/Kernel-Methods.st

@@ -0,0 +1,784 @@
+Smalltalk createPackage: 'Kernel-Methods'!
+Object subclass: #BlockClosure
+	instanceVariableNames: ''
+	package: 'Kernel-Methods'!
+!BlockClosure commentStamp!
+I represent a lexical closure.
+I am is directly mapped to JavaScript Function.
+
+## API
+
+1. Evaluation
+
+    My instances get evaluated with the `#value*` methods in the 'evaluating' protocol.
+
+    Example: ` [ :x | x + 1 ] value: 3 "Answers 4" `
+
+2. Control structures
+
+    Blocks are used (together with `Boolean`) for control structures (methods in the `controlling` protocol).
+
+    Example: `aBlock whileTrue: [ ... ]`
+
+3. Error handling
+
+    I provide the `#on:do:` method for handling exceptions.
+
+    Example: ` aBlock on: MessageNotUnderstood do: [ :ex | ... ] `!
+
+!BlockClosure methodsFor: 'accessing'!
+
+compiledSource
+	<return self.toString()>
+!
+
+numArgs
+	<return self.length>
+!
+
+receiver
+	^ nil
+! !
+
+!BlockClosure methodsFor: 'controlling'!
+
+whileFalse
+	self whileFalse: []
+!
+
+whileFalse: aBlock
+	<while(!!$core.assert(self._value())) {aBlock._value()}>
+!
+
+whileTrue
+	self whileTrue: []
+!
+
+whileTrue: aBlock
+	<while($core.assert(self._value())) {aBlock._value()}>
+! !
+
+!BlockClosure methodsFor: 'converting'!
+
+asCompiledMethod: aString
+	<return $core.method({selector:aString, fn:self});>
+!
+
+currySelf
+	"Transforms [ :selfarg :x :y | stcode ] block
+	which represents JS function (selfarg, x, y, ...) {jscode}
+	into function (x, y, ...) {jscode} that takes selfarg from 'this'.
+	IOW, it is usable as JS method and first arg takes the receiver."
+	
+	<
+		return function () {
+			var args = [ this ];
+			args.push.apply(args, arguments);
+			return self.apply(null, args);
+		}
+	>
+! !
+
+!BlockClosure methodsFor: 'error handling'!
+
+on: anErrorClass do: aBlock
+	"All exceptions thrown in the Smalltalk stack are cought.
+	Convert all JS exceptions to JavaScriptException instances."
+	
+	^ self tryCatch: [ :error | | smalltalkError |
+		smalltalkError := Smalltalk asSmalltalkException: error.
+		(smalltalkError isKindOf: anErrorClass)
+		ifTrue: [ aBlock value: smalltalkError ]
+		ifFalse: [ smalltalkError resignal ] ]
+!
+
+tryCatch: aBlock
+	<
+		try {
+			return self._value();
+		} catch(error) {
+			return aBlock._value_(error);
+		}
+	>
+! !
+
+!BlockClosure methodsFor: 'evaluating'!
+
+applyTo: anObject arguments: aCollection
+	<return self.apply(anObject, aCollection)>
+!
+
+ensure: aBlock
+	<try{return self._value()}finally{aBlock._value()}>
+!
+
+new
+	"Use the receiver as a JS constructor.
+	*Do not* use this method to instanciate Smalltalk objects!!"
+	<return new self()>
+!
+
+newValue: anObject
+	^ self newWithValues: { anObject }
+!
+
+newValue: anObject value: anObject2
+	^ self newWithValues: { anObject. anObject2 }.
+!
+
+newValue: anObject value: anObject2 value: anObject3
+	^ self newWithValues: { anObject. anObject2. anObject3 }.
+!
+
+newWithValues: aCollection
+	"Simulates JS new operator by combination of Object.create and .apply"
+	<
+		var object = Object.create(self.prototype);
+		var result = self.apply(object, aCollection);
+		return typeof result === "object" ? result : object;
+	>
+!
+
+timeToRun
+	"Answer the number of milliseconds taken to execute this block."
+
+	^ Date millisecondsToRun: self
+!
+
+value
+	<return self();>
+!
+
+value: anArg
+	<return self(anArg);>
+!
+
+value: firstArg value: secondArg
+	<return self(firstArg, secondArg);>
+!
+
+value: firstArg value: secondArg value: thirdArg
+	<return self(firstArg, secondArg, thirdArg);>
+!
+
+valueWithPossibleArguments: aCollection
+	<return self.apply(null, aCollection);>
+! !
+
+!BlockClosure methodsFor: 'timeout/interval'!
+
+fork
+	ForkPool default fork: self
+!
+
+valueWithInterval: aNumber
+	<
+		var interval = setInterval(self, aNumber);
+		return $globals.Timeout._on_(interval);
+	>
+!
+
+valueWithTimeout: aNumber
+	<
+		var timeout = setTimeout(self, aNumber);
+		return $globals.Timeout._on_(timeout);
+	>
+! !
+
+Object subclass: #CompiledMethod
+	instanceVariableNames: ''
+	package: 'Kernel-Methods'!
+!CompiledMethod commentStamp!
+I represent a class method of the system. I hold the source and compiled code of a class method.
+
+## API
+My instances can be accessed using `Behavior >> #methodAt:`
+
+    Object methodAt: 'asString'
+
+Source code access:
+
+	(String methodAt: 'lines') source
+
+Referenced classes:
+
+	(String methodAt: 'lines') referencedClasses
+
+Messages sent from an instance:
+	
+	(String methodAt: 'lines') messageSends!
+
+!CompiledMethod methodsFor: 'accessing'!
+
+arguments
+	<return self.args || []>
+!
+
+category
+	^ self protocol
+!
+
+fn
+	^ self basicAt: 'fn'
+!
+
+fn: aBlock
+	self basicAt: 'fn' put: aBlock
+!
+
+messageSends
+	^ self basicAt: 'messageSends'
+!
+
+methodClass
+	^ self basicAt: 'methodClass'
+!
+
+package
+	"Answer the package the receiver belongs to:
+	- if it is an extension method, answer the corresponding package
+	- else answer the `methodClass` package"
+	
+	self methodClass ifNil: [ ^ nil ].
+	
+	(self protocol beginsWith: '*') ifFalse: [
+		^ self methodClass package ].
+		
+	^ Package 
+		named: self protocol allButFirst
+		ifAbsent: [ nil ]
+!
+
+protocol
+	^ (self basicAt: 'protocol') ifNil: [ self defaultProtocol ]
+!
+
+protocol: aString
+	| oldProtocol |
+	oldProtocol := self protocol.
+	self basicAt: 'protocol' put: aString.
+
+	SystemAnnouncer current announce: (MethodMoved new
+		method: self;
+		oldProtocol: oldProtocol;
+		yourself).
+
+	self methodClass ifNotNil: [ :methodClass |
+		methodClass organization addElement: aString.
+		methodClass removeProtocolIfEmpty: oldProtocol ]
+!
+
+referencedClasses
+	^ self basicAt: 'referencedClasses'
+!
+
+selector
+	^ self basicAt: 'selector'
+!
+
+selector: aString
+	self basicAt: 'selector' put: aString
+!
+
+source
+	^ (self basicAt: 'source') ifNil: [ '' ]
+!
+
+source: aString
+	self basicAt: 'source' put: aString
+! !
+
+!CompiledMethod methodsFor: 'browsing'!
+
+browse
+	Finder findMethod: self
+! !
+
+!CompiledMethod methodsFor: 'defaults'!
+
+defaultProtocol
+	^ 'as yet unclassified'
+! !
+
+!CompiledMethod methodsFor: 'evaluating'!
+
+sendTo: anObject arguments: aCollection
+	^ self fn applyTo: anObject arguments: aCollection
+! !
+
+!CompiledMethod methodsFor: 'testing'!
+
+isCompiledMethod
+	^ true
+!
+
+isOverridden
+	| selector |
+    
+    selector := self selector.
+    self methodClass allSubclassesDo: [ :each |
+	    (each includesSelector: selector)
+        	ifTrue: [ ^ true ] ].
+	^ false
+!
+
+isOverride
+	| superclass |
+    
+    superclass := self methodClass superclass.
+	superclass ifNil: [ ^ false ].
+	
+    ^ (self methodClass superclass lookupSelector: self selector) notNil
+! !
+
+Object subclass: #ForkPool
+	instanceVariableNames: 'poolSize maxPoolSize queue worker'
+	package: 'Kernel-Methods'!
+!ForkPool commentStamp!
+I am responsible for handling forked blocks.
+The pool size sets the maximum concurrent forked blocks.
+
+## API
+
+The default instance is accessed with `#default`.
+The maximum concurrent forked blocks can be set with `#maxPoolSize:`.
+
+Forking is done via `BlockClosure >> #fork`!
+
+!ForkPool methodsFor: 'accessing'!
+
+maxPoolSize
+	^ maxPoolSize ifNil: [ self defaultMaxPoolSize ]
+!
+
+maxPoolSize: anInteger
+	maxPoolSize := anInteger
+! !
+
+!ForkPool methodsFor: 'actions'!
+
+fork: aBlock
+	poolSize < self maxPoolSize ifTrue: [ self addWorker ].
+	queue nextPut: aBlock
+! !
+
+!ForkPool methodsFor: 'defaults'!
+
+defaultMaxPoolSize
+	^ self class defaultMaxPoolSize
+! !
+
+!ForkPool methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	
+	poolSize := 0.
+	queue := Queue new.
+	worker := self makeWorker
+!
+
+makeWorker
+	| sentinel |
+	sentinel := Object new.
+	^ [ | block |
+		poolSize := poolSize - 1.
+		block := queue nextIfAbsent: [ sentinel ].
+		block == sentinel ifFalse: [
+			[ block value ] ensure: [ self addWorker ] ]]
+! !
+
+!ForkPool methodsFor: 'private'!
+
+addWorker
+	worker valueWithTimeout: 0.
+	poolSize := poolSize + 1
+! !
+
+ForkPool class instanceVariableNames: 'default'!
+
+!ForkPool class methodsFor: 'accessing'!
+
+default
+	^ default ifNil: [ default := self new ]
+!
+
+defaultMaxPoolSize
+	^ 100
+!
+
+resetDefault
+	default := nil
+! !
+
+Object subclass: #Message
+	instanceVariableNames: 'selector arguments'
+	package: 'Kernel-Methods'!
+!Message commentStamp!
+In general, the system does not use instances of me for efficiency reasons.
+However, when a message is not understood by its receiver, the interpreter will make up an instance of it in order to capture the information involved in an actual message transmission.
+This instance is sent it as an argument with the message `#doesNotUnderstand:` to the receiver.
+
+See boot.js, `messageNotUnderstood` and its counterpart `Object >> #doesNotUnderstand:`
+
+## API
+
+Besides accessing methods, `#sendTo:` provides a convenient way to send a message to an object.!
+
+!Message methodsFor: 'accessing'!
+
+arguments
+	^ arguments
+!
+
+arguments: anArray
+	arguments := anArray
+!
+
+selector
+	^ selector
+!
+
+selector: aString
+	selector := aString
+! !
+
+!Message methodsFor: 'actions'!
+
+sendTo: anObject
+	^ anObject perform: self selector withArguments: self arguments
+! !
+
+!Message methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	aStream
+		nextPutAll: '(';
+		nextPutAll: self selector;
+		nextPutAll: ')'
+! !
+
+!Message class methodsFor: 'instance creation'!
+
+selector: aString arguments: anArray
+	^ self new
+		selector: aString;
+		arguments: anArray;
+		yourself
+! !
+
+Object subclass: #MessageSend
+	instanceVariableNames: 'receiver message'
+	package: 'Kernel-Methods'!
+!MessageSend commentStamp!
+I encapsulate message sends to objects. Arguments can be either predefined or supplied when the message send is performed. 
+
+## API
+
+Use `#value` to perform a message send with its predefined arguments and `#value:*` if additonal arguments have to supplied.!
+
+!MessageSend methodsFor: 'accessing'!
+
+arguments
+	^ message arguments
+!
+
+arguments: aCollection
+	message arguments: aCollection
+!
+
+receiver
+	^ receiver
+!
+
+receiver: anObject
+	receiver := anObject
+!
+
+selector
+	^ message selector
+!
+
+selector: aString
+	message selector: aString
+! !
+
+!MessageSend methodsFor: 'evaluating'!
+
+value
+	^ message sendTo: self receiver
+!
+
+value: anObject
+	^ message 
+		arguments: { anObject };
+		sendTo: self receiver
+!
+
+value: firstArgument value: secondArgument
+	^ message 
+		arguments: { firstArgument. secondArgument };
+		sendTo: self receiver
+!
+
+value: firstArgument value: secondArgument value: thirdArgument
+	^ message 
+		arguments: { firstArgument. secondArgument. thirdArgument };
+		sendTo: self receiver
+!
+
+valueWithPossibleArguments: aCollection
+	self arguments: aCollection.
+	^ self value
+! !
+
+!MessageSend methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	message := Message new
+! !
+
+!MessageSend methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	aStream
+		nextPutAll: '(';
+		nextPutAll: self receiver;
+		nextPutAll: ' >> ';
+		nextPutAll: self selector;
+		nextPutAll: ')'
+! !
+
+Object subclass: #MethodContext
+	instanceVariableNames: ''
+	package: 'Kernel-Methods'!
+!MethodContext commentStamp!
+I hold all the dynamic state associated with the execution of either a method activation resulting from a message send. I am used to build the call stack while debugging.
+
+My instances are JavaScript `SmalltalkMethodContext` objects defined in `boot.js`.!
+
+!MethodContext methodsFor: 'accessing'!
+
+basicReceiver
+	<return self.receiver>
+!
+
+evaluatedSelector
+	<return self.evaluatedSelector>
+!
+
+findContextSuchThat: testBlock
+	"Search self and my sender chain for first one that satisfies `testBlock`.  
+	Answer `nil` if none satisfy"
+
+	| context |
+	
+	context := self.
+	[ context isNil] whileFalse: [
+		(testBlock value: context) 
+			ifTrue: [ ^ context ].
+		context := context outerContext ].
+
+	^ nil
+!
+
+home
+	<return self.homeContext>
+!
+
+index
+	<return self.index || 0>
+!
+
+locals
+	<return self.locals || {}>
+!
+
+method
+	| method lookupClass receiverClass supercall |
+	
+	self methodContext ifNil: [ ^ nil ].
+
+	receiverClass := self methodContext receiver class.
+	method := receiverClass lookupSelector: self methodContext selector.
+	supercall := self outerContext 
+		ifNil: [ false ]
+		ifNotNil: [ :outer | outer supercall ].
+
+	^ supercall
+		ifFalse: [ method ]
+		ifTrue: [ method methodClass superclass lookupSelector: self methodContext selector ]
+!
+
+methodContext
+	self isBlockContext ifFalse: [ ^ self ].
+	
+	^ self outerContext ifNotNil: [ :outer |
+		outer methodContext ]
+!
+
+outerContext
+	<return self.outerContext || self.homeContext>
+!
+
+receiver
+	^ (self isBlockContext and: [ self outerContext notNil ])
+		ifTrue: [ self outerContext receiver ]
+		ifFalse: [ self basicReceiver ]
+!
+
+selector
+	<
+		if(self.selector) {
+			return $core.js2st(self.selector);
+		} else {
+			return nil;
+		}
+	>
+!
+
+sendIndexAt: aSelector
+	<return self.sendIdx[aSelector] || 0>
+!
+
+sendIndexes
+	<return self.sendIdx>
+!
+
+supercall
+	<return self.supercall == true>
+!
+
+temps
+	self deprecatedAPI.
+	
+	^ self locals
+! !
+
+!MethodContext methodsFor: 'converting'!
+
+asString
+	^ self isBlockContext
+		ifTrue: [ 'a block (in ', self methodContext asString, ')' ]
+		ifFalse: [ 
+			| methodClass |
+			methodClass := self method methodClass.
+			methodClass = self receiver class 
+				ifTrue: [ self receiver class name, ' >> ', self selector ]
+				ifFalse: [ self receiver class name, '(', methodClass name, ') >> ', self selector ] ]
+! !
+
+!MethodContext methodsFor: 'printing'!
+
+printOn: aStream
+	super printOn: aStream.
+	aStream 
+		nextPutAll: '(';
+		nextPutAll: self asString;
+		nextPutAll: ')'
+! !
+
+!MethodContext methodsFor: 'testing'!
+
+isBlockContext
+	"Block context do not have selectors."
+	
+	^ self selector isNil
+! !
+
+Object subclass: #NativeFunction
+	instanceVariableNames: ''
+	package: 'Kernel-Methods'!
+!NativeFunction commentStamp!
+I am a wrapper around native functions, such as `WebSocket`.
+For 'normal' functions (whose constructor is the JavaScript `Function` object), use `BlockClosure`.
+
+## API
+
+See the class-side `instance creation` methods for instance creation.
+
+Created instances will most probably be instance of `JSObjectProxy`.
+
+## Usage example:
+
+	| ws |
+	ws := NativeFunction constructor: 'WebSocket' value: 'ws://localhost'.
+	ws at: 'onopen' put: [ ws send: 'hey there from Amber' ]!
+
+!NativeFunction class methodsFor: 'instance creation'!
+
+constructor: aString
+	<
+		var nativeFunc=eval(aString);
+		return new nativeFunc();
+	>
+!
+
+constructor: aString value:anObject
+	<
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject);
+	>
+!
+
+constructor: aString value:anObject value: anObject2
+	<
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject,anObject2);
+	>
+!
+
+constructor: aString value:anObject value: anObject2 value:anObject3
+	<
+		var nativeFunc=eval(aString);
+		return new nativeFunc(anObject,anObject2, anObject3);
+	>
+! !
+
+!NativeFunction class methodsFor: 'testing'!
+
+exists: aString
+	^ PlatformInterface existsGlobal: aString
+! !
+
+Object subclass: #Timeout
+	instanceVariableNames: 'rawTimeout'
+	package: 'Kernel-Methods'!
+!Timeout commentStamp!
+I am wrapping the returns from `set{Timeout,Interval}`.
+
+## Motivation
+
+Number suffices in browsers, but node.js returns an object.!
+
+!Timeout methodsFor: 'accessing'!
+
+rawTimeout: anObject
+	rawTimeout := anObject
+! !
+
+!Timeout methodsFor: 'timeout/interval'!
+
+clearInterval
+	<
+		var interval = self["@rawTimeout"];
+		clearInterval(interval);
+	>
+!
+
+clearTimeout
+	<
+		var timeout = self["@rawTimeout"];
+		clearTimeout(timeout);
+	>
+! !
+
+!Timeout class methodsFor: 'instance creation'!
+
+on: anObject
+	^ self new rawTimeout: anObject; yourself
+! !
+

+ 6052 - 0
bower_components/amber/src/Kernel-Objects.js

@@ -0,0 +1,6052 @@
+define("amber_core/Kernel-Objects", ["amber/boot"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Objects');
+$core.packages["Kernel-Objects"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ProtoObject', null, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ProtoObject.comment="I implement the basic behavior required for any object in Amber.\x0a\x0aIn most cases, subclassing `ProtoObject` is wrong and `Object` should be used instead. However subclassing `ProtoObject` can be useful in some special cases like proxy implementations.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__eq_eq(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{anObject:anObject},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "= anObject\x0a\x09^ self == anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=="]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "==",
+protocol: 'comparing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._identityHash();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["identityHash"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__eq($recv(anObject)._identityHash());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"==",{anObject:anObject},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "== anObject\x0a\x09^ self identityHash = anObject identityHash",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "identityHash"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._printString();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09^ self printString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printString"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "class",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.klass;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"class",{},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "class\x0a\x09<return self.klass>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "doesNotUnderstand:",
+protocol: 'error handling',
+fn: function (aMessage){
+var self=this;
+function $MessageNotUnderstood(){return $globals.MessageNotUnderstood||(typeof MessageNotUnderstood=="undefined"?nil:MessageNotUnderstood)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($MessageNotUnderstood())._new();
+$recv($1)._receiver_(self);
+$recv($1)._message_(aMessage);
+$2=$recv($1)._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"doesNotUnderstand:",{aMessage:aMessage},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aMessage"],
+source: "doesNotUnderstand: aMessage\x0a\x09MessageNotUnderstood new\x0a\x09\x09receiver: self;\x0a\x09\x09message: aMessage;\x0a\x09\x09signal",
+referencedClasses: ["MessageNotUnderstood"],
+//>>excludeEnd("ide");
+messageSends: ["receiver:", "new", "message:", "signal"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "evaluate:on:",
+protocol: 'evaluating',
+fn: function (aString,anEvaluator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anEvaluator)._evaluate_receiver_(aString,self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"evaluate:on:",{aString:aString,anEvaluator:anEvaluator},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anEvaluator"],
+source: "evaluate: aString on: anEvaluator\x0a\x09^ anEvaluator evaluate: aString receiver: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["evaluate:receiver:"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "identityHash",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var hash=self.identityHash;
+		if (hash) return hash;
+		hash=$core.nextId();
+		Object.defineProperty(self, 'identityHash', {value:hash});
+		return hash;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"identityHash",{},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "identityHash\x0a\x09<\x0a\x09\x09var hash=self.identityHash;\x0a\x09\x09if (hash) return hash;\x0a\x09\x09hash=$core.nextId();\x0a\x09\x09Object.defineProperty(self, 'identityHash', {value:hash});\x0a\x09\x09return hash;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "inspect",
+protocol: 'inspecting',
+fn: function (){
+var self=this;
+function $Inspector(){return $globals.Inspector||(typeof Inspector=="undefined"?nil:Inspector)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Inspector())._inspect_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspect",{},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "inspect\x0a\x09Inspector inspect: self",
+referencedClasses: ["Inspector"],
+//>>excludeEnd("ide");
+messageSends: ["inspect:"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "inspectOn:",
+protocol: 'inspecting',
+fn: function (anInspector){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInspector"],
+source: "inspectOn: anInspector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "instVarAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return self['@'+aString] ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instVarAt:",{aString:aString},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "instVarAt: aString\x0a\x09< return self['@'+aString] >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "instVarAt:put:",
+protocol: 'accessing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ self['@' + aString] = anObject ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"instVarAt:put:",{aString:aString,anObject:anObject},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "instVarAt: aString put: anObject\x0a\x09< self['@' + aString] = anObject >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "isKindOf:",
+protocol: 'testing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self._isMemberOf_(aClass);
+if($core.assert($2)){
+$1=true;
+} else {
+$1=$recv(self._class())._inheritsFrom_(aClass);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isKindOf:",{aClass:aClass},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "isKindOf: aClass\x0a\x09^ (self isMemberOf: aClass)\x0a\x09\x09ifTrue: [ true ]\x0a\x09\x09ifFalse: [ self class inheritsFrom: aClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isMemberOf:", "inheritsFrom:", "class"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "perform:",
+protocol: 'message handling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._perform_withArguments_(aString,[]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"perform:",{aString:aString},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "perform: aString\x0a\x09^ self perform: aString withArguments: #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["perform:withArguments:"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "perform:withArguments:",
+protocol: 'message handling',
+fn: function (aString,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return $core.send(self, aString._asJavaScriptMethodName(), aCollection);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"perform:withArguments:",{aString:aString,aCollection:aCollection},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aCollection"],
+source: "perform: aString withArguments: aCollection\x0a\x09<return $core.send(self, aString._asJavaScriptMethodName(), aCollection)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $5,$4,$3,$2,$1;
+$5=self._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._name();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["name"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._first();
+$2=$recv($3)._isVowel();
+if($core.assert($2)){
+$1="an ";
+} else {
+$1="a ";
+};
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(self._class())._name());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: (self class name first isVowel\x0a\x09\x09ifTrue: [ 'an ' ]\x0a\x09\x09ifFalse: [ 'a ' ]).\x0a\x09aStream nextPutAll: self class name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "ifTrue:ifFalse:", "isVowel", "first", "name", "class"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "printString",
+protocol: 'printing',
+fn: function (){
+var self=this;
+function $String(){return $globals.String||(typeof String=="undefined"?nil:String)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($String())._streamContents_((function(str){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._printOn_(str);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printString",{},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "printString\x0a\x09^ String streamContents: [ :str | \x0a\x09\x09self printOn: str ]",
+referencedClasses: ["String"],
+//>>excludeEnd("ide");
+messageSends: ["streamContents:", "printOn:"]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "yourself",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "yourself\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "~=",
+protocol: 'comparing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self.__eq(anObject)).__eq(false);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"~=",{anObject:anObject},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "~= anObject\x0a\x09^ (self = anObject) = false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["="]
+}),
+$globals.ProtoObject);
+
+$core.addMethod(
+$core.method({
+selector: "~~",
+protocol: 'comparing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self.__eq_eq(anObject)).__eq(false);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"~~",{anObject:anObject},$globals.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "~~ anObject\x0a\x09^ (self == anObject) = false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "=="]
+}),
+$globals.ProtoObject);
+
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ProtoObject.klass);
+
+
+$core.addClass('Object', $globals.ProtoObject, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Object.comment="**I am the root of the Smalltalk class system**. With the exception of unual subclasses of `ProtoObject`, all other classes in the system are subclasses of me.\x0a\x0aI provide default behavior common to all normal objects (some of it inherited from `ProtoObject`), such as:\x0a\x0a- accessing\x0a- copying\x0a- comparison\x0a- error handling\x0a- message sending\x0a- reflection\x0a\x0aAlso utility messages that all objects should respond to are defined here.\x0a\x0aI have no instance variable.\x0a\x0a##Access\x0a\x0aInstance variables can be accessed with `#instVarAt:` and `#instVarAt:put:`. `#instanceVariableNames` answers a collection of all instance variable names.\x0aAccessing JavaScript properties of an object is done through `#basicAt:`, `#basicAt:put:` and `basicDelete:`.\x0a\x0a##Copying\x0a\x0aCopying an object is handled by `#copy` and `#deepCopy`. The first one performs a shallow copy of the receiver, while the second one performs a deep copy.\x0aThe hook method `#postCopy` can be overriden in subclasses to copy fields as necessary to complete the full copy. It will be sent by the copy of the receiver.\x0a\x0a##Comparison\x0a\x0aI understand equality `#=` and identity `#==` comparison.\x0a\x0a##Error handling\x0a\x0a- `#halt` is the typical message to use for inserting breakpoints during debugging.\x0a- `#error:` throws a generic error exception\x0a- `#doesNotUnderstand:` handles the fact that there was an attempt to send the given message to the receiver but the receiver does not understand this message.\x0a\x09Overriding this message can be useful to implement proxies for example.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "->",
+protocol: 'converting',
+fn: function (anObject){
+var self=this;
+function $Association(){return $globals.Association||(typeof Association=="undefined"?nil:Association)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Association())._key_value_(self,anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"->",{anObject:anObject},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "-> anObject\x0a\x09^ Association key: self value: anObject",
+referencedClasses: ["Association"],
+//>>excludeEnd("ide");
+messageSends: ["key:value:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+var variables;
+function $HashedCollection(){return $globals.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+variables=$recv($HashedCollection())._new();
+$recv($recv(self._class())._allInstanceVariableNames())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(variables)._at_put_(each,$recv(self._instVarAt_(each))._asJSON());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=variables;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSON",{variables:variables},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09| variables |\x0a\x09variables := HashedCollection new.\x0a\x09self class allInstanceVariableNames do: [ :each |\x0a\x09\x09variables at: each put: (self instVarAt: each) asJSON ].\x0a\x09^ variables",
+referencedClasses: ["HashedCollection"],
+//>>excludeEnd("ide");
+messageSends: ["new", "do:", "allInstanceVariableNames", "class", "at:put:", "asJSON", "instVarAt:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "asJSONString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $JSON(){return $globals.JSON||(typeof JSON=="undefined"?nil:JSON)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($JSON())._stringify_(self._asJSON());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJSONString",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSONString\x0a\x09^ JSON stringify: self asJSON",
+referencedClasses: ["JSON"],
+//>>excludeEnd("ide");
+messageSends: ["stringify:", "asJSON"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._asString();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09^ self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asString"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "basicAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self[aString];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicAt:",{aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicAt: aString\x0a\x09<return self[aString]>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "basicAt:put:",
+protocol: 'accessing',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self[aString] = anObject;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicAt:put:",{aString:aString,anObject:anObject},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "basicAt: aString put: anObject\x0a\x09<return self[aString] = anObject>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "basicDelete:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+delete self[aString]; return aString;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicDelete:",{aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicDelete: aString\x0a\x09<delete self[aString]; return aString>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "basicPerform:",
+protocol: 'message handling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._basicPerform_withArguments_(aString,[]);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicPerform:",{aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "basicPerform: aString\x0a\x09^ self basicPerform: aString withArguments: #()",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicPerform:withArguments:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "basicPerform:withArguments:",
+protocol: 'message handling',
+fn: function (aString,aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self[aString].apply(self, aCollection);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicPerform:withArguments:",{aString:aString,aCollection:aCollection},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aCollection"],
+source: "basicPerform: aString withArguments: aCollection\x0a\x09<return self[aString].apply(self, aCollection);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "browse",
+protocol: 'browsing',
+fn: function (){
+var self=this;
+function $Finder(){return $globals.Finder||(typeof Finder=="undefined"?nil:Finder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Finder())._findClass_(self._class());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"browse",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "browse\x0a\x09Finder findClass: self class",
+referencedClasses: ["Finder"],
+//>>excludeEnd("ide");
+messageSends: ["findClass:", "class"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "copy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._shallowCopy())._postCopy();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"copy",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "copy\x0a\x09^ self shallowCopy postCopy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["postCopy", "shallowCopy"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var copy = self.klass._new();
+		Object.keys(self).forEach(function (i) {
+		if(/^@.+/.test(i)) {
+			copy[i] = self[i]._deepCopy();
+		}
+		});
+		return copy;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deepCopy",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09<\x0a\x09\x09var copy = self.klass._new();\x0a\x09\x09Object.keys(self).forEach(function (i) {\x0a\x09\x09if(/^@.+/.test(i)) {\x0a\x09\x09\x09copy[i] = self[i]._deepCopy();\x0a\x09\x09}\x0a\x09\x09});\x0a\x09\x09return copy;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "deprecatedAPI",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$6,$5,$4,$8,$7,$3,$2;
+$1=console;
+$6=$core.getThisContext()._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._asString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asString"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__comma(" is deprecated! (in ");
+$8=$recv($core.getThisContext()._home())._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=2;
+//>>excludeEnd("ctx");
+$7=$recv($8)._asString();
+$3=$recv($4).__comma($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($1)._warn_($2);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deprecatedAPI",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deprecatedAPI\x0a\x09\x22Just a simple way to deprecate methods.\x0a\x09#deprecatedAPI is in the 'error handling' protocol even if it doesn't throw an error,\x0a\x09but it could in the future.\x22\x0a\x09console warn: thisContext home asString, ' is deprecated! (in ', thisContext home home asString, ')'.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["warn:", ",", "asString", "home"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "deprecatedAPI:",
+protocol: 'error handling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$6,$5,$4,$8,$7,$3,$2;
+$1=console;
+$6=$core.getThisContext()._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=1;
+//>>excludeEnd("ctx");
+$5=$recv($6)._asString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asString"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__comma(" is deprecated! (in ");
+$8=$recv($core.getThisContext()._home())._home();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["home"]=2;
+//>>excludeEnd("ctx");
+$7=$recv($8)._asString();
+$3=$recv($4).__comma($7);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$recv($1)._warn_($2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["warn:"]=1;
+//>>excludeEnd("ctx");
+$recv(console)._warn_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deprecatedAPI:",{aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "deprecatedAPI: aString\x0a\x09\x22Just a simple way to deprecate methods.\x0a\x09#deprecatedAPI is in the 'error handling' protocol even if it doesn't throw an error,\x0a\x09but it could in the future.\x22\x0a\x09console warn: thisContext home asString, ' is deprecated! (in ', thisContext home home asString, ')'.\x0a\x09console warn: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["warn:", ",", "asString", "home"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "error:",
+protocol: 'error handling',
+fn: function (aString){
+var self=this;
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Error())._signal_(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"error:",{aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "error: aString\x0a\x09Error signal: aString",
+referencedClasses: ["Error"],
+//>>excludeEnd("ide");
+messageSends: ["signal:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "halt",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+function $Halt(){return $globals.Halt||(typeof Halt=="undefined"?nil:Halt)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Halt())._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"halt",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "halt\x0a\x09Halt signal",
+referencedClasses: ["Halt"],
+//>>excludeEnd("ide");
+messageSends: ["signal"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifNil: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:ifNotNil:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anotherBlock)._value_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNil:ifNotNil:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifNil: aBlock ifNotNil: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ anotherBlock value: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aBlock)._value_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotNil:",{aBlock:aBlock},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifNotNil: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ aBlock value: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:ifNil:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aBlock)._value_(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotNil:ifNil:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifNotNil: aBlock ifNil: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ aBlock value: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "inspectOn:",
+protocol: 'inspecting',
+fn: function (anInspector){
+var self=this;
+var variables;
+function $Dictionary(){return $globals.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+variables=$recv($Dictionary())._new();
+$recv(variables)._at_put_("#self",self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["at:put:"]=1;
+//>>excludeEnd("ctx");
+$recv($recv(self._class())._allInstanceVariableNames())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(variables)._at_put_(each,self._instVarAt_(each));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$recv(anInspector)._setLabel_(self._printString());
+$1=$recv(anInspector)._setVariables_(variables);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"inspectOn:",{anInspector:anInspector,variables:variables},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInspector"],
+source: "inspectOn: anInspector\x0a\x09| variables |\x0a\x09variables := Dictionary new.\x0a\x09variables at: '#self' put: self.\x0a\x09self class allInstanceVariableNames do: [ :each |\x0a\x09\x09variables at: each put: (self instVarAt: each) ].\x0a\x09anInspector\x0a\x09\x09setLabel: self printString;\x0a\x09\x09setVariables: variables",
+referencedClasses: ["Dictionary"],
+//>>excludeEnd("ide");
+messageSends: ["new", "at:put:", "do:", "allInstanceVariableNames", "class", "instVarAt:", "setLabel:", "printString", "setVariables:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isBehavior",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBehavior\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isBoolean",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBoolean\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isClass",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isClass\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isCompiledMethod",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isCompiledMethod\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isMemberOf:",
+protocol: 'testing',
+fn: function (aClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class()).__eq(aClass);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isMemberOf:",{aClass:aClass},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aClass"],
+source: "isMemberOf: aClass\x0a\x09^ self class = aClass",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "class"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isMetaclass",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isMetaclass\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isNil",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNil\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isNumber",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNumber\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isPackage",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isPackage\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isParseFailure",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isParseFailure\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isString",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isString\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "isSymbol",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isSymbol\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "notNil",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._isNil())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"notNil",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "notNil\x0a\x09^ self isNil not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isNil"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "postCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "postCopy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "putOn:",
+protocol: 'streaming',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPut_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"putOn:",{aStream:aStream},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "putOn: aStream\x0a\x09aStream nextPut: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPut:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "respondsTo:",
+protocol: 'testing',
+fn: function (aSelector){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._class())._canUnderstand_(aSelector);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"respondsTo:",{aSelector:aSelector},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSelector"],
+source: "respondsTo: aSelector\x0a\x09^ self class canUnderstand: aSelector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["canUnderstand:", "class"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var copy = self.klass._new();
+		Object.keys(self).forEach(function(i) {
+		if(/^@.+/.test(i)) {
+			copy[i] = self[i];
+		}
+		});
+		return copy;
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shallowCopy",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09<\x0a\x09\x09var copy = self.klass._new();\x0a\x09\x09Object.keys(self).forEach(function(i) {\x0a\x09\x09if(/^@.+/.test(i)) {\x0a\x09\x09\x09copy[i] = self[i];\x0a\x09\x09}\x0a\x09\x09});\x0a\x09\x09return copy;\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "shouldNotImplement",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("This method should not be implemented in ".__comma($recv(self._class())._name()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldNotImplement",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldNotImplement\x0a\x09self error: 'This method should not be implemented in ', self class name",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:", ",", "name", "class"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "size",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("Object not indexable");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"size",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "size\x0a\x09self error: 'Object not indexable'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "subclassResponsibility",
+protocol: 'error handling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("This method is a responsibility of a subclass");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclassResponsibility",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "subclassResponsibility\x0a\x09self error: 'This method is a responsibility of a subclass'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "throw:",
+protocol: 'error handling',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ throw anObject ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"throw:",{anObject:anObject},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "throw: anObject\x0a\x09< throw anObject >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "try:catch:",
+protocol: 'error handling',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._deprecatedAPI();
+$1=$recv(aBlock)._tryCatch_(anotherBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"try:catch:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "try: aBlock catch: anotherBlock\x0a\x09self deprecatedAPI.\x0a\x09\x0a\x09^ aBlock tryCatch: anotherBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deprecatedAPI", "tryCatch:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "value",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.valueOf();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "value\x0a\x09<return self.valueOf()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+
+$core.addMethod(
+$core.method({
+selector: "accessorProtocolWith:",
+protocol: 'helios',
+fn: function (aGenerator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aGenerator)._accessorProtocolForObject();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accessorProtocolWith:",{aGenerator:aGenerator},$globals.Object.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aGenerator"],
+source: "accessorProtocolWith: aGenerator\x0a\x09aGenerator accessorProtocolForObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["accessorProtocolForObject"]
+}),
+$globals.Object.klass);
+
+$core.addMethod(
+$core.method({
+selector: "accessorsSourceCodesWith:",
+protocol: 'helios',
+fn: function (aGenerator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aGenerator)._accessorsForObject();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accessorsSourceCodesWith:",{aGenerator:aGenerator},$globals.Object.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aGenerator"],
+source: "accessorsSourceCodesWith: aGenerator\x0a\x09aGenerator accessorsForObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["accessorsForObject"]
+}),
+$globals.Object.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09\x22no op\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initializeProtocolWith:",
+protocol: 'helios',
+fn: function (aGenerator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aGenerator)._initializeProtocolForObject();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeProtocolWith:",{aGenerator:aGenerator},$globals.Object.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aGenerator"],
+source: "initializeProtocolWith: aGenerator\x0a\x09aGenerator initializeProtocolForObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeProtocolForObject"]
+}),
+$globals.Object.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initializeSourceCodesWith:",
+protocol: 'helios',
+fn: function (aGenerator){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aGenerator)._initializeForObject();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeSourceCodesWith:",{aGenerator:aGenerator},$globals.Object.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aGenerator"],
+source: "initializeSourceCodesWith: aGenerator\x0a\x09aGenerator initializeForObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeForObject"]
+}),
+$globals.Object.klass);
+
+
+$core.addClass('Boolean', $globals.Object, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Boolean.comment="I define the protocol for logic testing operations and conditional control structures for the logical values (see the `controlling` protocol).\x0a\x0aI have two instances, `true` and `false`.\x0a\x0aI am directly mapped to JavaScript Boolean. The `true` and `false` objects are the JavaScript boolean objects.\x0a\x0a## Usage Example:\x0a\x0a    aBoolean not ifTrue: [ ... ] ifFalse: [ ... ]";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "&",
+protocol: 'controlling',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self == true) {
+		return aBoolean;
+		} else {
+		return false;
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"&",{aBoolean:aBoolean},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "& aBoolean\x0a\x09<\x0a\x09\x09if(self == true) {\x0a\x09\x09return aBoolean;\x0a\x09\x09} else {\x0a\x09\x09return false;\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return aBoolean != null &&
+			typeof aBoolean._isBoolean === "function" &&
+			aBoolean._isBoolean() &&
+			Boolean(self == true) == aBoolean
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aBoolean:aBoolean},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "= aBoolean\x0a\x09<\x0a\x09\x09return aBoolean != null &&\x0a\x09\x09\x09typeof aBoolean._isBoolean === \x22function\x22 &&\x0a\x09\x09\x09aBoolean._isBoolean() &&\x0a\x09\x09\x09Boolean(self == true) == aBoolean\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "==",
+protocol: 'comparing',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__eq(aBoolean);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"==",{aBoolean:aBoolean},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "== aBoolean\x0a\x09^ self = aBoolean",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["="]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "and:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self.__eq(true);
+$1=$recv($2)._ifTrue_ifFalse_(aBlock,(function(){
+return false;
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"and:",{aBlock:aBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "and: aBlock\x0a\x09^ self = true\x0a\x09\x09ifTrue: aBlock\x0a\x09\x09ifFalse: [ false ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "="]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "asBit",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+if($core.assert(self)){
+$1=(1);
+} else {
+$1=(0);
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asBit",{},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asBit\x0a\x09^ self ifTrue: [ 1 ] ifFalse: [ 0 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:"]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return self.toString() ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09< return self.toString() >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "ifFalse:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ifTrue_ifFalse_((function(){
+
+}),aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifFalse:",{aBlock:aBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifFalse: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self ifTrue: [] ifFalse: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:"]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "ifFalse:ifTrue:",
+protocol: 'controlling',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ifTrue_ifFalse_(anotherBlock,aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifFalse:ifTrue:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifFalse: aBlock ifTrue: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self ifTrue: anotherBlock ifFalse: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:"]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "ifTrue:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ifTrue_ifFalse_(aBlock,(function(){
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifTrue:",{aBlock:aBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifTrue: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self ifTrue: aBlock ifFalse: []",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:"]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "ifTrue:ifFalse:",
+protocol: 'controlling',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self == true) {
+		return aBlock._value();
+		} else {
+		return anotherBlock._value();
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifTrue:ifFalse:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifTrue: aBlock ifFalse: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09<\x0a\x09\x09if(self == true) {\x0a\x09\x09return aBlock._value();\x0a\x09\x09} else {\x0a\x09\x09return anotherBlock._value();\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "isBoolean",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isBoolean\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "not",
+protocol: 'controlling',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__eq(false);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"not",{},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "not\x0a\x09^ self = false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["="]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "or:",
+protocol: 'controlling',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=self.__eq(true);
+$1=$recv($2)._ifTrue_ifFalse_((function(){
+return true;
+
+}),aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"or:",{aBlock:aBlock},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "or: aBlock\x0a\x09^ self = true\x0a\x09\x09ifTrue: [ true ]\x0a\x09\x09ifFalse: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "="]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "asString"]
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+$core.addMethod(
+$core.method({
+selector: "|",
+protocol: 'controlling',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self == true) {
+		return true;
+		} else {
+		return aBoolean;
+		}
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"|",{aBoolean:aBoolean},$globals.Boolean)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "| aBoolean\x0a\x09<\x0a\x09\x09if(self == true) {\x0a\x09\x09return true;\x0a\x09\x09} else {\x0a\x09\x09return aBoolean;\x0a\x09\x09}\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Boolean);
+
+
+
+$core.addClass('Date', $globals.Object, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Date.comment="I am used to work with both dates and times. Therefore `Date today` and `Date now` are both valid in\x0aAmber and answer the same date object.\x0a\x0aDate directly maps to the `Date()` JavaScript constructor, and Amber date objects are JavaScript date objects.\x0a\x0a## API\x0a\x0aThe class-side `instance creation` protocol contains some convenience methods for creating date/time objects such as `#fromSeconds:`.\x0a\x0aArithmetic and comparison is supported (see the `comparing` and `arithmetic` protocols).\x0a\x0aThe `converting` protocol provides convenience methods for various convertions (to numbers, strings, etc.).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "+",
+protocol: 'arithmetic',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self + aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"+",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: "+ aDate\x0a\x09<return self + aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "-",
+protocol: 'arithmetic',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self - aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"-",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: "- aDate\x0a\x09<return self - aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "<",
+protocol: 'comparing',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self < aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: "< aDate\x0a\x09<return self < aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "<=",
+protocol: 'comparing',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self <= aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<=",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: "<= aDate\x0a\x09<return self <= aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: ">",
+protocol: 'comparing',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self > aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: "> aDate\x0a\x09<return self >> aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: ">=",
+protocol: 'comparing',
+fn: function (aDate){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self >= aDate;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">=",{aDate:aDate},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aDate"],
+source: ">= aDate\x0a\x09<return self >>= aDate>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asDateString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toDateString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asDateString",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asDateString\x0a\x09<return self.toDateString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asLocaleString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toLocaleString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asLocaleString",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asLocaleString\x0a\x09<return self.toLocaleString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asMilliseconds",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._time();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asMilliseconds",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asMilliseconds\x0a\x09^ self time",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["time"]
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asNumber",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._asMilliseconds();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asNumber",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asNumber\x0a\x09^ self asMilliseconds",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asMilliseconds"]
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09<return self.toString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "asTimeString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toTimeString();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asTimeString",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asTimeString\x0a\x09<return self.toTimeString()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "day",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._dayOfWeek();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"day",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "day\x0a\x09^ self dayOfWeek",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["dayOfWeek"]
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "day:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._dayOfWeek_(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"day:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "day: aNumber\x0a\x09self dayOfWeek: aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["dayOfWeek:"]
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "dayOfMonth",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getDate();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dayOfMonth",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "dayOfMonth\x0a\x09<return self.getDate()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "dayOfMonth:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setDate(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dayOfMonth:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "dayOfMonth: aNumber\x0a\x09<self.setDate(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "dayOfWeek",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getDay() + 1;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dayOfWeek",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "dayOfWeek\x0a\x09<return self.getDay() + 1>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "dayOfWeek:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.setDay(aNumber - 1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dayOfWeek:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "dayOfWeek: aNumber\x0a\x09<return self.setDay(aNumber - 1)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "hours",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getHours();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hours",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hours\x0a\x09<return self.getHours()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "hours:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setHours(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hours:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "hours: aNumber\x0a\x09<self.setHours(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "milliseconds",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getMilliseconds();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"milliseconds",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "milliseconds\x0a\x09<return self.getMilliseconds()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "milliseconds:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setMilliseconds(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"milliseconds:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "milliseconds: aNumber\x0a\x09<self.setMilliseconds(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "minutes",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getMinutes();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"minutes",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "minutes\x0a\x09<return self.getMinutes()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "minutes:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setMinutes(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"minutes:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "minutes: aNumber\x0a\x09<self.setMinutes(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "month",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getMonth() + 1;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"month",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "month\x0a\x09<return self.getMonth() + 1>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "month:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setMonth(aNumber - 1);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"month:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "month: aNumber\x0a\x09<self.setMonth(aNumber - 1)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "asString"]
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "seconds",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getSeconds();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"seconds",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "seconds\x0a\x09<return self.getSeconds()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "seconds:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setSeconds(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"seconds:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "seconds: aNumber\x0a\x09<self.setSeconds(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "time",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getTime();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"time",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "time\x0a\x09<return self.getTime()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "time:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setTime(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"time:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "time: aNumber\x0a\x09<self.setTime(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "year",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.getFullYear();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"year",{},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "year\x0a\x09<return self.getFullYear()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+$core.addMethod(
+$core.method({
+selector: "year:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self.setFullYear(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"year:",{aNumber:aNumber},$globals.Date)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "year: aNumber\x0a\x09<self.setFullYear(aNumber)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date);
+
+
+$core.addMethod(
+$core.method({
+selector: "fromMilliseconds:",
+protocol: 'instance creation',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._new_(aNumber);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromMilliseconds:",{aNumber:aNumber},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "fromMilliseconds: aNumber\x0a\x09^ self new: aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new:"]
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromSeconds:",
+protocol: 'instance creation',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._fromMilliseconds_($recv(aNumber).__star((1000)));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromSeconds:",{aNumber:aNumber},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "fromSeconds: aNumber\x0a\x09^ self fromMilliseconds: aNumber * 1000",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["fromMilliseconds:", "*"]
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromString:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._new_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:",{aString:aString},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "fromString: aString\x0a\x09\x22Example: Date fromString('2011/04/15 00:00:00')\x22\x0a\x09^ self new: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new:"]
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "magnitude";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'magnitude'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "millisecondsToRun:",
+protocol: 'instance creation',
+fn: function (aBlock){
+var self=this;
+var t;
+function $Date(){return $globals.Date||(typeof Date=="undefined"?nil:Date)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+t=$recv($Date())._now();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["now"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+$1=$recv($recv($Date())._now()).__minus(t);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"millisecondsToRun:",{aBlock:aBlock,t:t},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "millisecondsToRun: aBlock\x0a\x09| t |\x0a\x09t := Date now.\x0a\x09aBlock value.\x0a\x09^ Date now - t",
+referencedClasses: ["Date"],
+//>>excludeEnd("ide");
+messageSends: ["now", "value", "-"]
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new:",
+protocol: 'instance creation',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return new Date(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new:",{anObject:anObject},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "new: anObject\x0a\x09<return new Date(anObject)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "now",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._today();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"now",{},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "now\x0a\x09^ self today",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["today"]
+}),
+$globals.Date.klass);
+
+$core.addMethod(
+$core.method({
+selector: "today",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._new();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"today",{},$globals.Date.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "today\x0a\x09^ self new",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["new"]
+}),
+$globals.Date.klass);
+
+
+$core.addClass('Number', $globals.Object, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Number.comment="I am the Amber representation for all numbers.\x0aI am directly mapped to JavaScript Number.\x0a\x0a## API\x0a\x0aI provide all necessary methods for arithmetic operations, comparison, conversion and so on with numbers.\x0a\x0aMy instances can also be used to evaluate a block a fixed number of times:\x0a\x0a\x095 timesRepeat: [ Transcript show: 'This will be printed 5 times'; cr ].\x0a\x09\x0a\x091 to: 5 do: [ :aNumber| Transcript show: aNumber asString; cr ].\x0a\x09\x0a\x091 to: 10 by: 2 do: [ :aNumber| Transcript show: aNumber asString; cr ].";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "&",
+protocol: 'converting',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self & aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"&",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "& aNumber\x0a\x09<return self & aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "*",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self * aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"*",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "* aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self * aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "**",
+protocol: 'mathematical functions',
+fn: function (exponent){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._raisedTo_(exponent);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"**",{exponent:exponent},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["exponent"],
+source: "** exponent\x0a\x09^ self raisedTo: exponent",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["raisedTo:"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "+",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self + aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"+",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "+ aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self + aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "-",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self - aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"-",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "- aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self - aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "/",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self / aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"/",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "/ aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self / aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "//",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self.__slash(aNumber))._floor();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"//",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "// aNumber\x0a\x09^ (self / aNumber) floor",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["floor", "/"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "<",
+protocol: 'comparing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self < aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "< aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self < aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "<=",
+protocol: 'comparing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self <= aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<=",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "<= aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self <= aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return aNumber != null &&
+			typeof aNumber._isNumber === "function" &&
+			aNumber._isNumber() &&
+			Number(self) == aNumber
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "= aNumber\x0a\x09<\x0a\x09\x09return aNumber != null &&\x0a\x09\x09\x09typeof aNumber._isNumber === \x22function\x22 &&\x0a\x09\x09\x09aNumber._isNumber() &&\x0a\x09\x09\x09Number(self) == aNumber\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: ">",
+protocol: 'comparing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self > aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "> aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self >> aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: ">=",
+protocol: 'comparing',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self >= aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">=",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: ">= aNumber\x0a\x09\x22Inlined in the Compiler\x22\x0a\x09<return self >>= aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "@",
+protocol: 'converting',
+fn: function (aNumber){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Point())._x_y_(self,aNumber);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"@",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "@ aNumber\x0a\x09^ Point x: self y: aNumber",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "\x5c\x5c",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self % aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"\x5c\x5c",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "\x5c\x5c aNumber\x0a\x09<return self % aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "abs",
+protocol: 'arithmetic',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.abs(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"abs",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "abs\x0a\x09<return Math.abs(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "arcCos",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.acos(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arcCos",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arcCos\x0a\x09<return Math.acos(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "arcSin",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.asin(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arcSin",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arcSin\x0a\x09<return Math.asin(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "arcTan",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.atan(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"arcTan",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "arcTan\x0a\x09<return Math.atan(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "asJavascript",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv("(".__comma(self._printString())).__comma(")");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJavascript",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJavascript\x0a\x09^ '(', self printString, ')'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "printString"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "asNumber",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asNumber\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "asPoint",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($Point())._x_y_(self,self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asPoint",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asPoint\x0a\x09^ Point x: self y: self",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "asString",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return String(self) ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asString",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asString\x0a\x09< return String(self) >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "atRandom",
+protocol: 'converting',
+fn: function (){
+var self=this;
+function $Random(){return $globals.Random||(typeof Random=="undefined"?nil:Random)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($recv($recv($recv($Random())._new())._next()).__star(self))._truncated()).__plus((1));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"atRandom",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "atRandom\x0a\x09^ (Random new next * self) truncated + 1",
+referencedClasses: ["Random"],
+//>>excludeEnd("ide");
+messageSends: ["+", "truncated", "*", "next", "new"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "ceiling",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.ceil(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ceiling",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ceiling\x0a\x09<return Math.ceil(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "copy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "copy\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "cos",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.cos(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cos",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cos\x0a\x09<return Math.cos(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._copy();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deepCopy",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09^ self copy",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["copy"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "even",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=(0).__eq(self.__backslash_backslash((2)));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"even",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "even\x0a\x09^ 0 = (self \x5c\x5c 2)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "\x5c\x5c"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "floor",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.floor(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"floor",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "floor\x0a\x09<return Math.floor(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "identityHash",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._asString()).__comma("n");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"identityHash",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "identityHash\x0a\x09^ self asString, 'n'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "asString"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "isNumber",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNumber\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "isZero",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__eq((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isZero",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isZero\x0a\x09^ self = 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["="]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "ln",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.log(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ln",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ln\x0a\x09<return Math.log(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "log",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.log(self) / Math.LN10;;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"log",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "log\x0a\x09<return Math.log(self) / Math.LN10;>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "log:",
+protocol: 'mathematical functions',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.log(self) / Math.log(aNumber);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"log:",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "log: aNumber\x0a\x09<return Math.log(self) / Math.log(aNumber);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "max:",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.max(self, aNumber);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"max:",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "max: aNumber\x0a\x09<return Math.max(self, aNumber);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "min:",
+protocol: 'arithmetic',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.min(self, aNumber);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"min:",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "min: aNumber\x0a\x09<return Math.min(self, aNumber);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "negated",
+protocol: 'arithmetic',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=(0).__minus(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"negated",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "negated\x0a\x09^ 0 - self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["-"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "negative",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__lt((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"negative",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "negative\x0a\x09\x22Answer whether the receiver is mathematically negative.\x22\x0a\x0a\x09^ self < 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["<"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "odd",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._even())._not();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"odd",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "odd\x0a\x09^ self even not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "even"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "positive",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__gt_eq((0));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"positive",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "positive\x0a\x09\x22Answer whether the receiver is positive or equal to 0. (ST-80 protocol).\x22\x0a\x0a\x09^ self >= 0",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [">="]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(self._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "asString"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "printShowingDecimalPlaces:",
+protocol: 'printing',
+fn: function (placesDesired){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.toFixed(placesDesired);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printShowingDecimalPlaces:",{placesDesired:placesDesired},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["placesDesired"],
+source: "printShowingDecimalPlaces: placesDesired\x0a\x09<return self.toFixed(placesDesired)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "raisedTo:",
+protocol: 'mathematical functions',
+fn: function (exponent){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.pow(self, exponent);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"raisedTo:",{exponent:exponent},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["exponent"],
+source: "raisedTo: exponent\x0a\x09<return Math.pow(self, exponent);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "rounded",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.round(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"rounded",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "rounded\x0a\x09<return Math.round(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "sign",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._isZero();
+if($core.assert($1)){
+return (0);
+};
+$2=self._positive();
+if($core.assert($2)){
+return (1);
+} else {
+return (-1);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sign",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sign\x0a\x09self isZero \x0a\x09\x09ifTrue: [ ^ 0 ].\x0a\x09self positive\x0a\x09\x09ifTrue: [ ^ 1 ]\x0a\x09\x09ifFalse: [ ^ -1 ].",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "isZero", "ifTrue:ifFalse:", "positive"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "sin",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.sin(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sin",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sin\x0a\x09<return Math.sin(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "sqrt",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.sqrt(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sqrt",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sqrt\x0a\x09<return Math.sqrt(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "squared",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__star(self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"squared",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "squared\x0a\x09^ self * self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["*"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "tan",
+protocol: 'mathematical functions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.tan(self);;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tan",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tan\x0a\x09<return Math.tan(self);>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "timesRepeat:",
+protocol: 'enumerating',
+fn: function (aBlock){
+var self=this;
+var count;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+count=(1);
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(count).__gt(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileFalse_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+count=$recv(count).__plus((1));
+return count;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"timesRepeat:",{aBlock:aBlock,count:count},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "timesRepeat: aBlock\x0a\x09| count |\x0a\x09count := 1.\x0a\x09[ count > self ] whileFalse: [\x0a\x09\x09aBlock value.\x0a\x09\x09count := count + 1 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileFalse:", ">", "value", "+"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "to:",
+protocol: 'converting',
+fn: function (aNumber){
+var self=this;
+var array,first,last,count;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+first=self._truncated();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["truncated"]=1;
+//>>excludeEnd("ctx");
+last=$recv($recv(aNumber)._truncated()).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+count=(1);
+array=$recv($Array())._new();
+$recv($recv(last).__minus(first))._timesRepeat_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(array)._at_put_(count,first);
+count=$recv(count).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=2;
+//>>excludeEnd("ctx");
+count;
+first=$recv(first).__plus((1));
+return first;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+$1=array;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"to:",{aNumber:aNumber,array:array,first:first,last:last,count:count},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "to: aNumber\x0a\x09| array first last count |\x0a\x09first := self truncated.\x0a\x09last := aNumber truncated + 1.\x0a\x09count := 1.\x0a\x09array := Array new.\x0a\x09(last - first) timesRepeat: [\x0a\x09\x09array at: count put: first.\x0a\x09\x09count := count + 1.\x0a\x09\x09first := first + 1 ].\x0a\x09^ array",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["truncated", "+", "new", "timesRepeat:", "-", "at:put:"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "to:by:",
+protocol: 'converting',
+fn: function (stop,step){
+var self=this;
+var array,value,pos;
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+value=self;
+array=$recv($Array())._new();
+pos=(1);
+$1=$recv(step).__eq((0));
+if($core.assert($1)){
+self._error_("step must be non-zero");
+};
+$2=$recv(step).__lt((0));
+if($core.assert($2)){
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(value).__gt_eq(stop);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(array)._at_put_(pos,value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["at:put:"]=1;
+//>>excludeEnd("ctx");
+pos=$recv(pos).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+pos;
+value=$recv(value).__plus(step);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=2;
+//>>excludeEnd("ctx");
+return value;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["whileTrue:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(value).__lt_eq(stop);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(array)._at_put_(pos,value);
+pos=$recv(pos).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=3;
+//>>excludeEnd("ctx");
+pos;
+value=$recv(value).__plus(step);
+return value;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,7)});
+//>>excludeEnd("ctx");
+}));
+};
+$3=array;
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"to:by:",{stop:stop,step:step,array:array,value:value,pos:pos},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["stop", "step"],
+source: "to: stop by: step\x0a\x09| array value pos |\x0a\x09value := self.\x0a\x09array := Array new.\x0a\x09pos := 1.\x0a\x09step = 0 ifTrue: [ self error: 'step must be non-zero' ].\x0a\x09step < 0\x0a\x09\x09ifTrue: [ [ value >= stop ] whileTrue: [\x0a\x09\x09\x09\x09\x09array at: pos put: value.\x0a\x09\x09\x09\x09\x09pos := pos + 1.\x0a\x09\x09\x09\x09\x09value := value + step ]]\x0a\x09\x09ifFalse: [ [ value <= stop ] whileTrue: [\x0a\x09\x09\x09\x09\x09array at: pos put: value.\x0a\x09\x09\x09\x09pos := pos + 1.\x0a\x09\x09\x09\x09\x09value := value + step ]].\x0a\x09^ array",
+referencedClasses: ["Array"],
+//>>excludeEnd("ide");
+messageSends: ["new", "ifTrue:", "=", "error:", "ifTrue:ifFalse:", "<", "whileTrue:", ">=", "at:put:", "+", "<="]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "to:by:do:",
+protocol: 'enumerating',
+fn: function (stop,step,aBlock){
+var self=this;
+var value;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+value=self;
+$1=$recv(step).__eq((0));
+if($core.assert($1)){
+self._error_("step must be non-zero");
+};
+$2=$recv(step).__lt((0));
+if($core.assert($2)){
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(value).__gt_eq(stop);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_(value);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["value:"]=1;
+//>>excludeEnd("ctx");
+value=$recv(value).__plus(step);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+return value;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["whileTrue:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(value).__lt_eq(stop);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,6)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_(value);
+value=$recv(value).__plus(step);
+return value;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,7)});
+//>>excludeEnd("ctx");
+}));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"to:by:do:",{stop:stop,step:step,aBlock:aBlock,value:value},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["stop", "step", "aBlock"],
+source: "to: stop by: step do: aBlock\x0a\x09| value |\x0a\x09value := self.\x0a\x09step = 0 ifTrue: [ self error: 'step must be non-zero' ].\x0a\x09step < 0\x0a\x09\x09ifTrue: [ [ value >= stop ] whileTrue: [\x0a\x09\x09\x09\x09\x09aBlock value: value.\x0a\x09\x09\x09\x09\x09value := value + step ]]\x0a\x09\x09ifFalse: [ [ value <= stop ] whileTrue: [\x0a\x09\x09\x09\x09\x09aBlock value: value.\x0a\x09\x09\x09\x09\x09value := value + step ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:", "=", "error:", "ifTrue:ifFalse:", "<", "whileTrue:", ">=", "value:", "+", "<="]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "to:do:",
+protocol: 'enumerating',
+fn: function (stop,aBlock){
+var self=this;
+var nextValue;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+nextValue=self;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(nextValue).__lt_eq(stop);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._whileTrue_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_(nextValue);
+nextValue=$recv(nextValue).__plus((1));
+return nextValue;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"to:do:",{stop:stop,aBlock:aBlock,nextValue:nextValue},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["stop", "aBlock"],
+source: "to: stop do: aBlock\x0a\x09\x22Evaluate aBlock for each number from self to aNumber.\x22\x0a\x09| nextValue |\x0a\x09nextValue := self.\x0a\x09[ nextValue <= stop ]\x0a\x09\x09whileTrue:\x0a\x09\x09\x09[ aBlock value: nextValue.\x0a\x09\x09\x09nextValue := nextValue + 1 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["whileTrue:", "<=", "value:", "+"]
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "truncated",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		if(self >= 0) {
+			return Math.floor(self);
+		} else {
+			return Math.floor(self * (-1)) * (-1);
+		};
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"truncated",{},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "truncated\x0a\x09<\x0a\x09\x09if(self >>= 0) {\x0a\x09\x09\x09return Math.floor(self);\x0a\x09\x09} else {\x0a\x09\x09\x09return Math.floor(self * (-1)) * (-1);\x0a\x09\x09};\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+$core.addMethod(
+$core.method({
+selector: "|",
+protocol: 'converting',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self | aNumber;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"|",{aNumber:aNumber},$globals.Number)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "| aNumber\x0a\x09<return self | aNumber>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number);
+
+
+$core.addMethod(
+$core.method({
+selector: "e",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.E;;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"e",{},$globals.Number.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "e\x0a\x09<return Math.E;>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number.klass);
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "magnitude";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'magnitude'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number.klass);
+
+$core.addMethod(
+$core.method({
+selector: "pi",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.PI;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pi",{},$globals.Number.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pi\x0a\x09<return Math.PI>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Number.klass);
+
+
+$core.addClass('Point', $globals.Object, ['x', 'y'], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Point.comment="I represent an x-y pair of numbers usually designating a geometric coordinate.\x0a\x0a## API\x0a\x0aInstances are traditionally created using the binary `#@` message to a number:\x0a\x0a\x09100@120\x0a\x0aPoints can then be arithmetically manipulated:\x0a\x0a\x09100@100 + (10@10)\x0a\x0a...or for example:\x0a\x0a\x09(100@100) * 2\x0a\x0a**NOTE:** Creating a point with a negative y-value will need a space after `@` in order to avoid a parsing error:\x0a\x0a\x09100@ -100 \x22but 100@-100 would not parse\x22";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "*",
+protocol: 'arithmetic',
+fn: function (aPoint){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$5,$4,$2,$7,$6,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(aPoint)._asPoint();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asPoint"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._x();
+$2=$recv($3).__star($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=1;
+//>>excludeEnd("ctx");
+$7=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7).__star($recv($recv(aPoint)._asPoint())._y());
+$1=$recv($Point())._x_y_($2,$6);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"*",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "* aPoint\x0a\x09^ Point x: self x * aPoint asPoint x y: self y * aPoint asPoint y",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:", "*", "x", "asPoint", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "+",
+protocol: 'arithmetic',
+fn: function (aPoint){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$5,$4,$2,$7,$6,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(aPoint)._asPoint();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asPoint"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._x();
+$2=$recv($3).__plus($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+$7=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7).__plus($recv($recv(aPoint)._asPoint())._y());
+$1=$recv($Point())._x_y_($2,$6);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"+",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "+ aPoint\x0a\x09^ Point x: self x + aPoint asPoint x y: self y + aPoint asPoint y",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:", "+", "x", "asPoint", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "-",
+protocol: 'arithmetic',
+fn: function (aPoint){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$5,$4,$2,$7,$6,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(aPoint)._asPoint();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asPoint"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._x();
+$2=$recv($3).__minus($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["-"]=1;
+//>>excludeEnd("ctx");
+$7=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7).__minus($recv($recv(aPoint)._asPoint())._y());
+$1=$recv($Point())._x_y_($2,$6);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"-",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "- aPoint\x0a\x09^ Point x: self x - aPoint asPoint x y: self y - aPoint asPoint y",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:", "-", "x", "asPoint", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "/",
+protocol: 'arithmetic',
+fn: function (aPoint){
+var self=this;
+function $Point(){return $globals.Point||(typeof Point=="undefined"?nil:Point)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$5,$4,$2,$7,$6,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$5=$recv(aPoint)._asPoint();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["asPoint"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._x();
+$2=$recv($3).__slash($4);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["/"]=1;
+//>>excludeEnd("ctx");
+$7=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7).__slash($recv($recv(aPoint)._asPoint())._y());
+$1=$recv($Point())._x_y_($2,$6);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"/",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "/ aPoint\x0a\x09^ Point x: self x / aPoint asPoint x y: self y / aPoint asPoint y",
+referencedClasses: ["Point"],
+//>>excludeEnd("ide");
+messageSends: ["x:y:", "/", "x", "asPoint", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "<",
+protocol: 'comparing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$4,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__lt($recv(aPoint)._x());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["<"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+return $recv($4).__lt($recv(aPoint)._y());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "< aPoint\x0a\x09^ self x < aPoint x and: [\x0a\x09\x09self y < aPoint y ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "<", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "<=",
+protocol: 'comparing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$4,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__lt_eq($recv(aPoint)._x());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["<="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+return $recv($4).__lt_eq($recv(aPoint)._y());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"<=",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "<= aPoint\x0a\x09^ self x <= aPoint x and: [\x0a\x09\x09self y <= aPoint y ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "<=", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "=",
+protocol: 'comparing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$5,$4,$7,$6,$1;
+$3=$recv(aPoint)._class();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["class"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__eq(self._class());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$5=$recv(aPoint)._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5).__eq(self._x());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["="]=2;
+//>>excludeEnd("ctx");
+$7=$recv(aPoint)._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+$6=$recv($7).__eq(self._y());
+return $recv($4).__and($6);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"=",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "= aPoint\x0a\x09^ aPoint class = self class and: [\x0a\x09\x09(aPoint x = self x) & (aPoint y = self y) ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", "=", "class", "&", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: ">",
+protocol: 'comparing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$4,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__gt($recv(aPoint)._x());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[">"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+return $recv($4).__gt($recv(aPoint)._y());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "> aPoint\x0a\x09^ self x > aPoint x and: [\x0a\x09\x09self y > aPoint y ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", ">", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: ">=",
+protocol: 'comparing',
+fn: function (aPoint){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$4,$1;
+$3=self._x();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["x"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__gt_eq($recv(aPoint)._x());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[">="]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=self._y();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["y"]=1;
+//>>excludeEnd("ctx");
+return $recv($4).__gt_eq($recv(aPoint)._y());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,">=",{aPoint:aPoint},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: ">= aPoint\x0a\x09^ self x >= aPoint x and: [\x0a\x09\x09self y >= aPoint y ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["and:", ">=", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "asPoint",
+protocol: 'converting',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asPoint\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "dist:",
+protocol: 'transforming',
+fn: function (aPoint){
+var self=this;
+var dx,dy;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+dx=$recv($recv(aPoint)._x()).__minus(self["@x"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["-"]=1;
+//>>excludeEnd("ctx");
+dy=$recv($recv(aPoint)._y()).__minus(self["@y"]);
+$3=$recv(dx).__star(dx);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["*"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__plus($recv(dy).__star(dy));
+$1=$recv($2)._sqrt();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dist:",{aPoint:aPoint,dx:dx,dy:dy},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPoint"],
+source: "dist: aPoint \x0a\x09\x22Answer the distance between aPoint and the receiver.\x22\x0a\x09| dx dy |\x0a\x09dx := aPoint x - x.\x0a\x09dy := aPoint y - y.\x0a\x09^ (dx * dx + (dy * dy)) sqrt",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["-", "x", "y", "sqrt", "+", "*"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(self["@x"])._printOn_(aStream);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printOn:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("@");
+$1=$recv($recv(self["@y"])._notNil())._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@y"])._negative();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+$recv(aStream)._space();
+};
+$recv(self["@y"])._printOn_(aStream);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09\x22Print receiver in classic x@y notation.\x22\x0a\x0a\x09x printOn: aStream.\x0a\x09\x0a\x09aStream nextPutAll: '@'.\x0a\x09(y notNil and: [ y negative ]) ifTrue: [\x0a\x09\x09\x09\x22Avoid ambiguous @- construct\x22\x0a\x09\x09\x09aStream space ].\x0a\x09\x0a\x09y printOn: aStream",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["printOn:", "nextPutAll:", "ifTrue:", "and:", "notNil", "negative", "space"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "translateBy:",
+protocol: 'transforming',
+fn: function (delta){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=$recv($recv(delta)._x()).__plus(self["@x"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2).__at($recv($recv(delta)._y()).__plus(self["@y"]));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"translateBy:",{delta:delta},$globals.Point)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["delta"],
+source: "translateBy: delta\x0a\x09\x22Answer a Point translated by delta (an instance of Point).\x22\x0a\x09^ (delta x + x) @ (delta y + y)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["@", "+", "x", "y"]
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "x",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@x"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "x\x0a\x09^ x",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "x:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+self["@x"]=aNumber;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "x: aNumber\x0a\x09x := aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "y",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@y"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "y\x0a\x09^ y",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point);
+
+$core.addMethod(
+$core.method({
+selector: "y:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+self["@y"]=aNumber;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "y: aNumber\x0a\x09y := aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point);
+
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "magnitude";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'magnitude'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Point.klass);
+
+$core.addMethod(
+$core.method({
+selector: "x:y:",
+protocol: 'instance creation',
+fn: function (aNumber,anotherNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._x_(aNumber);
+$recv($2)._y_(anotherNumber);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"x:y:",{aNumber:aNumber,anotherNumber:anotherNumber},$globals.Point.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber", "anotherNumber"],
+source: "x: aNumber y: anotherNumber\x0a\x09^ self new\x0a\x09\x09x: aNumber;\x0a\x09\x09y: anotherNumber;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["x:", "new", "y:", "yourself"]
+}),
+$globals.Point.klass);
+
+
+$core.addClass('Random', $globals.Object, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Random.comment="I an used to generate a random number and I am implemented as a trivial wrapper around javascript `Math.random()`.\x0a\x0a## API\x0a\x0aThe typical use case it to use the `#next` method like the following:\x0a\x0a\x09Random new next\x0a\x0aThis will return a float x where x < 1 and x > 0. If you want a random integer from 1 to 10 you can use `#atRandom`\x0a\x0a\x0910 atRandom\x0a\x0aA random number in a specific interval can be obtained with the following:\x0a\x0a\x09(3 to: 7) atRandom\x0a\x0aBe aware that `#to:` does not create an Interval as in other Smalltalk implementations but in fact an `Array` of numbers, so it's better to use:\x0a\x0a\x095 atRandom + 2\x0a\x0aSince `#atRandom` is implemented in `SequencableCollection` you can easy pick an element at random:\x0a\x0a\x09#('a' 'b' 'c') atRandom\x0a\x0aAs well as letter from a `String`:\x0a\x0a\x09'abc' atRandom\x0a\x0aSince Amber does not have Characters this will return a `String` of length 1 like for example `'b'`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "next",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return Math.random();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next",{},$globals.Random)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "next\x0a\x09<return Math.random()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Random);
+
+$core.addMethod(
+$core.method({
+selector: "next:",
+protocol: 'accessing',
+fn: function (anInteger){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv((1)._to_(anInteger))._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._next();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"next:",{anInteger:anInteger},$globals.Random)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "next: anInteger\x0a\x09^ (1 to: anInteger) collect: [ :each | self next ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "to:", "next"]
+}),
+$globals.Random);
+
+
+
+$core.addClass('UndefinedObject', $globals.Object, [], 'Kernel-Objects');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.UndefinedObject.comment="I describe the behavior of my sole instance, `nil`. `nil` represents a prior value for variables that have not been initialized, or for results which are meaningless.\x0a\x0a`nil` is the Smalltalk equivalent of the `undefined` JavaScript object.\x0a\x0a__note:__ When sending messages to the `undefined` JavaScript object, it will be replaced by `nil`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "asJSON",
+protocol: 'converting',
+fn: function (){
+var self=this;
+var $1;
+$1=null;
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJSON\x0a\x09^ null",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "deepCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "deepCopy\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._ifNil_ifNotNil_(aBlock,(function(){
+
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNil:",{aBlock:aBlock},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifNil: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self ifNil: aBlock ifNotNil: []",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:ifNotNil:"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "ifNil:ifNotNil:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(aBlock)._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNil:ifNotNil:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifNil: aBlock ifNotNil: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ aBlock value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "ifNotNil: aBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "ifNotNil:ifNil:",
+protocol: 'testing',
+fn: function (aBlock,anotherBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(anotherBlock)._value();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ifNotNil:ifNil:",{aBlock:aBlock,anotherBlock:anotherBlock},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anotherBlock"],
+source: "ifNotNil: aBlock ifNil: anotherBlock\x0a\x09\x22inlined in the Compiler\x22\x0a\x09^ anotherBlock value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["value"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "isImmutable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isImmutable\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "isNil",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return true;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isNil\x0a\x09^ true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "notNil",
+protocol: 'testing',
+fn: function (){
+var self=this;
+return false;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "notNil\x0a\x09^ false",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "printOn:",
+protocol: 'printing',
+fn: function (aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("nil");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"printOn:",{aStream:aStream},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aStream"],
+source: "printOn: aStream\x0a\x09aStream nextPutAll: 'nil'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "shallowCopy",
+protocol: 'copying',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shallowCopy\x0a\x09^ self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:",
+protocol: 'class creation',
+fn: function (aString,anotherString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,anotherString,nil);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:",{aString:aString,anotherString:anotherString},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anotherString"],
+source: "subclass: aString instanceVariableNames: anotherString\x0a\x09\x22Kept for file-in compatibility.\x22\x0a\x09^ self subclass: aString instanceVariableNames: anotherString package: nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:category:",
+protocol: 'class creation',
+fn: function (aString,aString2,aString3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:category:",{aString:aString,aString2:aString2,aString3:aString3},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 category: aString3\x0a\x09\x22Kept for file-in compatibility.\x22\x0a\x09^ self subclass: aString instanceVariableNames: aString2 package: aString3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:classVariableNames:poolDictionaries:category:",
+protocol: 'class creation',
+fn: function (aString,aString2,classVars,pools,aString3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._subclass_instanceVariableNames_package_(aString,aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:classVariableNames:poolDictionaries:category:",{aString:aString,aString2:aString2,classVars:classVars,pools:pools,aString3:aString3},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "classVars", "pools", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 classVariableNames: classVars poolDictionaries: pools category: aString3\x0a\x09\x22Kept for file-in compatibility. ignores class variables and pools.\x22\x0a\x09^ self subclass: aString instanceVariableNames: aString2 package: aString3",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["subclass:instanceVariableNames:package:"]
+}),
+$globals.UndefinedObject);
+
+$core.addMethod(
+$core.method({
+selector: "subclass:instanceVariableNames:package:",
+protocol: 'class creation',
+fn: function (aString,aString2,aString3){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($ClassBuilder())._new())._superclass_subclass_instanceVariableNames_package_(self,$recv(aString)._asString(),aString2,aString3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"subclass:instanceVariableNames:package:",{aString:aString,aString2:aString2,aString3:aString3},$globals.UndefinedObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aString2", "aString3"],
+source: "subclass: aString instanceVariableNames: aString2 package: aString3\x0a\x09^ ClassBuilder new\x0a\x09\x09superclass: self subclass: aString asString instanceVariableNames: aString2 package: aString3",
+referencedClasses: ["ClassBuilder"],
+//>>excludeEnd("ide");
+messageSends: ["superclass:subclass:instanceVariableNames:package:", "new", "asString"]
+}),
+$globals.UndefinedObject);
+
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._error_("You cannot create new instances of UndefinedObject. Use nil");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.UndefinedObject.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09\x09self error: 'You cannot create new instances of UndefinedObject. Use nil'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["error:"]
+}),
+$globals.UndefinedObject.klass);
+
+});

+ 1394 - 0
bower_components/amber/src/Kernel-Objects.st

@@ -0,0 +1,1394 @@
+Smalltalk createPackage: 'Kernel-Objects'!
+nil subclass: #ProtoObject
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!ProtoObject commentStamp!
+I implement the basic behavior required for any object in Amber.
+
+In most cases, subclassing `ProtoObject` is wrong and `Object` should be used instead. However subclassing `ProtoObject` can be useful in some special cases like proxy implementations.!
+
+!ProtoObject methodsFor: 'accessing'!
+
+class
+	<return self.klass>
+!
+
+identityHash
+	<
+		var hash=self.identityHash;
+		if (hash) return hash;
+		hash=$core.nextId();
+		Object.defineProperty(self, 'identityHash', {value:hash});
+		return hash;
+	>
+!
+
+instVarAt: aString
+	< return self['@'+aString] >
+!
+
+instVarAt: aString put: anObject
+	< self['@' + aString] = anObject >
+!
+
+yourself
+	^ self
+! !
+
+!ProtoObject methodsFor: 'comparing'!
+
+= anObject
+	^ self == anObject
+!
+
+== anObject
+	^ self identityHash = anObject identityHash
+!
+
+~= anObject
+	^ (self = anObject) = false
+!
+
+~~ anObject
+	^ (self == anObject) = false
+! !
+
+!ProtoObject methodsFor: 'converting'!
+
+asString
+	^ self printString
+! !
+
+!ProtoObject methodsFor: 'error handling'!
+
+doesNotUnderstand: aMessage
+	MessageNotUnderstood new
+		receiver: self;
+		message: aMessage;
+		signal
+! !
+
+!ProtoObject methodsFor: 'evaluating'!
+
+evaluate: aString on: anEvaluator
+	^ anEvaluator evaluate: aString receiver: self
+! !
+
+!ProtoObject methodsFor: 'initialization'!
+
+initialize
+! !
+
+!ProtoObject methodsFor: 'inspecting'!
+
+inspect
+	Inspector inspect: self
+!
+
+inspectOn: anInspector
+! !
+
+!ProtoObject methodsFor: 'message handling'!
+
+perform: aString
+	^ self perform: aString withArguments: #()
+!
+
+perform: aString withArguments: aCollection
+	<return $core.send(self, aString._asJavaScriptMethodName(), aCollection)>
+! !
+
+!ProtoObject methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: (self class name first isVowel
+		ifTrue: [ 'an ' ]
+		ifFalse: [ 'a ' ]).
+	aStream nextPutAll: self class name
+!
+
+printString
+	^ String streamContents: [ :str | 
+		self printOn: str ]
+! !
+
+!ProtoObject methodsFor: 'testing'!
+
+isKindOf: aClass
+	^ (self isMemberOf: aClass)
+		ifTrue: [ true ]
+		ifFalse: [ self class inheritsFrom: aClass ]
+! !
+
+!ProtoObject class methodsFor: 'initialization'!
+
+initialize
+! !
+
+ProtoObject subclass: #Object
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!Object commentStamp!
+**I am the root of the Smalltalk class system**. With the exception of unual subclasses of `ProtoObject`, all other classes in the system are subclasses of me.
+
+I provide default behavior common to all normal objects (some of it inherited from `ProtoObject`), such as:
+
+- accessing
+- copying
+- comparison
+- error handling
+- message sending
+- reflection
+
+Also utility messages that all objects should respond to are defined here.
+
+I have no instance variable.
+
+##Access
+
+Instance variables can be accessed with `#instVarAt:` and `#instVarAt:put:`. `#instanceVariableNames` answers a collection of all instance variable names.
+Accessing JavaScript properties of an object is done through `#basicAt:`, `#basicAt:put:` and `basicDelete:`.
+
+##Copying
+
+Copying an object is handled by `#copy` and `#deepCopy`. The first one performs a shallow copy of the receiver, while the second one performs a deep copy.
+The hook method `#postCopy` can be overriden in subclasses to copy fields as necessary to complete the full copy. It will be sent by the copy of the receiver.
+
+##Comparison
+
+I understand equality `#=` and identity `#==` comparison.
+
+##Error handling
+
+- `#halt` is the typical message to use for inserting breakpoints during debugging.
+- `#error:` throws a generic error exception
+- `#doesNotUnderstand:` handles the fact that there was an attempt to send the given message to the receiver but the receiver does not understand this message.
+	Overriding this message can be useful to implement proxies for example.!
+
+!Object methodsFor: 'accessing'!
+
+basicAt: aString
+	<return self[aString]>
+!
+
+basicAt: aString put: anObject
+	<return self[aString] = anObject>
+!
+
+basicDelete: aString
+	<delete self[aString]; return aString>
+!
+
+size
+	self error: 'Object not indexable'
+!
+
+value
+	<return self.valueOf()>
+! !
+
+!Object methodsFor: 'browsing'!
+
+browse
+	Finder findClass: self class
+! !
+
+!Object methodsFor: 'converting'!
+
+-> anObject
+	^ Association key: self value: anObject
+!
+
+asJSON
+	| variables |
+	variables := HashedCollection new.
+	self class allInstanceVariableNames do: [ :each |
+		variables at: each put: (self instVarAt: each) asJSON ].
+	^ variables
+!
+
+asJSONString
+	^ JSON stringify: self asJSON
+!
+
+asJavascript
+	^ self asString
+! !
+
+!Object methodsFor: 'copying'!
+
+copy
+	^ self shallowCopy postCopy
+!
+
+deepCopy
+	<
+		var copy = self.klass._new();
+		Object.keys(self).forEach(function (i) {
+		if(/^@.+/.test(i)) {
+			copy[i] = self[i]._deepCopy();
+		}
+		});
+		return copy;
+	>
+!
+
+postCopy
+!
+
+shallowCopy
+	<
+		var copy = self.klass._new();
+		Object.keys(self).forEach(function(i) {
+		if(/^@.+/.test(i)) {
+			copy[i] = self[i];
+		}
+		});
+		return copy;
+	>
+! !
+
+!Object methodsFor: 'error handling'!
+
+deprecatedAPI
+	"Just a simple way to deprecate methods.
+	#deprecatedAPI is in the 'error handling' protocol even if it doesn't throw an error,
+	but it could in the future."
+	console warn: thisContext home asString, ' is deprecated!! (in ', thisContext home home asString, ')'.
+!
+
+deprecatedAPI: aString
+	"Just a simple way to deprecate methods.
+	#deprecatedAPI is in the 'error handling' protocol even if it doesn't throw an error,
+	but it could in the future."
+	console warn: thisContext home asString, ' is deprecated!! (in ', thisContext home home asString, ')'.
+	console warn: aString
+!
+
+error: aString
+	Error signal: aString
+!
+
+halt
+	Halt signal
+!
+
+shouldNotImplement
+	self error: 'This method should not be implemented in ', self class name
+!
+
+subclassResponsibility
+	self error: 'This method is a responsibility of a subclass'
+!
+
+throw: anObject
+	< throw anObject >
+!
+
+try: aBlock catch: anotherBlock
+	self deprecatedAPI.
+	
+	^ aBlock tryCatch: anotherBlock
+! !
+
+!Object methodsFor: 'inspecting'!
+
+inspectOn: anInspector
+	| variables |
+	variables := Dictionary new.
+	variables at: '#self' put: self.
+	self class allInstanceVariableNames do: [ :each |
+		variables at: each put: (self instVarAt: each) ].
+	anInspector
+		setLabel: self printString;
+		setVariables: variables
+! !
+
+!Object methodsFor: 'message handling'!
+
+basicPerform: aString
+	^ self basicPerform: aString withArguments: #()
+!
+
+basicPerform: aString withArguments: aCollection
+	<return self[aString].apply(self, aCollection);>
+! !
+
+!Object methodsFor: 'streaming'!
+
+putOn: aStream
+	aStream nextPut: self
+! !
+
+!Object methodsFor: 'testing'!
+
+ifNil: aBlock
+	"inlined in the Compiler"
+	^ self
+!
+
+ifNil: aBlock ifNotNil: anotherBlock
+	"inlined in the Compiler"
+	^ anotherBlock value: self
+!
+
+ifNotNil: aBlock
+	"inlined in the Compiler"
+	^ aBlock value: self
+!
+
+ifNotNil: aBlock ifNil: anotherBlock
+	"inlined in the Compiler"
+	^ aBlock value: self
+!
+
+isBehavior
+	^ false
+!
+
+isBoolean
+	^ false
+!
+
+isClass
+	^ false
+!
+
+isCompiledMethod
+	^ false
+!
+
+isImmutable
+	^ false
+!
+
+isMemberOf: aClass
+	^ self class = aClass
+!
+
+isMetaclass
+	^ false
+!
+
+isNil
+	^ false
+!
+
+isNumber
+	^ false
+!
+
+isPackage
+	^ false
+!
+
+isParseFailure
+	^ false
+!
+
+isString
+	^ false
+!
+
+isSymbol
+	^ false
+!
+
+notNil
+	^ self isNil not
+!
+
+respondsTo: aSelector
+	^ self class canUnderstand: aSelector
+! !
+
+!Object class methodsFor: 'helios'!
+
+accessorProtocolWith: aGenerator
+	aGenerator accessorProtocolForObject
+!
+
+accessorsSourceCodesWith: aGenerator
+	aGenerator accessorsForObject
+!
+
+initializeProtocolWith: aGenerator
+	aGenerator initializeProtocolForObject
+!
+
+initializeSourceCodesWith: aGenerator
+	aGenerator initializeForObject
+! !
+
+!Object class methodsFor: 'initialization'!
+
+initialize
+	"no op"
+! !
+
+Object subclass: #Boolean
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!Boolean commentStamp!
+I define the protocol for logic testing operations and conditional control structures for the logical values (see the `controlling` protocol).
+
+I have two instances, `true` and `false`.
+
+I am directly mapped to JavaScript Boolean. The `true` and `false` objects are the JavaScript boolean objects.
+
+## Usage Example:
+
+    aBoolean not ifTrue: [ ... ] ifFalse: [ ... ]!
+
+!Boolean methodsFor: 'comparing'!
+
+= aBoolean
+	<
+		return aBoolean !!= null &&
+			typeof aBoolean._isBoolean === "function" &&
+			aBoolean._isBoolean() &&
+			Boolean(self == true) == aBoolean
+	>
+!
+
+== aBoolean
+	^ self = aBoolean
+! !
+
+!Boolean methodsFor: 'controlling'!
+
+& aBoolean
+	<
+		if(self == true) {
+		return aBoolean;
+		} else {
+		return false;
+		}
+	>
+!
+
+and: aBlock
+	^ self = true
+		ifTrue: aBlock
+		ifFalse: [ false ]
+!
+
+ifFalse: aBlock
+	"inlined in the Compiler"
+	^ self ifTrue: [] ifFalse: aBlock
+!
+
+ifFalse: aBlock ifTrue: anotherBlock
+	"inlined in the Compiler"
+	^ self ifTrue: anotherBlock ifFalse: aBlock
+!
+
+ifTrue: aBlock
+	"inlined in the Compiler"
+	^ self ifTrue: aBlock ifFalse: []
+!
+
+ifTrue: aBlock ifFalse: anotherBlock
+	"inlined in the Compiler"
+	<
+		if(self == true) {
+		return aBlock._value();
+		} else {
+		return anotherBlock._value();
+		}
+	>
+!
+
+not
+	^ self = false
+!
+
+or: aBlock
+	^ self = true
+		ifTrue: [ true ]
+		ifFalse: aBlock
+!
+
+| aBoolean
+	<
+		if(self == true) {
+		return true;
+		} else {
+		return aBoolean;
+		}
+	>
+! !
+
+!Boolean methodsFor: 'converting'!
+
+asBit
+	^ self ifTrue: [ 1 ] ifFalse: [ 0 ]
+!
+
+asJSON
+	^ self
+!
+
+asString
+	< return self.toString() >
+! !
+
+!Boolean methodsFor: 'copying'!
+
+deepCopy
+	^ self
+!
+
+shallowCopy
+	^ self
+! !
+
+!Boolean methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: self asString
+! !
+
+!Boolean methodsFor: 'testing'!
+
+isBoolean
+	^ true
+!
+
+isImmutable
+	^ true
+! !
+
+Object subclass: #Date
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!Date commentStamp!
+I am used to work with both dates and times. Therefore `Date today` and `Date now` are both valid in
+Amber and answer the same date object.
+
+Date directly maps to the `Date()` JavaScript constructor, and Amber date objects are JavaScript date objects.
+
+## API
+
+The class-side `instance creation` protocol contains some convenience methods for creating date/time objects such as `#fromSeconds:`.
+
+Arithmetic and comparison is supported (see the `comparing` and `arithmetic` protocols).
+
+The `converting` protocol provides convenience methods for various convertions (to numbers, strings, etc.).!
+
+!Date methodsFor: 'accessing'!
+
+day
+	^ self dayOfWeek
+!
+
+day: aNumber
+	self dayOfWeek: aNumber
+!
+
+dayOfMonth
+	<return self.getDate()>
+!
+
+dayOfMonth: aNumber
+	<self.setDate(aNumber)>
+!
+
+dayOfWeek
+	<return self.getDay() + 1>
+!
+
+dayOfWeek: aNumber
+	<return self.setDay(aNumber - 1)>
+!
+
+hours
+	<return self.getHours()>
+!
+
+hours: aNumber
+	<self.setHours(aNumber)>
+!
+
+milliseconds
+	<return self.getMilliseconds()>
+!
+
+milliseconds: aNumber
+	<self.setMilliseconds(aNumber)>
+!
+
+minutes
+	<return self.getMinutes()>
+!
+
+minutes: aNumber
+	<self.setMinutes(aNumber)>
+!
+
+month
+	<return self.getMonth() + 1>
+!
+
+month: aNumber
+	<self.setMonth(aNumber - 1)>
+!
+
+seconds
+	<return self.getSeconds()>
+!
+
+seconds: aNumber
+	<self.setSeconds(aNumber)>
+!
+
+time
+	<return self.getTime()>
+!
+
+time: aNumber
+	<self.setTime(aNumber)>
+!
+
+year
+	<return self.getFullYear()>
+!
+
+year: aNumber
+	<self.setFullYear(aNumber)>
+! !
+
+!Date methodsFor: 'arithmetic'!
+
++ aDate
+	<return self + aDate>
+!
+
+- aDate
+	<return self - aDate>
+! !
+
+!Date methodsFor: 'comparing'!
+
+< aDate
+	<return self < aDate>
+!
+
+<= aDate
+	<return self <= aDate>
+!
+
+> aDate
+	<return self >> aDate>
+!
+
+>= aDate
+	<return self >>= aDate>
+! !
+
+!Date methodsFor: 'converting'!
+
+asDateString
+	<return self.toDateString()>
+!
+
+asLocaleString
+	<return self.toLocaleString()>
+!
+
+asMilliseconds
+	^ self time
+!
+
+asNumber
+	^ self asMilliseconds
+!
+
+asString
+	<return self.toString()>
+!
+
+asTimeString
+	<return self.toTimeString()>
+! !
+
+!Date methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: self asString
+! !
+
+!Date class methodsFor: 'helios'!
+
+heliosClass
+	^ 'magnitude'
+! !
+
+!Date class methodsFor: 'instance creation'!
+
+fromMilliseconds: aNumber
+	^ self new: aNumber
+!
+
+fromSeconds: aNumber
+	^ self fromMilliseconds: aNumber * 1000
+!
+
+fromString: aString
+	"Example: Date fromString('2011/04/15 00:00:00')"
+	^ self new: aString
+!
+
+millisecondsToRun: aBlock
+	| t |
+	t := Date now.
+	aBlock value.
+	^ Date now - t
+!
+
+new: anObject
+	<return new Date(anObject)>
+!
+
+now
+	^ self today
+!
+
+today
+	^ self new
+! !
+
+Object subclass: #Number
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!Number commentStamp!
+I am the Amber representation for all numbers.
+I am directly mapped to JavaScript Number.
+
+## API
+
+I provide all necessary methods for arithmetic operations, comparison, conversion and so on with numbers.
+
+My instances can also be used to evaluate a block a fixed number of times:
+
+	5 timesRepeat: [ Transcript show: 'This will be printed 5 times'; cr ].
+	
+	1 to: 5 do: [ :aNumber| Transcript show: aNumber asString; cr ].
+	
+	1 to: 10 by: 2 do: [ :aNumber| Transcript show: aNumber asString; cr ].!
+
+!Number methodsFor: 'accessing'!
+
+identityHash
+	^ self asString, 'n'
+! !
+
+!Number methodsFor: 'arithmetic'!
+
+* aNumber
+	"Inlined in the Compiler"
+	<return self * aNumber>
+!
+
++ aNumber
+	"Inlined in the Compiler"
+	<return self + aNumber>
+!
+
+- aNumber
+	"Inlined in the Compiler"
+	<return self - aNumber>
+!
+
+/ aNumber
+	"Inlined in the Compiler"
+	<return self / aNumber>
+!
+
+// aNumber
+	^ (self / aNumber) floor
+!
+
+\\ aNumber
+	<return self % aNumber>
+!
+
+abs
+	<return Math.abs(self);>
+!
+
+max: aNumber
+	<return Math.max(self, aNumber);>
+!
+
+min: aNumber
+	<return Math.min(self, aNumber);>
+!
+
+negated
+	^ 0 - self
+! !
+
+!Number methodsFor: 'comparing'!
+
+< aNumber
+	"Inlined in the Compiler"
+	<return self < aNumber>
+!
+
+<= aNumber
+	"Inlined in the Compiler"
+	<return self <= aNumber>
+!
+
+= aNumber
+	<
+		return aNumber !!= null &&
+			typeof aNumber._isNumber === "function" &&
+			aNumber._isNumber() &&
+			Number(self) == aNumber
+	>
+!
+
+> aNumber
+	"Inlined in the Compiler"
+	<return self >> aNumber>
+!
+
+>= aNumber
+	"Inlined in the Compiler"
+	<return self >>= aNumber>
+! !
+
+!Number methodsFor: 'converting'!
+
+& aNumber
+	<return self & aNumber>
+!
+
+@ aNumber
+	^ Point x: self y: aNumber
+!
+
+asJSON
+	^ self
+!
+
+asJavascript
+	^ '(', self printString, ')'
+!
+
+asNumber
+	^ self
+!
+
+asPoint
+	^ Point x: self y: self
+!
+
+asString
+	< return String(self) >
+!
+
+atRandom
+	^ (Random new next * self) truncated + 1
+!
+
+ceiling
+	<return Math.ceil(self);>
+!
+
+floor
+	<return Math.floor(self);>
+!
+
+rounded
+	<return Math.round(self);>
+!
+
+to: aNumber
+	| array first last count |
+	first := self truncated.
+	last := aNumber truncated + 1.
+	count := 1.
+	array := Array new.
+	(last - first) timesRepeat: [
+		array at: count put: first.
+		count := count + 1.
+		first := first + 1 ].
+	^ array
+!
+
+to: stop by: step
+	| array value pos |
+	value := self.
+	array := Array new.
+	pos := 1.
+	step = 0 ifTrue: [ self error: 'step must be non-zero' ].
+	step < 0
+		ifTrue: [ [ value >= stop ] whileTrue: [
+					array at: pos put: value.
+					pos := pos + 1.
+					value := value + step ]]
+		ifFalse: [ [ value <= stop ] whileTrue: [
+					array at: pos put: value.
+				pos := pos + 1.
+					value := value + step ]].
+	^ array
+!
+
+truncated
+	<
+		if(self >>= 0) {
+			return Math.floor(self);
+		} else {
+			return Math.floor(self * (-1)) * (-1);
+		};
+	>
+!
+
+| aNumber
+	<return self | aNumber>
+! !
+
+!Number methodsFor: 'copying'!
+
+copy
+	^ self
+!
+
+deepCopy
+	^ self copy
+! !
+
+!Number methodsFor: 'enumerating'!
+
+timesRepeat: aBlock
+	| count |
+	count := 1.
+	[ count > self ] whileFalse: [
+		aBlock value.
+		count := count + 1 ]
+!
+
+to: stop by: step do: aBlock
+	| value |
+	value := self.
+	step = 0 ifTrue: [ self error: 'step must be non-zero' ].
+	step < 0
+		ifTrue: [ [ value >= stop ] whileTrue: [
+					aBlock value: value.
+					value := value + step ]]
+		ifFalse: [ [ value <= stop ] whileTrue: [
+					aBlock value: value.
+					value := value + step ]]
+!
+
+to: stop do: aBlock
+	"Evaluate aBlock for each number from self to aNumber."
+	| nextValue |
+	nextValue := self.
+	[ nextValue <= stop ]
+		whileTrue:
+			[ aBlock value: nextValue.
+			nextValue := nextValue + 1 ]
+! !
+
+!Number methodsFor: 'mathematical functions'!
+
+** exponent
+	^ self raisedTo: exponent
+!
+
+arcCos
+	<return Math.acos(self);>
+!
+
+arcSin
+	<return Math.asin(self);>
+!
+
+arcTan
+	<return Math.atan(self);>
+!
+
+cos
+	<return Math.cos(self);>
+!
+
+ln
+	<return Math.log(self);>
+!
+
+log
+	<return Math.log(self) / Math.LN10;>
+!
+
+log: aNumber
+	<return Math.log(self) / Math.log(aNumber);>
+!
+
+raisedTo: exponent
+	<return Math.pow(self, exponent);>
+!
+
+sign
+	self isZero 
+		ifTrue: [ ^ 0 ].
+	self positive
+		ifTrue: [ ^ 1 ]
+		ifFalse: [ ^ -1 ].
+!
+
+sin
+	<return Math.sin(self);>
+!
+
+sqrt
+	<return Math.sqrt(self)>
+!
+
+squared
+	^ self * self
+!
+
+tan
+	<return Math.tan(self);>
+! !
+
+!Number methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: self asString
+!
+
+printShowingDecimalPlaces: placesDesired
+	<return self.toFixed(placesDesired)>
+! !
+
+!Number methodsFor: 'testing'!
+
+even
+	^ 0 = (self \\ 2)
+!
+
+isImmutable
+	^ true
+!
+
+isNumber
+	^ true
+!
+
+isZero
+	^ self = 0
+!
+
+negative
+	"Answer whether the receiver is mathematically negative."
+
+	^ self < 0
+!
+
+odd
+	^ self even not
+!
+
+positive
+	"Answer whether the receiver is positive or equal to 0. (ST-80 protocol)."
+
+	^ self >= 0
+! !
+
+!Number class methodsFor: 'helios'!
+
+heliosClass
+	^ 'magnitude'
+! !
+
+!Number class methodsFor: 'instance creation'!
+
+e
+	<return Math.E;>
+!
+
+pi
+	<return Math.PI>
+! !
+
+Object subclass: #Point
+	instanceVariableNames: 'x y'
+	package: 'Kernel-Objects'!
+!Point commentStamp!
+I represent an x-y pair of numbers usually designating a geometric coordinate.
+
+## API
+
+Instances are traditionally created using the binary `#@` message to a number:
+
+	100@120
+
+Points can then be arithmetically manipulated:
+
+	100@100 + (10@10)
+
+...or for example:
+
+	(100@100) * 2
+
+**NOTE:** Creating a point with a negative y-value will need a space after `@` in order to avoid a parsing error:
+
+	100@ -100 "but 100@-100 would not parse"!
+
+!Point methodsFor: 'accessing'!
+
+x
+	^ x
+!
+
+x: aNumber
+	x := aNumber
+!
+
+y
+	^ y
+!
+
+y: aNumber
+	y := aNumber
+! !
+
+!Point methodsFor: 'arithmetic'!
+
+* aPoint
+	^ Point x: self x * aPoint asPoint x y: self y * aPoint asPoint y
+!
+
++ aPoint
+	^ Point x: self x + aPoint asPoint x y: self y + aPoint asPoint y
+!
+
+- aPoint
+	^ Point x: self x - aPoint asPoint x y: self y - aPoint asPoint y
+!
+
+/ aPoint
+	^ Point x: self x / aPoint asPoint x y: self y / aPoint asPoint y
+! !
+
+!Point methodsFor: 'comparing'!
+
+< aPoint
+	^ self x < aPoint x and: [
+		self y < aPoint y ]
+!
+
+<= aPoint
+	^ self x <= aPoint x and: [
+		self y <= aPoint y ]
+!
+
+= aPoint
+	^ aPoint class = self class and: [
+		(aPoint x = self x) & (aPoint y = self y) ]
+!
+
+> aPoint
+	^ self x > aPoint x and: [
+		self y > aPoint y ]
+!
+
+>= aPoint
+	^ self x >= aPoint x and: [
+		self y >= aPoint y ]
+! !
+
+!Point methodsFor: 'converting'!
+
+asPoint
+	^ self
+! !
+
+!Point methodsFor: 'printing'!
+
+printOn: aStream
+	"Print receiver in classic x@y notation."
+
+	x printOn: aStream.
+	
+	aStream nextPutAll: '@'.
+	(y notNil and: [ y negative ]) ifTrue: [
+			"Avoid ambiguous @- construct"
+			aStream space ].
+	
+	y printOn: aStream
+! !
+
+!Point methodsFor: 'transforming'!
+
+dist: aPoint 
+	"Answer the distance between aPoint and the receiver."
+	| dx dy |
+	dx := aPoint x - x.
+	dy := aPoint y - y.
+	^ (dx * dx + (dy * dy)) sqrt
+!
+
+translateBy: delta
+	"Answer a Point translated by delta (an instance of Point)."
+	^ (delta x + x) @ (delta y + y)
+! !
+
+!Point class methodsFor: 'helios'!
+
+heliosClass
+	^ 'magnitude'
+! !
+
+!Point class methodsFor: 'instance creation'!
+
+x: aNumber y: anotherNumber
+	^ self new
+		x: aNumber;
+		y: anotherNumber;
+		yourself
+! !
+
+Object subclass: #Random
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!Random commentStamp!
+I an used to generate a random number and I am implemented as a trivial wrapper around javascript `Math.random()`.
+
+## API
+
+The typical use case it to use the `#next` method like the following:
+
+	Random new next
+
+This will return a float x where x < 1 and x > 0. If you want a random integer from 1 to 10 you can use `#atRandom`
+
+	10 atRandom
+
+A random number in a specific interval can be obtained with the following:
+
+	(3 to: 7) atRandom
+
+Be aware that `#to:` does not create an Interval as in other Smalltalk implementations but in fact an `Array` of numbers, so it's better to use:
+
+	5 atRandom + 2
+
+Since `#atRandom` is implemented in `SequencableCollection` you can easy pick an element at random:
+
+	#('a' 'b' 'c') atRandom
+
+As well as letter from a `String`:
+
+	'abc' atRandom
+
+Since Amber does not have Characters this will return a `String` of length 1 like for example `'b'`.!
+
+!Random methodsFor: 'accessing'!
+
+next
+	<return Math.random()>
+!
+
+next: anInteger
+	^ (1 to: anInteger) collect: [ :each | self next ]
+! !
+
+Object subclass: #UndefinedObject
+	instanceVariableNames: ''
+	package: 'Kernel-Objects'!
+!UndefinedObject commentStamp!
+I describe the behavior of my sole instance, `nil`. `nil` represents a prior value for variables that have not been initialized, or for results which are meaningless.
+
+`nil` is the Smalltalk equivalent of the `undefined` JavaScript object.
+
+__note:__ When sending messages to the `undefined` JavaScript object, it will be replaced by `nil`.!
+
+!UndefinedObject methodsFor: 'class creation'!
+
+subclass: aString instanceVariableNames: anotherString
+	"Kept for file-in compatibility."
+	^ self subclass: aString instanceVariableNames: anotherString package: nil
+!
+
+subclass: aString instanceVariableNames: aString2 category: aString3
+	"Kept for file-in compatibility."
+	^ self subclass: aString instanceVariableNames: aString2 package: aString3
+!
+
+subclass: aString instanceVariableNames: aString2 classVariableNames: classVars poolDictionaries: pools category: aString3
+	"Kept for file-in compatibility. ignores class variables and pools."
+	^ self subclass: aString instanceVariableNames: aString2 package: aString3
+!
+
+subclass: aString instanceVariableNames: aString2 package: aString3
+	^ ClassBuilder new
+		superclass: self subclass: aString asString instanceVariableNames: aString2 package: aString3
+! !
+
+!UndefinedObject methodsFor: 'converting'!
+
+asJSON
+	^ null
+! !
+
+!UndefinedObject methodsFor: 'copying'!
+
+deepCopy
+	^ self
+!
+
+shallowCopy
+	^ self
+! !
+
+!UndefinedObject methodsFor: 'printing'!
+
+printOn: aStream
+	aStream nextPutAll: 'nil'
+! !
+
+!UndefinedObject methodsFor: 'testing'!
+
+ifNil: aBlock
+	"inlined in the Compiler"
+	^ self ifNil: aBlock ifNotNil: []
+!
+
+ifNil: aBlock ifNotNil: anotherBlock
+	"inlined in the Compiler"
+	^ aBlock value
+!
+
+ifNotNil: aBlock
+	"inlined in the Compiler"
+	^ self
+!
+
+ifNotNil: aBlock ifNil: anotherBlock
+	"inlined in the Compiler"
+	^ anotherBlock value
+!
+
+isImmutable
+	^ true
+!
+
+isNil
+	^ true
+!
+
+notNil
+	^ false
+! !
+
+!UndefinedObject class methodsFor: 'instance creation'!
+
+new
+		self error: 'You cannot create new instances of UndefinedObject. Use nil'
+! !
+

Diff do ficheiro suprimidas por serem muito extensas
+ 12244 - 0
bower_components/amber/src/Kernel-Tests.js


+ 2713 - 0
bower_components/amber/src/Kernel-Tests.st

@@ -0,0 +1,2713 @@
+Smalltalk createPackage: 'Kernel-Tests'!
+TestCase subclass: #AnnouncementSubscriptionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!AnnouncementSubscriptionTest methodsFor: 'tests'!
+
+testAddExtensionMethod
+	| method dirty |
+	dirty := self class package isDirty.
+	self class package beClean.
+	method := self class compile: 'doNothing' protocol: '**not-a-package'.
+	self deny: self class package isDirty.
+	
+	self class removeCompiledMethod: method.
+	dirty ifTrue: [ self class package beDirty ]
+!
+
+testHandlesAnnouncement
+	| subscription announcementClass1 announcementClass2 classBuilder |
+	
+	classBuilder := ClassBuilder new.
+	announcementClass1 := classBuilder basicAddSubclassOf: SystemAnnouncement named: 'TestAnnouncement1' instanceVariableNames: #() package: 'Kernel-Tests'.
+	
+	subscription := AnnouncementSubscription new announcementClass: SystemAnnouncement.
+	"Test whether the same class triggers the announcement"
+	self assert: (subscription handlesAnnouncement: SystemAnnouncement) equals: true.
+	"Test whether a subclass triggers the announcement"
+	self assert: (subscription handlesAnnouncement: announcementClass1) equals: true.
+	"Test whether an unrelated class does not trigger the announcement"
+	self assert: (subscription handlesAnnouncement: Object) equals: false.
+	
+	classBuilder basicRemoveClass: announcementClass1.
+! !
+
+TestCase subclass: #AnnouncerTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!AnnouncerTest methodsFor: 'tests'!
+
+testOnDo
+	| counter announcer |
+	
+	counter := 0.
+	announcer := Announcer new.
+	announcer on: SystemAnnouncement do: [ counter := counter + 1 ].
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 1.
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 2.
+!
+
+testOnDoFor
+	| counter announcer |
+	
+	counter := 0.
+	announcer := Announcer new.
+	announcer on: SystemAnnouncement do: [ counter := counter + 1 ] for: self.
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 1.
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 2.
+	
+	announcer unsubscribe: self.
+	
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 2.
+!
+
+testOnDoOnce
+	| counter announcer |
+	
+	counter := 0.
+	announcer := Announcer new.
+	announcer on: SystemAnnouncement doOnce: [ counter := counter + 1 ].
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 1.
+
+	announcer announce: (SystemAnnouncement new).
+	self assert: counter equals: 1.
+! !
+
+TestCase subclass: #BlockClosureTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!BlockClosureTest methodsFor: 'tests'!
+
+testCanClearInterval
+	self shouldnt: [ ([ Error new signal ] valueWithInterval: 0) clearInterval ] raise: Error
+!
+
+testCanClearTimeout
+	self shouldnt: [ ([ Error new signal ] valueWithTimeout: 0) clearTimeout ] raise: Error
+!
+
+testCompiledSource
+	self assert: ([ 1+1 ] compiledSource includesSubString: 'function')
+!
+
+testCurrySelf
+	| curriedMethod array |
+	curriedMethod := [ :selfarg :x | selfarg at: x ] currySelf asCompiledMethod: 'foo:'.
+	array := #(3 1 4).
+	ClassBuilder new installMethod: curriedMethod forClass: Array protocol: '**test helper'.
+	[ self assert: (array foo: 2) equals: 1 ]
+	ensure: [ Array removeCompiledMethod: curriedMethod ]
+!
+
+testEnsure
+	self assert: ([ 3 ] ensure: [ 4 ]) equals: 3
+!
+
+testEnsureRaises
+	self should: [ [Error new signal ] ensure: [ true ]] raise: Error
+!
+
+testExceptionSemantics
+	"See https://github.com/NicolasPetton/amber/issues/314"
+	self timeout: 100.
+	
+	(self async: [
+		[
+			self assert: true.
+			Error signal.
+			"The following should *not* be run"
+			self deny: true.
+			self finished.
+		] on: Error do: [ :ex | self finished ]
+	]) valueWithTimeout: 0
+!
+
+testNewWithValues
+<
+	function TestConstructor(arg1, arg2, arg3) {}
+	TestConstructor.prototype.name = 'theTestPrototype';
+
+	var wrappedConstructor = $recv(TestConstructor);
+	var result = wrappedConstructor._newWithValues_([1, 2, 3 ]);
+	self._assert_(result instanceof TestConstructor);
+	self._assert_equals_(result.name, 'theTestPrototype');
+
+	"newWithValues: cannot help if the argument list is wrong, and should warn that a mistake was made."
+	self._should_raise_(function () {wrappedConstructor._newWithValues_('single argument');}, $globals.Error);
+>
+!
+
+testNumArgs
+	self assert: [] numArgs equals: 0.
+	self assert: [ :a :b | ] numArgs equals: 2
+!
+
+testOnDo
+	self assert: ([ Error new signal ] on: Error do: [ :ex | true ])
+!
+
+testValue
+	self assert: ([ 1+1 ] value) equals: 2.
+	self assert: ([ :x | x +1 ] value: 2) equals: 3.
+	self assert: ([ :x :y | x*y ] value: 2 value: 4) equals: 8.
+
+	"Arguments are optional in Amber. This isn't ANSI compliant."
+
+	self assert: ([ :a :b :c | 1 ] value) equals: 1
+!
+
+testValueWithPossibleArguments
+	self assert: ([ 1 ] valueWithPossibleArguments: #(3 4)) equals: 1.
+	self assert: ([ :a | a + 4 ] valueWithPossibleArguments: #(3 4)) equals: 7.
+	self assert: ([ :a :b | a + b ] valueWithPossibleArguments: #(3 4 5)) equals: 7.
+!
+
+testWhileFalse
+	| i |
+	i := 0.
+	[ i > 5 ] whileFalse: [ i := i + 1 ].
+	self assert: i equals: 6.
+
+	i := 0.
+	[ i := i + 1. i > 5 ] whileFalse.
+	self assert: i equals: 6
+!
+
+testWhileTrue
+	| i |
+	i := 0.
+	[ i < 5 ] whileTrue: [ i := i + 1 ].
+	self assert: i equals: 5.
+
+	i := 0.
+	[ i := i + 1. i < 5 ] whileTrue.
+	self assert: i equals: 5
+! !
+
+TestCase subclass: #BooleanTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!BooleanTest methodsFor: 'tests'!
+
+testEquality
+	"We're on top of JS...just be sure to check the basics!!"
+
+	self deny: 0 = false.
+	self deny: false = 0.
+	self deny: '' = false.
+	self deny: false = ''.
+
+	self assert: (true = true).
+	self deny: false = true.
+	self deny: true = false.
+	self assert: (false = false).
+
+	"JS may do some type coercing after sending a message"
+	self assert: (true yourself = true).
+	self assert: (true yourself = true yourself)
+!
+
+testIdentity
+	"We're on top of JS...just be sure to check the basics!!"
+
+	self deny: 0 == false.
+	self deny: false == 0.
+	self deny: '' == false.
+	self deny: false == ''.
+
+	self assert: true == true.
+	self deny: false == true.
+	self deny: true == false.
+	self assert: false == false.
+
+	"JS may do some type coercing after sending a message"
+	self assert: true yourself == true.
+	self assert: true yourself == true yourself
+!
+
+testIfTrueIfFalse
+
+	self assert: (true ifTrue: [ 'alternative block' ]) equals: 'alternative block'.
+	self assert: (true ifFalse: [ 'alternative block' ]) equals: nil.
+
+	self assert: (false ifTrue: [ 'alternative block' ]) equals: nil.
+	self assert: (false ifFalse: [ 'alternative block' ]) equals: 'alternative block'.
+
+	self assert: (false ifTrue: [ 'alternative block' ] ifFalse: [ 'alternative block2' ]) equals: 'alternative block2'.
+	self assert: (false ifFalse: [ 'alternative block' ] ifTrue: [ 'alternative block2' ]) equals: 'alternative block'.
+
+	self assert: (true ifTrue: [ 'alternative block' ] ifFalse: [ 'alternative block2' ]) equals: 'alternative block'.
+	self assert: (true ifFalse: [ 'alternative block' ] ifTrue: [ 'alternative block2' ]) equals: 'alternative block2'.
+!
+
+testIfTrueIfFalseWithBoxing
+
+	self assert: (true yourself ifTrue: [ 'alternative block' ]) equals: 'alternative block'.
+	self assert: (true yourself ifFalse: [ 'alternative block' ]) equals: nil.
+
+	self assert: (false yourself ifTrue: [ 'alternative block' ]) equals: nil.
+	self assert: (false yourself ifFalse: [ 'alternative block' ]) equals: 'alternative block'.
+
+	self assert: (false yourself ifTrue: [ 'alternative block' ] ifFalse: [ 'alternative block2' ]) equals: 'alternative block2'.
+	self assert: (false yourself ifFalse: [ 'alternative block' ] ifTrue: [ 'alternative block2' ]) equals: 'alternative block'.
+
+	self assert: (true yourself ifTrue: [ 'alternative block' ] ifFalse: [ 'alternative block2' ]) equals: 'alternative block'.
+	self assert: (true yourself ifFalse: [ 'alternative block' ] ifTrue: [ 'alternative block2' ]) equals: 'alternative block2'.
+!
+
+testLogic
+	"Trivial logic table"
+	self assert: (true & true);
+		deny: (true & false);
+		deny: (false & true);
+		deny: (false & false).
+	self assert: (true | true);
+		assert: (true | false);
+		assert: (false | true);
+		deny: (false | false).
+	"Checking that expressions work fine too"
+	self assert: (true & (1 > 0));
+		deny: ((1 > 0) & false);
+		deny: ((1 > 0) & (1 > 2)).
+	self assert: (false | (1 > 0));
+		assert: ((1 > 0) | false);
+		assert: ((1 > 0) | (1 > 2))
+!
+
+testLogicKeywords
+	"Trivial logic table"
+	self
+		assert: (true and: [ true ]);
+		deny: (true and: [ false ]);
+		deny: (false and: [ true ]);
+		deny: (false and: [ false ]).
+	self
+		assert: (true or: [ true ]);
+		assert: (true or: [ false ]);
+		assert: (false or: [ true ]);
+		deny: (false or: [ false ]).
+		
+	"Checking that expressions work fine too"
+	self
+		assert: (true and: [ 1 > 0 ]);
+		deny: ((1 > 0) and: [ false ]);
+		deny: ((1 > 0) and: [ 1 > 2 ]).
+	self
+		assert: (false or: [ 1 > 0 ]);
+		assert: ((1 > 0) or: [ false ]);
+		assert: ((1 > 0) or: [ 1 > 2 ])
+!
+
+testNonBooleanError
+	self should: [ '' ifTrue: [] ifFalse: [] ] raise: NonBooleanReceiver
+! !
+
+TestCase subclass: #ClassBuilderTest
+	instanceVariableNames: 'builder theClass'
+	package: 'Kernel-Tests'!
+
+!ClassBuilderTest methodsFor: 'running'!
+
+setUp
+	builder := ClassBuilder new
+!
+
+tearDown
+	theClass ifNotNil: [ Smalltalk removeClass: theClass. theClass := nil ]
+! !
+
+!ClassBuilderTest methodsFor: 'tests'!
+
+testClassCopy
+	theClass := builder copyClass: ObjectMock named: 'ObjectMock2'.
+	self assert: theClass superclass == ObjectMock superclass.
+	self assert: theClass instanceVariableNames == ObjectMock instanceVariableNames.
+	self assert: theClass name equals: 'ObjectMock2'.
+	self assert: theClass package == ObjectMock package.
+	self assert: theClass methodDictionary keys equals: ObjectMock methodDictionary keys
+!
+
+testClassMigration
+	| instance oldClass |
+	
+	oldClass := builder copyClass: ObjectMock named: 'ObjectMock2'.
+	instance := (Smalltalk globals at: 'ObjectMock2') new.
+	
+	"Change the superclass of ObjectMock2"
+	ObjectMock subclass: (Smalltalk globals at: 'ObjectMock2')
+		instanceVariableNames: ''
+		package: 'Kernel-Tests'.
+	
+	self deny: oldClass == ObjectMock2.
+	
+	self assert: ObjectMock2 superclass == ObjectMock.
+	self assert: ObjectMock2 instanceVariableNames isEmpty.
+	self assert: ObjectMock2 selectors equals: oldClass selectors.
+	self assert: ObjectMock2 comment equals: oldClass comment.
+	self assert: ObjectMock2 package name equals: 'Kernel-Tests'.
+	
+	self deny: instance class == ObjectMock2.
+	"Commeting this out. Tests implementation detail."
+	"self assert: instance class name equals: 'OldObjectMock2'."
+	
+	self assert: (Smalltalk globals at: instance class name) isNil.
+	
+	Smalltalk removeClass: ObjectMock2
+!
+
+testClassMigrationWithClassInstanceVariables
+	
+	builder copyClass: ObjectMock named: 'ObjectMock2'.
+	ObjectMock2 class instanceVariableNames: 'foo bar'.
+	
+	"Change the superclass of ObjectMock2"
+	ObjectMock subclass: (Smalltalk globals at: 'ObjectMock2')
+		instanceVariableNames: ''
+		package: 'Kernel-Tests'.
+	
+	self assert: ObjectMock2 class instanceVariableNames equals: #('foo' 'bar').
+	
+	Smalltalk removeClass: ObjectMock2
+!
+
+testClassMigrationWithSubclasses
+	
+	builder copyClass: ObjectMock named: 'ObjectMock2'.
+	ObjectMock2 subclass: 'ObjectMock3' instanceVariableNames: '' package: 'Kernel-Tests'.
+	ObjectMock3 subclass: 'ObjectMock4' instanceVariableNames: '' package: 'Kernel-Tests'.
+	
+	"Change the superclass of ObjectMock2"
+	ObjectMock subclass: (Smalltalk globals at: 'ObjectMock2')
+		instanceVariableNames: ''
+		package: 'Kernel-Tests'.
+	
+	self assert: (ObjectMock subclasses includes: ObjectMock2).
+	self assert: (ObjectMock2 subclasses includes: ObjectMock3).
+	self assert: (ObjectMock3 subclasses includes: ObjectMock4).
+	
+	ObjectMock allSubclasses do: [ :each | Smalltalk removeClass: each ]
+!
+
+testInstanceVariableNames
+	self assert: (builder instanceVariableNamesFor: '  hello   world   ') equals: #('hello' 'world')
+! !
+
+TestCase subclass: #CollectionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!CollectionTest methodsFor: 'convenience'!
+
+assertSameContents: aCollection as: anotherCollection
+	self assert: (aCollection size = anotherCollection size).
+	aCollection do: [ :each |
+		self assert: ((aCollection occurrencesOf: each) = (anotherCollection occurrencesOf: each)) ]
+! !
+
+!CollectionTest methodsFor: 'fixture'!
+
+collection
+	"Answers pre-filled collection of type tested."
+
+	self subclassResponsibility
+!
+
+collectionClass
+	"Answers class of collection type tested"
+
+	^ self class collectionClass
+!
+
+collectionOfPrintStrings
+	"Answers self collection but with values
+	changed to their printStrings"
+
+	self subclassResponsibility
+!
+
+collectionSize
+	"Answers size of self collection."
+
+	self subclassResponsibility
+!
+
+collectionWithDuplicates
+	"Answers pre-filled collection of type tested,
+	with exactly five distinct elements,
+	some of them appearing multiple times, if possible."
+
+	self subclassResponsibility
+!
+
+collectionWithNewValue
+	"Answers a collection which shows how
+	self collection would look after adding
+	self sampleNewValue"
+	
+	self subclassResponsibility
+!
+
+sampleNewValue
+	"Answers a value that is not yet there
+	and can be put into a tested collection"
+	
+	^ 'N'
+!
+
+sampleNewValueAsCollection
+	"Answers self sampleNewValue
+	wrapped in single element collection
+	of tested type"
+	
+	^ self collectionClass with: self sampleNewValue
+! !
+
+!CollectionTest methodsFor: 'testing'!
+
+isCollectionReadOnly
+	^ false
+! !
+
+!CollectionTest methodsFor: 'tests'!
+
+testAddAll
+	self assert: (self collection addAll: self collectionClass new; yourself) equals: self collection.
+	self assert: (self collectionClass new addAll: self collection; yourself) equals: self collection.
+	self assert: (self collectionClass new addAll: self collectionClass new; yourself) equals: self collectionClass new.
+	self assert: (self collection addAll: self sampleNewValueAsCollection; yourself) equals: self collectionWithNewValue.
+	self assertSameContents: (self sampleNewValueAsCollection addAll: self collection; yourself) as: self collectionWithNewValue
+!
+
+testAllSatisfy
+	| collection anyOne |
+	collection := self collection.
+	anyOne := collection anyOne.
+	self assert: (collection allSatisfy: [ :each | collection includes: each ]).
+	self deny: (collection allSatisfy: [ :each | each ~= anyOne ])
+!
+
+testAnyOne
+	self should: [ self collectionClass new anyOne ] raise: Error.
+	self assert: (self collection includes: self collection anyOne)
+!
+
+testAnySatisfy
+	| anyOne |
+	anyOne := self collection anyOne.
+	self assert: (self collection anySatisfy: [ :each | each = anyOne ]).
+	self deny: (self collection anySatisfy: [ :each | each = Object new ])
+!
+
+testAsArray
+	self
+		assertSameContents: self collection
+		as: self collection asArray
+!
+
+testAsOrderedCollection
+	self
+		assertSameContents: self collection
+		as: self collection asOrderedCollection
+!
+
+testAsSet
+	| c set |
+	c := self collectionWithDuplicates.
+	set := c asSet.
+	self assert: set size equals: 5.
+	c do: [ :each |
+		self assert: (set includes: each) ]
+!
+
+testCollect
+	self assert: (self collection collect: [ :each | each ]) equals: self collection.
+	self assert: (self collectionWithNewValue collect: [ :each | each ]) equals: self collectionWithNewValue.
+	self assert: (self collectionClass new collect: [ :each | each printString ]) equals: self collectionClass new.
+	self assert: ((self collection collect: [ self sampleNewValue ]) detect: [ true ]) equals: self sampleNewValue.
+	self assert: (self collection collect: [ :each | each printString ]) equals: self collectionOfPrintStrings
+!
+
+testComma
+	self assert: self collection, self collectionClass new equals: self collection.
+	self assert: self collectionClass new, self collection equals: self collection.
+	self assert: self collectionClass new, self collectionClass new equals: self collectionClass new.
+	self assert: self collection, self sampleNewValueAsCollection equals: self collectionWithNewValue.
+	self assertSameContents: self sampleNewValueAsCollection, self collection as: self collectionWithNewValue
+!
+
+testDetect
+	self
+		shouldnt: [ self collection detect: [ true ] ]
+		raise: Error.
+	self
+		should: [ self collection detect: [ false ] ]
+		raise: Error.
+	self assert: (self sampleNewValueAsCollection detect: [ true ]) equals: self sampleNewValue.
+	self assert: (self collectionWithNewValue detect: [ :each | each = self sampleNewValue ]) equals: self sampleNewValue.
+	self
+		should: [ self collection detect: [ :each | each = self sampleNewValue ] ]
+		raise: Error
+!
+
+testDetectIfNone
+	| sentinel |
+	sentinel := Object new.
+	self assert: (self collection detect: [ true ] ifNone: [ sentinel ]) ~= sentinel.
+	self assert: (self collection detect: [ false ] ifNone: [ sentinel ]) equals: sentinel.
+	self assert: (self sampleNewValueAsCollection detect: [ true ] ifNone: [ sentinel ]) equals: self sampleNewValue.
+	self assert: (self collectionWithNewValue detect: [ :each | each = self sampleNewValue ] ifNone: [ sentinel ]) equals: self sampleNewValue.
+	self assert: (self collection detect: [ :each | each = self sampleNewValue ] ifNone: [ sentinel ]) equals: sentinel
+!
+
+testDo
+	| newCollection |
+	newCollection := OrderedCollection new.
+	self collection do: [ :each |
+		newCollection add: each ].
+	self
+		assertSameContents: self collection
+		as: newCollection.
+	newCollection := OrderedCollection new.
+	self collectionWithDuplicates do: [ :each |
+		newCollection add: each ].
+	self
+		assertSameContents: self collectionWithDuplicates
+		as: newCollection
+!
+
+testIfEmptyFamily
+	self assert: (self collectionClass new ifEmpty: [ 42 ]) equals: 42.
+	self assert: (self collection ifEmpty: [ 42 ]) equals: self collection.
+
+	self assert: (self collectionClass new ifNotEmpty: [ 42 ]) equals: self collectionClass new.
+	self assert: (self collection ifNotEmpty: [ 42 ]) equals: 42.
+	self assert: (self collection ifNotEmpty: [ :col | col ]) equals: self collection.
+	
+	self assert: (self collectionClass new ifEmpty: [ 42 ] ifNotEmpty: [ 999 ]) equals: 42.
+	self assert: (self collection ifEmpty: [ 42 ] ifNotEmpty: [ 999 ]) equals: 999.
+	self assert: (self collection ifEmpty: [ 42 ] ifNotEmpty: [ :col | col ]) equals: self collection.
+
+	self assert: (self collectionClass new ifNotEmpty: [ 42 ] ifEmpty: [ 999 ]) equals: 999.
+	self assert: (self collection ifNotEmpty: [ 42 ] ifEmpty: [ 999 ]) equals: 42.
+	self assert: (self collection ifNotEmpty: [ :col | col ] ifEmpty: [ 999 ]) equals: self collection.
+!
+
+testIsEmpty
+	self assert: self collectionClass new isEmpty.
+	self deny: self collection isEmpty
+!
+
+testNoneSatisfy
+	| anyOne |
+	anyOne := self collection anyOne.
+	self deny: (self collection noneSatisfy: [ :each | each = anyOne ]).
+	self assert: (self collection noneSatisfy: [ :each | each = Object new ])
+!
+
+testRemoveAll
+	self assert: (self collection removeAll; yourself) equals: self collectionClass new
+!
+
+testSelect
+	self assert: (self collection select: [ false ]) equals: self collectionClass new.
+	self assert: (self collection select: [ true ]) equals: self collection.
+	self assert: (self collectionWithNewValue select: [ :each | each = self sampleNewValue ]) equals: self sampleNewValueAsCollection.
+	self assert: (self collectionWithNewValue select: [ :each | each ~= self sampleNewValue ]) equals: self collection.
+	self assert: (self collection select: [ :each | each = self sampleNewValue ]) equals: self collectionClass new.
+	self assert: (self collectionWithNewValue select: [ :each | each ~= self sampleNewValue ]) equals: self collection
+!
+
+testSize
+	self assert: self collectionClass new size equals: 0.
+	self assert: self sampleNewValueAsCollection size equals: 1.
+	self assert: self collection size equals: self collectionSize
+! !
+
+!CollectionTest class methodsFor: 'fixture'!
+
+collectionClass
+	"Answers class of collection type tested,
+	or nil if test is abstract"
+
+	^ nil
+! !
+
+!CollectionTest class methodsFor: 'testing'!
+
+isAbstract
+	^ self collectionClass isNil
+! !
+
+CollectionTest subclass: #IndexableCollectionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!IndexableCollectionTest methodsFor: 'fixture'!
+
+collectionWithNewValue
+	"Answers a collection which shows how
+	self collection would look after adding
+	self sampleNewValue at self sampleNewIndex"
+	
+	self subclassResponsibility
+!
+
+sampleNewIndex
+	"Answers a value that can be used as index in at:put: or at:ifAbsentPut:"
+	
+	self subclassResponsibility
+!
+
+sampleNonIndexesDo: aBlock
+	"Executes block a few times,
+	each time passing value that is known
+	not to be an index, as the first parameter"
+	
+	self subclassResponsibility
+!
+
+samplesDo: aBlock
+	"Executes block a few times,
+	each time passing known index and value stored
+	under that index as the parameters"
+	
+	self subclassResponsibility
+! !
+
+!IndexableCollectionTest methodsFor: 'tests'!
+
+testAt
+	self nonIndexesDo: [ :each |
+		self should: [ self collection at: each ] raise: Error ].
+	self samplesDo: [ :index :value |
+		self assert: (self collection at: index) equals: value ]
+!
+
+testAtIfAbsent
+	self nonIndexesDo: [ :each |
+		self assert: (self collection at: each ifAbsent: [ self sampleNewValue ]) equals: self sampleNewValue ].
+	self samplesDo: [ :index :value |
+		self assert: (self collection at: index ifAbsent: [ self sampleNewValue ]) equals: value ].
+!
+
+testAtIfAbsentPut
+	| newCollection |
+	newCollection := self collection.
+	self samplesDo: [ :index :value |
+		self assert: (newCollection at: index ifAbsentPut: [ self sampleNewValue ]) equals: value ].
+	self assert: newCollection equals: self collection.
+	self assert: (newCollection at: self sampleNewIndex ifAbsentPut: [ self sampleNewValue ]) equals: self sampleNewValue.
+	self assert: newCollection equals: self collectionWithNewValue
+!
+
+testAtIfPresent
+	| visited sentinel |
+	sentinel := Object new.
+	self nonIndexesDo: [ :each |
+		visited := nil.
+		self assert: (self collection at: each ifPresent: [ :value1 | visited := value1. sentinel ]) equals: nil.
+		self assert: visited isNil ].
+	self samplesDo: [ :index :value |
+		visited := nil.
+		self assert: (self collection at: index ifPresent: [ :value2 | visited := value2. sentinel ]) equals: sentinel.
+		self assert: visited equals: (self collection at: index) ]
+!
+
+testAtIfPresentIfAbsent
+	| visited sentinel |
+	sentinel := Object new.
+	self nonIndexesDo: [ :each |
+		visited := nil.
+		self assert: (self collection at: each ifPresent: [ :value1 | visited := value1. sentinel ] ifAbsent: [ self sampleNewValue ] ) equals: self sampleNewValue.
+		self assert: visited isNil ].
+	self samplesDo: [ :index :value |
+		visited := nil.
+		self assert: (self collection at: index ifPresent: [ :value2 | visited := value2. sentinel ] ifAbsent: [ self sampleNewValue ]) equals: sentinel.
+		self assert: visited equals: (self collection at: index) ]
+!
+
+testAtPut
+	| newCollection |
+	newCollection := self collection.
+	self samplesDo: [ :index :value |
+		newCollection at: index put: value ].
+	self assert: newCollection equals: self collection.
+	newCollection at: self sampleNewIndex put: self sampleNewValue.
+	self assert: newCollection equals: self collectionWithNewValue
+!
+
+testEquality
+	self assert: self collectionClass new equals: self collectionClass new.
+	self assert: self collection equals: self collection.
+	self assert: self collectionWithNewValue equals: self collectionWithNewValue.
+	
+	self deny: self collectionClass new = self collection.
+	self deny: self collection = self collectionClass new
+!
+
+testIndexOf
+	self should: [ self collection indexOf: self sampleNewValue ] raise: Error.
+	self samplesDo: [ :index :value |
+		self assert: (self collection indexOf: value) equals: index ]
+!
+
+testIndexOfWithNull
+	| jsNull |
+	jsNull := JSON parse: 'null'.
+	self samplesDo: [ :index :value |
+		self assert: (self collection at: index put: jsNull; indexOf: jsNull) equals: index ]
+!
+
+testWithIndexDo
+	| collection |
+	collection := self collection.
+	
+	self collection withIndexDo: [ :each :index |
+		self assert: (collection at: index) equals: each ]
+! !
+
+IndexableCollectionTest subclass: #AssociativeCollectionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!AssociativeCollectionTest methodsFor: 'fixture'!
+
+collectionKeys
+	self subclassResponsibility
+!
+
+collectionValues
+	self subclassResponsibility
+!
+
+nonIndexesDo: aBlock
+	aBlock value: 5.
+	aBlock value: 'z'
+!
+
+sampleNewIndex
+	^ 'new'
+!
+
+samplesDo: aBlock
+	aBlock value: 'a' value: 2
+! !
+
+!AssociativeCollectionTest methodsFor: 'tests'!
+
+testAddAll
+	super testAddAll.
+	self assert: (self collection addAll: self collection; yourself) equals: self collection.
+	self assert: (self collection addAll: self collectionWithNewValue; yourself) equals: self collectionWithNewValue.
+	self assert: (self collectionWithNewValue addAll: self collection; yourself) equals: self collectionWithNewValue
+!
+
+testAsDictionary
+self assert: ( self collectionClass new asDictionary isMemberOf: Dictionary ).
+!
+
+testAsHashedCollection
+self assert: ( self collectionClass new asHashedCollection isMemberOf: HashedCollection ).
+!
+
+testComma
+	super testComma.
+	self assert: self collection, self collection equals: self collection.
+	self assert: self collection, self collectionWithNewValue equals: self collectionWithNewValue.
+	self assert: self collectionWithNewValue, self collection equals: self collectionWithNewValue
+!
+
+testFrom
+"Accept a collection of associations."
+| associations |
+associations := { 'a' -> 1. 'b' -> 2 }.
+self assertSameContents: ( self class collectionClass from: associations ) as: #{ 'a' -> 1. 'b' -> 2 }.
+!
+
+testKeys
+	self assert:self collectionClass new keys isEmpty.
+	self assertSameContents:self collection keys as: self collectionKeys.
+	self assertSameContents:self collectionWithNewValue keys as: self collectionKeys, { self sampleNewIndex }
+!
+
+testNewFromPairs
+"Accept an array in which all odd indexes are keys and evens are values."
+| flattenedAssociations |
+flattenedAssociations := { 'a'. 1. 'b'. 2 }.
+self assertSameContents: ( self class collectionClass newFromPairs: flattenedAssociations ) as: #{ 'a' -> 1. 'b' -> 2 }.
+!
+
+testPrintString
+	self
+		assert: (self collectionClass new
+							at:'firstname' put: 'James';
+							at:'lastname' put: 'Bond';
+							printString)
+		equals: 'a ', self collectionClass name, ' (''firstname'' -> ''James'' , ''lastname'' -> ''Bond'')'
+!
+
+testRemoveKey
+	self nonIndexesDo: [ :each |
+		| collection |
+		collection := self collection.
+		self should: [ collection removeKey: each ] raise: Error.
+		self assert: collection equals: self collection ].
+	self samplesDo: [ :index :value |
+		| collection |
+		collection := self collection.
+		self assert: (collection removeKey: index) equals: value.
+		self deny: collection = self collection ].
+	self
+		assert: (self collectionWithNewValue removeKey: self sampleNewIndex; yourself)
+		equals: self collection
+!
+
+testRemoveKeyIfAbsent
+	self nonIndexesDo: [ :each |
+		| collection |
+		collection := self collection.
+		self assert: (collection removeKey: each ifAbsent: [ self sampleNewValue ]) equals: self sampleNewValue.
+		self assert: collection equals: self collection ].
+	self samplesDo: [ :index :value |
+		| collection |
+		collection := self collection.
+		self assert: (collection removeKey: index ifAbsent: [ self sampleNewValue ]) equals: value.
+		self deny: collection = self collection ].
+	self
+		assert: (self collectionWithNewValue removeKey: self sampleNewIndex ifAbsent: [ self assert: false ]; yourself)
+		equals: self collection
+!
+
+testValues
+	self assert:self collectionClass new values isEmpty.
+	self assertSameContents:self collection values as: self collectionValues.
+	self assertSameContents:self collectionWithNewValue values as: self collectionValues, { self sampleNewValue }
+! !
+
+AssociativeCollectionTest subclass: #DictionaryTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!DictionaryTest methodsFor: 'fixture'!
+
+collection
+	^ Dictionary new
+		at: 1 put: 1;
+		at: 'a' put: 2;
+		at: true put: 3;
+		at: 1@3 put: -4;
+		yourself
+!
+
+collectionKeys
+	^ {1. 'a'. true. 1@3}
+!
+
+collectionOfPrintStrings
+	^ Dictionary new
+		at: 1 put: '1';
+		at: 'a' put: '2';
+		at: true put: '3';
+		at: 1@3 put: '-4';
+		yourself
+!
+
+collectionSize
+	^ 4
+!
+
+collectionValues
+	^ {1. 2. 3. -4}
+!
+
+collectionWithDuplicates
+	^ Dictionary new
+		at: 1 put: 1;
+		at: 'a' put: 2;
+		at: true put: 3;
+		at: 4 put: -4;
+		at: 'b' put: 1;
+		at: 3 put: 3;
+		at: false put: 12;
+		yourself
+!
+
+collectionWithNewValue
+	^ Dictionary new
+		at: 1 put: 1;
+		at: 'a' put: 2;
+		at: true put: 3;
+		at: 1@3 put: -4;
+		at: 'new' put: 'N';
+		yourself
+!
+
+sampleNewValueAsCollection
+	^ Dictionary new
+		at: 'new' put: 'N';
+		yourself
+!
+
+samplesDo: aBlock
+	super samplesDo: aBlock.
+	aBlock value: true value: 3.
+	aBlock value: 1@3 value: -4
+! !
+
+!DictionaryTest methodsFor: 'tests'!
+
+testAccessing
+	| d |
+
+	d := Dictionary new.
+
+	d at: 'hello' put: 'world'.
+	self assert: (d at: 'hello') equals: 'world'.
+	self assert: (d at: 'hello' ifAbsent: [ nil ]) equals: 'world'.
+	self deny: (d at: 'foo' ifAbsent: [ nil ]) = 'world'.
+
+	self assert: (d includesKey: 'hello').
+	self deny: (d includesKey: 'foo').
+
+	d at: 1 put: 2.
+	self assert: (d at: 1) equals: 2.
+
+	d at: 1@3 put: 3.
+	self assert: (d at: 1@3) equals: 3.
+
+	self assert: (d includesKey: 1@3).
+	self deny: (d includesKey: 3@1)
+!
+
+testDynamicDictionaries
+	self assert: #{'hello' -> 1} asDictionary equals: (Dictionary with: 'hello' -> 1)
+! !
+
+!DictionaryTest class methodsFor: 'fixture'!
+
+collectionClass
+	^ Dictionary
+! !
+
+AssociativeCollectionTest subclass: #HashedCollectionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!HashedCollectionTest methodsFor: 'fixture'!
+
+collection
+	^ #{ 'b' -> 1. 'a' -> 2. 'c' -> 3. 'd' -> -4 }
+!
+
+collectionKeys
+	^ { 'b'. 'a'. 'c'. 'd' }
+!
+
+collectionOfPrintStrings
+	^ #{ 'b' -> '1'. 'a' -> '2'. 'c' -> '3'. 'd' -> '-4' }
+!
+
+collectionSize
+	^ 4
+!
+
+collectionValues
+	^ { 1. 2. 3. -4 }
+!
+
+collectionWithDuplicates
+	^ #{ 'b' -> 1. 'a' -> 2. 'c' -> 3. 'd' -> -4. 'e' -> 1. 'f' -> 2. 'g' -> 10 }
+!
+
+collectionWithNewValue
+	^ #{ 'b' -> 1. 'a' -> 2. 'c' -> 3. 'd' -> -4. 'new' -> 'N' }
+!
+
+sampleNewValueAsCollection
+	^ #{ 'new' -> 'N' }
+! !
+
+!HashedCollectionTest methodsFor: 'tests'!
+
+testDynamicDictionaries
+	self assert: #{'hello' -> 1} asHashedCollection equals: (HashedCollection with: 'hello' -> 1)
+! !
+
+!HashedCollectionTest class methodsFor: 'fixture'!
+
+collectionClass
+	^ HashedCollection
+! !
+
+IndexableCollectionTest subclass: #SequenceableCollectionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!SequenceableCollectionTest methodsFor: 'fixture'!
+
+collectionFirst
+	self subclassResponsibility
+!
+
+collectionFirstTwo
+	self subclassResponsibility
+!
+
+collectionLast
+	self subclassResponsibility
+!
+
+collectionLastTwo
+	self subclassResponsibility
+!
+
+nonIndexesDo: aBlock
+	aBlock value: 0.
+	aBlock value: self collectionSize + 1.
+	aBlock value: 'z'
+!
+
+samplesDo: aBlock
+	aBlock value: 1 value: self collectionFirst.
+	aBlock value: self collectionSize value: self collectionLast
+! !
+
+!SequenceableCollectionTest methodsFor: 'tests'!
+
+testBeginsWith
+	self assert: (self collection beginsWith: self collectionClass new).
+	self assert: (self collection beginsWith: self collection).
+	self assert: (self collection beginsWith: self collectionFirstTwo).
+	self deny: (self collection beginsWith: self collectionLastTwo)
+!
+
+testEndsWith
+	self assert: (self collection endsWith: self collectionClass new).
+	self assert: (self collection endsWith: self collection).
+	self assert: (self collection endsWith: self collectionLastTwo).
+	self deny: (self collection endsWith: self collectionFirstTwo)
+!
+
+testFirst
+	self assert: self collection first equals: self collectionFirst
+!
+
+testFirstN
+	self 
+		assert: (self collection first: 2)
+		equals: self collectionFirstTwo.
+		
+	self
+		assert: (self collection first: 0)
+		equals: self collectionClass new.
+		
+	self
+		assert: (self collection first: self collectionSize)
+		equals: self collection.
+		
+	self should: [ self collection first: 33 ] raise: Error
+!
+
+testFourth
+	self assert: (self collection fourth) equals: (self collection at: 4)
+!
+
+testIndexOfStartingAt
+	| jsNull |
+	jsNull := JSON parse: 'null'.
+	self samplesDo: [ :index :value |
+		self assert: (self collection indexOf: value startingAt: 1) equals: index.
+		self assert: (self collection indexOf: value startingAt: index) equals: index.
+		self assert: (self collection indexOf: value startingAt: index+1) equals: 0 ]
+!
+
+testIndexOfStartingAtWithNull
+	| jsNull |
+	jsNull := JSON parse: 'null'.
+	self samplesDo: [ :index :value | | collection |
+		collection := self collection.
+		collection at: index put: jsNull.
+		self assert: (collection indexOf: jsNull startingAt: 1) equals: index.
+		self assert: (collection indexOf: jsNull startingAt: index) equals: index.
+		self assert: (collection indexOf: jsNull startingAt: index+1) equals: 0 ]
+!
+
+testLast
+	self assert: self collection last equals: self collectionLast
+!
+
+testLastN
+	self 
+		assert: (self collection last: 2) 
+		equals: self collectionLastTwo.
+		
+	self
+		assert: (self collection last: 0)
+		equals: self collectionClass new.
+
+	self
+		assert: (self collection last: self collectionSize)
+		equals: self collection.
+
+	self should: [ self collection last: 33 ] raise: Error
+!
+
+testSecond
+	self assert: (self collection second) equals: (self collection at: 2)
+!
+
+testThird
+	self assert: (self collection third) equals: (self collection at: 3)
+! !
+
+SequenceableCollectionTest subclass: #ArrayTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!ArrayTest methodsFor: 'fixture'!
+
+collection
+	^ #(1 2 3 -4)
+!
+
+collectionFirst
+	^ 1
+!
+
+collectionFirstTwo
+	^ #(1 2)
+!
+
+collectionLast
+	^ -4
+!
+
+collectionLastTwo
+	^ #(3 -4)
+!
+
+collectionOfPrintStrings
+	^ #('1' '2' '3' '-4')
+!
+
+collectionSize
+	^ 4
+!
+
+collectionWithDuplicates
+	^ #('a' 'b' 'c' 1 2 1 'a')
+!
+
+collectionWithNewValue
+	^ #(1 2 3 -4 'N')
+!
+
+sampleNewIndex
+	^ 5
+!
+
+samplesDo: aBlock
+	super samplesDo: aBlock.
+	aBlock value: 3 value: 3.
+! !
+
+!ArrayTest methodsFor: 'tests'!
+
+testAdd 
+	| array | 
+	array := self collection. 
+	array add: 6.
+	
+	self assert: array last equals: 6
+!
+
+testAddFirst
+	self assert: (self collection addFirst: 0; yourself) first equals: 0
+!
+
+testPrintString
+	| array |
+	array := Array new.
+	self assert: array printString equals: 'an Array ()'.
+	array add: 1; add: 3.
+	self assert: array printString equals: 'an Array (1 3)'.
+	array add: 'foo'.
+	self assert: array printString equals: 'an Array (1 3 ''foo'')'.
+	array remove: 1; remove: 3.
+	self assert: array printString equals: 'an Array (''foo'')'.
+	array addLast: 3.
+	self assert: array printString equals: 'an Array (''foo'' 3)'.
+	array addLast: 3.
+	self assert: array printString equals: 'an Array (''foo'' 3 3)'.
+!
+
+testRemove 
+	| array |
+	array := #(1 2 3 4 5). 
+	array remove: 3.
+
+	self assert: array equals: #(1 2 4 5).
+	self should: [ array remove: 3 ] raise: Error
+!
+
+testRemoveFromTo
+	
+	self assert: (#(1 2 3 4) removeFrom: 1 to: 3) equals: #(4).
+	self assert: (#(1 2 3 4) removeFrom: 2 to: 3) equals: #(1 4).
+	self assert: (#(1 2 3 4) removeFrom: 2 to: 4) equals: #(1)
+!
+
+testRemoveIndex
+	
+	self assert: (#(1 2 3 4) removeIndex: 2) equals: #(1 3 4).
+	self assert: (#(1 2 3 4) removeIndex: 1) equals: #(2 3 4).
+	self assert: (#('hello') removeIndex: 1) equals: #()
+!
+
+testRemoveLast 
+	| array |
+	array := #(1 2). 
+	array removeLast.
+	
+	self assert: array last equals: 1
+!
+
+testReversed
+	|array|
+	array := #(5 4 3 2 1). 
+	self assert: (array reversed) equals: #(1 2 3 4 5)
+!
+
+testSort
+	| array |
+	array := #(10 1 5). 
+	array sort.
+	self assert: array equals: #(1 5 10)
+! !
+
+!ArrayTest class methodsFor: 'fixture'!
+
+collectionClass
+	^ Array
+! !
+
+SequenceableCollectionTest subclass: #StringTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!StringTest methodsFor: 'fixture'!
+
+collection
+	^ 'helLo'
+!
+
+collectionFirst
+	^ 'h'
+!
+
+collectionFirstTwo
+	^ 'he'
+!
+
+collectionLast
+	^ 'o'
+!
+
+collectionLastTwo
+	^ 'Lo'
+!
+
+collectionOfPrintStrings
+	^ '''h''''e''''l''''L''''o'''
+!
+
+collectionSize
+	^ 5
+!
+
+collectionWithDuplicates
+	^ 'abbaerte'
+!
+
+collectionWithNewValue
+	^ 'helLoN'
+!
+
+sampleNewValueAsCollection
+	^ 'N'
+!
+
+samplesDo: aBlock
+	super samplesDo: aBlock.
+	aBlock value: 3 value: 'l'
+! !
+
+!StringTest methodsFor: 'tests'!
+
+testAddAll
+	"String instances are read-only"
+	self should: [ self collection addAll: self collection ] raise: Error
+!
+
+testAddRemove
+	self should: [ 'hello' add: 'a' ] raise: Error.
+	self should: [ 'hello' remove: 'h' ] raise: Error
+!
+
+testAsArray
+	self assert: 'hello' asArray equals: #('h' 'e' 'l' 'l' 'o').
+!
+
+testAsLowerCase
+	self assert: 'JACKIE' asLowercase equals: 'jackie'.
+!
+
+testAsNumber
+	self assert: '3' asNumber equals: 3.
+	self assert: '-3' asNumber equals: -3.
+	self assert: '-1.5' asNumber equals: -1.5.
+!
+
+testAsUpperCase
+	self assert: 'jackie' asUppercase equals: 'JACKIE'.
+!
+
+testAsciiValue
+    | characterA characterU |
+    characterA := 'A'.
+    characterU := 'U'.
+    self assert: (characterA asciiValue) equals:65.
+    self assert: (characterU asciiValue) equals:85
+!
+
+testAtIfAbsentPut
+	"String instances are read-only"
+	self should: [ 'hello' at: 6 ifAbsentPut: [ 'a' ] ] raise: Error
+!
+
+testAtPut
+	"String instances are read-only"
+	self should: [ 'hello' at: 1 put: 'a' ] raise: Error
+!
+
+testCapitalized
+	self assert: 'test' capitalized equals: 'Test'.
+	self assert: 'Test' capitalized equals: 'Test'.
+	self assert: '' capitalized equals: ''.
+	self assert: 'Test' isCapitalized equals: true.
+	self assert: 'test' isCapitalized equals: false.
+!
+
+testCharCodeAt
+	self assert: ('jackie' charCodeAt:1) equals: 106.
+	self assert: ('jackie' charCodeAt:2) equals: 97.
+	self assert: ('jackie' charCodeAt:3) equals: 99.
+	self assert: ('jackie' charCodeAt:4) equals: 107.
+	self assert: ('jackie' charCodeAt:5) equals: 105.
+	self assert: ('jackie' charCodeAt:6) equals: 101
+!
+
+testCopyFromTo
+	self assert: ('jackie' copyFrom: 1 to: 3) equals: 'jac'.
+	self assert: ('jackie' copyFrom: 4 to: 6) equals: 'kie'.
+!
+
+testCopyWithoutAll
+	self
+		assert: ('*hello* *world*' copyWithoutAll: '*')
+		equals: 'hello world'
+!
+
+testEquality
+	self assert: 'hello' equals: 'hello'.
+	self deny: 'hello' = 'world'.
+	
+	"Test for issue 459"
+	self deny: 'hello' = (#() at: 1 ifAbsent: [ ]).
+
+	self assert: 'hello' equals: 'hello' yourself.
+	self assert: 'hello' yourself equals: 'hello'.
+
+	"test JS falsy value"
+	self deny: '' = 0
+!
+
+testIdentity
+	self assert: 'hello' == 'hello'.
+	self deny: 'hello' == 'world'.
+
+	self assert: 'hello' == 'hello' yourself.
+	self assert: 'hello' yourself == 'hello'.
+
+	"test JS falsy value"
+	self deny: '' == 0
+!
+
+testIdentityHash
+	self assert: 'foo' identityHash equals: 'foo' identityHash.
+	self deny: ('foo' identityHash = 'bar' identityHash)
+!
+
+testIncludesSubString
+	self assert: ('amber' includesSubString: 'ber').
+	self deny: ('amber' includesSubString: 'zork').
+!
+
+testIndexOfStartingAtWithNull
+	"String cannot hold JS null"
+!
+
+testIndexOfWithNull
+	"String cannot hold JS null"
+!
+
+testIsVowel
+    |vowel consonant|
+    vowel := 'u'.
+    consonant := 'z'.
+    self assert: vowel isVowel equals: true.
+    self assert: consonant isVowel equals: false
+!
+
+testJoin
+	self assert: (',' join: #('hello' 'world')) equals: 'hello,world'
+!
+
+testRemoveAll
+	self should: [ self collection removeAll ] raise: Error
+!
+
+testReversed
+	self assert: 'jackiechan' reversed equals: 'nahceikcaj'.
+!
+
+testStreamContents
+	self
+		assert: (String streamContents: [ :aStream |
+			aStream
+				nextPutAll: 'hello'; space;
+				nextPutAll: 'world' ])
+		equals: 'hello world'
+!
+
+testSubStrings
+	self assert: ('jackiechan' subStrings: 'ie') equals: #( 'jack' 'chan' ).
+!
+
+testTrim
+	self assert: '       jackie' trimLeft equals: 'jackie'.
+	self assert: 'jackie               ' trimRight equals: 'jackie'.
+!
+
+testValue
+
+	self assert: (#asString value: 1) equals: '1'.
+
+	"Which (since String and BlockClosure are now polymorphic) enables the nice idiom..."
+	self assert: (#(1 2 3) collect: #asString) equals: #('1' '2' '3')
+! !
+
+!StringTest class methodsFor: 'fixture'!
+
+collectionClass
+	^ String
+! !
+
+CollectionTest subclass: #SetTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!SetTest methodsFor: 'fixture'!
+
+collection
+	^ Set new
+		add: Smalltalk;
+		add: nil;
+		add: 3@3;
+		add: false;
+		yourself
+!
+
+collectionOfPrintStrings
+	^ Set new
+		add: 'a SmalltalkImage';
+		add: 'nil';
+		add: '3@3';
+		add: 'false';
+		yourself
+!
+
+collectionSize
+	^ 4
+!
+
+collectionWithDuplicates
+	"Set has no duplicates"
+	^ self collection add: 0; yourself
+!
+
+collectionWithNewValue
+	^ Set new
+		add: Smalltalk;
+		add: nil;
+		add: 3@3;
+		add: 'N';
+		add: false;
+		yourself
+! !
+
+!SetTest methodsFor: 'tests'!
+
+testAddAll
+	super testAddAll.
+	self assert: (self collection addAll: self collection; yourself) equals: self collection.
+	self assert: (self collection addAll: self collectionWithNewValue; yourself) equals: self collectionWithNewValue.
+	self assert: (self collectionWithNewValue addAll: self collection; yourself) equals: self collectionWithNewValue
+!
+
+testAddRemove
+	| set |
+	set := Set new.
+	
+	self assert: set isEmpty.
+
+	set add: 3.
+	self assert: (set includes: 3).
+
+	set add: 5.
+	self assert: (set includes: 5).
+
+	set remove: 3.
+	self deny: (set includes: 3)
+!
+
+testAt
+	self should: [ Set new at: 1 put: 2 ] raise: Error
+!
+
+testCollect
+	super testCollect.
+	self assert: (#(5 6 8) asSet collect: [ :x | x \\ 3 ]) equals: #(0 2) asSet
+!
+
+testComma
+	super testComma.
+	self assert: self collection, self collection equals: self collection.
+	self assert: self collection, self collectionWithNewValue equals: self collectionWithNewValue.
+	self assert: self collectionWithNewValue, self collection equals: self collectionWithNewValue
+!
+
+testComparing
+	self assert: #(0 2) asSet equals: #(0 2) asSet.
+	self assert: #(2 0) asSet equals: #(0 2) asSet.
+	self deny: #(0 2 3) asSet = #(0 2) asSet.
+	self deny: #(1 2) asSet = #(0 2) asSet
+!
+
+testPrintString
+	| set |
+	set := Set new.
+	self assert: set printString equals: 'a Set ()'.
+	set add: 1; add: 3.
+	self assert: set printString equals: 'a Set (1 3)'.
+	set add: 'foo'.
+	self assert: set printString equals: 'a Set (1 3 ''foo'')'.
+	set remove: 1; remove: 3.
+	self assert: set printString equals: 'a Set (''foo'')'.
+	set add: 3.
+	self assert: set printString equals: 'a Set (3 ''foo'')'.
+	set add: 3.
+	self assert: set printString equals: 'a Set (3 ''foo'')'
+!
+
+testUnboxedObjects
+	self assert: {'foo' yourself. 'foo' yourself} asSet asArray equals: #('foo')
+!
+
+testUnicity
+	| set |
+	set := Set new.
+	set add: 21.
+	set add: 'hello'.
+
+	set add: 21.
+	self assert: set size equals: 2.
+	
+	set add: 'hello'.
+	self assert: set size equals: 2.
+
+	self assert: set asArray equals: #(21 'hello')
+! !
+
+!SetTest class methodsFor: 'fixture'!
+
+collectionClass
+	^ Set
+! !
+
+TestCase subclass: #ConsoleTranscriptTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!ConsoleTranscriptTest methodsFor: 'tests'!
+
+testShow
+| originalTranscript |
+originalTranscript := Transcript current.
+Transcript register: ConsoleTranscript new.
+
+self shouldnt: [ Transcript show: 'Hello console!!' ] raise: Error.
+self shouldnt: [ Transcript show: console ] raise: Error.
+
+Transcript register: originalTranscript.
+! !
+
+TestCase subclass: #JSObjectProxyTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!JSObjectProxyTest methodsFor: 'accessing'!
+
+jsNull
+	<return null>
+!
+
+jsObject
+	<return {a: 1, b: function() {return 2;}, c: function(object) {return object;}, d: '', 'e': null, 'f': void 0}>
+!
+
+jsUndefined
+	<return>
+! !
+
+!JSObjectProxyTest methodsFor: 'tests'!
+
+testAtIfAbsent
+	| testObject |
+	testObject := self jsObject.
+	self assert: (testObject at: 'abc' ifAbsent: [ 'Property does not exist' ]) equals: 'Property does not exist'.
+	self assert: (testObject at: 'e' ifAbsent: [ 'Property does not exist' ]) equals: nil.
+	self assert: (testObject at: 'a' ifAbsent: [ 'Property does not exist' ]) equals: 1.
+	self assert: (testObject at: 'f' ifAbsent: [ 'Property does not exist' ]) equals: nil.
+!
+
+testAtIfPresent
+	| testObject |
+	
+	testObject := self jsObject.
+	
+	self assert: (testObject at: 'abc' ifPresent: [ :x | 'hello ',x asString ]) equals: nil.
+	self assert: (testObject at: 'e' ifPresent: [ :x | 'hello ',x asString ]) equals: 'hello nil'.
+	self assert: (testObject at: 'a' ifPresent: [ :x | 'hello ',x asString ]) equals: 'hello 1'.
+	self assert: (testObject at: 'f' ifPresent: [ :x | 'hello ',x asString ]) equals: 'hello nil'.
+!
+
+testAtIfPresentIfAbsent
+	| testObject |
+	testObject := self jsObject.
+	self assert: (testObject at: 'abc' ifPresent: [ :x|'hello ',x asString ] ifAbsent: [ 'not present' ]) equals: 'not present'.
+	self assert: (testObject at: 'e' ifPresent: [ :x|'hello ',x asString ] ifAbsent: [ 'not present' ]) equals: 'hello nil'.
+	self assert: (testObject at: 'a' ifPresent: [ :x|'hello ',x asString ] ifAbsent: [ 'not present' ]) equals: 'hello 1'.
+	self assert: (testObject at: 'f' ifPresent: [ :x|'hello ',x asString ] ifAbsent: [ 'not present' ]) equals: 'hello nil'.
+!
+
+testAtPut
+	| testObject |
+	testObject := self jsObject.
+	
+	self assert: (testObject at: 'abc') ~= 'xyz'.
+	self assert: (testObject at: 'abc' put: 'xyz') equals: 'xyz'.
+	self assert: (testObject at: 'abc') equals: 'xyz'
+!
+
+testComparison
+	self assert: ({ console. 2 } indexOf: console) equals: 1.
+	self assert: console = console.
+	self deny: console = Object new.
+	self deny: console = self jsObject
+!
+
+testDNU
+	self should: [ self jsObject foo ] raise: MessageNotUnderstood
+!
+
+testDNURegression1057
+	| jsObject |
+	jsObject := #().
+	jsObject basicAt: 'allowJavaScriptCalls' put: true.
+	jsObject basicAt: 'foo' put: 3.
+	self shouldnt: [ jsObject foo ] raise: Error.
+	self assert: jsObject foo equals: 3.
+	self shouldnt: [ jsObject foo: 4 ] raise: Error.
+	self assert: jsObject foo equals: 4
+!
+
+testDNURegression1059
+	| jsObject |
+	jsObject := #().
+	jsObject basicAt: 'allowJavaScriptCalls' put: true.
+	jsObject basicAt: 'x' put: 3.
+	jsObject basicAt: 'x:' put: [ self error ].
+	self shouldnt: [ jsObject x: 4 ] raise: Error.
+	self assert: jsObject x equals: 4
+!
+
+testDNURegression1062
+	| jsObject stored |
+	jsObject := #().
+	jsObject basicAt: 'allowJavaScriptCalls' put: true.
+	jsObject basicAt: 'x' put: [ :v | stored := v ].
+	self shouldnt: [ jsObject x: 4 ] raise: Error.
+	self assert: stored equals: 4
+!
+
+testDNUWithAllowJavaScriptCalls
+	| jsObject |
+	jsObject := #().
+	jsObject basicAt: 'allowJavaScriptCalls' put: true.
+	self should: [ jsObject foo ] raise: MessageNotUnderstood
+!
+
+testMessageSend
+
+	self assert: self jsObject a equals: 1.
+	self assert: self jsObject b equals: 2.
+	self assert: (self jsObject c: 3) equals: 3
+!
+
+testMethodWithArguments
+	self assert: (self jsObject c: 1) equals: 1
+!
+
+testPrinting
+	self assert: self jsObject printString equals: '[object Object]'
+!
+
+testPropertyThatReturnsEmptyString
+	| object |
+
+	object := self jsObject.
+	self assert: object d equals: ''.
+
+	object d: 'hello'.
+	self assert: object d equals: 'hello'
+!
+
+testPropertyThatReturnsUndefined
+	| object |
+
+	object := self jsObject.
+	self shouldnt: [ object e ] raise: MessageNotUnderstood.
+	self assert: object e isNil
+!
+
+testSetPropertyWithFalsyValue
+	| jsObject |
+	jsObject := self jsObject.
+	self assert: (jsObject a) equals: 1.
+
+	jsObject a: self jsNull.
+	self assert: (jsObject a) equals: nil.
+	jsObject a: 0.
+	self assert: (jsObject a) equals: 0.
+	jsObject a: self jsUndefined.
+	self assert: (jsObject a) equals: nil.
+	jsObject a: ''.
+	self assert: (jsObject a) equals: ''.
+	jsObject a: false.
+	self assert: (jsObject a) equals: false
+!
+
+testValue
+	| testObject |
+	testObject := self jsObject.
+	testObject at: 'value' put: 'aValue'.
+	self assert: testObject value equals: 'aValue'
+!
+
+testYourself
+	| object |
+	object := self jsObject
+		d: 'test';
+		yourself.
+
+	self assert: object d equals: 'test'
+! !
+
+TestCase subclass: #JavaScriptExceptionTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!JavaScriptExceptionTest methodsFor: 'helpers'!
+
+throwException
+	<throw 'test'>
+! !
+
+!JavaScriptExceptionTest methodsFor: 'tests'!
+
+testCatchingException
+	[ self throwException ]
+		on: Error
+		do: [ :error |
+			self assert: error exception = 'test' ]
+!
+
+testRaisingException
+	self should: [ self throwException ] raise: JavaScriptException
+! !
+
+TestCase subclass: #MessageSendTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!MessageSendTest methodsFor: 'tests'!
+
+testValue
+	| messageSend |
+	
+	messageSend := MessageSend new
+		receiver: Object new;
+		selector: #asString;
+		yourself.
+		
+	self assert: messageSend value equals: 'an Object'
+!
+
+testValueWithArguments
+	| messageSend |
+	
+	messageSend := MessageSend new
+		receiver: 2;
+		selector: '+';
+		yourself.
+		
+	self assert: (messageSend value: 3) equals: 5.
+	
+	self assert: (messageSend valueWithPossibleArguments: #(4)) equals: 6
+! !
+
+TestCase subclass: #MethodInheritanceTest
+	instanceVariableNames: 'receiverTop receiverMiddle receiverBottom method performBlock'
+	package: 'Kernel-Tests'!
+
+!MethodInheritanceTest methodsFor: 'accessing'!
+
+codeGeneratorClass
+	^ CodeGenerator
+!
+
+targetClassBottom
+	^ JavaScriptException
+!
+
+targetClassMiddle
+	^ Error
+!
+
+targetClassTop
+	^ Object
+! !
+
+!MethodInheritanceTest methodsFor: 'factory'!
+
+compiler
+	^ Compiler new
+		codeGeneratorClass: self codeGeneratorClass;
+		yourself
+! !
+
+!MethodInheritanceTest methodsFor: 'initialization'!
+
+setUp
+	receiverTop := self targetClassTop new.
+	receiverMiddle := self targetClassMiddle new.
+	receiverBottom := self targetClassBottom new.
+	method := nil.
+	performBlock := [ self error: 'performBlock not initialized' ]
+!
+
+tearDown
+	[ self deinstallTop ] on: Error do: [ ].
+	[ self deinstallMiddle ] on: Error do: [ ].
+	[ self deinstallBottom ] on: Error do: [ ]
+! !
+
+!MethodInheritanceTest methodsFor: 'testing'!
+
+deinstallBottom
+	self targetClassBottom removeCompiledMethod: method
+!
+
+deinstallMiddle
+	self targetClassMiddle removeCompiledMethod: method
+!
+
+deinstallTop
+	self targetClassTop removeCompiledMethod: method
+!
+
+installBottom: aString
+	method := self compiler install: aString forClass: self targetClassBottom protocol: 'tests'
+!
+
+installMiddle: aString
+	method := self compiler install: aString forClass: self targetClassMiddle protocol: 'tests'
+!
+
+installTop: aString
+	method := self compiler install: aString forClass: self targetClassTop protocol: 'tests'
+!
+
+shouldMNU
+	self shouldMNUTop.
+	self shouldMNUMiddle.
+	self shouldMNUBottom
+!
+
+shouldMNUBottom
+	self should: [ performBlock value: receiverBottom ] raise: MessageNotUnderstood
+!
+
+shouldMNUMiddle
+	self should: [ performBlock value: receiverMiddle ] raise: MessageNotUnderstood
+!
+
+shouldMNUTop
+	self should: [ performBlock value: receiverTop ] raise: MessageNotUnderstood
+!
+
+shouldReturn: anObject
+	| result |
+
+	result := performBlock value: receiverTop.
+	self assert: { 'top'. anObject } equals: { 'top'. result }.
+	result := performBlock value: receiverMiddle.
+	self assert: { 'middle'. anObject } equals: { 'middle'. result }.
+	result := performBlock value: receiverBottom.
+	self assert: { 'bottom'. anObject } equals: { 'bottom'. result }
+!
+
+shouldReturn: anObject and: anObject2 and: anObject3
+	| result |
+
+	result := performBlock value: receiverTop.
+	self assert: { 'top'. anObject } equals: { 'top'. result }.
+	result := performBlock value: receiverMiddle.
+	self assert: { 'middle'. anObject2 } equals: { 'middle'. result }.
+	result := performBlock value: receiverBottom.
+	self assert: { 'bottom'. anObject3 } equals: { 'bottom'. result }
+! !
+
+!MethodInheritanceTest methodsFor: 'tests'!
+
+testMNU11
+	performBlock := [ :x | x foo ].
+	self shouldMNU.
+	self installTop: 'foo ^ false'.
+	self installTop: 'foo ^ true'.
+	self deinstallTop.
+	self shouldMNU
+!
+
+testMNU22
+	performBlock := [ :x | x foo ].
+	self shouldMNU.
+	self installMiddle: 'foo ^ false'.
+	self installMiddle: 'foo ^ true'.
+	self deinstallMiddle.
+	self shouldMNU
+!
+
+testReturns1
+	performBlock := [ :x | x foo ].
+	self installTop: 'foo ^ false'.
+	self shouldReturn: false.
+	self installTop: 'foo ^ true'.
+	self shouldReturn: true
+! !
+
+TestCase subclass: #NumberTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!NumberTest methodsFor: 'tests'!
+
+testAbs
+	self assert: 4 abs equals: 4.
+	self assert: -4 abs equals: 4
+!
+
+testArithmetic
+	
+	"We rely on JS here, so we won't test complex behavior, just check if
+	message sends are corrects"
+
+	self assert: 1.5 + 1 equals: 2.5.
+	self assert: 2 - 1 equals: 1.
+	self assert: -2 - 1 equals: -3.
+	self assert: 12 / 2 equals: 6.
+	self assert: 3 * 4 equals: 12.
+	self assert: 7 // 2 equals: 3.
+	self assert: 7 \\ 2 equals: 1.
+
+	"Simple parenthesis and execution order"
+	self assert: 1 + 2 * 3 equals: 9.
+	self assert: 1 + (2 * 3) equals: 7
+!
+
+testAsNumber
+	self assert: 3 asNumber equals: 3.
+!
+
+testCeiling
+	self assert: 1.2 ceiling equals: 2.
+	self assert: -1.2 ceiling equals: -1.
+	self assert: 1.0 ceiling equals: 1.
+!
+
+testComparison
+
+	self assert: 3 > 2.
+	self assert: 2 < 3.
+	
+	self deny: 3 < 2.
+	self deny: 2 > 3.
+
+	self assert: 3 >= 3.
+	self assert: 3.1 >= 3.
+	self assert: 3 <= 3.
+	self assert: 3 <= 3.1
+!
+
+testCopying
+	self assert: 1 copy == 1.
+	self assert: 1 deepCopy == 1
+!
+
+testEquality
+	self assert: (1 = 1).
+	self assert: (0 = 0).
+	self deny: (1 = 0).
+
+	self assert: (1 yourself = 1).
+	self assert: (1 = 1 yourself).
+	self assert: (1 yourself = 1 yourself).
+	
+	self deny: 0 = false.
+	self deny: false = 0.
+	self deny: '' = 0.
+	self deny: 0 = ''
+!
+
+testFloor
+	self assert: 1.2 floor equals: 1.
+	self assert: -1.2 floor equals: -2.
+	self assert: 1.0 floor equals: 1.
+!
+
+testHexNumbers
+
+	self assert: 16r9 equals: 9.
+	self assert: 16rA truncated equals: 10.
+	self assert: 16rB truncated equals: 11.
+	self assert: 16rC truncated equals: 12.
+	self assert: 16rD truncated equals: 13.
+	self assert: 16rE truncated equals: 14.
+	self assert: 16rF truncated equals: 15
+!
+
+testIdentity
+	self assert: 1 == 1.
+	self assert: 0 == 0.
+	self deny: 1 == 0.
+
+	self assert: 1 yourself == 1.
+	self assert: 1 == 1 yourself.
+	self assert: 1 yourself == 1 yourself.
+	
+	self deny: 1 == 2
+!
+
+testInvalidHexNumbers
+
+	self should: [ 16rG ] raise: MessageNotUnderstood.
+	self should: [ 16rg ] raise: MessageNotUnderstood.
+	self should: [ 16rH ] raise: MessageNotUnderstood.
+	self should: [ 16rh ] raise: MessageNotUnderstood.
+	self should: [ 16rI ] raise: MessageNotUnderstood.
+	self should: [ 16ri ] raise: MessageNotUnderstood.
+	self should: [ 16rJ ] raise: MessageNotUnderstood.
+	self should: [ 16rj ] raise: MessageNotUnderstood.
+	self should: [ 16rK ] raise: MessageNotUnderstood.
+	self should: [ 16rk ] raise: MessageNotUnderstood.
+	self should: [ 16rL ] raise: MessageNotUnderstood.
+	self should: [ 16rl ] raise: MessageNotUnderstood.
+	self should: [ 16rM ] raise: MessageNotUnderstood.
+	self should: [ 16rm ] raise: MessageNotUnderstood.
+	self should: [ 16rN ] raise: MessageNotUnderstood.
+	self should: [ 16rn ] raise: MessageNotUnderstood.
+	self should: [ 16rO ] raise: MessageNotUnderstood.
+	self should: [ 16ro ] raise: MessageNotUnderstood.
+	self should: [ 16rP ] raise: MessageNotUnderstood.
+	self should: [ 16rp ] raise: MessageNotUnderstood.
+	self should: [ 16rQ ] raise: MessageNotUnderstood.
+	self should: [ 16rq ] raise: MessageNotUnderstood.
+	self should: [ 16rR ] raise: MessageNotUnderstood.
+	self should: [ 16rr ] raise: MessageNotUnderstood.
+	self should: [ 16rS ] raise: MessageNotUnderstood.
+	self should: [ 16rs ] raise: MessageNotUnderstood.
+	self should: [ 16rT ] raise: MessageNotUnderstood.
+	self should: [ 16rt ] raise: MessageNotUnderstood.
+	self should: [ 16rU ] raise: MessageNotUnderstood.
+	self should: [ 16ru ] raise: MessageNotUnderstood.
+	self should: [ 16rV ] raise: MessageNotUnderstood.
+	self should: [ 16rv ] raise: MessageNotUnderstood.
+	self should: [ 16rW ] raise: MessageNotUnderstood.
+	self should: [ 16rw ] raise: MessageNotUnderstood.
+	self should: [ 16rX ] raise: MessageNotUnderstood.
+	self should: [ 16rx ] raise: MessageNotUnderstood.
+	self should: [ 16rY ] raise: MessageNotUnderstood.
+	self should: [ 16ry ] raise: MessageNotUnderstood.
+	self should: [ 16rZ ] raise: MessageNotUnderstood.
+	self should: [ 16rz ] raise: MessageNotUnderstood.
+	self should: [ 16rABcdEfZ ] raise: MessageNotUnderstood.
+!
+
+testLog
+	self assert: 10000 log equals: 4.
+	self assert: (512 log: 2) equals: 9.
+	self assert: Number e ln equals: 1.
+!
+
+testMinMax
+	
+	self assert: (2 max: 5) equals: 5.
+	self assert: (2 min: 5) equals: 2
+!
+
+testNegated
+	self assert: 3 negated equals: -3.
+	self assert: -3 negated equals: 3
+!
+
+testPrintShowingDecimalPlaces
+	self assert: (23 printShowingDecimalPlaces: 2) equals: '23.00'.
+	self assert: (23.5698 printShowingDecimalPlaces: 2) equals: '23.57'.
+	self assert: (234.567 negated printShowingDecimalPlaces: 5) equals: '-234.56700'.
+	self assert: (23.4567 printShowingDecimalPlaces: 0) equals: '23'.
+	self assert: (23.5567 printShowingDecimalPlaces: 0) equals: '24'.
+	self assert: (23.4567 negated printShowingDecimalPlaces: 0) equals: '-23'.
+	self assert: (23.5567 negated printShowingDecimalPlaces: 0) equals: '-24'.
+	self assert: (100000000 printShowingDecimalPlaces: 1) equals: '100000000.0'.
+	self assert: (0.98 printShowingDecimalPlaces: 5) equals: '0.98000'.
+	self assert: (0.98 negated printShowingDecimalPlaces: 2) equals: '-0.98'.
+	self assert: (2.567 printShowingDecimalPlaces: 2) equals: '2.57'.
+	self assert: (-2.567 printShowingDecimalPlaces: 2) equals: '-2.57'.
+	self assert: (0 printShowingDecimalPlaces: 2) equals: '0.00'.
+!
+
+testRaisedTo
+	self assert: (2 raisedTo: 4) equals: 16.
+	self assert: (2 raisedTo: 0) equals: 1.
+	self assert: (2 raisedTo: -3) equals: 0.125.
+	self assert: (4 raisedTo: 0.5) equals: 2.
+	
+	self assert: 2 ** 4 equals: 16.
+!
+
+testRounded
+	
+	self assert: 3 rounded equals: 3.
+	self assert: 3.212 rounded equals: 3.
+	self assert: 3.51 rounded equals: 4
+!
+
+testSign
+	self assert: 5 sign equals: 1.
+	self assert: 0 sign equals: 0.
+	self assert: -1.4 sign equals: -1.
+!
+
+testSqrt
+	
+	self assert: 4 sqrt equals: 2.
+	self assert: 16 sqrt equals: 4
+!
+
+testSquared
+	
+	self assert: 4 squared equals: 16
+!
+
+testTimesRepeat
+	| i |
+
+	i := 0.
+	0 timesRepeat: [ i := i + 1 ].
+	self assert: i equals: 0.
+
+	5 timesRepeat: [ i := i + 1 ].
+	self assert: i equals: 5
+!
+
+testTo
+	self assert: (1 to: 5) equals: #(1 2 3 4 5)
+!
+
+testToBy
+	self assert: (0 to: 6 by: 2) equals: #(0 2 4 6).
+
+	self should: [ 1 to: 4 by: 0 ] raise: Error
+!
+
+testTrigonometry
+	self assert: 0 cos equals: 1.
+	self assert: 0 sin equals: 0.
+	self assert: 0 tan equals: 0.
+	self assert: 1 arcCos equals: 0.
+	self assert: 0 arcSin equals: 0.
+	self assert: 0 arcTan equals: 0.
+!
+
+testTruncated
+	
+	self assert: 3 truncated equals: 3.
+	self assert: 3.212 truncated equals: 3.
+	self assert: 3.51 truncated equals: 3
+! !
+
+Object subclass: #ObjectMock
+	instanceVariableNames: 'foo bar'
+	package: 'Kernel-Tests'!
+!ObjectMock commentStamp!
+ObjectMock is there only to perform tests on classes.!
+
+!ObjectMock methodsFor: 'not yet classified'!
+
+foo
+	^ foo
+!
+
+foo: anObject
+	foo := anObject
+! !
+
+TestCase subclass: #ObjectTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!ObjectTest methodsFor: 'tests'!
+
+notDefined
+	<return void 0;>
+!
+
+testBasicAccess
+	| o |
+	o := Object new.
+	o basicAt: 'a' put: 1.
+	self assert: (o basicAt: 'a') equals: 1.
+	self assert: (o basicAt: 'b') equals: nil
+!
+
+testBasicPerform
+	| o |
+	o := Object new.
+	o basicAt: 'func' put: [ 'hello' ].
+	o basicAt: 'func2' put: [ :a | a + 1 ].
+
+	self assert: (o basicPerform: 'func') equals: 'hello'.
+	self assert: (o basicPerform: 'func2' withArguments: #(3)) equals: 4
+!
+
+testDNU
+	self should: [ Object new foo ] raise: MessageNotUnderstood
+!
+
+testEquality
+	| o |
+	o := Object new.
+	self deny: o = Object new.
+	self assert: (o = o).
+	self assert: (o yourself = o).
+	self assert: (o = o yourself)
+!
+
+testHalt
+	self should: [ Object new halt ] raise: Error
+!
+
+testIdentity
+	| o |
+	o := Object new.
+	self deny: o == Object new.
+	self assert: o == o.
+	self assert: o yourself == o.
+	self assert: o == o yourself
+!
+
+testIfNil
+	self deny: Object new isNil.
+	self deny: (Object new ifNil: [ true ]) = true.
+	self assert: (Object new ifNotNil: [ true ]) equals: true.
+
+	self assert: (Object new ifNil: [ false ] ifNotNil: [ true ]) equals: true.
+	self assert: (Object new ifNotNil: [ true ] ifNil: [ false ]) equals: true
+!
+
+testInstVars
+	| o |
+	o := ObjectMock new.
+	self assert: (o instVarAt: #foo) equals: nil.
+
+	o instVarAt: #foo put: 1.
+	self assert: (o instVarAt: #foo) equals: 1.
+	self assert: (o instVarAt: 'foo') equals: 1
+!
+
+testNilUndefined
+	"nil in Smalltalk is the undefined object in JS"
+
+	self assert: self notDefined equals: nil
+!
+
+testYourself
+	| o |
+	o := ObjectMock new.
+	self assert: o yourself == o
+!
+
+testidentityHash
+	| o1 o2 |
+	
+	o1 := Object new.
+	o2 := Object new.
+
+	self assert: o1 identityHash == o1 identityHash.
+	self deny: o1 identityHash == o2 identityHash
+! !
+
+TestCase subclass: #PointTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!PointTest methodsFor: 'tests'!
+
+testAccessing
+	self assert: (Point x: 3 y: 4) x equals: 3.
+	self assert: (Point x: 3 y: 4) y equals: 4.
+	self assert: (Point new x: 3) x equals: 3.
+	self assert: (Point new y: 4) y equals: 4
+!
+
+testArithmetic
+	self assert: 3@4 * (3@4 ) equals: (Point x: 9 y: 16).
+	self assert: 3@4 + (3@4 ) equals: (Point x: 6 y: 8).
+	self assert: 3@4 - (3@4 ) equals: (Point x: 0 y: 0).
+	self assert: 6@8 / (3@4 ) equals: (Point x: 2 y: 2)
+!
+
+testAt
+	self assert: 3@4 equals: (Point x: 3 y: 4)
+!
+
+testComparison
+	self assert: 3@4 < (4@5).
+	self deny: 3@4 < (4@4).
+	
+	self assert: 4@5 <= (4@5).
+	self deny: 4@5 <= (3@5).
+	
+	self assert: 5@6 > (4@5).
+	self deny: 5@6 > (6@6).
+	
+	self assert: 4@5 >= (4@5).
+	self deny: 4@5 >= (5@5)
+!
+
+testEgality
+	self assert: (3@4 = (3@4)).
+	self deny: 3@5 = (3@6)
+!
+
+testNew
+
+	self assert: (Point new x: 3) y equals: nil.
+	self deny: (Point new x: 3) x = 0.
+	self assert: (Point new y: 4) x equals: nil.
+	self deny: (Point new y: 4) y = 0
+!
+
+testTranslateBy
+	self assert: (3@3 translateBy: 0@1) equals: 3@4.
+	self assert: (3@3 translateBy: 0@1 negated) equals: 3@2.
+	self assert: (3@3 translateBy: 2@3) equals: 5@6.
+	self assert: (3@3 translateBy: 3 negated @0) equals: 0@3.
+! !
+
+TestCase subclass: #QueueTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!QueueTest methodsFor: 'tests'!
+
+testNextIfAbsent
+	| queue |
+	queue := Queue new.
+	queue nextPut: 'index1'. 
+
+	self assert: (queue  nextIfAbsent: 'empty') = 'index1'.
+	self deny: (queue  nextIfAbsent: 'empty') = 'index1'
+!
+
+testQueueNext
+	| queue |               
+	queue := Queue new.
+	queue 
+		nextPut: 'index1';
+		nextPut: 'index2'.
+
+	self assert: queue next = 'index1'.
+	self deny: queue next = 'index'.
+	self should: [ queue next ] raise: Error
+! !
+
+TestCase subclass: #RandomTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!RandomTest methodsFor: 'tests'!
+
+testAtRandomNumber
+	|val|	
+
+	100 timesRepeat: [
+		val := 10 atRandom.	
+		self assert: (val > 0).
+		self assert: (val <11)
+	]
+!
+
+testAtRandomSequenceableCollection
+	|val|
+	
+	100 timesRepeat: [
+		val := 'abc' atRandom.
+		self assert: ((val = 'a') | (val = 'b') | (val = 'c' )).
+	].
+!
+
+textNext
+
+	10000 timesRepeat: [
+			| current next |
+			next := Random new next.
+			self assert: (next >= 0).
+			self assert: (next < 1).
+			self deny: current = next.
+			next = current ]
+! !
+
+TestCase subclass: #StreamTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!StreamTest methodsFor: 'accessing'!
+
+collectionClass
+	^ self class collectionClass
+!
+
+newCollection
+	^ self collectionClass new
+!
+
+newStream
+	^ self collectionClass new stream
+! !
+
+!StreamTest methodsFor: 'tests'!
+
+testAtStartAtEnd
+	| stream |
+	
+	stream := self newStream.
+	self assert: stream atStart.
+	self assert: stream atEnd.
+	
+	stream nextPutAll: self newCollection.
+	self assert: stream atEnd.
+	self deny: stream atStart.
+	
+	stream position: 1.
+	self deny: stream atEnd.
+	self deny: stream atStart
+!
+
+testContents
+	| stream |
+	
+	stream := self newStream.
+	stream nextPutAll: self newCollection.
+	
+	self assert: stream contents equals: self newCollection
+!
+
+testIsEmpty
+	| stream |
+	
+	stream := self newStream.
+	self assert: stream isEmpty.
+	
+	stream nextPutAll: self newCollection.
+	self deny: stream isEmpty
+!
+
+testPosition
+	| collection stream |
+	
+	collection := self newCollection.
+	stream := self newStream.
+	
+	stream nextPutAll: collection.
+	self assert: stream position equals: collection size.
+	
+	stream position: 0.
+	self assert: stream position equals: 0.
+	
+	stream next.
+	self assert: stream position equals: 1.
+	
+	stream next.
+	self assert: stream position equals: 2
+!
+
+testReading
+	| stream collection |
+	
+	collection := self newCollection.
+	stream := self newStream.
+	
+	stream 
+		nextPutAll: collection;
+		position: 0.
+	
+	collection do: [ :each |
+		self assert: stream next equals: each ].
+		
+	self assert: stream next isNil
+!
+
+testStreamContents
+!
+
+testWrite
+	| stream collection |
+	
+	collection := self newCollection.
+	stream := self newStream.
+	
+	collection do: [ :each | stream << each ].
+	self assert: stream contents equals: collection
+!
+
+testWriting
+	| stream collection |
+	
+	collection := self newCollection.
+	stream := self newStream.
+	
+	collection do: [ :each | stream nextPut: each ].
+	self assert: stream contents equals: collection.
+	
+	stream := self newStream.
+	stream nextPutAll: collection.
+	self assert: stream contents equals: collection
+! !
+
+!StreamTest class methodsFor: 'accessing'!
+
+collectionClass
+	^ nil
+! !
+
+!StreamTest class methodsFor: 'testing'!
+
+isAbstract
+	^ self collectionClass isNil
+! !
+
+StreamTest subclass: #ArrayStreamTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!ArrayStreamTest methodsFor: 'accessing'!
+
+newCollection
+	^ { true. 1. 3@4. 'foo' }
+! !
+
+!ArrayStreamTest class methodsFor: 'accessing'!
+
+collectionClass
+	^ Array
+! !
+
+StreamTest subclass: #StringStreamTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!StringStreamTest methodsFor: 'accessing'!
+
+newCollection
+	^ 'hello world'
+! !
+
+!StringStreamTest class methodsFor: 'accessing'!
+
+collectionClass
+	^ String
+! !
+
+TestCase subclass: #UndefinedTest
+	instanceVariableNames: ''
+	package: 'Kernel-Tests'!
+
+!UndefinedTest methodsFor: 'tests'!
+
+testCopying
+	self assert: nil copy equals: nil
+!
+
+testDeepCopy
+	self assert: nil deepCopy = nil
+!
+
+testIfNil
+	self assert: (nil ifNil: [ true ]) equals: true.
+	self deny: (nil ifNotNil: [ true ]) = true.
+	self assert: (nil ifNil: [ true ] ifNotNil: [ false ]) equals: true.
+	self deny: (nil ifNotNil: [ true ] ifNil: [ false ]) = true
+!
+
+testIsNil
+	self assert: nil isNil.
+	self deny: nil notNil.
+! !
+

+ 115 - 0
bower_components/amber/src/Kernel-Transcript.js

@@ -0,0 +1,115 @@
+define("amber_core/Kernel-Transcript", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Kernel-Transcript');
+$core.packages["Kernel-Transcript"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ConsoleTranscript', $globals.Object, ['textarea'], 'Kernel-Transcript');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ConsoleTranscript.comment="I am a specific transcript emitting to the JavaScript console.\x0a\x0aIf no other transcript is registered, I am the default.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "clear",
+protocol: 'printing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "clear\x0a\x09\x22no op\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ConsoleTranscript);
+
+$core.addMethod(
+$core.method({
+selector: "cr",
+protocol: 'printing',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cr\x0a\x09\x22no op\x22",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ConsoleTranscript);
+
+$core.addMethod(
+$core.method({
+selector: "open",
+protocol: 'actions',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "open",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ConsoleTranscript);
+
+$core.addMethod(
+$core.method({
+selector: "show:",
+protocol: 'printing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+console.log(String($recv(anObject)._asString()));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"show:",{anObject:anObject},$globals.ConsoleTranscript)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "show: anObject\x0a\x22Smalltalk objects should have no trouble displaying themselves on the Transcript; Javascript objects don't know how, so must be wrapped in a JSObectProxy.\x22\x0a<console.log(String($recv(anObject)._asString()))>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ConsoleTranscript);
+
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Transcript(){return $globals.Transcript||(typeof Transcript=="undefined"?nil:Transcript)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($Transcript())._registerIfNone_(self._new());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.ConsoleTranscript.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09Transcript registerIfNone: self new",
+referencedClasses: ["Transcript"],
+//>>excludeEnd("ide");
+messageSends: ["registerIfNone:", "new"]
+}),
+$globals.ConsoleTranscript.klass);
+
+});

+ 35 - 0
bower_components/amber/src/Kernel-Transcript.st

@@ -0,0 +1,35 @@
+Smalltalk createPackage: 'Kernel-Transcript'!
+Object subclass: #ConsoleTranscript
+	instanceVariableNames: 'textarea'
+	package: 'Kernel-Transcript'!
+!ConsoleTranscript commentStamp!
+I am a specific transcript emitting to the JavaScript console.
+
+If no other transcript is registered, I am the default.!
+
+!ConsoleTranscript methodsFor: 'actions'!
+
+open
+! !
+
+!ConsoleTranscript methodsFor: 'printing'!
+
+clear
+	"no op"
+!
+
+cr
+	"no op"
+!
+
+show: anObject
+"Smalltalk objects should have no trouble displaying themselves on the Transcript; Javascript objects don't know how, so must be wrapped in a JSObectProxy."
+<console.log(String($recv(anObject)._asString()))>
+! !
+
+!ConsoleTranscript class methodsFor: 'initialization'!
+
+initialize
+	Transcript registerIfNone: self new
+! !
+

+ 962 - 0
bower_components/amber/src/SUnit-Tests.js

@@ -0,0 +1,962 @@
+define("amber_core/SUnit-Tests", ["amber/boot", "amber_core/SUnit"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('SUnit-Tests');
+$core.packages["SUnit-Tests"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ExampleSetTest', $globals.TestCase, ['empty', 'full'], 'SUnit-Tests');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ExampleSetTest.comment="ExampleSetTest is taken from Pharo 1.4.\x0a\x0aTHe purpose of this class is to demonstrate a simple use case of the test framework.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'running',
+fn: function (){
+var self=this;
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@empty"]=$recv($Set())._new();
+self["@full"]=$recv($Set())._with_with_((5),"abc");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"setUp",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp\x0a\x09empty := Set new.\x0a\x09full := Set with: 5 with: #abc",
+referencedClasses: ["Set"],
+//>>excludeEnd("ide");
+messageSends: ["new", "with:with:"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testAdd",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@empty"])._add_((5));
+self._assert_($recv(self["@empty"])._includes_((5)));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testAdd",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testAdd\x0a\x09empty add: 5.\x0a\x09self assert: (empty includes: 5)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "assert:", "includes:"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testGrow",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@empty"])._addAll_((1)._to_((100)));
+self._assert_equals_($recv(self["@empty"])._size(),(100));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testGrow",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testGrow\x0a\x09empty addAll: (1 to: 100).\x0a\x09self assert: empty size equals: 100",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addAll:", "to:", "assert:equals:", "size"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testIllegal",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@empty"])._at_((5));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$Error());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["should:raise:"]=1;
+//>>excludeEnd("ctx");
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@empty"])._at_put_((5),"abc");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),$Error());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testIllegal",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testIllegal\x0a\x09self\x0a\x09\x09should: [ empty at: 5 ]\x0a\x09\x09raise: Error.\x0a\x09self\x0a\x09\x09should: [ empty at: 5 put: #abc ]\x0a\x09\x09raise: Error",
+referencedClasses: ["Error"],
+//>>excludeEnd("ide");
+messageSends: ["should:raise:", "at:", "at:put:"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testIncludes",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@full"])._includes_((5));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["includes:"]=1;
+//>>excludeEnd("ctx");
+self._assert_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:"]=1;
+//>>excludeEnd("ctx");
+self._assert_($recv(self["@full"])._includes_("abc"));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testIncludes",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testIncludes\x0a\x09self assert: (full includes: 5).\x0a\x09self assert: (full includes: #abc)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:", "includes:"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testOccurrences",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv(self["@empty"])._occurrencesOf_((0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["occurrencesOf:"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($1,(0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+$2=$recv(self["@full"])._occurrencesOf_((5));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["occurrencesOf:"]=2;
+//>>excludeEnd("ctx");
+self._assert_equals_($2,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["assert:equals:"]=2;
+//>>excludeEnd("ctx");
+$recv(self["@full"])._add_((5));
+self._assert_equals_($recv(self["@full"])._occurrencesOf_((5)),(1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testOccurrences",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testOccurrences\x0a\x09self assert: (empty occurrencesOf: 0) equals: 0.\x0a\x09self assert: (full occurrencesOf: 5) equals: 1.\x0a\x09full add: 5.\x0a\x09self assert: (full occurrencesOf: 5) equals: 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:equals:", "occurrencesOf:", "add:"]
+}),
+$globals.ExampleSetTest);
+
+$core.addMethod(
+$core.method({
+selector: "testRemove",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv(self["@full"])._remove_((5));
+$1=$recv(self["@full"])._includes_("abc");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["includes:"]=1;
+//>>excludeEnd("ctx");
+self._assert_($1);
+self._deny_($recv(self["@full"])._includes_((5)));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testRemove",{},$globals.ExampleSetTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testRemove\x0a\x09full remove: 5.\x0a\x09self assert: (full includes: #abc).\x0a\x09self deny: (full includes: 5)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["remove:", "assert:", "includes:", "deny:"]
+}),
+$globals.ExampleSetTest);
+
+
+
+$core.addClass('SUnitAsyncTest', $globals.TestCase, ['flag'], 'SUnit-Tests');
+$core.addMethod(
+$core.method({
+selector: "fakeError",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@flag"]="bad";
+self._timeout_((30));
+self["@flag"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self["@flag"]="ok";
+self["@flag"];
+return self._error_("Intentional");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((20));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeError",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeError\x0a\x09flag := 'bad'.\x0a\x09self timeout: 30.\x0a\x09flag := (self async: [ flag := 'ok'. self error: 'Intentional' ]) valueWithTimeout: 20",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "error:"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "fakeErrorFailingInTearDown",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@flag"]="bad";
+self._timeout_((30));
+self["@flag"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._error_("Intentional");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((20));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeErrorFailingInTearDown",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeErrorFailingInTearDown\x0a\x09flag := 'bad'.\x0a\x09self timeout: 30.\x0a\x09flag := (self async: [ self error: 'Intentional' ]) valueWithTimeout: 20",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "error:"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "fakeFailure",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@flag"]="bad";
+self._timeout_((30));
+self["@flag"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self["@flag"]="ok";
+self["@flag"];
+return self._assert_(false);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((20));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeFailure",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeFailure\x0a\x09flag := 'bad'.\x0a\x09self timeout: 30.\x0a\x09flag := (self async: [ flag := 'ok'. self assert: false ]) valueWithTimeout: 20",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "assert:"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "fakeMultipleTimeoutFailing",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._timeout_((100));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["timeout:"]=1;
+//>>excludeEnd("ctx");
+$1=self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._timeout_((20));
+return $recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((30));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["async:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._valueWithTimeout_((20));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["valueWithTimeout:"]=1;
+//>>excludeEnd("ctx");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeMultipleTimeoutFailing",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeMultipleTimeoutFailing\x0a\x09self timeout: 100.\x0a\x09(self async: [ \x0a\x09\x09self timeout: 20.\x0a\x09\x09(self async: [ self finished ]) valueWithTimeout: 30\x0a\x09]) valueWithTimeout: 20",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "fakeMultipleTimeoutPassing",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._timeout_((20));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["timeout:"]=1;
+//>>excludeEnd("ctx");
+$1=self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._timeout_((40));
+return $recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((20));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["async:"]=1;
+//>>excludeEnd("ctx");
+$recv($1)._valueWithTimeout_((10));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["valueWithTimeout:"]=1;
+//>>excludeEnd("ctx");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeMultipleTimeoutPassing",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeMultipleTimeoutPassing\x0a\x09self timeout: 20.\x0a\x09(self async: [\x0a\x09\x09self timeout: 40.\x0a\x09\x09(self async: [ self finished ]) valueWithTimeout: 20\x0a\x09]) valueWithTimeout: 10",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "fakeTimeout",
+protocol: 'helpers',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._timeout_((10));
+$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((20));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fakeTimeout",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fakeTimeout\x0a\x09self timeout: 10.\x0a\x09(self async: [ self finished ]) valueWithTimeout: 20",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "selectorSetOf:",
+protocol: 'private',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aCollection)._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._selector();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._asSet();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selectorSetOf:",{aCollection:aCollection},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "selectorSetOf: aCollection\x0a\x09^ (aCollection collect: [ :each | each selector ]) asSet",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asSet", "collect:", "selector"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'running',
+fn: function (){
+var self=this;
+self["@flag"]="ok";
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp\x0a\x09flag := 'ok'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "tearDown",
+protocol: 'running',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_equals_("ok",self["@flag"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tearDown",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tearDown\x0a\x09self assert: 'ok' equals: flag",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:equals:"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testAsyncErrorsAndFailures",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var suite,runner,result,assertBlock;
+function $TestSuiteRunner(){return $globals.TestSuiteRunner||(typeof TestSuiteRunner=="undefined"?nil:TestSuiteRunner)}
+function $ResultAnnouncement(){return $globals.ResultAnnouncement||(typeof ResultAnnouncement=="undefined"?nil:ResultAnnouncement)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$4;
+suite=["fakeError", "fakeErrorFailingInTearDown", "fakeFailure", "testPass"]._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._class())._selector_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+runner=$recv($TestSuiteRunner())._on_(suite);
+self._timeout_((200));
+result=$recv(runner)._result();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["result"]=1;
+//>>excludeEnd("ctx");
+assertBlock=self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._selectorSetOf_($recv(result)._errors());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["selectorSetOf:"]=1;
+//>>excludeEnd("ctx");
+$2=["fakeError"]._asSet();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["asSet"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($1,$2);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_(self._selectorSetOf_($recv(result)._failures()),["fakeErrorFailingInTearDown", "fakeFailure"]._asSet());
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv($recv(runner)._announcer())._on_do_($ResultAnnouncement(),(function(ann){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$3=$recv($recv(ann)._result()).__eq_eq(result);
+if($core.assert($3)){
+$4=$recv($recv(result)._runs()).__eq($recv(result)._total());
+return $recv($4)._ifTrue_(assertBlock);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(runner)._run();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testAsyncErrorsAndFailures",{suite:suite,runner:runner,result:result,assertBlock:assertBlock},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testAsyncErrorsAndFailures\x0a\x09| suite runner result assertBlock |\x0a\x09suite := #('fakeError' 'fakeErrorFailingInTearDown' 'fakeFailure' 'testPass') collect: [ :each | self class selector: each ].\x0a\x09runner := TestSuiteRunner on: suite.\x0a\x09self timeout: 200.\x0a\x09result := runner result.\x0a\x09assertBlock := self async: [\x0a\x09\x09self assert: (self selectorSetOf: result errors) equals: #('fakeError') asSet.\x0a\x09\x09self assert: (self selectorSetOf: result failures) equals: #('fakeErrorFailingInTearDown' 'fakeFailure') asSet.\x0a\x09\x09self finished\x0a\x09].\x0a\x09runner announcer on: ResultAnnouncement do: [ :ann |\x0a\x09\x09ann result == result ifTrue: [ result runs = result total ifTrue: assertBlock ] ].\x0a\x09runner run",
+referencedClasses: ["TestSuiteRunner", "ResultAnnouncement"],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "selector:", "class", "on:", "timeout:", "result", "async:", "assert:equals:", "selectorSetOf:", "errors", "asSet", "failures", "finished", "on:do:", "announcer", "ifTrue:", "==", "=", "runs", "total", "run"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testAsyncNeedsTimeout",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._async_((function(){
+
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["async:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$Error());
+self._timeout_((0));
+self._shouldnt_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._async_((function(){
+
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}),$Error());
+self._finished();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testAsyncNeedsTimeout",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testAsyncNeedsTimeout\x0a\x09self should: [ self async: [ ] ] raise: Error.\x0a\x09self timeout: 0.\x0a\x09self shouldnt: [ self async: [ ] ] raise: Error.\x0a\x09self finished",
+referencedClasses: ["Error"],
+//>>excludeEnd("ide");
+messageSends: ["should:raise:", "async:", "timeout:", "shouldnt:raise:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testFinishedNeedsTimeout",
+protocol: 'tests',
+fn: function (){
+var self=this;
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._should_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["finished"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}),$Error());
+self._timeout_((0));
+self._shouldnt_raise_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}),$Error());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testFinishedNeedsTimeout",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testFinishedNeedsTimeout\x0a\x09self should: [ self finished ] raise: Error.\x0a\x09self timeout: 0.\x0a\x09self shouldnt: [ self finished ] raise: Error.",
+referencedClasses: ["Error"],
+//>>excludeEnd("ide");
+messageSends: ["should:raise:", "finished", "timeout:", "shouldnt:raise:"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testIsAsyncReturnsCorrectValues",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=self._isAsync();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["isAsync"]=1;
+//>>excludeEnd("ctx");
+self._deny_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["deny:"]=1;
+//>>excludeEnd("ctx");
+self._timeout_((0));
+$2=self._isAsync();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["isAsync"]=2;
+//>>excludeEnd("ctx");
+self._assert_($2);
+self._finished();
+self._deny_(self._isAsync());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testIsAsyncReturnsCorrectValues",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testIsAsyncReturnsCorrectValues\x0a\x09self deny: self isAsync.\x0a\x09self timeout: 0.\x0a\x09self assert: self isAsync.\x0a\x09self finished.\x0a\x09self deny: self isAsync",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["deny:", "isAsync", "timeout:", "assert:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testPass",
+protocol: 'tests',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@flag"]="bad";
+self._timeout_((10));
+self["@flag"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._assert_(true);
+self._finished();
+self["@flag"]="ok";
+return self["@flag"];
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((5));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testPass",{},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testPass\x0a\x09flag := 'bad'.\x0a\x09self timeout: 10.\x0a\x09flag := (self async: [ self assert: true. self finished. flag := 'ok' ]) valueWithTimeout: 5",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "assert:", "finished"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testTimeouts",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var suite,runner,result,assertBlock;
+function $TestSuiteRunner(){return $globals.TestSuiteRunner||(typeof TestSuiteRunner=="undefined"?nil:TestSuiteRunner)}
+function $Set(){return $globals.Set||(typeof Set=="undefined"?nil:Set)}
+function $ResultAnnouncement(){return $globals.ResultAnnouncement||(typeof ResultAnnouncement=="undefined"?nil:ResultAnnouncement)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+suite=["fakeTimeout", "fakeMultipleTimeoutFailing", "fakeMultipleTimeoutPassing", "testPass"]._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._class())._selector_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+runner=$recv($TestSuiteRunner())._on_(suite);
+self._timeout_((200));
+result=$recv(runner)._result();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["result"]=1;
+//>>excludeEnd("ctx");
+assertBlock=self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=self._selectorSetOf_($recv(result)._errors());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["selectorSetOf:"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_($1,$recv($Set())._new());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+self._assert_equals_(self._selectorSetOf_($recv(result)._failures()),["fakeMultipleTimeoutFailing", "fakeTimeout"]._asSet());
+return self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+$recv($recv(runner)._announcer())._on_do_($ResultAnnouncement(),(function(ann){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv($recv(ann)._result()).__eq_eq(result);
+if($core.assert($2)){
+$3=$recv($recv(result)._runs()).__eq($recv(result)._total());
+return $recv($3)._ifTrue_(assertBlock);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ann:ann},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+$recv(runner)._run();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testTimeouts",{suite:suite,runner:runner,result:result,assertBlock:assertBlock},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testTimeouts\x0a\x09| suite runner result assertBlock |\x0a\x09suite := #('fakeTimeout' 'fakeMultipleTimeoutFailing' 'fakeMultipleTimeoutPassing' 'testPass') collect: [ :each | self class selector: each ].\x0a\x09runner := TestSuiteRunner on: suite.\x0a\x09self timeout: 200.\x0a\x09result := runner result.\x0a\x09assertBlock := self async: [\x0a\x09\x09self assert: (self selectorSetOf: result errors) equals: Set new.\x0a\x09\x09self assert: (self selectorSetOf: result failures) equals: #('fakeMultipleTimeoutFailing' 'fakeTimeout') asSet.\x0a\x09\x09self finished\x0a\x09].\x0a\x09runner announcer on: ResultAnnouncement do: [ :ann |\x0a\x09\x09ann result == result ifTrue: [ result runs = result total ifTrue: assertBlock ] ].\x0a\x09runner run",
+referencedClasses: ["TestSuiteRunner", "Set", "ResultAnnouncement"],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "selector:", "class", "on:", "timeout:", "result", "async:", "assert:equals:", "selectorSetOf:", "errors", "new", "failures", "asSet", "finished", "on:do:", "announcer", "ifTrue:", "==", "=", "runs", "total", "run"]
+}),
+$globals.SUnitAsyncTest);
+
+$core.addMethod(
+$core.method({
+selector: "testTwoAsyncPassesWithFinishedOnlyOneIsRun",
+protocol: 'tests',
+fn: function (){
+var self=this;
+var x;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self["@flag"]="bad";
+self._timeout_((10));
+x=(0);
+$1=self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._finished();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["finished"]=1;
+//>>excludeEnd("ctx");
+self["@flag"]="ok";
+self["@flag"];
+x=$recv(x).__plus((1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["+"]=1;
+//>>excludeEnd("ctx");
+x;
+return self._assert_equals_(x,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["assert:equals:"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["async:"]=1;
+//>>excludeEnd("ctx");
+self["@flag"]=$recv($1)._valueWithTimeout_((0));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["valueWithTimeout:"]=1;
+//>>excludeEnd("ctx");
+self["@flag"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+self._finished();
+self["@flag"]="ok";
+self["@flag"];
+x=$recv(x).__plus((1));
+x;
+return self._assert_equals_(x,(1));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_((0));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testTwoAsyncPassesWithFinishedOnlyOneIsRun",{x:x},$globals.SUnitAsyncTest)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testTwoAsyncPassesWithFinishedOnlyOneIsRun\x0a\x09| x |\x0a\x09flag := 'bad'.\x0a\x09self timeout: 10.\x0a\x09x := 0.\x0a\x09flag := (self async: [ self finished. flag := 'ok'. x := x+1. self assert: x equals: 1 ]) valueWithTimeout: 0.\x0a\x09flag := (self async: [ self finished. flag := 'ok'. x := x+1. self assert: x equals: 1 ]) valueWithTimeout: 0.",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["timeout:", "valueWithTimeout:", "async:", "finished", "+", "assert:equals:"]
+}),
+$globals.SUnitAsyncTest);
+
+
+});

+ 186 - 0
bower_components/amber/src/SUnit-Tests.st

@@ -0,0 +1,186 @@
+Smalltalk createPackage: 'SUnit-Tests'!
+TestCase subclass: #ExampleSetTest
+	instanceVariableNames: 'empty full'
+	package: 'SUnit-Tests'!
+!ExampleSetTest commentStamp!
+ExampleSetTest is taken from Pharo 1.4.
+
+THe purpose of this class is to demonstrate a simple use case of the test framework.!
+
+!ExampleSetTest methodsFor: 'running'!
+
+setUp
+	empty := Set new.
+	full := Set with: 5 with: #abc
+! !
+
+!ExampleSetTest methodsFor: 'tests'!
+
+testAdd
+	empty add: 5.
+	self assert: (empty includes: 5)
+!
+
+testGrow
+	empty addAll: (1 to: 100).
+	self assert: empty size equals: 100
+!
+
+testIllegal
+	self
+		should: [ empty at: 5 ]
+		raise: Error.
+	self
+		should: [ empty at: 5 put: #abc ]
+		raise: Error
+!
+
+testIncludes
+	self assert: (full includes: 5).
+	self assert: (full includes: #abc)
+!
+
+testOccurrences
+	self assert: (empty occurrencesOf: 0) equals: 0.
+	self assert: (full occurrencesOf: 5) equals: 1.
+	full add: 5.
+	self assert: (full occurrencesOf: 5) equals: 1
+!
+
+testRemove
+	full remove: 5.
+	self assert: (full includes: #abc).
+	self deny: (full includes: 5)
+! !
+
+TestCase subclass: #SUnitAsyncTest
+	instanceVariableNames: 'flag'
+	package: 'SUnit-Tests'!
+
+!SUnitAsyncTest methodsFor: 'helpers'!
+
+fakeError
+	flag := 'bad'.
+	self timeout: 30.
+	flag := (self async: [ flag := 'ok'. self error: 'Intentional' ]) valueWithTimeout: 20
+!
+
+fakeErrorFailingInTearDown
+	flag := 'bad'.
+	self timeout: 30.
+	flag := (self async: [ self error: 'Intentional' ]) valueWithTimeout: 20
+!
+
+fakeFailure
+	flag := 'bad'.
+	self timeout: 30.
+	flag := (self async: [ flag := 'ok'. self assert: false ]) valueWithTimeout: 20
+!
+
+fakeMultipleTimeoutFailing
+	self timeout: 100.
+	(self async: [ 
+		self timeout: 20.
+		(self async: [ self finished ]) valueWithTimeout: 30
+	]) valueWithTimeout: 20
+!
+
+fakeMultipleTimeoutPassing
+	self timeout: 20.
+	(self async: [
+		self timeout: 40.
+		(self async: [ self finished ]) valueWithTimeout: 20
+	]) valueWithTimeout: 10
+!
+
+fakeTimeout
+	self timeout: 10.
+	(self async: [ self finished ]) valueWithTimeout: 20
+! !
+
+!SUnitAsyncTest methodsFor: 'private'!
+
+selectorSetOf: aCollection
+	^ (aCollection collect: [ :each | each selector ]) asSet
+! !
+
+!SUnitAsyncTest methodsFor: 'running'!
+
+setUp
+	flag := 'ok'
+!
+
+tearDown
+	self assert: 'ok' equals: flag
+! !
+
+!SUnitAsyncTest methodsFor: 'tests'!
+
+testAsyncErrorsAndFailures
+	| suite runner result assertBlock |
+	suite := #('fakeError' 'fakeErrorFailingInTearDown' 'fakeFailure' 'testPass') collect: [ :each | self class selector: each ].
+	runner := TestSuiteRunner on: suite.
+	self timeout: 200.
+	result := runner result.
+	assertBlock := self async: [
+		self assert: (self selectorSetOf: result errors) equals: #('fakeError') asSet.
+		self assert: (self selectorSetOf: result failures) equals: #('fakeErrorFailingInTearDown' 'fakeFailure') asSet.
+		self finished
+	].
+	runner announcer on: ResultAnnouncement do: [ :ann |
+		ann result == result ifTrue: [ result runs = result total ifTrue: assertBlock ] ].
+	runner run
+!
+
+testAsyncNeedsTimeout
+	self should: [ self async: [ ] ] raise: Error.
+	self timeout: 0.
+	self shouldnt: [ self async: [ ] ] raise: Error.
+	self finished
+!
+
+testFinishedNeedsTimeout
+	self should: [ self finished ] raise: Error.
+	self timeout: 0.
+	self shouldnt: [ self finished ] raise: Error.
+!
+
+testIsAsyncReturnsCorrectValues
+	self deny: self isAsync.
+	self timeout: 0.
+	self assert: self isAsync.
+	self finished.
+	self deny: self isAsync
+!
+
+testPass
+	flag := 'bad'.
+	self timeout: 10.
+	flag := (self async: [ self assert: true. self finished. flag := 'ok' ]) valueWithTimeout: 5
+!
+
+testTimeouts
+	| suite runner result assertBlock |
+	suite := #('fakeTimeout' 'fakeMultipleTimeoutFailing' 'fakeMultipleTimeoutPassing' 'testPass') collect: [ :each | self class selector: each ].
+	runner := TestSuiteRunner on: suite.
+	self timeout: 200.
+	result := runner result.
+	assertBlock := self async: [
+		self assert: (self selectorSetOf: result errors) equals: Set new.
+		self assert: (self selectorSetOf: result failures) equals: #('fakeMultipleTimeoutFailing' 'fakeTimeout') asSet.
+		self finished
+	].
+	runner announcer on: ResultAnnouncement do: [ :ann |
+		ann result == result ifTrue: [ result runs = result total ifTrue: assertBlock ] ].
+	runner run
+!
+
+testTwoAsyncPassesWithFinishedOnlyOneIsRun
+	| x |
+	flag := 'bad'.
+	self timeout: 10.
+	x := 0.
+	flag := (self async: [ self finished. flag := 'ok'. x := x+1. self assert: x equals: 1 ]) valueWithTimeout: 0.
+	flag := (self async: [ self finished. flag := 'ok'. x := x+1. self assert: x equals: 1 ]) valueWithTimeout: 0.
+! !
+

+ 1859 - 0
bower_components/amber/src/SUnit.js

@@ -0,0 +1,1859 @@
+define("amber_core/SUnit", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Exceptions", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Classes"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('SUnit');
+$core.packages["SUnit"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('ResultAnnouncement', $globals.Object, ['result'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ResultAnnouncement.comment="I get signaled when a `TestCase` has been run.\x0a\x0aMy instances hold the result (instance of `TestResult`) of the test run.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "result",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@result"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "result\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ResultAnnouncement);
+
+$core.addMethod(
+$core.method({
+selector: "result:",
+protocol: 'accessing',
+fn: function (aTestResult){
+var self=this;
+self["@result"]=aTestResult;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestResult"],
+source: "result: aTestResult\x0a\x09result := aTestResult",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ResultAnnouncement);
+
+
+
+$core.addClass('TestCase', $globals.Object, ['testSelector', 'asyncTimeout', 'context'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TestCase.comment="I am an implementation of the command pattern to run a test.\x0a\x0a## API\x0a\x0aMy instances are created with the class method `#selector:`,\x0apassing the symbol that names the method to be executed when the test case runs.\x0a\x0aWhen you discover a new fixture, subclass `TestCase` and create a `#test...` method for the first test.\x0aAs that method develops and more `#test...` methods are added, you will find yourself refactoring temps\x0ainto instance variables for the objects in the fixture and overriding `#setUp` to initialize these variables.\x0aAs required, override `#tearDown` to nil references, release objects and deallocate.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "assert:",
+protocol: 'testing',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_description_(aBoolean,"Assertion failed");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assert:",{aBoolean:aBoolean},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "assert: aBoolean\x0a\x09self assert: aBoolean description: 'Assertion failed'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:description:"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "assert:description:",
+protocol: 'testing',
+fn: function (aBoolean,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+if(!$core.assert(aBoolean)){
+self._signalFailure_(aString);
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assert:description:",{aBoolean:aBoolean,aString:aString},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean", "aString"],
+source: "assert: aBoolean description: aString\x0a\x09aBoolean ifFalse: [ self signalFailure: aString ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "signalFailure:"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "assert:equals:",
+protocol: 'testing',
+fn: function (actual,expected){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$6,$5,$4,$3,$1;
+$2=$recv(actual).__eq(expected);
+$6=$recv(expected)._printString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["printString"]=1;
+//>>excludeEnd("ctx");
+$5="Expected: ".__comma($6);
+$4=$recv($5).__comma(" but was: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma($recv(actual)._printString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$1=self._assert_description_($2,$3);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"assert:equals:",{actual:actual,expected:expected},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["actual", "expected"],
+source: "assert: actual equals: expected\x0a\x09^ self assert: (actual = expected) description: 'Expected: ', expected printString, ' but was: ', actual printString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:description:", "=", ",", "printString"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "async:",
+protocol: 'async',
+fn: function (aBlock){
+var self=this;
+var c;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+self._errorIfNotAsync_("#async");
+c=self["@context"];
+$1=(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=self._isAsync();
+if($core.assert($2)){
+return $recv(c)._execute_(aBlock);
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+});
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"async:",{aBlock:aBlock,c:c},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "async: aBlock\x0a\x09| c |\x0a\x09self errorIfNotAsync: '#async'.\x0a\x09c := context.\x0a\x09^ [ self isAsync ifTrue: [ c execute: aBlock ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["errorIfNotAsync:", "ifTrue:", "isAsync", "execute:"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "context:",
+protocol: 'accessing',
+fn: function (aRunningTestContext){
+var self=this;
+self["@context"]=aRunningTestContext;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aRunningTestContext"],
+source: "context: aRunningTestContext\x0a\x09context := aRunningTestContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "deny:",
+protocol: 'testing',
+fn: function (aBoolean){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_($recv(aBoolean)._not());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"deny:",{aBoolean:aBoolean},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBoolean"],
+source: "deny: aBoolean\x0a\x09self assert: aBoolean not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:", "not"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "errorIfNotAsync:",
+protocol: 'error handling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._isAsync();
+if(!$core.assert($1)){
+self._error_($recv(aString).__comma(" used without prior #timeout:"));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"errorIfNotAsync:",{aString:aString},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "errorIfNotAsync: aString\x0a\x09self isAsync ifFalse: [\x0a\x09\x09self error: aString, ' used without prior #timeout:' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "isAsync", "error:", ","]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "finished",
+protocol: 'async',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._errorIfNotAsync_("#finished");
+self["@asyncTimeout"]=nil;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"finished",{},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "finished\x0a\x09self errorIfNotAsync: '#finished'.\x0a\x09asyncTimeout := nil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["errorIfNotAsync:"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "isAsync",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@asyncTimeout"])._notNil();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isAsync",{},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isAsync\x0a\x09^ asyncTimeout notNil",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["notNil"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "performTest",
+protocol: 'running',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@asyncTimeout"]=nil;
+self._perform_(self._selector());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"performTest",{},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "performTest\x0a\x09asyncTimeout := nil.\x0a\x09self perform: self selector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["perform:", "selector"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "runCase",
+protocol: 'running',
+fn: function (){
+var self=this;
+function $TestContext(){return $globals.TestContext||(typeof TestContext=="undefined"?nil:TestContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($TestContext())._testCase_(self))._start();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"runCase",{},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "runCase\x0a\x09\x22Runs a test case in isolated context, leaking all errors.\x22\x0a\x0a\x09(TestContext testCase: self) start",
+referencedClasses: ["TestContext"],
+//>>excludeEnd("ide");
+messageSends: ["start", "testCase:"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "selector",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@testSelector"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "selector\x0a\x09^ testSelector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "setTestSelector:",
+protocol: 'accessing',
+fn: function (aSelector){
+var self=this;
+self["@testSelector"]=aSelector;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSelector"],
+source: "setTestSelector: aSelector\x0a\x09testSelector := aSelector",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "setUp",
+protocol: 'running',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "setUp",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "should:",
+protocol: 'testing',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_($recv(aBlock)._value());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:",{aBlock:aBlock},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "should: aBlock\x0a\x09self assert: aBlock value",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:", "value"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "should:raise:",
+protocol: 'testing',
+fn: function (aBlock,anExceptionClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_($recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+return false;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_(anExceptionClass,(function(ex){
+return true;
+
+})));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"should:raise:",{aBlock:aBlock,anExceptionClass:anExceptionClass},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anExceptionClass"],
+source: "should: aBlock raise: anExceptionClass\x0a\x09self assert: ([ aBlock value. false ]\x0a\x09\x09on: anExceptionClass\x0a\x09\x09do: [ :ex | true ])",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:", "on:do:", "value"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "shouldnt:raise:",
+protocol: 'testing',
+fn: function (aBlock,anExceptionClass){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._assert_($recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aBlock)._value();
+return true;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_(anExceptionClass,(function(ex){
+return false;
+
+})));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldnt:raise:",{aBlock:aBlock,anExceptionClass:anExceptionClass},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock", "anExceptionClass"],
+source: "shouldnt: aBlock raise: anExceptionClass\x0a\x09self assert: ([ aBlock value. true ]\x0a\x09\x09on: anExceptionClass\x0a\x09\x09do: [ :ex | false ])",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["assert:", "on:do:", "value"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "signalFailure:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+function $TestFailure(){return $globals.TestFailure||(typeof TestFailure=="undefined"?nil:TestFailure)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$1=$recv($TestFailure())._new();
+$recv($1)._messageText_(aString);
+$2=$recv($1)._signal();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"signalFailure:",{aString:aString},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "signalFailure: aString\x0a\x09TestFailure new\x0a\x09\x09messageText: aString;\x0a\x09\x09signal",
+referencedClasses: ["TestFailure"],
+//>>excludeEnd("ide");
+messageSends: ["messageText:", "new", "signal"]
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "tearDown",
+protocol: 'running',
+fn: function (){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tearDown",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase);
+
+$core.addMethod(
+$core.method({
+selector: "timeout:",
+protocol: 'async',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+$1=self["@asyncTimeout"];
+if(($receiver = $1) == null || $receiver.isNil){
+$1;
+} else {
+$recv(self["@asyncTimeout"])._clearTimeout();
+};
+self["@asyncTimeout"]=(0);
+self["@asyncTimeout"]=$recv(self._async_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._assert_description_(false,"SUnit grace time exhausted");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+})))._valueWithTimeout_(aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"timeout:",{aNumber:aNumber},$globals.TestCase)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "timeout: aNumber\x0a\x09\x22Set a grace time timeout in milliseconds to run the test asynchronously\x22\x0a\x09\x0a\x09asyncTimeout ifNotNil: [ asyncTimeout clearTimeout ].\x0a\x09\x0a\x09\x22to allow #async: message send without throwing an error\x22\x0a\x09asyncTimeout := 0.\x0a\x09\x0a\x09asyncTimeout := (self async: [\x0a\x09\x09self assert: false description: 'SUnit grace time exhausted' ])\x0a\x09\x09\x09valueWithTimeout: aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotNil:", "clearTimeout", "valueWithTimeout:", "async:", "assert:description:"]
+}),
+$globals.TestCase);
+
+
+$core.addMethod(
+$core.method({
+selector: "allTestSelectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var selectors;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+selectors=self._testSelectors();
+$1=self._shouldInheritSelectors();
+if($core.assert($1)){
+$recv(selectors)._addAll_($recv(self._superclass())._allTestSelectors());
+};
+$2=selectors;
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"allTestSelectors",{selectors:selectors},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "allTestSelectors\x0a\x09| selectors |\x0a\x09selectors := self testSelectors.\x0a\x09self shouldInheritSelectors ifTrue: [\x0a\x09\x09selectors addAll: self superclass allTestSelectors ].\x0a\x09^ selectors",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["testSelectors", "ifTrue:", "shouldInheritSelectors", "addAll:", "allTestSelectors", "superclass"]
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "buildSuite",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._allTestSelectors())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._selector_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"buildSuite",{},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "buildSuite\x0a\x09^ self allTestSelectors collect: [ :each | self selector: each ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "allTestSelectors", "selector:"]
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "test";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'test'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "isAbstract",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._name()).__eq("TestCase");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isAbstract",{},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isAbstract\x0a\x09^ self name = 'TestCase'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["=", "name"]
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "lookupHierarchyRoot",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+function $TestCase(){return $globals.TestCase||(typeof TestCase=="undefined"?nil:TestCase)}
+return $TestCase();
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "lookupHierarchyRoot\x0a\x09^ TestCase",
+referencedClasses: ["TestCase"],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "selector:",
+protocol: 'accessing',
+fn: function (aSelector){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._setTestSelector_(aSelector);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"selector:",{aSelector:aSelector},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aSelector"],
+source: "selector: aSelector\x0a\x09^ self new\x0a\x09\x09setTestSelector: aSelector;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["setTestSelector:", "new", "yourself"]
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "shouldInheritSelectors",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self.__tild_eq(self._lookupHierarchyRoot());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"shouldInheritSelectors",{},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "shouldInheritSelectors\x0a\x09^ self ~= self lookupHierarchyRoot",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["~=", "lookupHierarchyRoot"]
+}),
+$globals.TestCase.klass);
+
+$core.addMethod(
+$core.method({
+selector: "testSelectors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(self._methodDictionary())._keys())._select_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._match_("^test");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testSelectors",{},$globals.TestCase.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "testSelectors\x0a\x09^ self methodDictionary keys select: [ :each | each match: '^test' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["select:", "keys", "methodDictionary", "match:"]
+}),
+$globals.TestCase.klass);
+
+
+$core.addClass('TestContext', $globals.Object, ['testCase'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TestContext.comment="I govern running a particular test case.\x0a\x0aMy main added value is `#execute:` method which runs a block as a part of test case (restores context, nilling it afterwards, cleaning/calling `#tearDown` as appropriate for sync/async scenario).";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "execute:",
+protocol: 'running',
+fn: function (aBlock){
+var self=this;
+var failed;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+$recv(self["@testCase"])._context_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["context:"]=1;
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+failed=true;
+failed;
+$recv(aBlock)._value();
+failed=false;
+return failed;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._ensure_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(self["@testCase"])._context_(nil);
+$1=$recv(failed)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self["@testCase"])._isAsync();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["isAsync"]=1;
+//>>excludeEnd("ctx");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+if($core.assert($1)){
+$recv(self["@testCase"])._finished();
+};
+$2=$recv(self["@testCase"])._isAsync();
+if(!$core.assert($2)){
+return $recv(self["@testCase"])._tearDown();
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"execute:",{aBlock:aBlock,failed:failed},$globals.TestContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "execute: aBlock\x0a\x09| failed |\x0a\x09\x0a\x09testCase context: self.\x0a\x09[\x0a\x09\x09failed := true.\x0a\x09\x09aBlock value.\x0a\x09\x09failed := false\x0a\x09]\x0a\x09\x09ensure: [\x0a\x09\x09\x09testCase context: nil.\x0a\x09\x09\x09\x0a\x09\x09\x09(failed and: [ testCase isAsync ]) ifTrue: [\x0a\x09\x09\x09\x09testCase finished ].\x0a\x09\x09\x09testCase isAsync ifFalse: [\x0a\x09\x09\x09\x09testCase tearDown ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["context:", "ensure:", "value", "ifTrue:", "and:", "isAsync", "finished", "ifFalse:", "tearDown"]
+}),
+$globals.TestContext);
+
+$core.addMethod(
+$core.method({
+selector: "start",
+protocol: 'running',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._execute_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(self["@testCase"])._setUp();
+return $recv(self["@testCase"])._performTest();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"start",{},$globals.TestContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "start\x0a\x09self execute: [\x0a\x09\x09testCase setUp.\x0a\x09\x09testCase performTest ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["execute:", "setUp", "performTest"]
+}),
+$globals.TestContext);
+
+$core.addMethod(
+$core.method({
+selector: "testCase:",
+protocol: 'accessing',
+fn: function (aTestCase){
+var self=this;
+self["@testCase"]=aTestCase;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestCase"],
+source: "testCase: aTestCase\x0a\x09testCase := aTestCase",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestContext);
+
+
+$core.addMethod(
+$core.method({
+selector: "testCase:",
+protocol: 'instance creation',
+fn: function (aTestCase){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._testCase_(aTestCase);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testCase:",{aTestCase:aTestCase},$globals.TestContext.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestCase"],
+source: "testCase: aTestCase\x0a\x09^ self new\x0a\x09\x09testCase: aTestCase;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["testCase:", "new", "yourself"]
+}),
+$globals.TestContext.klass);
+
+
+$core.addClass('ReportingTestContext', $globals.TestContext, ['finished', 'result'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.ReportingTestContext.comment="I add `TestResult` reporting to `TestContext`.\x0a\x0aErrors are caught and save into a `TestResult`,\x0aWhen test case is finished (which can be later for async tests), a callback block is executed; this is used by a `TestSuiteRunner`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "execute:",
+protocol: 'running',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._withErrorReporting_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return (
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ReportingTestContext.superclass.fn.prototype._execute_.apply($recv(self), [aBlock]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.supercall = false;
+//>>excludeEnd("ctx");;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._ensure_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(self["@testCase"])._isAsync();
+if(!$core.assert($1)){
+$recv(self["@result"])._increaseRuns();
+return $recv(self["@finished"])._value();
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"execute:",{aBlock:aBlock},$globals.ReportingTestContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "execute: aBlock\x0a\x09[\x0a\x09\x09self withErrorReporting: [ super execute: aBlock ]\x0a\x09]\x0a\x09\x09ensure: [\x0a\x09\x09\x09testCase isAsync ifFalse: [\x0a\x09\x09\x09\x09result increaseRuns. finished value ] ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ensure:", "withErrorReporting:", "execute:", "ifFalse:", "isAsync", "increaseRuns", "value"]
+}),
+$globals.ReportingTestContext);
+
+$core.addMethod(
+$core.method({
+selector: "finished:",
+protocol: 'accessing',
+fn: function (aBlock){
+var self=this;
+self["@finished"]=aBlock;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "finished: aBlock\x0a\x09finished := aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ReportingTestContext);
+
+$core.addMethod(
+$core.method({
+selector: "result:",
+protocol: 'accessing',
+fn: function (aTestResult){
+var self=this;
+self["@result"]=aTestResult;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestResult"],
+source: "result: aTestResult\x0a\x09result := aTestResult",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.ReportingTestContext);
+
+$core.addMethod(
+$core.method({
+selector: "withErrorReporting:",
+protocol: 'private',
+fn: function (aBlock){
+var self=this;
+function $TestFailure(){return $globals.TestFailure||(typeof TestFailure=="undefined"?nil:TestFailure)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(aBlock)._on_do_($TestFailure(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(self["@result"])._addFailure_(self["@testCase"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({ex:ex},$ctx2,2)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self["@result"])._addError_(self["@testCase"]);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["on:do:"]=1;
+//>>excludeEnd("ctx");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"withErrorReporting:",{aBlock:aBlock},$globals.ReportingTestContext)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "withErrorReporting: aBlock\x0a\x09[ aBlock\x0a\x09\x09on: TestFailure\x0a\x09\x09do: [ :ex | result addFailure: testCase ]\x0a\x09]\x0a\x09\x09on: Error\x0a\x09\x09do: [ :ex | result addError: testCase ]",
+referencedClasses: ["TestFailure", "Error"],
+//>>excludeEnd("ide");
+messageSends: ["on:do:", "addFailure:", "addError:"]
+}),
+$globals.ReportingTestContext);
+
+
+$core.addMethod(
+$core.method({
+selector: "testCase:result:finished:",
+protocol: 'instance creation',
+fn: function (aTestCase,aTestResult,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.ReportingTestContext.klass.superclass.fn.prototype._testCase_.apply($recv(self), [aTestCase]));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv($2)._result_(aTestResult);
+$recv($2)._finished_(aBlock);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"testCase:result:finished:",{aTestCase:aTestCase,aTestResult:aTestResult,aBlock:aBlock},$globals.ReportingTestContext.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestCase", "aTestResult", "aBlock"],
+source: "testCase: aTestCase result: aTestResult finished: aBlock\x0a\x09^ (super testCase: aTestCase)\x0a\x09\x09result: aTestResult;\x0a\x09\x09finished: aBlock;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["result:", "testCase:", "finished:", "yourself"]
+}),
+$globals.ReportingTestContext.klass);
+
+
+$core.addClass('TestFailure', $globals.Error, [], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TestFailure.comment="I am raised when the boolean parameter of an #`assert:` or `#deny:` call is the opposite of what the assertion claims.\x0a\x0aThe test framework distinguishes between failures and errors.\x0aA failure is an event whose possibiity is explicitly anticipated and checked for in an assertion,\x0awhereas an error is an unanticipated problem like a division by 0 or an index out of bounds.";
+//>>excludeEnd("ide");
+
+
+$core.addClass('TestResult', $globals.Object, ['timestamp', 'runs', 'errors', 'failures', 'total'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TestResult.comment="I implement the collecting parameter pattern for running a bunch of tests.\x0a\x0aMy instances hold tests that have run, sorted into the result categories of passed, failures and errors.\x0a\x0a`TestResult` is an interesting object to subclass or substitute. `#runCase:` is the external protocol you need to reproduce";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "addError:",
+protocol: 'accessing',
+fn: function (anError){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._errors())._add_(anError);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addError:",{anError:anError},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anError"],
+source: "addError: anError\x0a\x09self errors add: anError",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "errors"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "addFailure:",
+protocol: 'accessing',
+fn: function (aFailure){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._failures())._add_(aFailure);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addFailure:",{aFailure:aFailure},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aFailure"],
+source: "addFailure: aFailure\x0a\x09self failures add: aFailure",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["add:", "failures"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "errors",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@errors"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "errors\x0a\x09^ errors",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "failures",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@failures"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "failures\x0a\x09^ failures",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "increaseRuns",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@runs"]=$recv(self["@runs"]).__plus((1));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"increaseRuns",{},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "increaseRuns\x0a\x09runs := runs + 1",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["+"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Date(){return $globals.Date||(typeof Date=="undefined"?nil:Date)}
+function $Array(){return $globals.Array||(typeof Array=="undefined"?nil:Array)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.TestResult.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@timestamp"]=$recv($Date())._now();
+self["@runs"]=(0);
+self["@errors"]=$recv($Array())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+self["@failures"]=$recv($Array())._new();
+self["@total"]=(0);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09timestamp := Date now.\x0a\x09runs := 0.\x0a\x09errors := Array new.\x0a\x09failures := Array new.\x0a\x09total := 0",
+referencedClasses: ["Date", "Array"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "now", "new"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "nextRunDo:",
+protocol: 'running',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=self._runs();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["runs"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__eq_eq(self._total());
+if(!$core.assert($2)){
+$1=$recv(aBlock)._value_($recv(self._runs()).__plus((1)));
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nextRunDo:",{aBlock:aBlock},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "nextRunDo: aBlock\x0a\x09\x22Runs aBlock with index of next run or does nothing if no more runs\x22\x0a\x09^ self runs == self total\x0a\x09\x09ifFalse: [ aBlock value: self runs + 1 ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "==", "runs", "total", "value:", "+"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "runCase:",
+protocol: 'running',
+fn: function (aTestCase){
+var self=this;
+function $TestFailure(){return $globals.TestFailure||(typeof TestFailure=="undefined"?nil:TestFailure)}
+function $Error(){return $globals.Error||(typeof Error=="undefined"?nil:Error)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+self._increaseRuns();
+return $recv(aTestCase)._runCase();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)});
+//>>excludeEnd("ctx");
+}))._on_do_($TestFailure(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return self._addFailure_(aTestCase);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx3) {$ctx3.fillBlock({ex:ex},$ctx2,3)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._on_do_($Error(),(function(ex){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._addError_(aTestCase);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({ex:ex},$ctx1,4)});
+//>>excludeEnd("ctx");
+}));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["on:do:"]=1;
+//>>excludeEnd("ctx");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"runCase:",{aTestCase:aTestCase},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTestCase"],
+source: "runCase: aTestCase\x0a\x09[ [ self increaseRuns.\x0a\x09\x09aTestCase runCase ]\x0a\x09on: TestFailure do: [ :ex | self addFailure: aTestCase ]]\x0a\x09on: Error do: [ :ex | self addError: aTestCase ]",
+referencedClasses: ["TestFailure", "Error"],
+//>>excludeEnd("ide");
+messageSends: ["on:do:", "increaseRuns", "runCase", "addFailure:", "addError:"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "runs",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@runs"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "runs\x0a\x09^ runs",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "status",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=$recv(self._errors())._isEmpty();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["isEmpty"]=1;
+//>>excludeEnd("ctx");
+if($core.assert($2)){
+$3=$recv(self._failures())._isEmpty();
+if($core.assert($3)){
+$1="success";
+} else {
+$1="failure";
+};
+} else {
+$1="error";
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"status",{},$globals.TestResult)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "status\x0a\x09^ self errors isEmpty\x0a\x09\x09ifTrue: [\x0a\x09\x09\x09self failures isEmpty\x0a\x09\x09\x09\x09ifTrue: [ 'success' ]\x0a\x09\x09\x09\x09ifFalse: [ 'failure' ]]\x0a\x09\x09ifFalse: [ 'error' ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifTrue:ifFalse:", "isEmpty", "errors", "failures"]
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "timestamp",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@timestamp"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "timestamp\x0a\x09^ timestamp",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "total",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@total"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "total\x0a\x09^ total",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+$core.addMethod(
+$core.method({
+selector: "total:",
+protocol: 'accessing',
+fn: function (aNumber){
+var self=this;
+self["@total"]=aNumber;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "total: aNumber\x0a\x09total := aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestResult);
+
+
+
+$core.addClass('TestSuiteRunner', $globals.Object, ['suite', 'result', 'announcer', 'runNextTest'], 'SUnit');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TestSuiteRunner.comment="I am responsible for running a collection (`suite`) of tests.\x0a\x0a## API\x0a\x0aInstances should be created using the class-side `#on:` method, taking a collection of tests to run as parameter.\x0aTo run the test suite, use `#run`.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "announcer",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@announcer"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "announcer\x0a\x09^ announcer",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "contextOf:",
+protocol: 'private',
+fn: function (anInteger){
+var self=this;
+function $ReportingTestContext(){return $globals.ReportingTestContext||(typeof ReportingTestContext=="undefined"?nil:ReportingTestContext)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($ReportingTestContext())._testCase_result_finished_($recv(self["@suite"])._at_(anInteger),self["@result"],(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._resume();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contextOf:",{anInteger:anInteger},$globals.TestSuiteRunner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anInteger"],
+source: "contextOf: anInteger\x0a\x09^ ReportingTestContext testCase: (suite at: anInteger) result: result finished: [ self resume ]",
+referencedClasses: ["ReportingTestContext"],
+//>>excludeEnd("ide");
+messageSends: ["testCase:result:finished:", "at:", "resume"]
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $Announcer(){return $globals.Announcer||(typeof Announcer=="undefined"?nil:Announcer)}
+function $TestResult(){return $globals.TestResult||(typeof TestResult=="undefined"?nil:TestResult)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.TestSuiteRunner.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+self["@announcer"]=$recv($Announcer())._new();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["new"]=1;
+//>>excludeEnd("ctx");
+self["@result"]=$recv($TestResult())._new();
+self["@runNextTest"]=(function(){
+var runs;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+runs=$recv(self["@result"])._runs();
+runs;
+$1=$recv(runs).__lt($recv(self["@result"])._total());
+if($core.assert($1)){
+return $recv(self._contextOf_($recv(runs).__plus((1))))._start();
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({runs:runs},$ctx1,1)});
+//>>excludeEnd("ctx");
+});
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.TestSuiteRunner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09announcer := Announcer new.\x0a\x09result := TestResult new.\x0a\x09runNextTest := [ | runs | runs := result runs. runs < result total ifTrue: [ (self contextOf: runs + 1) start ] ].",
+referencedClasses: ["Announcer", "TestResult"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "new", "runs", "ifTrue:", "<", "total", "start", "contextOf:", "+"]
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "result",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@result"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "result\x0a\x09^ result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "resume",
+protocol: 'actions',
+fn: function (){
+var self=this;
+function $ResultAnnouncement(){return $globals.ResultAnnouncement||(typeof ResultAnnouncement=="undefined"?nil:ResultAnnouncement)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@runNextTest"])._fork();
+$recv(self["@announcer"])._announce_($recv($recv($ResultAnnouncement())._new())._result_(self["@result"]));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"resume",{},$globals.TestSuiteRunner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "resume\x0a\x09runNextTest fork.\x0a\x09announcer announce: (ResultAnnouncement new result: result)",
+referencedClasses: ["ResultAnnouncement"],
+//>>excludeEnd("ide");
+messageSends: ["fork", "announce:", "result:", "new"]
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "run",
+protocol: 'actions',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self["@result"])._total_($recv(self["@suite"])._size());
+self._resume();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"run",{},$globals.TestSuiteRunner)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "run\x0a\x09result total: suite size.\x0a\x09self resume",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["total:", "size", "resume"]
+}),
+$globals.TestSuiteRunner);
+
+$core.addMethod(
+$core.method({
+selector: "suite:",
+protocol: 'accessing',
+fn: function (aCollection){
+var self=this;
+self["@suite"]=aCollection;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "suite: aCollection\x0a\x09suite := aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TestSuiteRunner);
+
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.TestSuiteRunner.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.TestSuiteRunner.klass);
+
+$core.addMethod(
+$core.method({
+selector: "on:",
+protocol: 'instance creation',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.TestSuiteRunner.klass.superclass.fn.prototype._new.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=$recv($2)._suite_(aCollection);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"on:",{aCollection:aCollection},$globals.TestSuiteRunner.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "on: aCollection\x0a\x09^ super new suite: aCollection",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["suite:", "new"]
+}),
+$globals.TestSuiteRunner.klass);
+
+$core.addMethod(
+$core.method({
+selector: "isTestClass",
+protocol: '*SUnit',
+fn: function (){
+var self=this;
+function $TestCase(){return $globals.TestCase||(typeof TestCase=="undefined"?nil:TestCase)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._includesBehavior_($TestCase()))._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(self._isAbstract())._not();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isTestClass",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTestClass\x0a\x09^(self includesBehavior: TestCase) and: [ \x0a\x09\x09\x09self isAbstract not ]",
+referencedClasses: ["TestCase"],
+//>>excludeEnd("ide");
+messageSends: ["and:", "includesBehavior:", "not", "isAbstract"]
+}),
+$globals.Behavior);
+
+$core.addMethod(
+$core.method({
+selector: "isTestPackage",
+protocol: '*SUnit',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._classes())._anySatisfy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(each)._isTestClass();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isTestPackage",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isTestPackage\x0a\x09^ self classes anySatisfy: [ :each | each isTestClass ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["anySatisfy:", "classes", "isTestClass"]
+}),
+$globals.Package);
+
+});

+ 458 - 0
bower_components/amber/src/SUnit.st

@@ -0,0 +1,458 @@
+Smalltalk createPackage: 'SUnit'!
+Object subclass: #ResultAnnouncement
+	instanceVariableNames: 'result'
+	package: 'SUnit'!
+!ResultAnnouncement commentStamp!
+I get signaled when a `TestCase` has been run.
+
+My instances hold the result (instance of `TestResult`) of the test run.!
+
+!ResultAnnouncement methodsFor: 'accessing'!
+
+result
+	^ result
+!
+
+result: aTestResult
+	result := aTestResult
+! !
+
+Object subclass: #TestCase
+	instanceVariableNames: 'testSelector asyncTimeout context'
+	package: 'SUnit'!
+!TestCase commentStamp!
+I am an implementation of the command pattern to run a test.
+
+## API
+
+My instances are created with the class method `#selector:`,
+passing the symbol that names the method to be executed when the test case runs.
+
+When you discover a new fixture, subclass `TestCase` and create a `#test...` method for the first test.
+As that method develops and more `#test...` methods are added, you will find yourself refactoring temps
+into instance variables for the objects in the fixture and overriding `#setUp` to initialize these variables.
+As required, override `#tearDown` to nil references, release objects and deallocate.!
+
+!TestCase methodsFor: 'accessing'!
+
+context: aRunningTestContext
+	context := aRunningTestContext
+!
+
+selector
+	^ testSelector
+!
+
+setTestSelector: aSelector
+	testSelector := aSelector
+! !
+
+!TestCase methodsFor: 'async'!
+
+async: aBlock
+	| c |
+	self errorIfNotAsync: '#async'.
+	c := context.
+	^ [ self isAsync ifTrue: [ c execute: aBlock ] ]
+!
+
+finished
+	self errorIfNotAsync: '#finished'.
+	asyncTimeout := nil
+!
+
+timeout: aNumber
+	"Set a grace time timeout in milliseconds to run the test asynchronously"
+	
+	asyncTimeout ifNotNil: [ asyncTimeout clearTimeout ].
+	
+	"to allow #async: message send without throwing an error"
+	asyncTimeout := 0.
+	
+	asyncTimeout := (self async: [
+		self assert: false description: 'SUnit grace time exhausted' ])
+			valueWithTimeout: aNumber
+! !
+
+!TestCase methodsFor: 'error handling'!
+
+errorIfNotAsync: aString
+	self isAsync ifFalse: [
+		self error: aString, ' used without prior #timeout:' ]
+! !
+
+!TestCase methodsFor: 'private'!
+
+signalFailure: aString
+	TestFailure new
+		messageText: aString;
+		signal
+! !
+
+!TestCase methodsFor: 'running'!
+
+performTest
+	asyncTimeout := nil.
+	self perform: self selector
+!
+
+runCase
+	"Runs a test case in isolated context, leaking all errors."
+
+	(TestContext testCase: self) start
+!
+
+setUp
+!
+
+tearDown
+! !
+
+!TestCase methodsFor: 'testing'!
+
+assert: aBoolean
+	self assert: aBoolean description: 'Assertion failed'
+!
+
+assert: aBoolean description: aString
+	aBoolean ifFalse: [ self signalFailure: aString ]
+!
+
+assert: actual equals: expected
+	^ self assert: (actual = expected) description: 'Expected: ', expected printString, ' but was: ', actual printString
+!
+
+deny: aBoolean
+	self assert: aBoolean not
+!
+
+isAsync
+	^ asyncTimeout notNil
+!
+
+should: aBlock
+	self assert: aBlock value
+!
+
+should: aBlock raise: anExceptionClass
+	self assert: ([ aBlock value. false ]
+		on: anExceptionClass
+		do: [ :ex | true ])
+!
+
+shouldnt: aBlock raise: anExceptionClass
+	self assert: ([ aBlock value. true ]
+		on: anExceptionClass
+		do: [ :ex | false ])
+! !
+
+!TestCase class methodsFor: 'accessing'!
+
+allTestSelectors
+	| selectors |
+	selectors := self testSelectors.
+	self shouldInheritSelectors ifTrue: [
+		selectors addAll: self superclass allTestSelectors ].
+	^ selectors
+!
+
+buildSuite
+	^ self allTestSelectors collect: [ :each | self selector: each ]
+!
+
+lookupHierarchyRoot
+	^ TestCase
+!
+
+selector: aSelector
+	^ self new
+		setTestSelector: aSelector;
+		yourself
+!
+
+testSelectors
+	^ self methodDictionary keys select: [ :each | each match: '^test' ]
+! !
+
+!TestCase class methodsFor: 'helios'!
+
+heliosClass
+	^ 'test'
+! !
+
+!TestCase class methodsFor: 'testing'!
+
+isAbstract
+	^ self name = 'TestCase'
+!
+
+shouldInheritSelectors
+	^ self ~= self lookupHierarchyRoot
+! !
+
+Object subclass: #TestContext
+	instanceVariableNames: 'testCase'
+	package: 'SUnit'!
+!TestContext commentStamp!
+I govern running a particular test case.
+
+My main added value is `#execute:` method which runs a block as a part of test case (restores context, nilling it afterwards, cleaning/calling `#tearDown` as appropriate for sync/async scenario).!
+
+!TestContext methodsFor: 'accessing'!
+
+testCase: aTestCase
+	testCase := aTestCase
+! !
+
+!TestContext methodsFor: 'running'!
+
+execute: aBlock
+	| failed |
+	
+	testCase context: self.
+	[
+		failed := true.
+		aBlock value.
+		failed := false
+	]
+		ensure: [
+			testCase context: nil.
+			
+			(failed and: [ testCase isAsync ]) ifTrue: [
+				testCase finished ].
+			testCase isAsync ifFalse: [
+				testCase tearDown ] ]
+!
+
+start
+	self execute: [
+		testCase setUp.
+		testCase performTest ]
+! !
+
+!TestContext class methodsFor: 'instance creation'!
+
+testCase: aTestCase
+	^ self new
+		testCase: aTestCase;
+		yourself
+! !
+
+TestContext subclass: #ReportingTestContext
+	instanceVariableNames: 'finished result'
+	package: 'SUnit'!
+!ReportingTestContext commentStamp!
+I add `TestResult` reporting to `TestContext`.
+
+Errors are caught and save into a `TestResult`,
+When test case is finished (which can be later for async tests), a callback block is executed; this is used by a `TestSuiteRunner`.!
+
+!ReportingTestContext methodsFor: 'accessing'!
+
+finished: aBlock
+	finished := aBlock
+!
+
+result: aTestResult
+	result := aTestResult
+! !
+
+!ReportingTestContext methodsFor: 'private'!
+
+withErrorReporting: aBlock
+	[ aBlock
+		on: TestFailure
+		do: [ :ex | result addFailure: testCase ]
+	]
+		on: Error
+		do: [ :ex | result addError: testCase ]
+! !
+
+!ReportingTestContext methodsFor: 'running'!
+
+execute: aBlock
+	[
+		self withErrorReporting: [ super execute: aBlock ]
+	]
+		ensure: [
+			testCase isAsync ifFalse: [
+				result increaseRuns. finished value ] ]
+! !
+
+!ReportingTestContext class methodsFor: 'instance creation'!
+
+testCase: aTestCase result: aTestResult finished: aBlock
+	^ (super testCase: aTestCase)
+		result: aTestResult;
+		finished: aBlock;
+		yourself
+! !
+
+Error subclass: #TestFailure
+	instanceVariableNames: ''
+	package: 'SUnit'!
+!TestFailure commentStamp!
+I am raised when the boolean parameter of an #`assert:` or `#deny:` call is the opposite of what the assertion claims.
+
+The test framework distinguishes between failures and errors.
+A failure is an event whose possibiity is explicitly anticipated and checked for in an assertion,
+whereas an error is an unanticipated problem like a division by 0 or an index out of bounds.!
+
+Object subclass: #TestResult
+	instanceVariableNames: 'timestamp runs errors failures total'
+	package: 'SUnit'!
+!TestResult commentStamp!
+I implement the collecting parameter pattern for running a bunch of tests.
+
+My instances hold tests that have run, sorted into the result categories of passed, failures and errors.
+
+`TestResult` is an interesting object to subclass or substitute. `#runCase:` is the external protocol you need to reproduce!
+
+!TestResult methodsFor: 'accessing'!
+
+addError: anError
+	self errors add: anError
+!
+
+addFailure: aFailure
+	self failures add: aFailure
+!
+
+errors
+	^ errors
+!
+
+failures
+	^ failures
+!
+
+increaseRuns
+	runs := runs + 1
+!
+
+runs
+	^ runs
+!
+
+status
+	^ self errors isEmpty
+		ifTrue: [
+			self failures isEmpty
+				ifTrue: [ 'success' ]
+				ifFalse: [ 'failure' ]]
+		ifFalse: [ 'error' ]
+!
+
+timestamp
+	^ timestamp
+!
+
+total
+	^ total
+!
+
+total: aNumber
+	total := aNumber
+! !
+
+!TestResult methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	timestamp := Date now.
+	runs := 0.
+	errors := Array new.
+	failures := Array new.
+	total := 0
+! !
+
+!TestResult methodsFor: 'running'!
+
+nextRunDo: aBlock
+	"Runs aBlock with index of next run or does nothing if no more runs"
+	^ self runs == self total
+		ifFalse: [ aBlock value: self runs + 1 ]
+!
+
+runCase: aTestCase
+	[ [ self increaseRuns.
+		aTestCase runCase ]
+	on: TestFailure do: [ :ex | self addFailure: aTestCase ]]
+	on: Error do: [ :ex | self addError: aTestCase ]
+! !
+
+Object subclass: #TestSuiteRunner
+	instanceVariableNames: 'suite result announcer runNextTest'
+	package: 'SUnit'!
+!TestSuiteRunner commentStamp!
+I am responsible for running a collection (`suite`) of tests.
+
+## API
+
+Instances should be created using the class-side `#on:` method, taking a collection of tests to run as parameter.
+To run the test suite, use `#run`.!
+
+!TestSuiteRunner methodsFor: 'accessing'!
+
+announcer
+	^ announcer
+!
+
+result
+	^ result
+!
+
+suite: aCollection
+	suite := aCollection
+! !
+
+!TestSuiteRunner methodsFor: 'actions'!
+
+resume
+	runNextTest fork.
+	announcer announce: (ResultAnnouncement new result: result)
+!
+
+run
+	result total: suite size.
+	self resume
+! !
+
+!TestSuiteRunner methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	announcer := Announcer new.
+	result := TestResult new.
+	runNextTest := [ | runs | runs := result runs. runs < result total ifTrue: [ (self contextOf: runs + 1) start ] ].
+! !
+
+!TestSuiteRunner methodsFor: 'private'!
+
+contextOf: anInteger
+	^ ReportingTestContext testCase: (suite at: anInteger) result: result finished: [ self resume ]
+! !
+
+!TestSuiteRunner class methodsFor: 'instance creation'!
+
+new
+	self shouldNotImplement
+!
+
+on: aCollection
+	^ super new suite: aCollection
+! !
+
+!Behavior methodsFor: '*SUnit'!
+
+isTestClass
+	^(self includesBehavior: TestCase) and: [ 
+			self isAbstract not ]
+! !
+
+!Package methodsFor: '*SUnit'!
+
+isTestPackage
+	^ self classes anySatisfy: [ :each | each isTestClass ]
+! !
+

+ 5765 - 0
bower_components/amber/src/Web.js

@@ -0,0 +1,5765 @@
+define("amber_core/Web", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Methods", "amber_core/Kernel-Collections"], function($boot){
+var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;
+var smalltalk=$core,_st=$recv,globals=$globals;
+$core.addPackage('Web');
+$core.packages["Web"].transport = {"type":"amd","amdNamespace":"amber_core"};
+
+$core.addClass('BrowserInterface', $globals.Object, [], 'Web');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.BrowserInterface.comment="I am platform interface class that tries to use window and jQuery; that is, one for browser environment.\x0a\x0a## API\x0a\x0a    self isAvailable. \x22true if window and jQuery exist\x22.\x0a\x0a    self alert: 'Hey, there is a problem'.\x0a    self confirm: 'Affirmative?'.\x0a    self prompt: 'Your name:'.\x0a\x0a    self ajax: #{\x0a        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'\x0a    }.";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "ajax:",
+protocol: 'actions',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(jQuery)._ajax_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ajax:",{anObject:anObject},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "ajax: anObject\x0a\x09^ jQuery ajax: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ajax:"]
+}),
+$globals.BrowserInterface);
+
+$core.addMethod(
+$core.method({
+selector: "alert:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(window)._alert_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alert:",{aString:aString},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "alert: aString\x0a\x09^ window alert: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["alert:"]
+}),
+$globals.BrowserInterface);
+
+$core.addMethod(
+$core.method({
+selector: "confirm:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(window)._confirm_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"confirm:",{aString:aString},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "confirm: aString\x0a\x09^ window confirm: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["confirm:"]
+}),
+$globals.BrowserInterface);
+
+$core.addMethod(
+$core.method({
+selector: "isAvailable",
+protocol: 'testing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return typeof window !== "undefined" && typeof jQuery !== "undefined";
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isAvailable",{},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isAvailable\x0a<return typeof window !== \x22undefined\x22 && typeof jQuery !== \x22undefined\x22>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.BrowserInterface);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:",
+protocol: 'actions',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(window)._prompt_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:",{aString:aString},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "prompt: aString\x0a\x09^ window prompt: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["prompt:"]
+}),
+$globals.BrowserInterface);
+
+$core.addMethod(
+$core.method({
+selector: "prompt:default:",
+protocol: 'actions',
+fn: function (aString,defaultString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(window)._prompt_default_(aString,defaultString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"prompt:default:",{aString:aString,defaultString:defaultString},$globals.BrowserInterface)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "defaultString"],
+source: "prompt: aString default: defaultString\x0a\x09^ window prompt: aString default: defaultString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["prompt:default:"]
+}),
+$globals.BrowserInterface);
+
+
+
+$core.addClass('HTMLCanvas', $globals.Object, ['root'], 'Web');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.HTMLCanvas.comment="I am a canvas for building HTML.\x0a\x0aI provide the `#tag:` method to create a `TagBrush` (wrapping a DOM element) and convenience methods in the `tags` protocol.\x0a\x0a## API\x0a\x0aMy instances are used as the argument of the `#renderOn:` method of `Widget` objects.\x0a\x0aThe `#with:` method is used to compose HTML, nesting tags. `#with:` can take a `TagBrush`, a `String`, a `BlockClosure` or a `Widget` as argument.\x0a\x0a## Usage example:\x0a\x0a    aCanvas a \x0a        with: [ aCanvas span with: 'click me' ];\x0a        onClick: [ window alert: 'clicked!' ]";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "a",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("a");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"a",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "a\x0a\x09^ self tag: 'a'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "abbr",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("abbr");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"abbr",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "abbr\x0a\x09^ self tag: 'abbr'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "address",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("address");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"address",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "address\x0a\x09^ self tag: 'address'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "area",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("area");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"area",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "area\x0a\x09^ self tag: 'area'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "article",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("article");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"article",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "article\x0a\x09^ self tag: 'article'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "aside",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("aside");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"aside",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "aside\x0a\x09^ self tag: 'aside'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "audio",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("audio");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"audio",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "audio\x0a\x09^ self tag: 'audio'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "base",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("base");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"base",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "base\x0a\x09^ self tag: 'base'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "blockquote",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("blockquote");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"blockquote",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "blockquote\x0a\x09^ self tag: 'blockquote'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "body",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("body");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"body",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "body\x0a\x09^ self tag: 'body'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "br",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("br");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"br",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "br\x0a\x09^ self tag: 'br'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "button",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("button");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"button",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "button\x0a\x09^ self tag: 'button'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "canvas",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("canvas");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"canvas",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "canvas\x0a\x09^ self tag: 'canvas'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "caption",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("caption");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"caption",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "caption\x0a\x09^ self tag: 'caption'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "cite",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("cite");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cite",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "cite\x0a\x09^ self tag: 'cite'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "code",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("code");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"code",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "code\x0a\x09^ self tag: 'code'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "col",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("col");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"col",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "col\x0a\x09^ self tag: 'col'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "colgroup",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("colgroup");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"colgroup",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "colgroup\x0a\x09^ self tag: 'colgroup'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "command",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("command");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"command",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "command\x0a\x09^ self tag: 'command'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "datalist",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("datalist");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"datalist",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "datalist\x0a\x09^ self tag: 'datalist'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "dd",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("dd");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dd",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "dd\x0a\x09^ self tag: 'dd'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "del",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("del");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"del",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "del\x0a\x09^ self tag: 'del'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "details",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("details");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"details",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "details\x0a\x09^ self tag: 'details'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "div",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("div");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"div",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "div\x0a\x09^ self tag: 'div'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "div:",
+protocol: 'tags',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._div())._with_(aBlock);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"div:",{aBlock:aBlock},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "div: aBlock\x0a\x09^ self div with: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "div"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "dl",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("dl");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dl",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "dl\x0a\x09^ self tag: 'dl'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "dt",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("dt");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"dt",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "dt\x0a\x09^ self tag: 'dt'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "em",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("em");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"em",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "em\x0a\x09^ self tag: 'em'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "embed",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("embed");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"embed",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "embed\x0a\x09^ self tag: 'embed'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "entity:",
+protocol: 'adding',
+fn: function (aString){
+var self=this;
+var result;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$4,$3,$1,$5;
+$2="<span />"._asJQuery();
+$4="&".__comma(aString);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(";");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$1=$recv($2)._html_($3);
+result=$recv($1)._text();
+$5=$recv($recv(result)._size()).__eq((1));
+if(!$core.assert($5)){
+self._error_("Not an HTML entity: ".__comma(aString));
+};
+self._with_(result);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"entity:",{aString:aString,result:result},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "entity: aString\x0a\x09\x22Adds a character representing html entity, eg.\x0a\x09html entity: 'copy'\x0a\x09adds a copyright sign.\x0a\x09If a name does not represent valid HTML entity, error is raised.\x22\x0a\x09| result |\x0a\x09result := ('<span />' asJQuery html: '&', aString, ';') text.\x0a\x09result size = 1 ifFalse: [ self error: 'Not an HTML entity: ', aString ].\x0a\x09self with: result",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["text", "html:", "asJQuery", ",", "ifFalse:", "=", "size", "error:", "with:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "fieldset",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("fieldset");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fieldset",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "fieldset\x0a\x09^ self tag: 'fieldset'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "figcaption",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("figcaption");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"figcaption",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "figcaption\x0a\x09^ self tag: 'figcaption'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "figure",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("figure");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"figure",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "figure\x0a\x09^ self tag: 'figure'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "footer",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("footer");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"footer",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "footer\x0a\x09^ self tag: 'footer'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "form",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("form");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"form",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "form\x0a\x09^ self tag: 'form'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h1",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h1");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h1",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h1\x0a\x09^ self tag: 'h1'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h1:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h1())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h1:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h1: anObject\x0a\x09^ self h1 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h1"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h2",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h2");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h2",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h2\x0a\x09^ self tag: 'h2'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h2:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h2())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h2:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h2: anObject\x0a\x09^ self h2 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h2"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h3",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h3");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h3",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h3\x0a\x09^ self tag: 'h3'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h3:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h3())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h3:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h3: anObject\x0a\x09^ self h3 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h3"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h4",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h4");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h4",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h4\x0a\x09^ self tag: 'h4'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h4:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h4())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h4:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h4: anObject\x0a\x09^ self h4 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h4"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h5",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h5");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h5",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h5\x0a\x09^ self tag: 'h5'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h5:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h5())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h5:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h5: anObject\x0a\x09^ self h5 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h5"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h6",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("h6");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h6",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "h6\x0a\x09^ self tag: 'h6'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "h6:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._h6())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"h6:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "h6: anObject\x0a\x09^ self h6 with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "h6"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "head",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("head");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"head",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "head\x0a\x09^ self tag: 'head'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "header",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("header");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"header",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "header\x0a\x09^ self tag: 'header'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "hgroup",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("hgroup");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hgroup",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hgroup\x0a\x09^ self tag: 'hgroup'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "hr",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("hr");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hr",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hr\x0a\x09^ self tag: 'hr'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "html",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("html");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"html",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "html\x0a\x09^ self tag: 'html'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "iframe",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("iframe");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"iframe",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "iframe\x0a\x09^ self tag: 'iframe'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "iframe:",
+protocol: 'tags',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._iframe())._src_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"iframe:",{aString:aString},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "iframe: aString\x0a\x09^ self iframe src: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["src:", "iframe"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "img",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("img");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"img",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "img\x0a\x09^ self tag: 'img'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "img:",
+protocol: 'tags',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._img())._src_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"img:",{aString:aString},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "img: aString\x0a\x09^ self img src: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["src:", "img"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+function $TagBrush(){return $globals.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$receiver;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.HTMLCanvas.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=self["@root"];
+if(($receiver = $1) == null || $receiver.isNil){
+self["@root"]=$recv($TagBrush())._fromString_canvas_("div",self);
+self["@root"];
+} else {
+$1;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09root ifNil: [ root := TagBrush fromString: 'div' canvas: self ]",
+referencedClasses: ["TagBrush"],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "ifNil:", "fromString:canvas:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "initializeFromJQuery:",
+protocol: 'initialization',
+fn: function (aJQuery){
+var self=this;
+function $TagBrush(){return $globals.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@root"]=$recv($TagBrush())._fromJQuery_canvas_(aJQuery,self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:",{aJQuery:aJQuery},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "initializeFromJQuery: aJQuery\x0a\x09root := TagBrush fromJQuery: aJQuery canvas: self",
+referencedClasses: ["TagBrush"],
+//>>excludeEnd("ide");
+messageSends: ["fromJQuery:canvas:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "input",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("input");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"input",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "input\x0a\x09^ self tag: 'input'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "label",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("label");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"label",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "label\x0a\x09^ self tag: 'label'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "legend",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("legend");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"legend",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "legend\x0a\x09^ self tag: 'legend'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "li",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("li");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"li",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "li\x0a\x09^ self tag: 'li'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "li:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._li())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"li:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "li: anObject\x0a\x09^ self li with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "li"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "link",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("link");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"link",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "link\x0a\x09^ self tag: 'link'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "map",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("map");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"map",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "map\x0a\x09^ self tag: 'map'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "mark",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("mark");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"mark",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "mark\x0a\x09^ self tag: 'mark'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "menu",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("menu");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"menu",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "menu\x0a\x09^ self tag: 'menu'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "meta",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("meta");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"meta",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "meta\x0a\x09^ self tag: 'meta'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "nav",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("nav");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"nav",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "nav\x0a\x09^ self tag: 'nav'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "newTag:",
+protocol: 'tags',
+fn: function (aString){
+var self=this;
+function $TagBrush(){return $globals.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($TagBrush())._fromString_canvas_(aString,self);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"newTag:",{aString:aString},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "newTag: aString\x0a\x09^ TagBrush fromString: aString canvas: self",
+referencedClasses: ["TagBrush"],
+//>>excludeEnd("ide");
+messageSends: ["fromString:canvas:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "noscript",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("noscript");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"noscript",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "noscript\x0a\x09^ self tag: 'noscript'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "object",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("object");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"object",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "object\x0a\x09^ self tag: 'object'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "ol",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("ol");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ol",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ol\x0a\x09^ self tag: 'ol'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "ol:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._ol())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ol:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "ol: anObject\x0a\x09^ self ol with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "ol"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "optgroup",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("optgroup");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"optgroup",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "optgroup\x0a\x09^ self tag: 'optgroup'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "option",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("option");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"option",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "option\x0a\x09^ self tag: 'option'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "output",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("output");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"output",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "output\x0a\x09^ self tag: 'output'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "p",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("p");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"p",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "p\x0a\x09^ self tag: 'p'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "p:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._p())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"p:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "p: anObject\x0a\x09^ self p with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "p"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "param",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("param");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"param",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "param\x0a\x09^ self tag: 'param'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "pre",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("pre");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"pre",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "pre\x0a\x09^ self tag: 'pre'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "progress",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("progress");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"progress",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "progress\x0a\x09^ self tag: 'progress'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "root",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@root"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "root\x0a\x09^ root",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "root:",
+protocol: 'accessing',
+fn: function (aTagBrush){
+var self=this;
+self["@root"]=aTagBrush;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "root: aTagBrush\x0a\x09root := aTagBrush",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "script",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("script");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"script",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "script\x0a\x09^ self tag: 'script'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "section",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("section");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"section",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "section\x0a\x09^ self tag: 'section'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "select",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("select");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"select",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "select\x0a\x09^ self tag: 'select'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "small",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("small");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"small",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "small\x0a\x09^ self tag: 'small'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "snippet:",
+protocol: 'accessing',
+fn: function (anElement){
+var self=this;
+var clone,caret;
+function $TagBrush(){return $globals.TagBrush||(typeof TagBrush=="undefined"?nil:TagBrush)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3;
+clone=$recv($recv(anElement)._asJQuery())._clone();
+$1=$recv($TagBrush())._fromJQuery_canvas_(clone,self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["fromJQuery:canvas:"]=1;
+//>>excludeEnd("ctx");
+self._with_($1);
+caret=$recv(clone)._find_("[data-snippet=\x22*\x22]");
+$2=$recv($recv(caret)._toArray())._isEmpty();
+if($core.assert($2)){
+caret=clone;
+caret;
+};
+$3=$recv($TagBrush())._fromJQuery_canvas_($recv(caret)._removeAttr_("data-snippet"),self);
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippet:",{anElement:anElement,clone:clone,caret:caret},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anElement"],
+source: "snippet: anElement\x0a\x09\x22Adds clone of anElement, finds [data-snippet=\x22\x22*\x22\x22] subelement\x0a\x09and returns TagBrush as if that subelement was just added.\x0a\x09\x0a\x09Rarely needed to use directly, use `html foo` dynamically installed method\x0a\x09for a snippet named foo.\x22\x0a\x09\x0a\x09| clone caret |\x0a\x09\x0a\x09clone := anElement asJQuery clone.\x0a\x09self with: (TagBrush fromJQuery: clone canvas: self).\x0a\x09caret := clone find: '[data-snippet=\x22*\x22]'.\x0a\x09caret toArray isEmpty ifTrue: [ caret := clone ].\x0a\x09^ TagBrush fromJQuery: (caret removeAttr: 'data-snippet') canvas: self",
+referencedClasses: ["TagBrush"],
+//>>excludeEnd("ide");
+messageSends: ["clone", "asJQuery", "with:", "fromJQuery:canvas:", "find:", "ifTrue:", "isEmpty", "toArray", "removeAttr:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "source",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("source");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"source",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "source\x0a\x09^ self tag: 'source'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "span",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("span");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"span",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "span\x0a\x09^ self tag: 'span'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "span:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._span())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"span:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "span: anObject\x0a\x09^ self span with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "span"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "strong",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("strong");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"strong",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "strong\x0a\x09^ self tag: 'strong'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "strong:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._strong())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"strong:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "strong: anObject\x0a\x09^ self strong with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "strong"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "style",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("style");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"style",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "style\x0a\x09^ self tag: 'style'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "style:",
+protocol: 'tags',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._style();
+$recv($2)._with_(aString);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"style:",{aString:aString},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "style: aString\x0a\x09^ self style with: aString; yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "style", "yourself"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "sub",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("sub");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sub",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sub\x0a\x09^ self tag: 'sub'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "summary",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("summary");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"summary",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "summary\x0a\x09^ self tag: 'summary'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "sup",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("sup");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sup",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sup\x0a\x09^ self tag: 'sup'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "table",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("table");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"table",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "table\x0a\x09^ self tag: 'table'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "tag:",
+protocol: 'tags',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self["@root"])._addBrush_(self._newTag_(aString));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tag:",{aString:aString},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "tag: aString\x0a\x09^ root addBrush: (self newTag: aString)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addBrush:", "newTag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "tbody",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("tbody");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tbody",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tbody\x0a\x09^ self tag: 'tbody'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "td",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("td");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"td",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "td\x0a\x09^ self tag: 'td'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "textarea",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("textarea");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"textarea",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "textarea\x0a\x09^ self tag: 'textarea'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "tfoot",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("tfoot");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tfoot",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tfoot\x0a\x09^ self tag: 'tfoot'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "th",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("th");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"th",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "th\x0a\x09^ self tag: 'th'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "thead",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("thead");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"thead",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "thead\x0a\x09^ self tag: 'thead'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "time",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("time");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"time",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "time\x0a\x09^ self tag: 'time'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "title",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("title");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"title",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "title\x0a\x09^ self tag: 'title'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "tr",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("tr");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tr",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "tr\x0a\x09^ self tag: 'tr'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "ul",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("ul");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ul",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ul\x0a\x09^ self tag: 'ul'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "ul:",
+protocol: 'tags',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._ul())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ul:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "ul: anObject\x0a\x09^ self ul with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "ul"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "video",
+protocol: 'tags',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._tag_("video");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"video",{},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "video\x0a\x09^ self tag: 'video'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["tag:"]
+}),
+$globals.HTMLCanvas);
+
+$core.addMethod(
+$core.method({
+selector: "with:",
+protocol: 'adding',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._root())._with_(anObject);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},$globals.HTMLCanvas)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "with: anObject\x0a\x09^ self root with: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["with:", "root"]
+}),
+$globals.HTMLCanvas);
+
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(jQuery)._basicAt_put_("allowJavaScriptCalls",true);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.HTMLCanvas.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09\x22Allow JS method calls for the jQuery object.\x0a\x09See boot.js DNU handling.\x22\x0a\x09\x0a\x09jQuery basicAt: 'allowJavaScriptCalls' put: true",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["basicAt:put:"]
+}),
+$globals.HTMLCanvas.klass);
+
+$core.addMethod(
+$core.method({
+selector: "onJQuery:",
+protocol: 'instance creation',
+fn: function (aJQuery){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._basicNew();
+$recv($2)._initializeFromJQuery_(aJQuery);
+$recv($2)._initialize();
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onJQuery:",{aJQuery:aJQuery},$globals.HTMLCanvas.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "onJQuery: aJQuery\x0a\x09^ self basicNew\x0a\x09\x09initializeFromJQuery: aJQuery;\x0a\x09\x09initialize;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeFromJQuery:", "basicNew", "initialize", "yourself"]
+}),
+$globals.HTMLCanvas.klass);
+
+
+$core.addClass('HTMLSnippet', $globals.Object, ['snippets'], 'Web');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.HTMLSnippet.comment="My sole instance is the registry of html snippets.\x0a`HTMLSnippet current` is the public singleton instance.\x0a\x0aOn startup, it scans the document for any html elements\x0awith `'data-snippet=\x22foo\x22'` attribute and takes them off the document,\x0aremembering them in the store under the specified name.\x0aIt also install method #foo into HTMLCanvas dynamically.\x0a\x0aEvery html snippet should mark a 'caret', a place where contents\x0acan be inserted, by 'data-snippet=\x22*\x22' (a special name for caret).\x0aFor example:\x0a\x0a`<li data-snippet='menuelement' class='...'><a data-snippet='*'></a></li>`\x0a\x0adefines a list element with a link inside; the link itself is marked as a caret.\x0a\x0aYou can later issue\x0a\x0a`html menuelement href: '/foo'; with: 'A foo'`\x0a\x0ato insert the whole snippet and directly manipulate the caret, so it renders:\x0a\x0a`<li class='...'><a href='/foo'>A foo</a></li>`\x0a\x0aFor a self-careting tags (not very useful, but you do not need to fill class etc.\x0ayou can use\x0a\x0a`<div class='lots of classes' attr1='one' attr2='two' data-snippet='*bar'></div>`\x0a\x0aand in code later do:\x0a\x0a`html bar with: [ xxx ]`\x0a\x0ato render\x0a\x0a`<div class='lots of classes' attr1='one' attr2='two'>...added by xxx...</div>`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "initializeFromJQuery:",
+protocol: 'initialization',
+fn: function (aJQuery){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._snippetsFromJQuery_(aJQuery))._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return self._installSnippetFromJQuery_($recv(each)._asJQuery());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:",{aJQuery:aJQuery},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "initializeFromJQuery: aJQuery\x0a\x09\x22Finds and takes out all snippets out of aJQuery.\x0a\x09Installs it into self.\x22\x0a\x09\x0a\x09(self snippetsFromJQuery: aJQuery) do: [ :each |\x0a\x09\x09self installSnippetFromJQuery: each asJQuery ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "snippetsFromJQuery:", "installSnippetFromJQuery:", "asJQuery"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "installSnippetFromJQuery:",
+protocol: 'snippet installation',
+fn: function (element){
+var self=this;
+var name;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2;
+name=$recv(element)._attr_("data-snippet");
+$1=$recv(name).__eq("*");
+if(!$core.assert($1)){
+$2=$recv("^\x5c*"._asRegexp())._test_(name);
+if($core.assert($2)){
+name=$recv(name)._allButFirst();
+name;
+$recv(element)._attr_put_("data-snippet","*");
+} else {
+$recv(element)._removeAttr_("data-snippet");
+};
+self._snippetAt_install_(name,$recv($recv(element)._detach())._get_((0)));
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"installSnippetFromJQuery:",{element:element,name:name},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["element"],
+source: "installSnippetFromJQuery: element\x0a\x09| name |\x0a\x09name := element attr: 'data-snippet'.\x0a\x09name = '*' ifFalse: [\x0a\x09\x09('^\x5c*' asRegexp test: name)\x0a\x09\x09\x09ifTrue: [\x0a\x09\x09\x09\x09name := name allButFirst.\x0a\x09\x09\x09\x09element attr: 'data-snippet' put: '*' ]\x0a\x09\x09\x09ifFalse: [\x0a\x09\x09\x09\x09element removeAttr: 'data-snippet' ].\x0a\x09\x09self snippetAt: name install: (element detach get: 0) ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["attr:", "ifFalse:", "=", "ifTrue:ifFalse:", "test:", "asRegexp", "allButFirst", "attr:put:", "removeAttr:", "snippetAt:install:", "get:", "detach"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "snippetAt:",
+protocol: 'accessing',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._snippets())._at_(aString);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippetAt:",{aString:aString},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "snippetAt: aString\x0a\x09^ self snippets at: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:", "snippets"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "snippetAt:compile:",
+protocol: 'method generation',
+fn: function (aString,anElement){
+var self=this;
+function $ClassBuilder(){return $globals.ClassBuilder||(typeof ClassBuilder=="undefined"?nil:ClassBuilder)}
+function $HTMLCanvas(){return $globals.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv($recv($ClassBuilder())._new())._installMethod_forClass_protocol_($recv($recv((function(htmlReceiver){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv(htmlReceiver)._snippet_(anElement);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({htmlReceiver:htmlReceiver},$ctx1,1)});
+//>>excludeEnd("ctx");
+}))._currySelf())._asCompiledMethod_(aString),$HTMLCanvas(),"**snippets");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippetAt:compile:",{aString:aString,anElement:anElement},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anElement"],
+source: "snippetAt: aString compile: anElement\x0a\x09\x22Method generation for the snippet.\x0a\x09The selector is aString, the method block uses anElement\x22\x0a\x09\x0a\x09ClassBuilder new\x0a\x09\x09installMethod: ([ :htmlReceiver | htmlReceiver snippet: anElement ]\x0a\x09\x09\x09currySelf asCompiledMethod: aString)\x0a\x09\x09forClass: HTMLCanvas\x0a\x09\x09protocol: '**snippets'",
+referencedClasses: ["ClassBuilder", "HTMLCanvas"],
+//>>excludeEnd("ide");
+messageSends: ["installMethod:forClass:protocol:", "new", "asCompiledMethod:", "currySelf", "snippet:"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "snippetAt:install:",
+protocol: 'snippet installation',
+fn: function (aString,anElement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._snippets())._at_put_(aString,anElement);
+self._snippetAt_compile_(aString,anElement);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippetAt:install:",{aString:aString,anElement:anElement},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anElement"],
+source: "snippetAt: aString install: anElement\x0a\x09self snippets at: aString put: anElement.\x0a\x09self snippetAt: aString compile: anElement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:", "snippets", "snippetAt:compile:"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "snippets",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@snippets"];
+if(($receiver = $2) == null || $receiver.isNil){
+self["@snippets"]=$globals.HashedCollection._newFromPairs_([]);
+$1=self["@snippets"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippets",{},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "snippets\x0a\x09^ snippets ifNil: [ snippets := #{} ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:"]
+}),
+$globals.HTMLSnippet);
+
+$core.addMethod(
+$core.method({
+selector: "snippetsFromJQuery:",
+protocol: 'private',
+fn: function (aJQuery){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv(aJQuery)._find_("[data-snippet]"))._toArray();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"snippetsFromJQuery:",{aJQuery:aJQuery},$globals.HTMLSnippet)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "snippetsFromJQuery: aJQuery\x0a\x09^ (aJQuery find: '[data-snippet]') toArray",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["toArray", "find:"]
+}),
+$globals.HTMLSnippet);
+
+
+$globals.HTMLSnippet.klass.iVarNames = ['current'];
+$core.addMethod(
+$core.method({
+selector: "current",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@current"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "current\x0a\x09^ current",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HTMLSnippet.klass);
+
+$core.addMethod(
+$core.method({
+selector: "ensureCurrent",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$3,$receiver;
+$1=self["@current"];
+if(($receiver = $1) == null || $receiver.isNil){
+$2=(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.HTMLSnippet.klass.superclass.fn.prototype._new.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$recv($2)._initializeFromJQuery_($recv(document)._asJQuery());
+$3=$recv($2)._yourself();
+self["@current"]=$3;
+self["@current"];
+} else {
+$1;
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"ensureCurrent",{},$globals.HTMLSnippet.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "ensureCurrent\x0a\x09current ifNil: [\x0a\x09\x09current := super new\x0a\x09\x09\x09initializeFromJQuery: document asJQuery;\x0a\x09\x09\x09yourself ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "initializeFromJQuery:", "new", "asJQuery", "yourself"]
+}),
+$globals.HTMLSnippet.klass);
+
+$core.addMethod(
+$core.method({
+selector: "initialize",
+protocol: 'initialization',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+(
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = true, 
+//>>excludeEnd("ctx");
+$globals.HTMLSnippet.klass.superclass.fn.prototype._initialize.apply($recv(self), []));
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.supercall = false;
+//>>excludeEnd("ctx");;
+$1=self._isDOMAvailable();
+if($core.assert($1)){
+self._ensureCurrent();
+};
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.HTMLSnippet.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09self isDOMAvailable ifTrue: [\x0a\x09\x09self ensureCurrent ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initialize", "ifTrue:", "isDOMAvailable", "ensureCurrent"]
+}),
+$globals.HTMLSnippet.klass);
+
+$core.addMethod(
+$core.method({
+selector: "isDOMAvailable",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+ return typeof document !== 'undefined' ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"isDOMAvailable",{},$globals.HTMLSnippet.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "isDOMAvailable\x0a\x09< return typeof document !== 'undefined' >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.HTMLSnippet.klass);
+
+$core.addMethod(
+$core.method({
+selector: "new",
+protocol: 'instance creation',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._shouldNotImplement();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"new",{},$globals.HTMLSnippet.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "new\x0a\x09self shouldNotImplement",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["shouldNotImplement"]
+}),
+$globals.HTMLSnippet.klass);
+
+
+$core.addClass('TagBrush', $globals.Object, ['canvas', 'element'], 'Web');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.TagBrush.comment="I am a brush for building a single DOM element (which I hold onto).\x0a\x0aAll tags but `<style>` are instances of me (see the `StyleBrush` class).\x0a\x0a## API\x0a\x0a1. Nesting\x0a\x0a    Use `#with:` to nest tags. `#with:` can take aString, `TagBrush` instance, a `Widget` or block closure as parameter.\x0a\x0a    Example: `aTag with: aString with: aCanvas div`\x0a\x0a2. Events\x0a\x0a    The `events` protocol contains all methods related to events (delegating event handling to jQuery).\x0a\x0a    Example: `aTag onClick: [ window alert: 'clicked' ]`\x0a\x0a3. Attributes\x0a\x0a    The `attribute` protocol contains methods for attribute manipulation (delegating to jQuery too).\x0a\x0a    Example: `aTag at: 'value' put: 'hello world'`\x0a\x0a4. Raw access and jQuery\x0a\x0a    The `#element` method can be used to access to JavaScript DOM element object.\x0a\x0a    Example: `aTag element cssStyle`\x0a\x0a    Use `#asJQuery` to access to the receiver converted into a jQuery object.\x0a\x0a    Example: `aTag asJQuery css: 'color' value: 'red'`";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "accesskey:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("accesskey",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"accesskey:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "accesskey: aString\x0a\x09self at: 'accesskey' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "action:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("action",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"action:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "action: aString\x0a\x09self at: 'action' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "addBrush:",
+protocol: 'adding',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._appendChild_($recv(aTagBrush)._element());
+return aTagBrush;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"addBrush:",{aTagBrush:aTagBrush},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "addBrush: aTagBrush\x0a\x09self appendChild: aTagBrush element.\x0a\x09^ aTagBrush",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendChild:", "element"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "align:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("align",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"align:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "align: aString\x0a\x09self at: 'align' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "alt:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("alt",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"alt:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "alt: aString\x0a\x09self at: 'alt' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "append:",
+protocol: 'adding',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(anObject)._appendToBrush_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"append:",{anObject:anObject},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "append: anObject\x0a\x09anObject appendToBrush: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendToBrush:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "appendBlock:",
+protocol: 'adding',
+fn: function (aBlock){
+var self=this;
+var root;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+root=$recv(self["@canvas"])._root();
+$recv(self["@canvas"])._root_(self);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["root:"]=1;
+//>>excludeEnd("ctx");
+$recv(aBlock)._value_(self["@canvas"]);
+$recv(self["@canvas"])._root_(root);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendBlock:",{aBlock:aBlock,root:root},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "appendBlock: aBlock\x0a\x09| root |\x0a\x09root := canvas root.\x0a\x09canvas root: self.\x0a\x09aBlock value: canvas.\x0a\x09canvas root: root",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["root", "root:", "value:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "appendChild:",
+protocol: 'adding',
+fn: function (anElement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var element=self['@element'];
+	if (null == element.canHaveChildren || element.canHaveChildren) {
+		element.appendChild(anElement);
+	} else {
+		element.text = String(element.text) + anElement.innerHTML;
+	} ;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendChild:",{anElement:anElement},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anElement"],
+source: "appendChild: anElement\x0a\x09\x22In IE7 and IE8 appendChild fails on several node types. So we need to check\x22\x0a\x09<var element=self['@element'];\x0a\x09if (null == element.canHaveChildren || element.canHaveChildren) {\x0a\x09\x09element.appendChild(anElement);\x0a\x09} else {\x0a\x09\x09element.text = String(element.text) + anElement.innerHTML;\x0a\x09} >",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "appendDocumentFragment:",
+protocol: 'private',
+fn: function (anElement){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var element=self['@element'].appendChild(anElement["@element"]);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendDocumentFragment:",{anElement:anElement},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anElement"],
+source: "appendDocumentFragment: anElement\x0a\x09<var element=self['@element'].appendChild(anElement[\x22@element\x22])>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "appendString:",
+protocol: 'adding',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._appendChild_(self._createTextNodeFor_(aString));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendString:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "appendString: aString\x0a\x09self appendChild: (self createTextNodeFor: aString)",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendChild:", "createTextNodeFor:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "appendToBrush:",
+protocol: 'adding',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aTagBrush)._addBrush_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "appendToBrush: aTagBrush\x0a\x09aTagBrush addBrush: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["addBrush:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "asJQuery",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._element())._asJQuery();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJQuery\x0a\x09^ self element asJQuery",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asJQuery", "element"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "asJQueryInContext:",
+protocol: 'converting',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv(self._element())._asJQueryInContext_(aContext);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQueryInContext:",{aContext:aContext},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "asJQueryInContext: aContext\x0a\x09^ self element asJQueryInContext: aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asJQueryInContext:", "element"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "at:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+function $Collection(){return $globals.Collection||(typeof Collection=="undefined"?nil:Collection)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._at_ifAbsent_(aString,(function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+return $recv($recv($Collection())._new())._errorNotFound();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "at: aString\x0a\x09^ self at: aString ifAbsent: [ Collection new errorNotFound ]",
+referencedClasses: ["Collection"],
+//>>excludeEnd("ide");
+messageSends: ["at:ifAbsent:", "errorNotFound", "new"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "at:ifAbsent:",
+protocol: 'attributes',
+fn: function (aString,aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self['@element'].hasAttribute(aString) ? self['@element'].getAttribute(aString) : aBlock._value();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aString:aString,aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aBlock"],
+source: "at: aString ifAbsent: aBlock\x0a\x09<return self['@element'].hasAttribute(aString) ? self['@element'].getAttribute(aString) : aBlock._value()>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "at:put:",
+protocol: 'attributes',
+fn: function (aString,aValue){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self['@element'].setAttribute(aString, aValue); return aValue;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"at:put:",{aString:aString,aValue:aValue},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aValue"],
+source: "at: aString put: aValue\x0a\x09<self['@element'].setAttribute(aString, aValue); return aValue>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "class:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self['@element'].className = aString;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"class:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "class: aString\x0a\x09<self['@element'].className = aString>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "cols:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("cols",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"cols:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "cols: aString\x0a\x09self at: 'cols' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "contenteditable:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("contenteditable",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contenteditable:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "contenteditable: aString\x0a\x09self at: 'contenteditable' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "contents:",
+protocol: 'adding',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+self._empty();
+$1=self._append_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contents:",{anObject:anObject},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "contents: anObject\x0a\x09self\x0a\x09empty;\x0a\x09append: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["empty", "append:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "contextmenu:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("contextmenu",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"contextmenu:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "contextmenu: aString\x0a\x09self at: 'contextmenu' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "createElementFor:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return document.createElement(String(aString));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"createElementFor:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "createElementFor: aString\x0a\x09<return document.createElement(String(aString))>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "createTextNodeFor:",
+protocol: 'private',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return document.createTextNode(String(aString));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"createTextNodeFor:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "createTextNodeFor: aString\x0a\x09<return document.createTextNode(String(aString))>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "draggable:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("draggable",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"draggable:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "draggable: aString\x0a\x09self at: 'draggable' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "element",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+var $1;
+$1=self["@element"];
+return $1;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "element\x0a\x09^ element",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "empty",
+protocol: 'adding',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._empty();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"empty",{},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "empty\x0a\x09self asJQuery empty",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["empty", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "for:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("for",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"for:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "for: aString\x0a\x09self at: 'for' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "height:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("height",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"height:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "height: aString\x0a\x09self at: 'height' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "hidden",
+protocol: 'attributes',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("hidden","hidden");
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"hidden",{},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "hidden\x0a\x09self at: 'hidden' put: 'hidden'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "href:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("href",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"href:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "href: aString\x0a\x09self at: 'href' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "id:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("id",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"id:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "id: aString\x0a\x09self at: 'id' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "initializeFromJQuery:canvas:",
+protocol: 'initialization',
+fn: function (aJQuery,aCanvas){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@element"]=$recv(aJQuery)._get_((0));
+self["@canvas"]=aCanvas;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeFromJQuery:canvas:",{aJQuery:aJQuery,aCanvas:aCanvas},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery", "aCanvas"],
+source: "initializeFromJQuery: aJQuery canvas: aCanvas\x0a\x09element := aJQuery get: 0.\x0a\x09canvas := aCanvas",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["get:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "initializeFromString:canvas:",
+protocol: 'initialization',
+fn: function (aString,aCanvas){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self["@element"]=self._createElementFor_(aString);
+self["@canvas"]=aCanvas;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"initializeFromString:canvas:",{aString:aString,aCanvas:aCanvas},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aCanvas"],
+source: "initializeFromString: aString canvas: aCanvas\x0a\x09element := self createElementFor: aString.\x0a\x09canvas := aCanvas",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["createElementFor:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "media:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("media",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"media:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "media: aString\x0a\x09self at: 'media' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "method:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("method",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"method:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "method: aString\x0a\x09self at: 'method' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "name:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("name",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"name:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "name: aString\x0a\x09self at: 'name' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onBlur:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("blur",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onBlur:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onBlur: aBlock\x0a\x09self asJQuery bind: 'blur' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onChange:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("change",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onChange:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onChange: aBlock\x0a\x09self asJQuery bind: 'change' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onClick:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("click",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onClick:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onClick: aBlock\x0a\x09self asJQuery bind: 'click' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onDblClick:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("dblclick",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onDblClick:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onDblClick: aBlock\x0a\x09self asJQuery bind: 'dblclick' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onFocus:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("focus",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onFocus:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onFocus: aBlock\x0a\x09self asJQuery bind: 'focus' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onFocusIn:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("focusin",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onFocusIn:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onFocusIn: aBlock\x0a\x09self asJQuery bind: 'focusin' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onFocusOut:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("focusout",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onFocusOut:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onFocusOut: aBlock\x0a\x09self asJQuery bind: 'focusout' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onHover:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("hover",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onHover:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onHover: aBlock\x0a\x09self asJQuery bind: 'hover' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onKeyDown:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("keydown",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onKeyDown:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onKeyDown: aBlock\x0a\x09self asJQuery bind: 'keydown' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onKeyPress:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("keypress",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onKeyPress:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onKeyPress: aBlock\x0a\x09self asJQuery bind: 'keypress' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onKeyUp:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("keyup",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onKeyUp:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onKeyUp: aBlock\x0a\x09self asJQuery bind: 'keyup' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseDown:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mousedown",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseDown:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseDown: aBlock\x0a\x09self asJQuery bind: 'mousedown' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseEnter:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mouseenter",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseEnter:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseEnter: aBlock\x0a\x09self asJQuery bind: 'mouseenter' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseLeave:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mouseleave",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseLeave:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseLeave: aBlock\x0a\x09self asJQuery bind: 'mouseleave' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseMove:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mousemove",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseMove:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseMove: aBlock\x0a\x09self asJQuery bind: 'mousemove' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseOut:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mouseout",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseOut:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseOut: aBlock\x0a\x09self asJQuery bind: 'mouseout' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseOver:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mouseover",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseOver:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseOver: aBlock\x0a\x09self asJQuery bind: 'mouseover' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onMouseUp:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("mouseup",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onMouseUp:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onMouseUp: aBlock\x0a\x09self asJQuery bind: 'mouseup' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onSelect:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("select",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onSelect:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onSelect: aBlock\x0a\x09self asJQuery bind: 'select' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onSubmit:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("submit",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onSubmit:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onSubmit: aBlock\x0a\x09self asJQuery bind: 'submit' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "onUnload:",
+protocol: 'events',
+fn: function (aBlock){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(self._asJQuery())._bind_do_("unload",aBlock);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"onUnload:",{aBlock:aBlock},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aBlock"],
+source: "onUnload: aBlock\x0a\x09self asJQuery bind: 'unload' do: aBlock",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["bind:do:", "asJQuery"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "placeholder:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("placeholder",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"placeholder:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "placeholder: aString\x0a\x09self at: 'placeholder' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "rel:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("rel",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"rel:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "rel: aString\x0a\x09self at: 'rel' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "removeAt:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self['@element'].removeAttribute(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"removeAt:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "removeAt: aString\x0a\x09<self['@element'].removeAttribute(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "rows:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("rows",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"rows:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "rows: aString\x0a\x09self at: 'rows' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "src:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("src",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"src:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "src: aString\x0a\x09self at: 'src' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "style:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("style",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"style:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "style: aString\x0a\x09self at: 'style' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "tabindex:",
+protocol: 'attributes',
+fn: function (aNumber){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("tabindex",aNumber);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"tabindex:",{aNumber:aNumber},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aNumber"],
+source: "tabindex: aNumber\x0a\x09self at: 'tabindex' put: aNumber",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "target:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("target",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"target:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "target: aString\x0a\x09self at: 'target' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "title:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("title",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"title:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "title: aString\x0a\x09self at: 'title' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "type:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("type",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"type:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "type: aString\x0a\x09self at: 'type' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "valign:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("valign",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"valign:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "valign: aString\x0a\x09self at: 'valign' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "value:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("value",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"value:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "value: aString\x0a\x09self at: 'value' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "width:",
+protocol: 'attributes',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._at_put_("width",aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"width:",{aString:aString},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "width: aString\x0a\x09self at: 'width' put: aString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["at:put:"]
+}),
+$globals.TagBrush);
+
+$core.addMethod(
+$core.method({
+selector: "with:",
+protocol: 'adding',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._append_(anObject);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"with:",{anObject:anObject},$globals.TagBrush)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "with: anObject\x0a\x09self append: anObject",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["append:"]
+}),
+$globals.TagBrush);
+
+
+$core.addMethod(
+$core.method({
+selector: "fromJQuery:canvas:",
+protocol: 'instance creation',
+fn: function (aJQuery,aCanvas){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._initializeFromJQuery_canvas_(aJQuery,aCanvas);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromJQuery:canvas:",{aJQuery:aJQuery,aCanvas:aCanvas},$globals.TagBrush.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery", "aCanvas"],
+source: "fromJQuery: aJQuery canvas: aCanvas\x0a\x09^ self new\x0a\x09\x09initializeFromJQuery: aJQuery canvas: aCanvas;\x0a\x09\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeFromJQuery:canvas:", "new", "yourself"]
+}),
+$globals.TagBrush.klass);
+
+$core.addMethod(
+$core.method({
+selector: "fromString:canvas:",
+protocol: 'instance creation',
+fn: function (aString,aCanvas){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$3,$1;
+$2=self._new();
+$recv($2)._initializeFromString_canvas_(aString,aCanvas);
+$3=$recv($2)._yourself();
+$1=$3;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"fromString:canvas:",{aString:aString,aCanvas:aCanvas},$globals.TagBrush.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aCanvas"],
+source: "fromString: aString canvas: aCanvas\x0a\x09^ self new\x0a\x09initializeFromString: aString canvas: aCanvas;\x0a\x09yourself",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["initializeFromString:canvas:", "new", "yourself"]
+}),
+$globals.TagBrush.klass);
+
+
+$core.addClass('Widget', $globals.InterfacingObject, [], 'Web');
+//>>excludeStart("ide", pragmas.excludeIdeData);
+$globals.Widget.comment="I am a presenter building HTML. Subclasses are typically reusable components.\x0a\x0a## API\x0a\x0aUse `#renderContentOn:` to build HTML. (See `HTMLCanvas` and `TagBrush` classes for more about building HTML).\x0a\x0aTo add a widget to the page, the convenience method `#appendToJQuery:` is very useful.\x0a\x0aExemple: \x0a\x0a    Counter new appendToJQuery: 'body' asJQuery";
+//>>excludeEnd("ide");
+$core.addMethod(
+$core.method({
+selector: "appendToBrush:",
+protocol: 'adding',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._appendToJQuery_($recv(aTagBrush)._asJQuery());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},$globals.Widget)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "appendToBrush: aTagBrush\x0a\x09self appendToJQuery: aTagBrush asJQuery",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendToJQuery:", "asJQuery"]
+}),
+$globals.Widget);
+
+$core.addMethod(
+$core.method({
+selector: "appendToJQuery:",
+protocol: 'adding',
+fn: function (aJQuery){
+var self=this;
+function $HTMLCanvas(){return $globals.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._renderOn_($recv($HTMLCanvas())._onJQuery_(aJQuery));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},$globals.Widget)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "appendToJQuery: aJQuery\x0a\x09self renderOn: (HTMLCanvas onJQuery: aJQuery)",
+referencedClasses: ["HTMLCanvas"],
+//>>excludeEnd("ide");
+messageSends: ["renderOn:", "onJQuery:"]
+}),
+$globals.Widget);
+
+$core.addMethod(
+$core.method({
+selector: "renderOn:",
+protocol: 'rendering',
+fn: function (html){
+var self=this;
+return self;
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["html"],
+source: "renderOn: html\x0a\x09self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Widget);
+
+
+$core.addMethod(
+$core.method({
+selector: "heliosClass",
+protocol: 'helios',
+fn: function (){
+var self=this;
+return "widget";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "heliosClass\x0a\x09^ 'widget'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Widget.klass);
+
+$core.addMethod(
+$core.method({
+selector: "appendToBrush:",
+protocol: '*Web',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aTagBrush)._appendBlock_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "appendToBrush: aTagBrush\x0a\x09aTagBrush appendBlock: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendBlock:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "appendToJQuery:",
+protocol: '*Web',
+fn: function (aJQuery){
+var self=this;
+function $HTMLCanvas(){return $globals.HTMLCanvas||(typeof HTMLCanvas=="undefined"?nil:HTMLCanvas)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._value_($recv($HTMLCanvas())._onJQuery_(aJQuery));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "appendToJQuery: aJQuery\x0a\x09self value: (HTMLCanvas onJQuery: aJQuery)",
+referencedClasses: ["HTMLCanvas"],
+//>>excludeEnd("ide");
+messageSends: ["value:", "onJQuery:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "asJQuery",
+protocol: '*Web',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv([self])._asJQuery();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJQuery\x0a\x09^ {self} asJQuery",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asJQuery"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "asJQueryInContext:",
+protocol: '*Web',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv([self])._asJQueryInContext_(aContext);
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQueryInContext:",{aContext:aContext},$globals.BlockClosure)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "asJQueryInContext: aContext\x0a\x09^ {self} asJQueryInContext: aContext",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["asJQueryInContext:"]
+}),
+$globals.BlockClosure);
+
+$core.addMethod(
+$core.method({
+selector: "asSnippet",
+protocol: '*Web',
+fn: function (){
+var self=this;
+function $HTMLSnippet(){return $globals.HTMLSnippet||(typeof HTMLSnippet=="undefined"?nil:HTMLSnippet)}
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=$recv($recv($HTMLSnippet())._current())._snippetAt_(self._asString());
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asSnippet",{},$globals.CharacterArray)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asSnippet\x0a\x09^ HTMLSnippet current snippetAt: self asString",
+referencedClasses: ["HTMLSnippet"],
+//>>excludeEnd("ide");
+messageSends: ["snippetAt:", "current", "asString"]
+}),
+$globals.CharacterArray);
+
+$core.addMethod(
+$core.method({
+selector: "asJQuery",
+protocol: '*Web',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(self['@jsObject']);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJQuery\x0a\x09<return jQuery(self['@jsObject'])>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "asJQueryInContext:",
+protocol: '*Web',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(self['@jsObject'], aContext);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQueryInContext:",{aContext:aContext},$globals.JSObjectProxy)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "asJQueryInContext: aContext\x0a\x09<return jQuery(self['@jsObject'], aContext)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.JSObjectProxy);
+
+$core.addMethod(
+$core.method({
+selector: "appendToBrush:",
+protocol: '*Web',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aTagBrush)._append_(self._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "appendToBrush: aTagBrush\x0a\x09aTagBrush append: self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["append:", "asString"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "appendToJQuery:",
+protocol: '*Web',
+fn: function (aJQuery){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aJQuery)._append_(self._asString());
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "appendToJQuery: aJQuery\x0a\x09aJQuery append: self asString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["append:", "asString"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "asJQuery",
+protocol: '*Web',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJQuery\x0a\x09<return jQuery(self)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "asJQueryInContext:",
+protocol: '*Web',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(self, aContext);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQueryInContext:",{aContext:aContext},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "asJQueryInContext: aContext\x0a\x09<return jQuery(self, aContext)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "postMessageTo:",
+protocol: '*Web',
+fn: function (aFrame){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$1=self._postMessageTo_origin_(aFrame,"*");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"postMessageTo:",{aFrame:aFrame},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aFrame"],
+source: "postMessageTo: aFrame\x0a^ self postMessageTo: aFrame origin: '*'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["postMessageTo:origin:"]
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "postMessageTo:origin:",
+protocol: '*Web',
+fn: function (aFrame,aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return aFrame.postMessage(self, aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"postMessageTo:origin:",{aFrame:aFrame,aString:aString},$globals.Object)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aFrame", "aString"],
+source: "postMessageTo: aFrame origin: aString\x0a<return aFrame.postMessage(self, aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Object);
+
+$core.addMethod(
+$core.method({
+selector: "appendToBrush:",
+protocol: '*Web',
+fn: function (aTagBrush){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aTagBrush)._appendString_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToBrush:",{aTagBrush:aTagBrush},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aTagBrush"],
+source: "appendToBrush: aTagBrush\x0a\x09aTagBrush appendString: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["appendString:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "appendToJQuery:",
+protocol: '*Web',
+fn: function (aJQuery){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+$recv(aJQuery)._append_(self);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"appendToJQuery:",{aJQuery:aJQuery},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aJQuery"],
+source: "appendToJQuery: aJQuery\x0a\x09aJQuery append: self",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["append:"]
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJQuery",
+protocol: '*Web',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(String(self));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQuery",{},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "asJQuery\x0a\x09<return jQuery(String(self))>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+$core.addMethod(
+$core.method({
+selector: "asJQueryInContext:",
+protocol: '*Web',
+fn: function (aContext){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return jQuery(String(self), aContext);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"asJQueryInContext:",{aContext:aContext},$globals.String)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aContext"],
+source: "asJQueryInContext: aContext\x0a\x09<return jQuery(String(self), aContext)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.String);
+
+});

+ 1181 - 0
bower_components/amber/src/Web.st

@@ -0,0 +1,1181 @@
+Smalltalk createPackage: 'Web'!
+Object subclass: #BrowserInterface
+	instanceVariableNames: ''
+	package: 'Web'!
+!BrowserInterface commentStamp!
+I am platform interface class that tries to use window and jQuery; that is, one for browser environment.
+
+## API
+
+    self isAvailable. "true if window and jQuery exist".
+
+    self alert: 'Hey, there is a problem'.
+    self confirm: 'Affirmative?'.
+    self prompt: 'Your name:'.
+
+    self ajax: #{
+        'url' -> '/patch.js'. 'type' -> 'GET'. dataType->'script'
+    }.!
+
+!BrowserInterface methodsFor: 'actions'!
+
+ajax: anObject
+	^ jQuery ajax: anObject
+!
+
+alert: aString
+	^ window alert: aString
+!
+
+confirm: aString
+	^ window confirm: aString
+!
+
+prompt: aString
+	^ window prompt: aString
+!
+
+prompt: aString default: defaultString
+	^ window prompt: aString default: defaultString
+! !
+
+!BrowserInterface methodsFor: 'testing'!
+
+isAvailable
+<return typeof window !!== "undefined" && typeof jQuery !!== "undefined">
+! !
+
+Object subclass: #HTMLCanvas
+	instanceVariableNames: 'root'
+	package: 'Web'!
+!HTMLCanvas commentStamp!
+I am a canvas for building HTML.
+
+I provide the `#tag:` method to create a `TagBrush` (wrapping a DOM element) and convenience methods in the `tags` protocol.
+
+## API
+
+My instances are used as the argument of the `#renderOn:` method of `Widget` objects.
+
+The `#with:` method is used to compose HTML, nesting tags. `#with:` can take a `TagBrush`, a `String`, a `BlockClosure` or a `Widget` as argument.
+
+## Usage example:
+
+    aCanvas a 
+        with: [ aCanvas span with: 'click me' ];
+        onClick: [ window alert: 'clicked!!' ]!
+
+!HTMLCanvas methodsFor: 'accessing'!
+
+root
+	^ root
+!
+
+root: aTagBrush
+	root := aTagBrush
+!
+
+snippet: anElement
+	"Adds clone of anElement, finds [data-snippet=""*""] subelement
+	and returns TagBrush as if that subelement was just added.
+	
+	Rarely needed to use directly, use `html foo` dynamically installed method
+	for a snippet named foo."
+	
+	| clone caret |
+	
+	clone := anElement asJQuery clone.
+	self with: (TagBrush fromJQuery: clone canvas: self).
+	caret := clone find: '[data-snippet="*"]'.
+	caret toArray isEmpty ifTrue: [ caret := clone ].
+	^ TagBrush fromJQuery: (caret removeAttr: 'data-snippet') canvas: self
+! !
+
+!HTMLCanvas methodsFor: 'adding'!
+
+entity: aString
+	"Adds a character representing html entity, eg.
+	html entity: 'copy'
+	adds a copyright sign.
+	If a name does not represent valid HTML entity, error is raised."
+	| result |
+	result := ('<span />' asJQuery html: '&', aString, ';') text.
+	result size = 1 ifFalse: [ self error: 'Not an HTML entity: ', aString ].
+	self with: result
+!
+
+with: anObject
+	^ self root with: anObject
+! !
+
+!HTMLCanvas methodsFor: 'initialization'!
+
+initialize
+	super initialize.
+	root ifNil: [ root := TagBrush fromString: 'div' canvas: self ]
+!
+
+initializeFromJQuery: aJQuery
+	root := TagBrush fromJQuery: aJQuery canvas: self
+! !
+
+!HTMLCanvas methodsFor: 'tags'!
+
+a
+	^ self tag: 'a'
+!
+
+abbr
+	^ self tag: 'abbr'
+!
+
+address
+	^ self tag: 'address'
+!
+
+area
+	^ self tag: 'area'
+!
+
+article
+	^ self tag: 'article'
+!
+
+aside
+	^ self tag: 'aside'
+!
+
+audio
+	^ self tag: 'audio'
+!
+
+base
+	^ self tag: 'base'
+!
+
+blockquote
+	^ self tag: 'blockquote'
+!
+
+body
+	^ self tag: 'body'
+!
+
+br
+	^ self tag: 'br'
+!
+
+button
+	^ self tag: 'button'
+!
+
+canvas
+	^ self tag: 'canvas'
+!
+
+caption
+	^ self tag: 'caption'
+!
+
+cite
+	^ self tag: 'cite'
+!
+
+code
+	^ self tag: 'code'
+!
+
+col
+	^ self tag: 'col'
+!
+
+colgroup
+	^ self tag: 'colgroup'
+!
+
+command
+	^ self tag: 'command'
+!
+
+datalist
+	^ self tag: 'datalist'
+!
+
+dd
+	^ self tag: 'dd'
+!
+
+del
+	^ self tag: 'del'
+!
+
+details
+	^ self tag: 'details'
+!
+
+div
+	^ self tag: 'div'
+!
+
+div: aBlock
+	^ self div with: aBlock
+!
+
+dl
+	^ self tag: 'dl'
+!
+
+dt
+	^ self tag: 'dt'
+!
+
+em
+	^ self tag: 'em'
+!
+
+embed
+	^ self tag: 'embed'
+!
+
+fieldset
+	^ self tag: 'fieldset'
+!
+
+figcaption
+	^ self tag: 'figcaption'
+!
+
+figure
+	^ self tag: 'figure'
+!
+
+footer
+	^ self tag: 'footer'
+!
+
+form
+	^ self tag: 'form'
+!
+
+h1
+	^ self tag: 'h1'
+!
+
+h1: anObject
+	^ self h1 with: anObject
+!
+
+h2
+	^ self tag: 'h2'
+!
+
+h2: anObject
+	^ self h2 with: anObject
+!
+
+h3
+	^ self tag: 'h3'
+!
+
+h3: anObject
+	^ self h3 with: anObject
+!
+
+h4
+	^ self tag: 'h4'
+!
+
+h4: anObject
+	^ self h4 with: anObject
+!
+
+h5
+	^ self tag: 'h5'
+!
+
+h5: anObject
+	^ self h5 with: anObject
+!
+
+h6
+	^ self tag: 'h6'
+!
+
+h6: anObject
+	^ self h6 with: anObject
+!
+
+head
+	^ self tag: 'head'
+!
+
+header
+	^ self tag: 'header'
+!
+
+hgroup
+	^ self tag: 'hgroup'
+!
+
+hr
+	^ self tag: 'hr'
+!
+
+html
+	^ self tag: 'html'
+!
+
+iframe
+	^ self tag: 'iframe'
+!
+
+iframe: aString
+	^ self iframe src: aString
+!
+
+img
+	^ self tag: 'img'
+!
+
+img: aString
+	^ self img src: aString
+!
+
+input
+	^ self tag: 'input'
+!
+
+label
+	^ self tag: 'label'
+!
+
+legend
+	^ self tag: 'legend'
+!
+
+li
+	^ self tag: 'li'
+!
+
+li: anObject
+	^ self li with: anObject
+!
+
+link
+	^ self tag: 'link'
+!
+
+map
+	^ self tag: 'map'
+!
+
+mark
+	^ self tag: 'mark'
+!
+
+menu
+	^ self tag: 'menu'
+!
+
+meta
+	^ self tag: 'meta'
+!
+
+nav
+	^ self tag: 'nav'
+!
+
+newTag: aString
+	^ TagBrush fromString: aString canvas: self
+!
+
+noscript
+	^ self tag: 'noscript'
+!
+
+object
+	^ self tag: 'object'
+!
+
+ol
+	^ self tag: 'ol'
+!
+
+ol: anObject
+	^ self ol with: anObject
+!
+
+optgroup
+	^ self tag: 'optgroup'
+!
+
+option
+	^ self tag: 'option'
+!
+
+output
+	^ self tag: 'output'
+!
+
+p
+	^ self tag: 'p'
+!
+
+p: anObject
+	^ self p with: anObject
+!
+
+param
+	^ self tag: 'param'
+!
+
+pre
+	^ self tag: 'pre'
+!
+
+progress
+	^ self tag: 'progress'
+!
+
+script
+	^ self tag: 'script'
+!
+
+section
+	^ self tag: 'section'
+!
+
+select
+	^ self tag: 'select'
+!
+
+small
+	^ self tag: 'small'
+!
+
+source
+	^ self tag: 'source'
+!
+
+span
+	^ self tag: 'span'
+!
+
+span: anObject
+	^ self span with: anObject
+!
+
+strong
+	^ self tag: 'strong'
+!
+
+strong: anObject
+	^ self strong with: anObject
+!
+
+style
+	^ self tag: 'style'
+!
+
+style: aString
+	^ self style with: aString; yourself
+!
+
+sub
+	^ self tag: 'sub'
+!
+
+summary
+	^ self tag: 'summary'
+!
+
+sup
+	^ self tag: 'sup'
+!
+
+table
+	^ self tag: 'table'
+!
+
+tag: aString
+	^ root addBrush: (self newTag: aString)
+!
+
+tbody
+	^ self tag: 'tbody'
+!
+
+td
+	^ self tag: 'td'
+!
+
+textarea
+	^ self tag: 'textarea'
+!
+
+tfoot
+	^ self tag: 'tfoot'
+!
+
+th
+	^ self tag: 'th'
+!
+
+thead
+	^ self tag: 'thead'
+!
+
+time
+	^ self tag: 'time'
+!
+
+title
+	^ self tag: 'title'
+!
+
+tr
+	^ self tag: 'tr'
+!
+
+ul
+	^ self tag: 'ul'
+!
+
+ul: anObject
+	^ self ul with: anObject
+!
+
+video
+	^ self tag: 'video'
+! !
+
+!HTMLCanvas class methodsFor: 'initialization'!
+
+initialize
+	"Allow JS method calls for the jQuery object.
+	See boot.js DNU handling."
+	
+	jQuery basicAt: 'allowJavaScriptCalls' put: true
+! !
+
+!HTMLCanvas class methodsFor: 'instance creation'!
+
+onJQuery: aJQuery
+	^ self basicNew
+		initializeFromJQuery: aJQuery;
+		initialize;
+		yourself
+! !
+
+Object subclass: #HTMLSnippet
+	instanceVariableNames: 'snippets'
+	package: 'Web'!
+!HTMLSnippet commentStamp!
+My sole instance is the registry of html snippets.
+`HTMLSnippet current` is the public singleton instance.
+
+On startup, it scans the document for any html elements
+with `'data-snippet="foo"'` attribute and takes them off the document,
+remembering them in the store under the specified name.
+It also install method #foo into HTMLCanvas dynamically.
+
+Every html snippet should mark a 'caret', a place where contents
+can be inserted, by 'data-snippet="*"' (a special name for caret).
+For example:
+
+`<li data-snippet='menuelement' class='...'><a data-snippet='*'></a></li>`
+
+defines a list element with a link inside; the link itself is marked as a caret.
+
+You can later issue
+
+`html menuelement href: '/foo'; with: 'A foo'`
+
+to insert the whole snippet and directly manipulate the caret, so it renders:
+
+`<li class='...'><a href='/foo'>A foo</a></li>`
+
+For a self-careting tags (not very useful, but you do not need to fill class etc.
+you can use
+
+`<div class='lots of classes' attr1='one' attr2='two' data-snippet='*bar'></div>`
+
+and in code later do:
+
+`html bar with: [ xxx ]`
+
+to render
+
+`<div class='lots of classes' attr1='one' attr2='two'>...added by xxx...</div>`!
+
+!HTMLSnippet methodsFor: 'accessing'!
+
+snippetAt: aString
+	^ self snippets at: aString
+!
+
+snippets
+	^ snippets ifNil: [ snippets := #{} ]
+! !
+
+!HTMLSnippet methodsFor: 'initialization'!
+
+initializeFromJQuery: aJQuery
+	"Finds and takes out all snippets out of aJQuery.
+	Installs it into self."
+	
+	(self snippetsFromJQuery: aJQuery) do: [ :each |
+		self installSnippetFromJQuery: each asJQuery ]
+! !
+
+!HTMLSnippet methodsFor: 'method generation'!
+
+snippetAt: aString compile: anElement
+	"Method generation for the snippet.
+	The selector is aString, the method block uses anElement"
+	
+	ClassBuilder new
+		installMethod: ([ :htmlReceiver | htmlReceiver snippet: anElement ]
+			currySelf asCompiledMethod: aString)
+		forClass: HTMLCanvas
+		protocol: '**snippets'
+! !
+
+!HTMLSnippet methodsFor: 'private'!
+
+snippetsFromJQuery: aJQuery
+	^ (aJQuery find: '[data-snippet]') toArray
+! !
+
+!HTMLSnippet methodsFor: 'snippet installation'!
+
+installSnippetFromJQuery: element
+	| name |
+	name := element attr: 'data-snippet'.
+	name = '*' ifFalse: [
+		('^\*' asRegexp test: name)
+			ifTrue: [
+				name := name allButFirst.
+				element attr: 'data-snippet' put: '*' ]
+			ifFalse: [
+				element removeAttr: 'data-snippet' ].
+		self snippetAt: name install: (element detach get: 0) ]
+!
+
+snippetAt: aString install: anElement
+	self snippets at: aString put: anElement.
+	self snippetAt: aString compile: anElement
+! !
+
+HTMLSnippet class instanceVariableNames: 'current'!
+
+!HTMLSnippet class methodsFor: 'initialization'!
+
+ensureCurrent
+	current ifNil: [
+		current := super new
+			initializeFromJQuery: document asJQuery;
+			yourself ]
+!
+
+initialize
+	super initialize.
+	self isDOMAvailable ifTrue: [
+		self ensureCurrent ]
+! !
+
+!HTMLSnippet class methodsFor: 'instance creation'!
+
+current
+	^ current
+!
+
+isDOMAvailable
+	< return typeof document !!== 'undefined' >
+!
+
+new
+	self shouldNotImplement
+! !
+
+Object subclass: #TagBrush
+	instanceVariableNames: 'canvas element'
+	package: 'Web'!
+!TagBrush commentStamp!
+I am a brush for building a single DOM element (which I hold onto).
+
+All tags but `<style>` are instances of me (see the `StyleBrush` class).
+
+## API
+
+1. Nesting
+
+    Use `#with:` to nest tags. `#with:` can take aString, `TagBrush` instance, a `Widget` or block closure as parameter.
+
+    Example: `aTag with: aString with: aCanvas div`
+
+2. Events
+
+    The `events` protocol contains all methods related to events (delegating event handling to jQuery).
+
+    Example: `aTag onClick: [ window alert: 'clicked' ]`
+
+3. Attributes
+
+    The `attribute` protocol contains methods for attribute manipulation (delegating to jQuery too).
+
+    Example: `aTag at: 'value' put: 'hello world'`
+
+4. Raw access and jQuery
+
+    The `#element` method can be used to access to JavaScript DOM element object.
+
+    Example: `aTag element cssStyle`
+
+    Use `#asJQuery` to access to the receiver converted into a jQuery object.
+
+    Example: `aTag asJQuery css: 'color' value: 'red'`!
+
+!TagBrush methodsFor: 'accessing'!
+
+element
+	^ element
+! !
+
+!TagBrush methodsFor: 'adding'!
+
+addBrush: aTagBrush
+	self appendChild: aTagBrush element.
+	^ aTagBrush
+!
+
+append: anObject
+	anObject appendToBrush: self
+!
+
+appendBlock: aBlock
+	| root |
+	root := canvas root.
+	canvas root: self.
+	aBlock value: canvas.
+	canvas root: root
+!
+
+appendChild: anElement
+	"In IE7 and IE8 appendChild fails on several node types. So we need to check"
+	<var element=self['@element'];
+	if (null == element.canHaveChildren || element.canHaveChildren) {
+		element.appendChild(anElement);
+	} else {
+		element.text = String(element.text) + anElement.innerHTML;
+	} >
+!
+
+appendString: aString
+	self appendChild: (self createTextNodeFor: aString)
+!
+
+appendToBrush: aTagBrush
+	aTagBrush addBrush: self
+!
+
+contents: anObject
+	self
+	empty;
+	append: anObject
+!
+
+empty
+	self asJQuery empty
+!
+
+with: anObject
+	self append: anObject
+! !
+
+!TagBrush methodsFor: 'attributes'!
+
+accesskey: aString
+	self at: 'accesskey' put: aString
+!
+
+action: aString
+	self at: 'action' put: aString
+!
+
+align: aString
+	self at: 'align' put: aString
+!
+
+alt: aString
+	self at: 'alt' put: aString
+!
+
+at: aString
+	^ self at: aString ifAbsent: [ Collection new errorNotFound ]
+!
+
+at: aString ifAbsent: aBlock
+	<return self['@element'].hasAttribute(aString) ? self['@element'].getAttribute(aString) : aBlock._value()>
+!
+
+at: aString put: aValue
+	<self['@element'].setAttribute(aString, aValue); return aValue>
+!
+
+class: aString
+	<self['@element'].className = aString>
+!
+
+cols: aString
+	self at: 'cols' put: aString
+!
+
+contenteditable: aString
+	self at: 'contenteditable' put: aString
+!
+
+contextmenu: aString
+	self at: 'contextmenu' put: aString
+!
+
+draggable: aString
+	self at: 'draggable' put: aString
+!
+
+for: aString
+	self at: 'for' put: aString
+!
+
+height: aString
+	self at: 'height' put: aString
+!
+
+hidden
+	self at: 'hidden' put: 'hidden'
+!
+
+href: aString
+	self at: 'href' put: aString
+!
+
+id: aString
+	self at: 'id' put: aString
+!
+
+media: aString
+	self at: 'media' put: aString
+!
+
+method: aString
+	self at: 'method' put: aString
+!
+
+name: aString
+	self at: 'name' put: aString
+!
+
+placeholder: aString
+	self at: 'placeholder' put: aString
+!
+
+rel: aString
+	self at: 'rel' put: aString
+!
+
+removeAt: aString
+	<self['@element'].removeAttribute(aString)>
+!
+
+rows: aString
+	self at: 'rows' put: aString
+!
+
+src: aString
+	self at: 'src' put: aString
+!
+
+style: aString
+	self at: 'style' put: aString
+!
+
+tabindex: aNumber
+	self at: 'tabindex' put: aNumber
+!
+
+target: aString
+	self at: 'target' put: aString
+!
+
+title: aString
+	self at: 'title' put: aString
+!
+
+type: aString
+	self at: 'type' put: aString
+!
+
+valign: aString
+	self at: 'valign' put: aString
+!
+
+value: aString
+	self at: 'value' put: aString
+!
+
+width: aString
+	self at: 'width' put: aString
+! !
+
+!TagBrush methodsFor: 'converting'!
+
+asJQuery
+	^ self element asJQuery
+!
+
+asJQueryInContext: aContext
+	^ self element asJQueryInContext: aContext
+! !
+
+!TagBrush methodsFor: 'events'!
+
+onBlur: aBlock
+	self asJQuery bind: 'blur' do: aBlock
+!
+
+onChange: aBlock
+	self asJQuery bind: 'change' do: aBlock
+!
+
+onClick: aBlock
+	self asJQuery bind: 'click' do: aBlock
+!
+
+onDblClick: aBlock
+	self asJQuery bind: 'dblclick' do: aBlock
+!
+
+onFocus: aBlock
+	self asJQuery bind: 'focus' do: aBlock
+!
+
+onFocusIn: aBlock
+	self asJQuery bind: 'focusin' do: aBlock
+!
+
+onFocusOut: aBlock
+	self asJQuery bind: 'focusout' do: aBlock
+!
+
+onHover: aBlock
+	self asJQuery bind: 'hover' do: aBlock
+!
+
+onKeyDown: aBlock
+	self asJQuery bind: 'keydown' do: aBlock
+!
+
+onKeyPress: aBlock
+	self asJQuery bind: 'keypress' do: aBlock
+!
+
+onKeyUp: aBlock
+	self asJQuery bind: 'keyup' do: aBlock
+!
+
+onMouseDown: aBlock
+	self asJQuery bind: 'mousedown' do: aBlock
+!
+
+onMouseEnter: aBlock
+	self asJQuery bind: 'mouseenter' do: aBlock
+!
+
+onMouseLeave: aBlock
+	self asJQuery bind: 'mouseleave' do: aBlock
+!
+
+onMouseMove: aBlock
+	self asJQuery bind: 'mousemove' do: aBlock
+!
+
+onMouseOut: aBlock
+	self asJQuery bind: 'mouseout' do: aBlock
+!
+
+onMouseOver: aBlock
+	self asJQuery bind: 'mouseover' do: aBlock
+!
+
+onMouseUp: aBlock
+	self asJQuery bind: 'mouseup' do: aBlock
+!
+
+onSelect: aBlock
+	self asJQuery bind: 'select' do: aBlock
+!
+
+onSubmit: aBlock
+	self asJQuery bind: 'submit' do: aBlock
+!
+
+onUnload: aBlock
+	self asJQuery bind: 'unload' do: aBlock
+! !
+
+!TagBrush methodsFor: 'initialization'!
+
+initializeFromJQuery: aJQuery canvas: aCanvas
+	element := aJQuery get: 0.
+	canvas := aCanvas
+!
+
+initializeFromString: aString canvas: aCanvas
+	element := self createElementFor: aString.
+	canvas := aCanvas
+! !
+
+!TagBrush methodsFor: 'private'!
+
+appendDocumentFragment: anElement
+	<var element=self['@element'].appendChild(anElement["@element"])>
+!
+
+createElementFor: aString
+	<return document.createElement(String(aString))>
+!
+
+createTextNodeFor: aString
+	<return document.createTextNode(String(aString))>
+! !
+
+!TagBrush class methodsFor: 'instance creation'!
+
+fromJQuery: aJQuery canvas: aCanvas
+	^ self new
+		initializeFromJQuery: aJQuery canvas: aCanvas;
+		yourself
+!
+
+fromString: aString canvas: aCanvas
+	^ self new
+	initializeFromString: aString canvas: aCanvas;
+	yourself
+! !
+
+InterfacingObject subclass: #Widget
+	instanceVariableNames: ''
+	package: 'Web'!
+!Widget commentStamp!
+I am a presenter building HTML. Subclasses are typically reusable components.
+
+## API
+
+Use `#renderContentOn:` to build HTML. (See `HTMLCanvas` and `TagBrush` classes for more about building HTML).
+
+To add a widget to the page, the convenience method `#appendToJQuery:` is very useful.
+
+Exemple: 
+
+    Counter new appendToJQuery: 'body' asJQuery!
+
+!Widget methodsFor: 'adding'!
+
+appendToBrush: aTagBrush
+	self appendToJQuery: aTagBrush asJQuery
+!
+
+appendToJQuery: aJQuery
+	self renderOn: (HTMLCanvas onJQuery: aJQuery)
+! !
+
+!Widget methodsFor: 'rendering'!
+
+renderOn: html
+	self
+! !
+
+!Widget class methodsFor: 'helios'!
+
+heliosClass
+	^ 'widget'
+! !
+
+!BlockClosure methodsFor: '*Web'!
+
+appendToBrush: aTagBrush
+	aTagBrush appendBlock: self
+!
+
+appendToJQuery: aJQuery
+	self value: (HTMLCanvas onJQuery: aJQuery)
+!
+
+asJQuery
+	^ {self} asJQuery
+!
+
+asJQueryInContext: aContext
+	^ {self} asJQueryInContext: aContext
+! !
+
+!CharacterArray methodsFor: '*Web'!
+
+asSnippet
+	^ HTMLSnippet current snippetAt: self asString
+! !
+
+!JSObjectProxy methodsFor: '*Web'!
+
+asJQuery
+	<return jQuery(self['@jsObject'])>
+!
+
+asJQueryInContext: aContext
+	<return jQuery(self['@jsObject'], aContext)>
+! !
+
+!Object methodsFor: '*Web'!
+
+appendToBrush: aTagBrush
+	aTagBrush append: self asString
+!
+
+appendToJQuery: aJQuery
+	aJQuery append: self asString
+!
+
+asJQuery
+	<return jQuery(self)>
+!
+
+asJQueryInContext: aContext
+	<return jQuery(self, aContext)>
+!
+
+postMessageTo: aFrame
+^ self postMessageTo: aFrame origin: '*'
+!
+
+postMessageTo: aFrame origin: aString
+<return aFrame.postMessage(self, aString)>
+! !
+
+!String methodsFor: '*Web'!
+
+appendToBrush: aTagBrush
+	aTagBrush appendString: self
+!
+
+appendToJQuery: aJQuery
+	aJQuery append: self
+!
+
+asJQuery
+	<return jQuery(String(self))>
+!
+
+asJQueryInContext: aContext
+	<return jQuery(String(self), aContext)>
+! !
+

+ 1162 - 0
bower_components/amber/support/boot.js

@@ -0,0 +1,1162 @@
+/* ====================================================================
+ |
+ |   Amber Smalltalk
+ |   http://amber-lang.net
+ |
+ ======================================================================
+
+ ======================================================================
+ |
+ | Copyright (c) 2010-2014
+ | Nicolas Petton <petton.nicolas@gmail.com>
+ |
+ | Copyright (c) 2012-2014
+ | The Amber team https://github.com/amber-smalltalk?tab=members
+ | Amber contributors https://github.com/amber-smalltalk/amber/graphs/contributors
+ |
+ | Amber is released under the MIT license
+ |
+ | Permission is hereby granted, free of charge, to any person obtaining
+ | a copy of this software and associated documentation files (the
+ | 'Software'), to deal in the Software without restriction, including
+ | without limitation the rights to use, copy, modify, merge, publish,
+ | distribute, sublicense, and/or sell copies of the Software, and to
+ | permit persons to whom the Software is furnished to do so, subject to
+ | the following conditions:
+ |
+ | The above copyright notice and this permission notice shall be
+ | included in all copies or substantial portions of the Software.
+ |
+ | THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
+ | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+ | CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ | TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ | SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ |
+ ==================================================================== */
+
+//jshint eqnull:true
+
+define("amber/boot", [ 'require', './browser-compatibility' ], function (require) {
+
+	/* Reconfigurable micro composition system, https://github.com/amber-smalltalk/brikz */
+
+	function Brikz(api, apiKey, initKey) {
+		var brikz = this, backup = {};
+		apiKey = apiKey || 'exports';
+		initKey = initKey || '__init__';
+
+		function mixin(src, target, what) {
+			for (var keys = Object.keys(what||src), l=keys.length, i=0; i<l; ++i) {
+				if (src == null) { target[keys[i]] = undefined; } else {
+					var value = src[keys[i]];
+					if (typeof value !== "undefined") { target[keys[i]] = value; }
+				}
+			}
+			return target;
+		}
+
+		var d={value: null, enumerable: false, configurable: true, writable: true};
+		Object.defineProperties(this, { ensure: d, rebuild: d });
+		var exclude = mixin(this, {});
+
+		this.rebuild = function () {
+			Object.keys(backup).forEach(function (key) {
+				mixin(null, api, (backup[key]||0)[apiKey]||{});
+			});
+			var oapi = mixin(api, {}), order = [], chk = {};
+			brikz.ensure = function(key) {
+				if (key in exclude) { return null; }
+				var b = brikz[key], bak = backup[key];
+				mixin(null, api, api);
+				while (typeof b === "function") { b = new b(brikz, api, bak); }
+				if (b && !chk[key]) { chk[key]=true; order.push(b); }
+				if (b && !b[apiKey]) { b[apiKey] = mixin(api, {}); }
+				brikz[key] = b;
+				return b;
+			};
+			Object.keys(brikz).forEach(function (key) { brikz.ensure(key); });
+			brikz.ensure = null;
+			mixin(oapi, mixin(null, api, api));
+			order.forEach(function(brik) { mixin(brik[apiKey] || {}, api); });
+			order.forEach(function(brik) { if (brik[initKey]) brik[initKey](); });
+			backup = mixin(brikz, {});
+		};
+	}
+
+	/* Brikz end */
+
+	function inherits(child, parent) {
+		child.prototype = Object.create(parent.prototype, {
+			constructor: { value: child,
+						   enumerable: false, configurable: true, writable: true }
+		});
+		return child;
+	}
+
+	var globals = {};
+	globals.SmalltalkSettings = {};
+	var api = Object.create(globals);
+	var brikz = new Brikz(api);
+
+	function RootBrik(brikz, st) {
+
+		/* Smalltalk foundational objects */
+
+		/* SmalltalkRoot is the hidden root of the Amber hierarchy.
+		 All objects including `Object` inherit from SmalltalkRoot */
+		function SmalltalkRoot() {}
+		function SmalltalkProtoObject() {}
+		inherits(SmalltalkProtoObject, SmalltalkRoot);
+		function SmalltalkObject() {}
+		inherits(SmalltalkObject, SmalltalkProtoObject);
+		function SmalltalkNil() {}
+		inherits(SmalltalkNil, SmalltalkObject);
+
+		this.Object = SmalltalkObject;
+		this.nil = new SmalltalkNil();
+
+		// Adds an `isNil` property to the `nil` object.  When sending
+		// nil objects from one environment to another, doing
+		// `anObject == nil` (in JavaScript) does not always answer
+		// true as the referenced nil object might come from the other
+		// environment.
+		Object.defineProperty(this.nil, 'isNil', {
+			value: true,
+			enumerable: false, configurable: false, writable: false
+		});
+
+		// Hidden root class of the system.
+		this.rootAsClass = {fn: SmalltalkRoot};
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Objects");
+			st.wrapClassName("ProtoObject", "Kernel-Objects", SmalltalkProtoObject, undefined, false);
+			st.wrapClassName("Object", "Kernel-Objects", SmalltalkObject, globals.ProtoObject, false);
+			st.wrapClassName("UndefinedObject", "Kernel-Objects", SmalltalkNil, globals.Object, false);
+		};
+	}
+
+	function OrganizeBrik(brikz, st) {
+
+		brikz.ensure("augments");
+		var SmalltalkObject = brikz.ensure("root").Object;
+
+		function SmalltalkOrganizer () {}
+		function SmalltalkPackageOrganizer () {
+			this.elements = [];
+		}
+		function SmalltalkClassOrganizer () {
+			this.elements = [];
+		}
+
+		inherits(SmalltalkOrganizer, SmalltalkObject);
+		inherits(SmalltalkPackageOrganizer, SmalltalkOrganizer);
+		inherits(SmalltalkClassOrganizer, SmalltalkOrganizer);
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Infrastructure");
+			st.wrapClassName("Organizer", "Kernel-Infrastructure", SmalltalkOrganizer, globals.Object, false);
+			st.wrapClassName("PackageOrganizer", "Kernel-Infrastructure", SmalltalkPackageOrganizer, globals.Organizer, false);
+			st.wrapClassName("ClassOrganizer", "Kernel-Infrastructure", SmalltalkClassOrganizer, globals.Organizer, false);
+		};
+
+		this.setupClassOrganization = function (klass) {
+			klass.organization = new SmalltalkClassOrganizer();
+			klass.organization.theClass = klass;
+		};
+
+		this.setupPackageOrganization = function (pkg) {
+			pkg.organization = new SmalltalkPackageOrganizer();
+		};
+
+		this.addOrganizationElement = function (owner, element) {
+			owner.organization.elements.addElement(element);
+		};
+
+		this.removeOrganizationElement = function (owner, element) {
+			owner.organization.elements.removeElement(element);
+		};
+	}
+
+	function DNUBrik(brikz, st) {
+
+		brikz.ensure("selectorConversion");
+		brikz.ensure("messageSend");
+		var manip = brikz.ensure("manipulation");
+		var rootAsClass = brikz.ensure("root").rootAsClass;
+
+		/* Method not implemented handlers */
+
+		var methods = [], methodDict = Object.create(null);
+		this.selectors = [];
+		this.jsSelectors = [];
+
+		this.get = function (stSelector) {
+			var method = methodDict[stSelector];
+			if(method) {
+				return method;
+			}
+			var jsSelector = st.st2js(stSelector);
+			this.selectors.push(stSelector);
+			this.jsSelectors.push(jsSelector);
+			method = {jsSelector: jsSelector, fn: createHandler(stSelector)};
+			methodDict[stSelector] = method;
+			methods.push(method);
+			manip.installMethod(method, rootAsClass);
+			return method;
+		};
+
+		/* Dnu handler method */
+
+		function createHandler(stSelector) {
+			return function() {
+				return brikz.messageSend.messageNotUnderstood(this, stSelector, arguments);
+			};
+		}
+	}
+
+	function ClassInitBrik(brikz, st) {
+
+		var dnu = brikz.ensure("dnu");
+		var manip = brikz.ensure("manipulation");
+
+		/* Initialize a class in its class hierarchy. Handle both classes and
+		 metaclasses. */
+
+		st.init = function(klass) {
+			initClass(klass);
+			if(klass.klass && !klass.meta) {
+				initClass(klass.klass);
+			}
+		};
+
+		function initClass(klass) {
+			if(klass.wrapped) {
+				copySuperclass(klass);
+			}
+		}
+
+		this.initClass = initClass;
+
+		function copySuperclass(klass) {
+			var superclass = klass.superclass,
+				localMethods = klass.methods,
+				protectedJsSelectors = {};
+			Object.keys(localMethods).forEach(function (each) {
+				protectedJsSelectors[localMethods[each].jsSelector] = true;
+			});
+			var superproto = superclass.fn.prototype;
+			dnu.jsSelectors.forEach(function (selector) {
+				if (!protectedJsSelectors[selector]) {
+					manip.installMethod({
+						jsSelector: selector,
+						fn: superproto[selector]
+					}, klass);
+				}
+			});
+		}
+	}
+
+	function ManipulationBrik(brikz, st) {
+
+		this.installMethodIfAbsent = function (handler, klass) {
+			if(!klass.fn.prototype[handler.jsSelector]) {
+				installMethod(handler, klass);
+			}
+		};
+
+		function installMethod (method, klass) {
+			Object.defineProperty(klass.fn.prototype, method.jsSelector, {
+				value: method.fn,
+				enumerable: false, configurable: true, writable: true
+			});
+		}
+		this.installMethod = installMethod;
+	}
+
+
+	function PackagesBrik(brikz, st) {
+
+		var org = brikz.ensure("organize");
+		var root = brikz.ensure("root");
+		var nil = root.nil;
+		var SmalltalkObject = root.Object;
+
+		function SmalltalkPackage() {}
+
+		inherits(SmalltalkPackage, SmalltalkObject);
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Infrastructure");
+			st.wrapClassName("Package", "Kernel-Infrastructure", SmalltalkPackage, globals.Object, false);
+		};
+
+		st.packages = {};
+
+		/* Smalltalk package creation. To add a Package, use smalltalk.addPackage() */
+
+		function pkg(spec) {
+			var that = new SmalltalkPackage();
+			that.pkgName = spec.pkgName;
+			org.setupPackageOrganization(that);
+			that.properties = spec.properties || {};
+			return that;
+		}
+
+		/* Add a package to the smalltalk.packages object, creating a new one if needed.
+		 If pkgName is null or empty we return nil, which is an allowed package for a class.
+		 If package already exists we still update the properties of it. */
+
+		st.addPackage = function(pkgName, properties) {
+			if(!pkgName) {return nil;}
+			if(!(st.packages[pkgName])) {
+				st.packages[pkgName] = pkg({
+					pkgName: pkgName,
+					properties: properties
+				});
+			} else {
+				if(properties) {
+					st.packages[pkgName].properties = properties;
+				}
+			}
+			return st.packages[pkgName];
+		};
+	}
+
+	function ClassesBrik(brikz, st) {
+
+		var org = brikz.ensure("organize");
+		var root = brikz.ensure("root");
+		var classInit = brikz.ensure("classInit");
+		var nil = root.nil;
+		var rootAsClass = root.rootAsClass;
+		var SmalltalkObject = root.Object;
+		rootAsClass.klass = {fn: SmalltalkClass};
+
+		function SmalltalkBehavior() {}
+		function SmalltalkClass() {}
+		function SmalltalkMetaclass() {}
+
+		inherits(SmalltalkBehavior, SmalltalkObject);
+		inherits(SmalltalkClass, SmalltalkBehavior);
+		inherits(SmalltalkMetaclass, SmalltalkBehavior);
+
+		SmalltalkMetaclass.prototype.meta = true;
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Classes");
+			st.wrapClassName("Behavior", "Kernel-Classes", SmalltalkBehavior, globals.Object, false);
+			st.wrapClassName("Metaclass", "Kernel-Classes", SmalltalkMetaclass, globals.Behavior, false);
+			st.wrapClassName("Class", "Kernel-Classes", SmalltalkClass, globals.Behavior, false);
+
+			// Manually bootstrap the metaclass hierarchy
+			globals.ProtoObject.klass.superclass = rootAsClass.klass = globals.Class;
+			addSubclass(globals.ProtoObject.klass);
+		};
+
+		/* Smalltalk classes */
+
+		var classes = [];
+		var wrappedClasses = [];
+
+		/* Smalltalk class creation. A class is an instance of an automatically
+		 created metaclass object. Newly created classes (not their metaclass)
+		 should be added to the smalltalk object, see smalltalk.addClass().
+		 Superclass linking is *not* handled here, see smalltalk.init()  */
+
+		function klass(spec) {
+			spec = spec || {};
+			var setSuperClass = spec.superclass;
+			if(!spec.superclass) {
+				spec.superclass = rootAsClass;
+			}
+
+			var meta = metaclass(spec);
+			var that = meta.instanceClass;
+
+			that.superclass = setSuperClass;
+
+			that.fn = spec.fn || inherits(function () {}, spec.superclass.fn);
+			that.subclasses = [];
+
+			setupClass(that, spec);
+
+			that.className = spec.className;
+			that.wrapped   = spec.wrapped || false;
+			meta.className = spec.className + ' class';
+			meta.superclass = spec.superclass.klass;
+			return that;
+		}
+
+		function metaclass(spec) {
+			spec = spec || {};
+			var that = new SmalltalkMetaclass();
+			that.fn = inherits(function () {}, spec.superclass.klass.fn);
+			that.instanceClass = new that.fn();
+			setupClass(that);
+			return that;
+		}
+
+		SmalltalkBehavior.prototype.toString = function () {
+			return 'Smalltalk ' + this.className;
+		};
+
+		function wireKlass(klass) {
+			Object.defineProperty(klass.fn.prototype, "klass", {
+				value: klass,
+				enumerable: false, configurable: true, writable: true
+			});
+		}
+
+		function setupClass(klass, spec) {
+			spec = spec || {};
+			klass.iVarNames = spec.iVarNames || [];
+			klass.pkg = spec.pkg;
+
+			org.setupClassOrganization(klass);
+			Object.defineProperty(klass, "methods", {
+				value: Object.create(null),
+				enumerable: false, configurable: true, writable: true
+			});
+			wireKlass(klass);
+		}
+
+		/* Add a class to the smalltalk object, creating a new one if needed.
+		 A Package is lazily created if it does not exist with given name. */
+
+		st.addClass = function(className, superclass, iVarNames, pkgName) {
+			// While subclassing nil is allowed, it might be an error, so
+			// warn about it.
+			if (typeof superclass == 'undefined' || superclass == nil) {
+				console.warn('Compiling ' + className + ' as a subclass of `nil`. A dependency might be missing.');
+			}
+			rawAddClass(pkgName, className, superclass, iVarNames, false, null);
+		};
+
+		function rawAddClass(pkgName, className, superclass, iVarNames, wrapped, fn) {
+			var pkg = st.packages[pkgName];
+
+			if (!pkg) {
+				throw new Error("Missing package "+pkgName);
+			}
+
+			if (!superclass || superclass == nil) { superclass = null; }
+			if(globals[className] && globals[className].superclass == superclass) {
+				//            globals[className].superclass = superclass;
+				globals[className].iVarNames = iVarNames || [];
+				if (pkg) globals[className].pkg = pkg;
+				if (fn) {
+					fn.prototype = globals[className].fn.prototype;
+					globals[className].fn = fn;
+					fn.prototype.constructor = fn;
+				}
+			} else {
+				if(globals[className]) {
+					st.removeClass(globals[className]);
+				}
+				globals[className] = klass({
+					className: className,
+					superclass: superclass,
+					pkg: pkg,
+					iVarNames: iVarNames,
+					fn: fn,
+					wrapped: wrapped
+				});
+
+				addSubclass(globals[className]);
+			}
+
+			classes.addElement(globals[className]);
+			org.addOrganizationElement(pkg, globals[className]);
+		}
+
+		st.removeClass = function(klass) {
+			org.removeOrganizationElement(klass.pkg, klass);
+			classes.removeElement(klass);
+			removeSubclass(klass);
+			delete globals[klass.className];
+		};
+
+		function addSubclass(klass) {
+			if(klass.superclass) {
+				klass.superclass.subclasses.addElement(klass);
+			}
+		}
+
+		function removeSubclass(klass) {
+			if(klass.superclass) {
+				klass.superclass.subclasses.removeElement(klass);
+			}
+		}
+
+		/* Create a new class wrapping a JavaScript constructor, and add it to the
+		 global smalltalk object. Package is lazily created if it does not exist with given name. */
+
+		st.wrapClassName = function(className, pkgName, fn, superclass, wrapped) {
+			wrapped = wrapped !== false;
+			rawAddClass(pkgName, className, superclass, globals[className] && globals[className].iVarNames, wrapped, fn);
+			if(wrapped) {
+				wrappedClasses.addElement(globals[className]);
+			}
+		};
+
+		/* Manually set the constructor of an existing Smalltalk klass, making it a wrapped class. */
+
+		st.setClassConstructor = function(klass, constructor) {
+			wrappedClasses.addElement(klass);
+			klass.wrapped = true;
+			klass.fn = constructor;
+
+			// The fn property changed. We need to add back the klass property to the prototype
+			wireKlass(klass);
+
+			classInit.initClass(klass);
+		};
+
+		/* Create an alias for an existing class */
+
+		st.alias = function(klass, alias) {
+			globals[alias] = klass;
+		};
+
+		/* Answer all registered Smalltalk classes */
+		//TODO: remove the function and make smalltalk.classes an array
+
+		st.classes = function() {
+			return classes;
+		};
+
+		st.wrappedClasses = function() {
+			return wrappedClasses;
+		};
+
+		// Still used, but could go away now that subclasses are stored
+		// into classes directly.
+		st.allSubclasses = function(klass) {
+			return klass._allSubclasses();
+		};
+
+	}
+
+	function MethodsBrik(brikz, st) {
+
+		var manip = brikz.ensure("manipulation");
+		var org = brikz.ensure("organize");
+		var stInit = brikz.ensure("stInit");
+		var dnu = brikz.ensure("dnu");
+		var SmalltalkObject = brikz.ensure("root").Object;
+		brikz.ensure("selectorConversion");
+		brikz.ensure("classes");
+
+		function SmalltalkMethod() {}
+		inherits(SmalltalkMethod, SmalltalkObject);
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Methods");
+			st.wrapClassName("CompiledMethod", "Kernel-Methods", SmalltalkMethod, globals.Object, false);
+		};
+
+		/* Smalltalk method object. To add a method to a class,
+		 use smalltalk.addMethod() */
+
+		st.method = function(spec) {
+			var that = new SmalltalkMethod();
+			that.selector          = spec.selector;
+			that.jsSelector        = spec.jsSelector;
+			that.args              = spec.args || {};
+			// spec.category is kept for compatibility
+			that.protocol          = spec.protocol || spec.category;
+			that.source            = spec.source;
+			that.messageSends      = spec.messageSends || [];
+			that.referencedClasses = spec.referencedClasses || [];
+			that.fn                = spec.fn;
+			return that;
+		};
+
+		function installNewDnuHandler(newHandler) {
+			var wrappedClasses = st.wrappedClasses();
+			for(var i = 0; i < wrappedClasses.length; i++) {
+				manip.installMethodIfAbsent(newHandler, wrappedClasses[i]);
+			}
+		}
+
+		function ensureJsSelector(method) {
+			if (!(method.jsSelector)) {
+				method.jsSelector = st.st2js(method.selector);
+			}
+		}
+
+		/* Add/remove a method to/from a class */
+
+		st.addMethod = function (method, klass) {
+			ensureJsSelector(method);
+			manip.installMethod(method, klass);
+			klass.methods[method.selector] = method;
+			method.methodClass = klass;
+
+			// During the bootstrap, #addCompiledMethod is not used.
+			// Therefore we populate the organizer here too
+			org.addOrganizationElement(klass, method.protocol);
+
+			propagateMethodChange(klass, method);
+
+			var usedSelectors = method.messageSends;
+			var dnuHandlers = [];
+
+			dnuHandlers.push(dnu.get(method.selector));
+
+			for(var i=0; i<usedSelectors.length; i++) {
+				dnuHandlers.push(dnu.get(usedSelectors[i]));
+			}
+
+			if(stInit.initialized()) {
+				dnuHandlers.forEach(function(each) {
+					installNewDnuHandler(each);
+				});
+			}
+		};
+
+		function propagateMethodChange(klass, method) {
+			// If already initialized (else it will be done later anyway),
+			// re-initialize all subclasses to ensure the method change
+			// propagation (for wrapped classes, not using the prototype
+			// chain).
+
+			if (stInit.initialized()) {
+				st.allSubclasses(klass).forEach(function (subclass) {
+					initMethodInClass(subclass, method);
+				});
+			}
+		}
+
+		function initMethodInClass (klass, method) {
+			if (klass.wrapped && !klass.methods[method.selector]) {
+				var jsSelector = method.jsSelector;
+				manip.installMethod({
+					jsSelector: jsSelector,
+					fn: klass.superclass.fn.prototype[jsSelector]
+				}, klass);
+			}
+		}
+
+		st.removeMethod = function(method, klass) {
+			if (klass !== method.methodClass) {
+				throw new Error(
+						"Refusing to remove method " +
+						method.methodClass.className + ">>" + method.selector +
+						" from different class " +
+						klass.className);
+			}
+
+			ensureJsSelector(method);
+			delete klass.fn.prototype[method.jsSelector];
+			delete klass.methods[method.selector];
+
+			initMethodInClass(klass, method);
+			propagateMethodChange(klass, method);
+
+			// Do *not* delete protocols from here.
+			// This is handled by #removeCompiledMethod
+		};
+
+		/* Answer all method selectors based on dnu handlers */
+
+		st.allSelectors = function() {
+			return dnu.selectors;
+		};
+
+	}
+
+	function AugmentsBrik(brikz, st) {
+
+		/* Array extensions */
+
+		Array.prototype.addElement = function(el) {
+			if(typeof el === 'undefined') { return; }
+			if(this.indexOf(el) == -1) {
+				this.push(el);
+			}
+		};
+
+		Array.prototype.removeElement = function(el) {
+			var i = this.indexOf(el);
+			if (i !== -1) { this.splice(i, 1); }
+		};
+	}
+
+	function SmalltalkInitBrik(brikz, st) {
+
+		brikz.ensure("classInit");
+		brikz.ensure("classes");
+
+		var initialized = false;
+
+		/* Smalltalk initialization. Called on page load */
+
+		st.initialize = function() {
+			if(initialized) { return; }
+
+			st.classes().forEach(function(klass) {
+				st.init(klass);
+			});
+
+			runnable();
+
+			st.classes().forEach(function(klass) {
+				klass._initialize();
+			});
+
+			initialized = true;
+		};
+
+		this.initialized = function () {
+			return initialized;
+		};
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Methods");
+			st.wrapClassName("Number", "Kernel-Objects", Number, globals.Object);
+			st.wrapClassName("BlockClosure", "Kernel-Methods", Function, globals.Object);
+			st.wrapClassName("Boolean", "Kernel-Objects", Boolean, globals.Object);
+			st.wrapClassName("Date", "Kernel-Objects", Date, globals.Object);
+
+			st.addPackage("Kernel-Collections");
+			st.addClass("Collection", globals.Object, null, "Kernel-Collections");
+			st.addClass("IndexableCollection", globals.Collection, null, "Kernel-Collections");
+			st.addClass("SequenceableCollection", globals.IndexableCollection, null, "Kernel-Collections");
+			st.addClass("CharacterArray", globals.SequenceableCollection, null, "Kernel-Collections");
+			st.wrapClassName("String", "Kernel-Collections", String, globals.CharacterArray);
+			st.wrapClassName("Array", "Kernel-Collections", Array, globals.SequenceableCollection);
+			st.wrapClassName("RegularExpression", "Kernel-Collections", RegExp, globals.Object);
+
+			st.addPackage("Kernel-Exceptions");
+			st.wrapClassName("Error", "Kernel-Exceptions", Error, globals.Object);
+
+			/* Alias definitions */
+
+			st.alias(globals.Array, "OrderedCollection");
+			st.alias(globals.Date, "Time");
+
+		};
+	}
+
+	function PrimitivesBrik(brikz, st) {
+
+		/* Unique ID number generator */
+
+		var oid = 0;
+		st.nextId = function() {
+			oid += 1;
+			return oid;
+		};
+
+		/* Converts a JavaScript object to valid Smalltalk Object */
+		st.readJSObject = function(js) {
+			var readObject = js.constructor === Object;
+			var readArray = js.constructor === Array;
+			var object = readObject ? globals.Dictionary._new() : readArray ? [] : js;
+
+			for(var i in js) {
+				if(readObject) {
+					object._at_put_(i, st.readJSObject(js[i]));
+				}
+				if(readArray) {
+					object[i] = st.readJSObject(js[i]);
+				}
+			}
+			return object;
+		};
+
+		/* Boolean assertion */
+		st.assert = function(shouldBeBoolean) {
+			// jshint -W041
+			if (undefined !== shouldBeBoolean && shouldBeBoolean.klass === globals.Boolean) {
+				return shouldBeBoolean == true;
+			} else {
+				globals.NonBooleanReceiver._new()._object_(shouldBeBoolean)._signal();
+			}
+		};
+
+		/* List of all reserved words in JavaScript. They may not be used as variables
+		 in Smalltalk. */
+
+		// list of reserved JavaScript keywords as of
+		//   http://es5.github.com/#x7.6.1.1
+		// and
+		//   http://people.mozilla.org/~jorendorff/es6-draft.html#sec-7.6.1
+		st.reservedWords = ['break', 'case', 'catch', 'continue', 'debugger',
+							'default', 'delete', 'do', 'else', 'finally', 'for', 'function',
+							'if', 'in', 'instanceof', 'new', 'return', 'switch', 'this', 'throw',
+							'try', 'typeof', 'var', 'void', 'while', 'with',
+							// Amber protected words: these should not be compiled as-is when in code
+							'arguments',
+							// ES5: future use: http://es5.github.com/#x7.6.1.2
+							'class', 'const', 'enum', 'export', 'extends', 'import', 'super',
+							// ES5: future use in strict mode
+							'implements', 'interface', 'let', 'package', 'private', 'protected',
+							'public', 'static', 'yield'];
+
+		st.globalJsVariables = ['jQuery', 'window', 'document', 'process', 'global'];
+
+	}
+
+	function RuntimeBrik(brikz, st) {
+
+		brikz.ensure("selectorConversion");
+		var root = brikz.ensure("root");
+		var nil = root.nil;
+		var SmalltalkObject = root.Object;
+
+		function SmalltalkMethodContext(home, setup) {
+			this.sendIdx     = {};
+			this.homeContext = home;
+			this.setup       = setup || function() {};
+
+			this.supercall = false;
+		}
+
+		inherits(SmalltalkMethodContext, SmalltalkObject);
+
+		this.__init__ = function () {
+			st.addPackage("Kernel-Methods");
+			st.wrapClassName("MethodContext", "Kernel-Methods", SmalltalkMethodContext, globals.Object, false);
+
+			// Fallbacks
+			SmalltalkMethodContext.prototype.locals = {};
+			SmalltalkMethodContext.prototype.receiver = null;
+			SmalltalkMethodContext.prototype.selector = null;
+			SmalltalkMethodContext.prototype.lookupClass = null;
+
+			SmalltalkMethodContext.prototype.fill = function(receiver, selector, locals, lookupClass) {
+				this.receiver    = receiver;
+				this.selector    = selector;
+				this.locals      = locals || {};
+				this.lookupClass = lookupClass;
+				if(this.homeContext) {
+					this.homeContext.evaluatedSelector = selector;
+				}
+			};
+
+			SmalltalkMethodContext.prototype.fillBlock = function(locals, ctx, index) {
+				this.locals        = locals || {};
+				this.outerContext  = ctx;
+				this.index         = index || 0;
+			};
+
+			SmalltalkMethodContext.prototype.init = function() {
+				var home = this.homeContext;
+				if(home) {
+					home.init();
+				}
+
+				this.setup(this);
+			};
+
+			SmalltalkMethodContext.prototype.method = function() {
+				var method;
+				var lookup = this.lookupClass || this.receiver.klass;
+				while(!method && lookup) {
+					method = lookup.methods[st.js2st(this.selector)];
+					lookup = lookup.superclass;
+				}
+				return method;
+			};
+		};
+
+		/* This is the current call context object. While it is publicly available,
+		 Use smalltalk.getThisContext() instead which will answer a safe copy of
+		 the current context */
+
+		st.thisContext = undefined;
+
+		st.withContext = function(worker, setup) {
+			if(st.thisContext) {
+				return inContext(worker, setup);
+			} else {
+				try {
+					return inContext(worker, setup);
+				} catch(error) {
+					handleError(error);
+					st.thisContext = null;
+					// Rethrow the error in any case.
+					error.amberHandled = true;
+					throw error;
+				}
+			}
+		};
+
+		function inContext(worker, setup) {
+			var context = pushContext(setup);
+			var result = worker(context);
+			popContext(context);
+			return result;
+		}
+
+		/* Wrap a JavaScript exception in a Smalltalk Exception.
+
+		 In case of a RangeError, stub the stack after 100 contexts to
+		 avoid another RangeError later when the stack is manipulated. */
+		function wrappedError(error) {
+			var errorWrapper = globals.JavaScriptException._on_(error);
+			// Add the error to the context, so it is visible in the stack
+			try { errorWrapper._signal(); } catch (ex) {}
+			var context = st.getThisContext();
+			if(isRangeError(error)) {
+				stubContextStack(context);
+			}
+			errorWrapper._context_(context);
+			return errorWrapper;
+		}
+
+		/* Stub the context stack after 100 contexts */
+		function stubContextStack(context) {
+			var currentContext = context;
+			var contexts = 0;
+			while(contexts < 100) {
+				if(currentContext) {
+					currentContext = currentContext.homeContext;
+				}
+				contexts++;
+			}
+			if(currentContext) {
+				currentContext.homeContext = undefined;
+			}
+		}
+
+		function isRangeError(error) {
+			return error instanceof RangeError;
+		}
+
+
+		/* Handles Smalltalk errors. Triggers the registered ErrorHandler
+		 (See the Smalltalk class ErrorHandler and its subclasses */
+
+		function handleError(error) {
+			if (!error.smalltalkError) {
+				error = wrappedError(error);
+			}
+			globals.ErrorHandler._handleError_(error);
+		}
+
+		/* Handle thisContext pseudo variable */
+
+		st.getThisContext = function() {
+			if(st.thisContext) {
+				st.thisContext.init();
+				return st.thisContext;
+			} else {
+				return nil;
+			}
+		};
+
+		function pushContext(setup) {
+			var newContext = st.thisContext = new SmalltalkMethodContext(st.thisContext, setup);
+			return newContext;
+		}
+
+		function popContext(context) {
+			st.thisContext = context.homeContext;
+		}
+
+	}
+
+	function MessageSendBrik(brikz, st) {
+
+		brikz.ensure("selectorConversion");
+		var nil = brikz.ensure("root").nil;
+
+		/* Handles unhandled errors during message sends */
+		// simply send the message and handle #dnu:
+
+		st.send = function(receiver, jsSelector, args, klass) {
+			var method;
+			if(receiver === null) {
+				receiver = nil;
+			}
+			method = klass ? klass.fn.prototype[jsSelector] : receiver.klass && receiver[jsSelector];
+			if(method) {
+				return method.apply(receiver, args || []);
+			} else {
+				return messageNotUnderstood(receiver, st.js2st(jsSelector), args);
+			}
+		};
+
+		function invokeDnuMethod(receiver, stSelector, args) {
+			return receiver._doesNotUnderstand_(
+				globals.Message._new()
+					._selector_(stSelector)
+					._arguments_([].slice.call(args))
+			);
+		}
+
+		/* Handles #dnu: *and* JavaScript method calls.
+		 if the receiver has no klass, we consider it a JS object (outside of the
+		 Amber system). Else assume that the receiver understands #doesNotUnderstand: */
+		function messageNotUnderstood(receiver, stSelector, args) {
+			if (receiver.klass !== undefined && !receiver.allowJavaScriptCalls) {
+				return invokeDnuMethod(receiver, stSelector, args);
+			}
+			/* Call a method of a JS object, or answer a property if it exists.
+			 Else try wrapping a JSObjectProxy around the receiver. */
+			var propertyName = st.st2prop(stSelector);
+			if (!(propertyName in receiver)) {
+				return invokeDnuMethod(globals.JSObjectProxy._on_(receiver), stSelector, args);
+			}
+			return accessJavaScript(receiver, propertyName, args);
+		}
+
+		/* If the object property is a function, then call it, except if it starts with
+		 an uppercase character (we probably want to answer the function itself in this
+		 case and send it #new from Amber).
+
+		 Converts keyword-based selectors by using the first
+		 keyword only, but keeping all message arguments.
+
+		 Example:
+		 "self do: aBlock with: anObject" -> "self.do(aBlock, anObject)" */
+		function accessJavaScript(receiver, propertyName, args) {
+			var propertyValue = receiver[propertyName];
+			if (typeof propertyValue === "function" && !/^[A-Z]/.test(propertyName)) {
+				return propertyValue.apply(receiver, args || []);
+			} else if (args.length > 0) {
+				receiver[propertyName] = args[0];
+				return nil;
+			} else {
+				return propertyValue;
+			}
+		}
+
+		st.accessJavaScript = accessJavaScript;
+		this.messageNotUnderstood = messageNotUnderstood;
+	}
+
+	function SelectorConversionBrik(brikz, st) {
+
+		/* Convert a Smalltalk selector into a JS selector */
+		st.st2js = function(string) {
+			var selector = '_' + string;
+			selector = selector.replace(/:/g, '_');
+			selector = selector.replace(/[\&]/g, '_and');
+			selector = selector.replace(/[\|]/g, '_or');
+			selector = selector.replace(/[+]/g, '_plus');
+			selector = selector.replace(/-/g, '_minus');
+			selector = selector.replace(/[*]/g ,'_star');
+			selector = selector.replace(/[\/]/g ,'_slash');
+			selector = selector.replace(/[\\]/g ,'_backslash');
+			selector = selector.replace(/[\~]/g ,'_tild');
+			selector = selector.replace(/>/g ,'_gt');
+			selector = selector.replace(/</g ,'_lt');
+			selector = selector.replace(/=/g ,'_eq');
+			selector = selector.replace(/,/g ,'_comma');
+			selector = selector.replace(/[@]/g ,'_at');
+			return selector;
+		};
+
+		/* Convert a string to a valid smalltalk selector.
+		 if you modify the following functions, also change st2js
+		 accordingly */
+		st.js2st = function(selector) {
+			if(selector.match(/__/)) {
+				return binaryJsToSt(selector);
+			} else {
+				return keywordJsToSt(selector);
+			}
+		};
+
+		function keywordJsToSt(selector) {
+			return selector.replace(/^_/, '').replace(/_/g, ':');
+		}
+
+		function binaryJsToSt(selector) {
+			return selector
+				.replace(/^_/, '')
+				.replace(/_and/g, '&')
+				.replace(/_or/g, '|')
+				.replace(/_plus/g, '+')
+				.replace(/_minus/g, '-')
+				.replace(/_star/g, '*')
+				.replace(/_slash/g, '/')
+				.replace(/_backslash/g, '\\')
+				.replace(/_tild/g, '~')
+				.replace(/_gt/g, '>')
+				.replace(/_lt/g, '<')
+				.replace(/_eq/g, '=')
+				.replace(/_comma/g, ',')
+				.replace(/_at/g, '@');
+		}
+
+		st.st2prop = function (stSelector) {
+			var colonPosition = stSelector.indexOf(':');
+			return colonPosition === -1 ? stSelector : stSelector.slice(0, colonPosition);
+		};
+
+		// Backward-compatible names, deprecated.
+		st.selector = st.st2js;
+		st.convertSelector = st.js2st;
+	}
+
+	/* Adds AMD and requirejs related methods to the smalltalk object */
+	function AMDBrik(brikz, st) {
+		this.__init__ = function () {
+			st.amdRequire = require;
+			st.defaultTransportType = st.defaultTransportType || "amd";
+			st.defaultAmdNamespace = st.defaultAmdNamespace || "amber_core";
+		};
+	}
+
+	/* Defines asReceiver to be present at load time */
+	/* (logically it belongs more to PrimitiveBrik) */
+	function AsReceiverBrik(brikz, st) {
+
+		var nil = brikz.ensure("root").nil;
+
+		/**
+		 * This function is used all over the compiled amber code.
+		 * It takes any value (JavaScript or Smalltalk)
+		 * and returns a proper Amber Smalltalk receiver.
+		 *
+		 * null or undefined -> nil,
+		 * plain JS object -> wrapped JS object,
+		 * otherwise unchanged
+		 */
+		this.asReceiver = function (o) {
+			if (o == null) { return nil; }
+			if (o.klass) { return o; }
+			return globals.JSObjectProxy._on_(o);
+		};
+	}
+
+
+	/* Making smalltalk that can load */
+
+	brikz.root = RootBrik;
+	brikz.dnu = DNUBrik;
+	brikz.organize = OrganizeBrik;
+	brikz.selectorConversion = SelectorConversionBrik;
+	brikz.classInit = ClassInitBrik;
+	brikz.manipulation = ManipulationBrik;
+	brikz.packages = PackagesBrik;
+	brikz.classes = ClassesBrik;
+	brikz.methods = MethodsBrik;
+	brikz.stInit = SmalltalkInitBrik;
+	brikz.augments = AugmentsBrik;
+	brikz.asReceiver = AsReceiverBrik;
+	brikz.amd = AMDBrik;
+
+	brikz.rebuild();
+
+	/* Making smalltalk that can run */
+
+	function runnable () {
+		brikz.messageSend = MessageSendBrik;
+		brikz.runtime = RuntimeBrik;
+		brikz.primitives = PrimitivesBrik;
+
+		brikz.rebuild();
+	}
+
+	return { api: api, /*deprecated:*/vm: api, nil: brikz.root.nil, globals: globals, asReceiver: brikz.asReceiver.asReceiver };
+});

+ 5 - 0
bower_components/amber/support/browser-compatibility.js

@@ -0,0 +1,5 @@
+define([
+    './ensure-console',
+    'amber_lib/es5-shim/es5-shim.min',
+    'amber_lib/es5-shim/es5-sham.min'
+], {});

+ 13 - 0
bower_components/amber/support/deploy.js

@@ -0,0 +1,13 @@
+define([
+    './helpers',
+    'jquery',
+    'amber_core/Kernel-Objects',
+    'amber_core/Kernel-Classes',
+    'amber_core/Kernel-Methods',
+    'amber_core/Kernel-Collections',
+    'amber_core/Kernel-Infrastructure',
+    'amber_core/Kernel-Exceptions',
+    'amber_core/Kernel-Transcript',
+    'amber_core/Kernel-Announcements',
+    'amber_core/Web'
+], function (amber) { return amber; });

+ 3 - 0
bower_components/amber/support/deprecated-vm-files/_st.js

@@ -0,0 +1,3 @@
+define("amber_vm/_st", ["./boot"], function (boot) {
+    return boot.asReceiver;
+});

+ 3 - 0
bower_components/amber/support/deprecated-vm-files/as-receiver.js

@@ -0,0 +1,3 @@
+define("amber_vm/_st", ["./boot"], function (boot) {
+    return boot.asReceiver;
+});

+ 3 - 0
bower_components/amber/support/deprecated-vm-files/boot.js

@@ -0,0 +1,3 @@
+define("amber_vm/boot", ["amber/boot"], function (boot) {
+    return boot;
+});

+ 3 - 0
bower_components/amber/support/deprecated-vm-files/globals.js

@@ -0,0 +1,3 @@
+define("amber_vm/globals", ["./boot"], function (boot) {
+    return boot.globals;
+});

+ 3 - 0
bower_components/amber/support/deprecated-vm-files/nil.js

@@ -0,0 +1,3 @@
+define("amber_vm/nil", ["./boot"], function (boot) {
+    return boot.nil;
+});

+ 4 - 0
bower_components/amber/support/deprecated-vm-files/smalltalk.js

@@ -0,0 +1,4 @@
+define("amber_vm/smalltalk", ["./boot"], function (boot) {
+    return boot.vm;
+});
+

+ 16 - 0
bower_components/amber/support/devel.js

@@ -0,0 +1,16 @@
+define([
+	'./helpers', // pre-fetch, dep of ./deploy
+	'./deploy', // pre-fetch, dep of ./lang
+	'./lang',
+    'codemirror/lib/codemirror',
+    'codemirror/mode/smalltalk/smalltalk',
+    'codemirror/addon/hint/show-hint',
+    'css!codemirror/theme/ambiance',
+    'css!codemirror/lib/codemirror',
+    'css!codemirror/addon/hint/show-hint',
+    'jquery-ui',
+    'amber_core/IDE',
+    'amber_core/Examples',
+    'amber_core/Benchfib',
+	'css!amber/resources/amber'
+], function (amber) { return amber; });

+ 10 - 0
bower_components/amber/support/ensure-console.js

@@ -0,0 +1,10 @@
+/* Make sure that console is defined */
+if(typeof console === "undefined") {
+	this.console = {
+		log: function() {},
+		warn: function() {},
+		info: function() {},
+		debug: function() {},
+		error: function() {}
+	};
+}

+ 86 - 0
bower_components/amber/support/helpers.js

@@ -0,0 +1,86 @@
+define("amber/helpers", ["amber/boot", "require"], function (boot, require) {
+    var globals = boot.globals,
+        exports = Object.create(globals), // backward compatibility, use {} later
+        api = boot.api,
+        nil = boot.nil;
+
+    // API
+
+    exports.popupHelios = function () {
+        require(['helios/index'], function (helios) {
+            helios.popup();
+        }, function (err) {
+            window.alert("Error loading helios.\nIf not present, you can install it with 'bower install helios --save-dev'.\nThe error follows:\n" + err);
+        });
+    };
+    Object.defineProperty(exports, "api", {
+        value: api,
+        enumerable: true, configurable: true, writable: false
+    });
+    Object.defineProperty(exports, "globals", {
+        value: globals,
+        enumerable: true, configurable: true, writable: false
+    });
+    Object.defineProperty(exports, "nil", {
+        value: nil,
+        enumerable: true, configurable: true, writable: false
+    });
+
+    function mixinToSettings(source) {
+        var settings = globals.SmalltalkSettings;
+        Object.keys(source).forEach(function (key) {
+            settings[key] = source[key];
+        });
+    }
+
+    function settingsInLocalStorage() {
+        //jshint evil:true
+        var global = new Function('return this')(),
+            storage = 'localStorage' in global && global.localStorage;
+
+        if (storage) {
+            var fromStorage;
+            try {
+                fromStorage = JSON.parse(storage.getItem('amber.SmalltalkSettings'));
+            } catch (ex) {
+                // pass
+            }
+            mixinToSettings(fromStorage || {});
+            if (typeof window !== "undefined") {
+                requirejs(['jquery'], function ($) {
+                    $(window).on('beforeunload', function () {
+                        storage.setItem('amber.SmalltalkSettings', JSON.stringify(globals.SmalltalkSettings));
+                    });
+                });
+            }
+        }
+    }
+
+    exports.initialize = function (options) {
+        globals.SmalltalkSettings['transport.defaultAmdNamespace'] = api.defaultAmdNamespace;
+        settingsInLocalStorage();
+        if (exports.defaultAmdNamespace) {
+            console.warn("`smalltalk.defaultAmdNamespace = 'namespace';` is deprecated. Please use `smalltalk.initialize({'transport.defaultAmdNamespace': 'namespace'});` instead.");
+            globals.SmalltalkSettings['transport.defaultAmdNamespace'] = globals.SmalltalkSettings['transport.defaultAmdNamespace'] || exports.defaultAmdNamespace;
+        }
+        mixinToSettings(options || {});
+        console.warn("smalltalk.ClassName is deprecated. Please use smalltalk.globals.ClassName instead.");
+        return api.initialize();
+    };
+
+    // Backward compatibility, deprecated
+
+    Object.defineProperty(exports, "smalltalk", {
+        value: api,
+        enumerable: true, configurable: true, writable: false
+    });
+    Object.defineProperty(exports, "vm", {
+        value: api,
+        enumerable: true, configurable: true, writable: false
+    });
+    exports.defaultAmdNamespace = null;
+
+    // Exports
+
+    return  exports;
+});

+ 17 - 0
bower_components/amber/support/lang.js

@@ -0,0 +1,17 @@
+define([
+	'./helpers', // pre-fetch, dep of ./deploy
+	'./deploy',
+	'amber/parser',
+	'amber_core/Kernel-ImportExport',
+	'amber_core/Compiler-Exceptions',
+	'amber_core/Compiler-Core',
+	'amber_core/Compiler-AST',
+	'amber_core/Compiler-Semantic',
+	'amber_core/Compiler-IR',
+	'amber_core/Compiler-Inlining',
+	'amber_core/Compiler-Interpreter',
+	'amber_core/SUnit',
+	'amber_core/Compiler-Tests',
+	'amber_core/Kernel-Tests',
+	'amber_core/SUnit-Tests'
+], function (amber) { return amber; });

+ 3820 - 0
bower_components/amber/support/parser.js

@@ -0,0 +1,3820 @@
+define("amber/parser", ["./boot"], function($boot) {
+var $globals = $boot.globals, nil = $boot.nil;
+$globals.SmalltalkParser = (function() {
+  /*
+   * Generated by PEG.js 0.8.0.
+   *
+   * http://pegjs.majda.cz/
+   */
+
+  function peg$subclass(child, parent) {
+    function ctor() { this.constructor = child; }
+    ctor.prototype = parent.prototype;
+    child.prototype = new ctor();
+  }
+
+  function SyntaxError(message, expected, found, offset, line, column) {
+    this.message  = message;
+    this.expected = expected;
+    this.found    = found;
+    this.offset   = offset;
+    this.line     = line;
+    this.column   = column;
+
+    this.name     = "SyntaxError";
+  }
+
+  peg$subclass(SyntaxError, Error);
+
+  function parse(input) {
+    var options = arguments.length > 1 ? arguments[1] : {},
+
+        peg$FAILED = {},
+
+        peg$startRuleFunctions = { start: peg$parsestart },
+        peg$startRuleFunction  = peg$parsestart,
+
+        peg$c0 = [],
+        peg$c1 = peg$FAILED,
+        peg$c2 = /^[ \t\x0B\f\xA0\uFEFF\n\r\u2028\u2029]/,
+        peg$c3 = { type: "class", value: "[ \\t\\x0B\\f\\xA0\\uFEFF\\n\\r\\u2028\\u2029]", description: "[ \\t\\x0B\\f\\xA0\\uFEFF\\n\\r\\u2028\\u2029]" },
+        peg$c4 = "\"",
+        peg$c5 = { type: "literal", value: "\"", description: "\"\\\"\"" },
+        peg$c6 = /^[^"]/,
+        peg$c7 = { type: "class", value: "[^\"]", description: "[^\"]" },
+        peg$c8 = /^[a-zA-Z]/,
+        peg$c9 = { type: "class", value: "[a-zA-Z]", description: "[a-zA-Z]" },
+        peg$c10 = /^[a-zA-Z0-9]/,
+        peg$c11 = { type: "class", value: "[a-zA-Z0-9]", description: "[a-zA-Z0-9]" },
+        peg$c12 = function(first, others) {return first + others.join("");},
+        peg$c13 = ":",
+        peg$c14 = { type: "literal", value: ":", description: "\":\"" },
+        peg$c15 = function(first, last) {return first + last;},
+        peg$c16 = /^[a-zA-Z0-9:]/,
+        peg$c17 = { type: "class", value: "[a-zA-Z0-9:]", description: "[a-zA-Z0-9:]" },
+        peg$c18 = /^[A-Z]/,
+        peg$c19 = { type: "class", value: "[A-Z]", description: "[A-Z]" },
+        peg$c20 = "'",
+        peg$c21 = { type: "literal", value: "'", description: "\"'\"" },
+        peg$c22 = "''",
+        peg$c23 = { type: "literal", value: "''", description: "\"''\"" },
+        peg$c24 = function() {return "'";},
+        peg$c25 = /^[^']/,
+        peg$c26 = { type: "class", value: "[^']", description: "[^']" },
+        peg$c27 = function(val) {
+                             return $globals.ValueNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._value_(val.join(""));
+                         },
+        peg$c28 = "$",
+        peg$c29 = { type: "literal", value: "$", description: "\"$\"" },
+        peg$c30 = { type: "any", description: "any character" },
+        peg$c31 = function(char) {
+                              return $globals.ValueNode._new()
+                                     ._position_((line()).__at(column()))
+                                     ._source_(text())
+                                     ._value_(char);
+                          },
+        peg$c32 = "#",
+        peg$c33 = { type: "literal", value: "#", description: "\"#\"" },
+        peg$c34 = function(rest) {return rest;},
+        peg$c35 = function(node) {return node._value();},
+        peg$c36 = function(val) {
+                              return $globals.ValueNode._new()
+                                     ._position_((line()).__at(column()))
+                                     ._source_(text())
+                                     ._value_(val);
+                          },
+        peg$c37 = function(n) {
+                             return $globals.ValueNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._value_(n);
+                         },
+        peg$c38 = "e",
+        peg$c39 = { type: "literal", value: "e", description: "\"e\"" },
+        peg$c40 = function(n) {return parseFloat(n.join(""));},
+        peg$c41 = null,
+        peg$c42 = "-",
+        peg$c43 = { type: "literal", value: "-", description: "\"-\"" },
+        peg$c44 = "16r",
+        peg$c45 = { type: "literal", value: "16r", description: "\"16r\"" },
+        peg$c46 = /^[0-9a-fA-F]/,
+        peg$c47 = { type: "class", value: "[0-9a-fA-F]", description: "[0-9a-fA-F]" },
+        peg$c48 = function(neg, num) {return parseInt(((neg || '') + num.join("")), 16);},
+        peg$c49 = /^[0-9]/,
+        peg$c50 = { type: "class", value: "[0-9]", description: "[0-9]" },
+        peg$c51 = ".",
+        peg$c52 = { type: "literal", value: ".", description: "\".\"" },
+        peg$c53 = function(neg, digits, dec) {return parseFloat(((neg || '') + digits.join("") + "." + dec.join("")), 10);},
+        peg$c54 = function(neg, digits) {return (parseInt((neg || '') + digits.join(""), 10));},
+        peg$c55 = "#(",
+        peg$c56 = { type: "literal", value: "#(", description: "\"#(\"" },
+        peg$c57 = "(",
+        peg$c58 = { type: "literal", value: "(", description: "\"(\"" },
+        peg$c59 = function(lit) {return lit._value();},
+        peg$c60 = ")",
+        peg$c61 = { type: "literal", value: ")", description: "\")\"" },
+        peg$c62 = function(lits) {
+                             return $globals.ValueNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._value_(lits);
+                         },
+        peg$c63 = "{",
+        peg$c64 = { type: "literal", value: "{", description: "\"{\"" },
+        peg$c65 = "}",
+        peg$c66 = { type: "literal", value: "}", description: "\"}\"" },
+        peg$c67 = function(expressions) {
+                             return $globals.DynamicArrayNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._nodes_(expressions || []);
+                         },
+        peg$c68 = "#{",
+        peg$c69 = { type: "literal", value: "#{", description: "\"#{\"" },
+        peg$c70 = function(expressions) {
+                                return $globals.DynamicDictionaryNode._new()
+                                       ._position_((line()).__at(column()))
+                                       ._source_(text())
+                                       ._nodes_(expressions || []);
+                            },
+        peg$c71 = "true",
+        peg$c72 = { type: "literal", value: "true", description: "\"true\"" },
+        peg$c73 = function() {return true;},
+        peg$c74 = "false",
+        peg$c75 = { type: "literal", value: "false", description: "\"false\"" },
+        peg$c76 = function() {return false;},
+        peg$c77 = "nil",
+        peg$c78 = { type: "literal", value: "nil", description: "\"nil\"" },
+        peg$c79 = function() {return nil;},
+        peg$c80 = function(val) {
+                               return $globals.ValueNode._new()
+                                      ._position_((line()).__at(column()))
+                                      ._source_(text())
+                                      ._value_(val);
+                           },
+        peg$c81 = function(identifier) {
+                             return $globals.VariableNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._value_(identifier);
+                         },
+        peg$c82 = function(key, arg) {return {key:key, arg:arg};},
+        peg$c83 = /^[\\+*\/=><,@%~|&\-]/,
+        peg$c84 = { type: "class", value: "[\\\\+*\\/=><,@%~|&\\-]", description: "[\\\\+*\\/=><,@%~|&\\-]" },
+        peg$c85 = function(bin) {return bin.join("");},
+        peg$c86 = function(pairs) {
+                             var keywords = [];
+                             var params = [];
+                             var i = 0;
+                             for(i = 0; i < pairs.length; i++){
+                                 keywords.push(pairs[i].key);
+                             }
+                             for(i = 0; i < pairs.length; i++){
+                                 params.push(pairs[i].arg);
+                             }
+                             return [keywords.join(""), params];
+                         },
+        peg$c87 = function(selector, arg) {return [selector, [arg]];},
+        peg$c88 = function(selector) {return [selector, []];},
+        peg$c89 = function(expression) {return expression;},
+        peg$c90 = function(first, others) { return [first].concat(others); },
+        peg$c91 = ":=",
+        peg$c92 = { type: "literal", value: ":=", description: "\":=\"" },
+        peg$c93 = function(variable, expression) {
+                             return $globals.AssignmentNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._left_(variable)
+                                    ._right_(expression);
+                         },
+        peg$c94 = "^",
+        peg$c95 = { type: "literal", value: "^", description: "\"^\"" },
+        peg$c96 = function(expression) {
+                             return $globals.ReturnNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._nodes_([expression]);
+                         },
+        peg$c97 = "|",
+        peg$c98 = { type: "literal", value: "|", description: "\"|\"" },
+        peg$c99 = function(variable) {return variable;},
+        peg$c100 = function(vars) {return vars;},
+        peg$c101 = function(param) {return param;},
+        peg$c102 = function(params) {return params;},
+        peg$c103 = function(ret) {return [ret];},
+        peg$c104 = function(exps, ret) {
+                               var expressions = exps;
+                               expressions.push(ret);
+                               return expressions;
+                           },
+        peg$c105 = function(expressions) {
+                               return expressions || [];
+                           },
+        peg$c106 = function(temps, statements) {
+                             return $globals.SequenceNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._temps_(temps || [])
+                                    ._nodes_(statements || []);
+                         },
+        peg$c107 = "[",
+        peg$c108 = { type: "literal", value: "[", description: "\"[\"" },
+        peg$c109 = "]",
+        peg$c110 = { type: "literal", value: "]", description: "\"]\"" },
+        peg$c111 = function(params, sequence) {
+                             return $globals.BlockNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._parameters_(params || [])
+                                    ._nodes_([sequence._asBlockSequenceNode()]);
+                         },
+        peg$c112 = void 0,
+        peg$c113 = function(selector) {
+                             return $globals.SendNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._selector_(selector);
+                         },
+        peg$c114 = function(message, tail) {
+                             if(tail) {
+                                 return tail._valueForReceiver_(message);
+                             }
+                             else {
+                                 return message;
+                             }
+                         },
+        peg$c115 = function(receiver, tail) {
+                             if(tail) {
+                                 return tail._valueForReceiver_(receiver);
+                             }
+                             else {
+                                 return receiver;
+                             }
+                         },
+        peg$c116 = function(selector, arg) {
+                             return $globals.SendNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._selector_(selector)
+                                    ._arguments_([arg]);
+                         },
+        peg$c117 = function(message, tail) {
+                             if(tail) {
+                                 return tail._valueForReceiver_(message);
+                              }
+                             else {
+                                 return message;
+                             }
+                         },
+        peg$c118 = function(pairs) {
+                             var selector = [];
+                             var args = [];
+                              for(var i = 0; i < pairs.length; i++) {
+                                  selector.push(pairs[i].key);
+                                  args.push(pairs[i].arg);
+                              }
+                              return $globals.SendNode._new()
+                                     ._position_((line()).__at(column()))
+                                     ._source_(text())
+                                     ._selector_(selector.join(""))
+                                     ._arguments_(args);
+                         },
+        peg$c119 = function(receiver, tail) {
+                             return tail._valueForReceiver_(receiver);
+                         },
+        peg$c120 = ";",
+        peg$c121 = { type: "literal", value: ";", description: "\";\"" },
+        peg$c122 = function(mess) {return mess;},
+        peg$c123 = function(send, messages) {
+                             var cascade = [];
+                             cascade.push(send);
+                             for(var i = 0; i < messages.length; i++) {
+                                 cascade.push(messages[i]);
+                             }
+                             return $globals.CascadeNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(text())
+                                    ._receiver_(send._receiver())
+                                    ._nodes_(cascade);
+                         },
+        peg$c124 = "<",
+        peg$c125 = { type: "literal", value: "<", description: "\"<\"" },
+        peg$c126 = ">>",
+        peg$c127 = { type: "literal", value: ">>", description: "\">>\"" },
+        peg$c128 = function() {return ">";},
+        peg$c129 = /^[^>]/,
+        peg$c130 = { type: "class", value: "[^>]", description: "[^>]" },
+        peg$c131 = ">",
+        peg$c132 = { type: "literal", value: ">", description: "\">\"" },
+        peg$c133 = function(val) {
+                             return $globals.JSStatementNode._new()
+                                    ._position_((line()).__at(column()))
+                                    ._source_(val.join(""))
+                         },
+        peg$c134 = function(pattern, sequence) {
+                              return $globals.MethodNode._new()
+                                     ._position_((line()).__at(column()))
+                                     ._source_(text())
+                                     ._selector_(pattern[0])
+                                     ._arguments_(pattern[1])
+                                     ._nodes_([sequence]);
+                         },
+        peg$c135 = function(send) { return send._selector() === "->" },
+        peg$c136 = function(send) { return [send._receiver(), send._arguments()[0]]; },
+        peg$c137 = function(first, others) { return first.concat.apply(first, others); },
+
+        peg$currPos          = 0,
+        peg$reportedPos      = 0,
+        peg$cachedPos        = 0,
+        peg$cachedPosDetails = { line: 1, column: 1, seenCR: false },
+        peg$maxFailPos       = 0,
+        peg$maxFailExpected  = [],
+        peg$silentFails      = 0,
+
+        peg$cache = {},
+        peg$result;
+
+    if ("startRule" in options) {
+      if (!(options.startRule in peg$startRuleFunctions)) {
+        throw new Error("Can't start parsing from rule \"" + options.startRule + "\".");
+      }
+
+      peg$startRuleFunction = peg$startRuleFunctions[options.startRule];
+    }
+
+    function text() {
+      return input.substring(peg$reportedPos, peg$currPos);
+    }
+
+    function offset() {
+      return peg$reportedPos;
+    }
+
+    function line() {
+      return peg$computePosDetails(peg$reportedPos).line;
+    }
+
+    function column() {
+      return peg$computePosDetails(peg$reportedPos).column;
+    }
+
+    function expected(description) {
+      throw peg$buildException(
+        null,
+        [{ type: "other", description: description }],
+        peg$reportedPos
+      );
+    }
+
+    function error(message) {
+      throw peg$buildException(message, null, peg$reportedPos);
+    }
+
+    function peg$computePosDetails(pos) {
+      function advance(details, startPos, endPos) {
+        var p, ch;
+
+        for (p = startPos; p < endPos; p++) {
+          ch = input.charAt(p);
+          if (ch === "\n") {
+            if (!details.seenCR) { details.line++; }
+            details.column = 1;
+            details.seenCR = false;
+          } else if (ch === "\r" || ch === "\u2028" || ch === "\u2029") {
+            details.line++;
+            details.column = 1;
+            details.seenCR = true;
+          } else {
+            details.column++;
+            details.seenCR = false;
+          }
+        }
+      }
+
+      if (peg$cachedPos !== pos) {
+        if (peg$cachedPos > pos) {
+          peg$cachedPos = 0;
+          peg$cachedPosDetails = { line: 1, column: 1, seenCR: false };
+        }
+        advance(peg$cachedPosDetails, peg$cachedPos, pos);
+        peg$cachedPos = pos;
+      }
+
+      return peg$cachedPosDetails;
+    }
+
+    function peg$fail(expected) {
+      if (peg$currPos < peg$maxFailPos) { return; }
+
+      if (peg$currPos > peg$maxFailPos) {
+        peg$maxFailPos = peg$currPos;
+        peg$maxFailExpected = [];
+      }
+
+      peg$maxFailExpected.push(expected);
+    }
+
+    function peg$buildException(message, expected, pos) {
+      function cleanupExpected(expected) {
+        var i = 1;
+
+        expected.sort(function(a, b) {
+          if (a.description < b.description) {
+            return -1;
+          } else if (a.description > b.description) {
+            return 1;
+          } else {
+            return 0;
+          }
+        });
+
+        while (i < expected.length) {
+          if (expected[i - 1] === expected[i]) {
+            expected.splice(i, 1);
+          } else {
+            i++;
+          }
+        }
+      }
+
+      function buildMessage(expected, found) {
+        function stringEscape(s) {
+          function hex(ch) { return ch.charCodeAt(0).toString(16).toUpperCase(); }
+
+          return s
+            .replace(/\\/g,   '\\\\')
+            .replace(/"/g,    '\\"')
+            .replace(/\x08/g, '\\b')
+            .replace(/\t/g,   '\\t')
+            .replace(/\n/g,   '\\n')
+            .replace(/\f/g,   '\\f')
+            .replace(/\r/g,   '\\r')
+            .replace(/[\x00-\x07\x0B\x0E\x0F]/g, function(ch) { return '\\x0' + hex(ch); })
+            .replace(/[\x10-\x1F\x80-\xFF]/g,    function(ch) { return '\\x'  + hex(ch); })
+            .replace(/[\u0180-\u0FFF]/g,         function(ch) { return '\\u0' + hex(ch); })
+            .replace(/[\u1080-\uFFFF]/g,         function(ch) { return '\\u'  + hex(ch); });
+        }
+
+        var expectedDescs = new Array(expected.length),
+            expectedDesc, foundDesc, i;
+
+        for (i = 0; i < expected.length; i++) {
+          expectedDescs[i] = expected[i].description;
+        }
+
+        expectedDesc = expected.length > 1
+          ? expectedDescs.slice(0, -1).join(", ")
+              + " or "
+              + expectedDescs[expected.length - 1]
+          : expectedDescs[0];
+
+        foundDesc = found ? "\"" + stringEscape(found) + "\"" : "end of input";
+
+        return "Expected " + expectedDesc + " but " + foundDesc + " found.";
+      }
+
+      var posDetails = peg$computePosDetails(pos),
+          found      = pos < input.length ? input.charAt(pos) : null;
+
+      if (expected !== null) {
+        cleanupExpected(expected);
+      }
+
+      return new SyntaxError(
+        message !== null ? message : buildMessage(expected, found),
+        expected,
+        found,
+        pos,
+        posDetails.line,
+        posDetails.column
+      );
+    }
+
+    function peg$parsestart() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 0,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parsemethod();
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseseparator() {
+      var s0, s1;
+
+      var key    = peg$currPos * 60 + 1,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = [];
+      if (peg$c2.test(input.charAt(peg$currPos))) {
+        s1 = input.charAt(peg$currPos);
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c3); }
+      }
+      if (s1 !== peg$FAILED) {
+        while (s1 !== peg$FAILED) {
+          s0.push(s1);
+          if (peg$c2.test(input.charAt(peg$currPos))) {
+            s1 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s1 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c3); }
+          }
+        }
+      } else {
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsecomments() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 2,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = [];
+      s1 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 34) {
+        s2 = peg$c4;
+        peg$currPos++;
+      } else {
+        s2 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c5); }
+      }
+      if (s2 !== peg$FAILED) {
+        s3 = [];
+        if (peg$c6.test(input.charAt(peg$currPos))) {
+          s4 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s4 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c7); }
+        }
+        while (s4 !== peg$FAILED) {
+          s3.push(s4);
+          if (peg$c6.test(input.charAt(peg$currPos))) {
+            s4 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c7); }
+          }
+        }
+        if (s3 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 34) {
+            s4 = peg$c4;
+            peg$currPos++;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c5); }
+          }
+          if (s4 !== peg$FAILED) {
+            s2 = [s2, s3, s4];
+            s1 = s2;
+          } else {
+            peg$currPos = s1;
+            s1 = peg$c1;
+          }
+        } else {
+          peg$currPos = s1;
+          s1 = peg$c1;
+        }
+      } else {
+        peg$currPos = s1;
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        while (s1 !== peg$FAILED) {
+          s0.push(s1);
+          s1 = peg$currPos;
+          if (input.charCodeAt(peg$currPos) === 34) {
+            s2 = peg$c4;
+            peg$currPos++;
+          } else {
+            s2 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c5); }
+          }
+          if (s2 !== peg$FAILED) {
+            s3 = [];
+            if (peg$c6.test(input.charAt(peg$currPos))) {
+              s4 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s4 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c7); }
+            }
+            while (s4 !== peg$FAILED) {
+              s3.push(s4);
+              if (peg$c6.test(input.charAt(peg$currPos))) {
+                s4 = input.charAt(peg$currPos);
+                peg$currPos++;
+              } else {
+                s4 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c7); }
+              }
+            }
+            if (s3 !== peg$FAILED) {
+              if (input.charCodeAt(peg$currPos) === 34) {
+                s4 = peg$c4;
+                peg$currPos++;
+              } else {
+                s4 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c5); }
+              }
+              if (s4 !== peg$FAILED) {
+                s2 = [s2, s3, s4];
+                s1 = s2;
+              } else {
+                peg$currPos = s1;
+                s1 = peg$c1;
+              }
+            } else {
+              peg$currPos = s1;
+              s1 = peg$c1;
+            }
+          } else {
+            peg$currPos = s1;
+            s1 = peg$c1;
+          }
+        }
+      } else {
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsews() {
+      var s0, s1;
+
+      var key    = peg$currPos * 60 + 3,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = [];
+      s1 = peg$parseseparator();
+      if (s1 === peg$FAILED) {
+        s1 = peg$parsecomments();
+      }
+      while (s1 !== peg$FAILED) {
+        s0.push(s1);
+        s1 = peg$parseseparator();
+        if (s1 === peg$FAILED) {
+          s1 = peg$parsecomments();
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseidentifier() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 4,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (peg$c8.test(input.charAt(peg$currPos))) {
+        s1 = input.charAt(peg$currPos);
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c9); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (peg$c10.test(input.charAt(peg$currPos))) {
+          s3 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c11); }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          if (peg$c10.test(input.charAt(peg$currPos))) {
+            s3 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c11); }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c12(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsekeyword() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 5,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseidentifier();
+      if (s1 !== peg$FAILED) {
+        if (input.charCodeAt(peg$currPos) === 58) {
+          s2 = peg$c13;
+          peg$currPos++;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c14); }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c15(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseselector() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 6,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (peg$c8.test(input.charAt(peg$currPos))) {
+        s1 = input.charAt(peg$currPos);
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c9); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (peg$c16.test(input.charAt(peg$currPos))) {
+          s3 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c17); }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          if (peg$c16.test(input.charAt(peg$currPos))) {
+            s3 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c17); }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c12(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseclassName() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 7,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (peg$c18.test(input.charAt(peg$currPos))) {
+        s1 = input.charAt(peg$currPos);
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c19); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (peg$c10.test(input.charAt(peg$currPos))) {
+          s3 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c11); }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          if (peg$c10.test(input.charAt(peg$currPos))) {
+            s3 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c11); }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c12(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsestring() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 8,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 39) {
+        s1 = peg$c20;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c21); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        s3 = peg$currPos;
+        if (input.substr(peg$currPos, 2) === peg$c22) {
+          s4 = peg$c22;
+          peg$currPos += 2;
+        } else {
+          s4 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c23); }
+        }
+        if (s4 !== peg$FAILED) {
+          peg$reportedPos = s3;
+          s4 = peg$c24();
+        }
+        s3 = s4;
+        if (s3 === peg$FAILED) {
+          if (peg$c25.test(input.charAt(peg$currPos))) {
+            s3 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c26); }
+          }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          s3 = peg$currPos;
+          if (input.substr(peg$currPos, 2) === peg$c22) {
+            s4 = peg$c22;
+            peg$currPos += 2;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c23); }
+          }
+          if (s4 !== peg$FAILED) {
+            peg$reportedPos = s3;
+            s4 = peg$c24();
+          }
+          s3 = s4;
+          if (s3 === peg$FAILED) {
+            if (peg$c25.test(input.charAt(peg$currPos))) {
+              s3 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s3 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c26); }
+            }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 39) {
+            s3 = peg$c20;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c21); }
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c27(s2);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsecharacter() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 9,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 36) {
+        s1 = peg$c28;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c29); }
+      }
+      if (s1 !== peg$FAILED) {
+        if (input.length > peg$currPos) {
+          s2 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c30); }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c31(s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsesymbol() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 10,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 35) {
+        s1 = peg$c32;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c33); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsebareSymbol();
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c34(s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebareSymbol() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 11,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseselector();
+      if (s1 === peg$FAILED) {
+        s1 = peg$parsebinarySelector();
+        if (s1 === peg$FAILED) {
+          s1 = peg$currPos;
+          s2 = peg$parsestring();
+          if (s2 !== peg$FAILED) {
+            peg$reportedPos = s1;
+            s2 = peg$c35(s2);
+          }
+          s1 = s2;
+        }
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c36(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsenumber() {
+      var s0, s1;
+
+      var key    = peg$currPos * 60 + 12,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsenumberExp();
+      if (s1 === peg$FAILED) {
+        s1 = peg$parsehex();
+        if (s1 === peg$FAILED) {
+          s1 = peg$parsefloat();
+          if (s1 === peg$FAILED) {
+            s1 = peg$parseinteger();
+          }
+        }
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c37(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsenumberExp() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 13,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$currPos;
+      s2 = peg$parsefloat();
+      if (s2 === peg$FAILED) {
+        s2 = peg$parseinteger();
+      }
+      if (s2 !== peg$FAILED) {
+        if (input.charCodeAt(peg$currPos) === 101) {
+          s3 = peg$c38;
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c39); }
+        }
+        if (s3 !== peg$FAILED) {
+          s4 = peg$parseinteger();
+          if (s4 !== peg$FAILED) {
+            s2 = [s2, s3, s4];
+            s1 = s2;
+          } else {
+            peg$currPos = s1;
+            s1 = peg$c1;
+          }
+        } else {
+          peg$currPos = s1;
+          s1 = peg$c1;
+        }
+      } else {
+        peg$currPos = s1;
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c40(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsehex() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 14,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 45) {
+        s1 = peg$c42;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c43); }
+      }
+      if (s1 === peg$FAILED) {
+        s1 = peg$c41;
+      }
+      if (s1 !== peg$FAILED) {
+        if (input.substr(peg$currPos, 3) === peg$c44) {
+          s2 = peg$c44;
+          peg$currPos += 3;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c45); }
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = [];
+          if (peg$c46.test(input.charAt(peg$currPos))) {
+            s4 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c47); }
+          }
+          if (s4 !== peg$FAILED) {
+            while (s4 !== peg$FAILED) {
+              s3.push(s4);
+              if (peg$c46.test(input.charAt(peg$currPos))) {
+                s4 = input.charAt(peg$currPos);
+                peg$currPos++;
+              } else {
+                s4 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c47); }
+              }
+            }
+          } else {
+            s3 = peg$c1;
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c48(s1, s3);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsefloat() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 15,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 45) {
+        s1 = peg$c42;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c43); }
+      }
+      if (s1 === peg$FAILED) {
+        s1 = peg$c41;
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (peg$c49.test(input.charAt(peg$currPos))) {
+          s3 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c50); }
+        }
+        if (s3 !== peg$FAILED) {
+          while (s3 !== peg$FAILED) {
+            s2.push(s3);
+            if (peg$c49.test(input.charAt(peg$currPos))) {
+              s3 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s3 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c50); }
+            }
+          }
+        } else {
+          s2 = peg$c1;
+        }
+        if (s2 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 46) {
+            s3 = peg$c51;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c52); }
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = [];
+            if (peg$c49.test(input.charAt(peg$currPos))) {
+              s5 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s5 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c50); }
+            }
+            if (s5 !== peg$FAILED) {
+              while (s5 !== peg$FAILED) {
+                s4.push(s5);
+                if (peg$c49.test(input.charAt(peg$currPos))) {
+                  s5 = input.charAt(peg$currPos);
+                  peg$currPos++;
+                } else {
+                  s5 = peg$FAILED;
+                  if (peg$silentFails === 0) { peg$fail(peg$c50); }
+                }
+              }
+            } else {
+              s4 = peg$c1;
+            }
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c53(s1, s2, s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseinteger() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 16,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 45) {
+        s1 = peg$c42;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c43); }
+      }
+      if (s1 === peg$FAILED) {
+        s1 = peg$c41;
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (peg$c49.test(input.charAt(peg$currPos))) {
+          s3 = input.charAt(peg$currPos);
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c50); }
+        }
+        if (s3 !== peg$FAILED) {
+          while (s3 !== peg$FAILED) {
+            s2.push(s3);
+            if (peg$c49.test(input.charAt(peg$currPos))) {
+              s3 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s3 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c50); }
+            }
+          }
+        } else {
+          s2 = peg$c1;
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c54(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseliteralArray() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 17,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.substr(peg$currPos, 2) === peg$c55) {
+        s1 = peg$c55;
+        peg$currPos += 2;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c56); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parseliteralArrayRest();
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c34(s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebareLiteralArray() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 18,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 40) {
+        s1 = peg$c57;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c58); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parseliteralArrayRest();
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c34(s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseliteralArrayRest() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 19,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = [];
+      s2 = peg$currPos;
+      s3 = peg$parsews();
+      if (s3 !== peg$FAILED) {
+        s4 = peg$parseparseTimeLiteral();
+        if (s4 === peg$FAILED) {
+          s4 = peg$parsebareLiteralArray();
+          if (s4 === peg$FAILED) {
+            s4 = peg$parsebareSymbol();
+          }
+        }
+        if (s4 !== peg$FAILED) {
+          peg$reportedPos = s2;
+          s3 = peg$c59(s4);
+          s2 = s3;
+        } else {
+          peg$currPos = s2;
+          s2 = peg$c1;
+        }
+      } else {
+        peg$currPos = s2;
+        s2 = peg$c1;
+      }
+      while (s2 !== peg$FAILED) {
+        s1.push(s2);
+        s2 = peg$currPos;
+        s3 = peg$parsews();
+        if (s3 !== peg$FAILED) {
+          s4 = peg$parseparseTimeLiteral();
+          if (s4 === peg$FAILED) {
+            s4 = peg$parsebareLiteralArray();
+            if (s4 === peg$FAILED) {
+              s4 = peg$parsebareSymbol();
+            }
+          }
+          if (s4 !== peg$FAILED) {
+            peg$reportedPos = s2;
+            s3 = peg$c59(s4);
+            s2 = s3;
+          } else {
+            peg$currPos = s2;
+            s2 = peg$c1;
+          }
+        } else {
+          peg$currPos = s2;
+          s2 = peg$c1;
+        }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 41) {
+            s3 = peg$c60;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c61); }
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c62(s1);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsedynamicArray() {
+      var s0, s1, s2, s3, s4, s5, s6;
+
+      var key    = peg$currPos * 60 + 20,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 123) {
+        s1 = peg$c63;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c64); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseexpressions();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              if (input.charCodeAt(peg$currPos) === 46) {
+                s5 = peg$c51;
+                peg$currPos++;
+              } else {
+                s5 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c52); }
+              }
+              if (s5 === peg$FAILED) {
+                s5 = peg$c41;
+              }
+              if (s5 !== peg$FAILED) {
+                if (input.charCodeAt(peg$currPos) === 125) {
+                  s6 = peg$c65;
+                  peg$currPos++;
+                } else {
+                  s6 = peg$FAILED;
+                  if (peg$silentFails === 0) { peg$fail(peg$c66); }
+                }
+                if (s6 !== peg$FAILED) {
+                  peg$reportedPos = s0;
+                  s1 = peg$c67(s3);
+                  s0 = s1;
+                } else {
+                  peg$currPos = s0;
+                  s0 = peg$c1;
+                }
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsedynamicDictionary() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 21,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.substr(peg$currPos, 2) === peg$c68) {
+        s1 = peg$c68;
+        peg$currPos += 2;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c69); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseassociations();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              if (input.charCodeAt(peg$currPos) === 125) {
+                s5 = peg$c65;
+                peg$currPos++;
+              } else {
+                s5 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c66); }
+              }
+              if (s5 !== peg$FAILED) {
+                peg$reportedPos = s0;
+                s1 = peg$c70(s3);
+                s0 = s1;
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsepseudoVariable() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 22,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$currPos;
+      if (input.substr(peg$currPos, 4) === peg$c71) {
+        s2 = peg$c71;
+        peg$currPos += 4;
+      } else {
+        s2 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c72); }
+      }
+      if (s2 !== peg$FAILED) {
+        peg$reportedPos = s1;
+        s2 = peg$c73();
+      }
+      s1 = s2;
+      if (s1 === peg$FAILED) {
+        s1 = peg$currPos;
+        if (input.substr(peg$currPos, 5) === peg$c74) {
+          s2 = peg$c74;
+          peg$currPos += 5;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c75); }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s1;
+          s2 = peg$c76();
+        }
+        s1 = s2;
+        if (s1 === peg$FAILED) {
+          s1 = peg$currPos;
+          if (input.substr(peg$currPos, 3) === peg$c77) {
+            s2 = peg$c77;
+            peg$currPos += 3;
+          } else {
+            s2 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c78); }
+          }
+          if (s2 !== peg$FAILED) {
+            peg$reportedPos = s1;
+            s2 = peg$c79();
+          }
+          s1 = s2;
+        }
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c80(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseparseTimeLiteral() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 23,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parsepseudoVariable();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parsenumber();
+        if (s0 === peg$FAILED) {
+          s0 = peg$parseliteralArray();
+          if (s0 === peg$FAILED) {
+            s0 = peg$parsestring();
+            if (s0 === peg$FAILED) {
+              s0 = peg$parsesymbol();
+              if (s0 === peg$FAILED) {
+                s0 = peg$parsecharacter();
+              }
+            }
+          }
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseruntimeLiteral() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 24,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parsedynamicDictionary();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parsedynamicArray();
+        if (s0 === peg$FAILED) {
+          s0 = peg$parseblock();
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseliteral() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 25,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parseruntimeLiteral();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parseparseTimeLiteral();
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsevariable() {
+      var s0, s1;
+
+      var key    = peg$currPos * 60 + 26,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseidentifier();
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c81(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsekeywordPair() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 27,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsekeyword();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsebinarySend();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c82(s2, s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebinarySelector() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 28,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = [];
+      if (peg$c83.test(input.charAt(peg$currPos))) {
+        s2 = input.charAt(peg$currPos);
+        peg$currPos++;
+      } else {
+        s2 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c84); }
+      }
+      if (s2 !== peg$FAILED) {
+        while (s2 !== peg$FAILED) {
+          s1.push(s2);
+          if (peg$c83.test(input.charAt(peg$currPos))) {
+            s2 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s2 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c84); }
+          }
+        }
+      } else {
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c85(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsekeywordPattern() {
+      var s0, s1, s2, s3, s4, s5, s6;
+
+      var key    = peg$currPos * 60 + 29,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = [];
+      s2 = peg$currPos;
+      s3 = peg$parsews();
+      if (s3 !== peg$FAILED) {
+        s4 = peg$parsekeyword();
+        if (s4 !== peg$FAILED) {
+          s5 = peg$parsews();
+          if (s5 !== peg$FAILED) {
+            s6 = peg$parseidentifier();
+            if (s6 !== peg$FAILED) {
+              peg$reportedPos = s2;
+              s3 = peg$c82(s4, s6);
+              s2 = s3;
+            } else {
+              peg$currPos = s2;
+              s2 = peg$c1;
+            }
+          } else {
+            peg$currPos = s2;
+            s2 = peg$c1;
+          }
+        } else {
+          peg$currPos = s2;
+          s2 = peg$c1;
+        }
+      } else {
+        peg$currPos = s2;
+        s2 = peg$c1;
+      }
+      if (s2 !== peg$FAILED) {
+        while (s2 !== peg$FAILED) {
+          s1.push(s2);
+          s2 = peg$currPos;
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsekeyword();
+            if (s4 !== peg$FAILED) {
+              s5 = peg$parsews();
+              if (s5 !== peg$FAILED) {
+                s6 = peg$parseidentifier();
+                if (s6 !== peg$FAILED) {
+                  peg$reportedPos = s2;
+                  s3 = peg$c82(s4, s6);
+                  s2 = s3;
+                } else {
+                  peg$currPos = s2;
+                  s2 = peg$c1;
+                }
+              } else {
+                peg$currPos = s2;
+                s2 = peg$c1;
+              }
+            } else {
+              peg$currPos = s2;
+              s2 = peg$c1;
+            }
+          } else {
+            peg$currPos = s2;
+            s2 = peg$c1;
+          }
+        }
+      } else {
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c86(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebinaryPattern() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 30,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsebinarySelector();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parseidentifier();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c87(s2, s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseunaryPattern() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 31,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parseidentifier();
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c88(s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseexpression() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 32,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parseassignment();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parsecascade();
+        if (s0 === peg$FAILED) {
+          s0 = peg$parsekeywordSend();
+          if (s0 === peg$FAILED) {
+            s0 = peg$parsebinarySend();
+          }
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseexpressionList() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 33,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        if (input.charCodeAt(peg$currPos) === 46) {
+          s2 = peg$c51;
+          peg$currPos++;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c52); }
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parseexpression();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c89(s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseexpressions() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 34,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseexpression();
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        s3 = peg$parseexpressionList();
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          s3 = peg$parseexpressionList();
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c90(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseassignment() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 35,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsevariable();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          if (input.substr(peg$currPos, 2) === peg$c91) {
+            s3 = peg$c91;
+            peg$currPos += 2;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c92); }
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              s5 = peg$parseexpression();
+              if (s5 !== peg$FAILED) {
+                peg$reportedPos = s0;
+                s1 = peg$c93(s1, s5);
+                s0 = s1;
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseret() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 36,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 94) {
+        s1 = peg$c94;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c95); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseexpression();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              if (input.charCodeAt(peg$currPos) === 46) {
+                s5 = peg$c51;
+                peg$currPos++;
+              } else {
+                s5 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c52); }
+              }
+              if (s5 === peg$FAILED) {
+                s5 = peg$c41;
+              }
+              if (s5 !== peg$FAILED) {
+                peg$reportedPos = s0;
+                s1 = peg$c96(s3);
+                s0 = s1;
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsetemps() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 37,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 124) {
+        s1 = peg$c97;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c98); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        s3 = peg$currPos;
+        s4 = peg$parsews();
+        if (s4 !== peg$FAILED) {
+          s5 = peg$parseidentifier();
+          if (s5 !== peg$FAILED) {
+            peg$reportedPos = s3;
+            s4 = peg$c99(s5);
+            s3 = s4;
+          } else {
+            peg$currPos = s3;
+            s3 = peg$c1;
+          }
+        } else {
+          peg$currPos = s3;
+          s3 = peg$c1;
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          s3 = peg$currPos;
+          s4 = peg$parsews();
+          if (s4 !== peg$FAILED) {
+            s5 = peg$parseidentifier();
+            if (s5 !== peg$FAILED) {
+              peg$reportedPos = s3;
+              s4 = peg$c99(s5);
+              s3 = s4;
+            } else {
+              peg$currPos = s3;
+              s3 = peg$c1;
+            }
+          } else {
+            peg$currPos = s3;
+            s3 = peg$c1;
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            if (input.charCodeAt(peg$currPos) === 124) {
+              s4 = peg$c97;
+              peg$currPos++;
+            } else {
+              s4 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c98); }
+            }
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c100(s2);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseblockParamList() {
+      var s0, s1, s2, s3, s4, s5, s6;
+
+      var key    = peg$currPos * 60 + 38,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = [];
+      s2 = peg$currPos;
+      s3 = peg$parsews();
+      if (s3 !== peg$FAILED) {
+        if (input.charCodeAt(peg$currPos) === 58) {
+          s4 = peg$c13;
+          peg$currPos++;
+        } else {
+          s4 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c14); }
+        }
+        if (s4 !== peg$FAILED) {
+          s5 = peg$parsews();
+          if (s5 !== peg$FAILED) {
+            s6 = peg$parseidentifier();
+            if (s6 !== peg$FAILED) {
+              peg$reportedPos = s2;
+              s3 = peg$c101(s6);
+              s2 = s3;
+            } else {
+              peg$currPos = s2;
+              s2 = peg$c1;
+            }
+          } else {
+            peg$currPos = s2;
+            s2 = peg$c1;
+          }
+        } else {
+          peg$currPos = s2;
+          s2 = peg$c1;
+        }
+      } else {
+        peg$currPos = s2;
+        s2 = peg$c1;
+      }
+      if (s2 !== peg$FAILED) {
+        while (s2 !== peg$FAILED) {
+          s1.push(s2);
+          s2 = peg$currPos;
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            if (input.charCodeAt(peg$currPos) === 58) {
+              s4 = peg$c13;
+              peg$currPos++;
+            } else {
+              s4 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c14); }
+            }
+            if (s4 !== peg$FAILED) {
+              s5 = peg$parsews();
+              if (s5 !== peg$FAILED) {
+                s6 = peg$parseidentifier();
+                if (s6 !== peg$FAILED) {
+                  peg$reportedPos = s2;
+                  s3 = peg$c101(s6);
+                  s2 = s3;
+                } else {
+                  peg$currPos = s2;
+                  s2 = peg$c1;
+                }
+              } else {
+                peg$currPos = s2;
+                s2 = peg$c1;
+              }
+            } else {
+              peg$currPos = s2;
+              s2 = peg$c1;
+            }
+          } else {
+            peg$currPos = s2;
+            s2 = peg$c1;
+          }
+        }
+      } else {
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 124) {
+            s3 = peg$c97;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c98); }
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c102(s1);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsesubexpression() {
+      var s0, s1, s2, s3, s4, s5;
+
+      var key    = peg$currPos * 60 + 39,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 40) {
+        s1 = peg$c57;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c58); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseexpression();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              if (input.charCodeAt(peg$currPos) === 41) {
+                s5 = peg$c60;
+                peg$currPos++;
+              } else {
+                s5 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c61); }
+              }
+              if (s5 !== peg$FAILED) {
+                peg$reportedPos = s0;
+                s1 = peg$c89(s3);
+                s0 = s1;
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsestatements() {
+      var s0, s1, s2, s3, s4, s5, s6, s7;
+
+      var key    = peg$currPos * 60 + 40,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseret();
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        if (input.charCodeAt(peg$currPos) === 46) {
+          s3 = peg$c51;
+          peg$currPos++;
+        } else {
+          s3 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c52); }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          if (input.charCodeAt(peg$currPos) === 46) {
+            s3 = peg$c51;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c52); }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c103(s1);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+      if (s0 === peg$FAILED) {
+        s0 = peg$currPos;
+        s1 = peg$parseexpressions();
+        if (s1 !== peg$FAILED) {
+          s2 = peg$parsews();
+          if (s2 !== peg$FAILED) {
+            s3 = [];
+            if (input.charCodeAt(peg$currPos) === 46) {
+              s4 = peg$c51;
+              peg$currPos++;
+            } else {
+              s4 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c52); }
+            }
+            if (s4 !== peg$FAILED) {
+              while (s4 !== peg$FAILED) {
+                s3.push(s4);
+                if (input.charCodeAt(peg$currPos) === 46) {
+                  s4 = peg$c51;
+                  peg$currPos++;
+                } else {
+                  s4 = peg$FAILED;
+                  if (peg$silentFails === 0) { peg$fail(peg$c52); }
+                }
+              }
+            } else {
+              s3 = peg$c1;
+            }
+            if (s3 !== peg$FAILED) {
+              s4 = peg$parsews();
+              if (s4 !== peg$FAILED) {
+                s5 = peg$parseret();
+                if (s5 !== peg$FAILED) {
+                  s6 = [];
+                  if (input.charCodeAt(peg$currPos) === 46) {
+                    s7 = peg$c51;
+                    peg$currPos++;
+                  } else {
+                    s7 = peg$FAILED;
+                    if (peg$silentFails === 0) { peg$fail(peg$c52); }
+                  }
+                  while (s7 !== peg$FAILED) {
+                    s6.push(s7);
+                    if (input.charCodeAt(peg$currPos) === 46) {
+                      s7 = peg$c51;
+                      peg$currPos++;
+                    } else {
+                      s7 = peg$FAILED;
+                      if (peg$silentFails === 0) { peg$fail(peg$c52); }
+                    }
+                  }
+                  if (s6 !== peg$FAILED) {
+                    peg$reportedPos = s0;
+                    s1 = peg$c104(s1, s5);
+                    s0 = s1;
+                  } else {
+                    peg$currPos = s0;
+                    s0 = peg$c1;
+                  }
+                } else {
+                  peg$currPos = s0;
+                  s0 = peg$c1;
+                }
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+        if (s0 === peg$FAILED) {
+          s0 = peg$currPos;
+          s1 = peg$parseexpressions();
+          if (s1 === peg$FAILED) {
+            s1 = peg$c41;
+          }
+          if (s1 !== peg$FAILED) {
+            s2 = [];
+            if (input.charCodeAt(peg$currPos) === 46) {
+              s3 = peg$c51;
+              peg$currPos++;
+            } else {
+              s3 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c52); }
+            }
+            while (s3 !== peg$FAILED) {
+              s2.push(s3);
+              if (input.charCodeAt(peg$currPos) === 46) {
+                s3 = peg$c51;
+                peg$currPos++;
+              } else {
+                s3 = peg$FAILED;
+                if (peg$silentFails === 0) { peg$fail(peg$c52); }
+              }
+            }
+            if (s2 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c105(s1);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsesequence() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 41,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parsejsStatement();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parsestSequence();
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsestSequence() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 42,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsetemps();
+      if (s1 === peg$FAILED) {
+        s1 = peg$c41;
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsestatements();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c106(s1, s3);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseblock() {
+      var s0, s1, s2, s3, s4, s5, s6;
+
+      var key    = peg$currPos * 60 + 43,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 91) {
+        s1 = peg$c107;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c108); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parseblockParamList();
+        if (s2 === peg$FAILED) {
+          s2 = peg$c41;
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsesequence();
+            if (s4 === peg$FAILED) {
+              s4 = peg$c41;
+            }
+            if (s4 !== peg$FAILED) {
+              s5 = peg$parsews();
+              if (s5 !== peg$FAILED) {
+                if (input.charCodeAt(peg$currPos) === 93) {
+                  s6 = peg$c109;
+                  peg$currPos++;
+                } else {
+                  s6 = peg$FAILED;
+                  if (peg$silentFails === 0) { peg$fail(peg$c110); }
+                }
+                if (s6 !== peg$FAILED) {
+                  peg$reportedPos = s0;
+                  s1 = peg$c111(s2, s4);
+                  s0 = s1;
+                } else {
+                  peg$currPos = s0;
+                  s0 = peg$c1;
+                }
+              } else {
+                peg$currPos = s0;
+                s0 = peg$c1;
+              }
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseoperand() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 44,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parseliteral();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parsevariable();
+        if (s0 === peg$FAILED) {
+          s0 = peg$parsesubexpression();
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseunaryMessage() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 45,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parseidentifier();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$currPos;
+          peg$silentFails++;
+          if (input.charCodeAt(peg$currPos) === 58) {
+            s4 = peg$c13;
+            peg$currPos++;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c14); }
+          }
+          peg$silentFails--;
+          if (s4 === peg$FAILED) {
+            s3 = peg$c112;
+          } else {
+            peg$currPos = s3;
+            s3 = peg$c1;
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c113(s2);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseunaryTail() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 46,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseunaryMessage();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseunaryTail();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c114(s1, s3);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseunarySend() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 47,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseoperand();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parseunaryTail();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c115(s1, s3);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebinaryMessage() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 48,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsebinarySelector();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parseunarySend();
+            if (s4 === peg$FAILED) {
+              s4 = peg$parseoperand();
+            }
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c116(s2, s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebinaryTail() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 49,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsebinaryMessage();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsebinaryTail();
+        if (s2 === peg$FAILED) {
+          s2 = peg$c41;
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c117(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsebinarySend() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 50,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseunarySend();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsebinaryTail();
+        if (s2 === peg$FAILED) {
+          s2 = peg$c41;
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c115(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsekeywordMessage() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 51,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = [];
+      s2 = peg$parsekeywordPair();
+      if (s2 !== peg$FAILED) {
+        while (s2 !== peg$FAILED) {
+          s1.push(s2);
+          s2 = peg$parsekeywordPair();
+        }
+      } else {
+        s1 = peg$c1;
+      }
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = s0;
+        s1 = peg$c118(s1);
+      }
+      s0 = s1;
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsekeywordSend() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 52,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsebinarySend();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsekeywordMessage();
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c119(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsemessage() {
+      var s0;
+
+      var key    = peg$currPos * 60 + 53,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$parsebinaryMessage();
+      if (s0 === peg$FAILED) {
+        s0 = peg$parseunaryMessage();
+        if (s0 === peg$FAILED) {
+          s0 = peg$parsekeywordMessage();
+        }
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsecascade() {
+      var s0, s1, s2, s3, s4, s5, s6, s7, s8;
+
+      var key    = peg$currPos * 60 + 54,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsekeywordSend();
+        if (s2 === peg$FAILED) {
+          s2 = peg$parsebinarySend();
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = [];
+          s4 = peg$currPos;
+          s5 = peg$parsews();
+          if (s5 !== peg$FAILED) {
+            if (input.charCodeAt(peg$currPos) === 59) {
+              s6 = peg$c120;
+              peg$currPos++;
+            } else {
+              s6 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c121); }
+            }
+            if (s6 !== peg$FAILED) {
+              s7 = peg$parsews();
+              if (s7 !== peg$FAILED) {
+                s8 = peg$parsemessage();
+                if (s8 !== peg$FAILED) {
+                  peg$reportedPos = s4;
+                  s5 = peg$c122(s8);
+                  s4 = s5;
+                } else {
+                  peg$currPos = s4;
+                  s4 = peg$c1;
+                }
+              } else {
+                peg$currPos = s4;
+                s4 = peg$c1;
+              }
+            } else {
+              peg$currPos = s4;
+              s4 = peg$c1;
+            }
+          } else {
+            peg$currPos = s4;
+            s4 = peg$c1;
+          }
+          if (s4 !== peg$FAILED) {
+            while (s4 !== peg$FAILED) {
+              s3.push(s4);
+              s4 = peg$currPos;
+              s5 = peg$parsews();
+              if (s5 !== peg$FAILED) {
+                if (input.charCodeAt(peg$currPos) === 59) {
+                  s6 = peg$c120;
+                  peg$currPos++;
+                } else {
+                  s6 = peg$FAILED;
+                  if (peg$silentFails === 0) { peg$fail(peg$c121); }
+                }
+                if (s6 !== peg$FAILED) {
+                  s7 = peg$parsews();
+                  if (s7 !== peg$FAILED) {
+                    s8 = peg$parsemessage();
+                    if (s8 !== peg$FAILED) {
+                      peg$reportedPos = s4;
+                      s5 = peg$c122(s8);
+                      s4 = s5;
+                    } else {
+                      peg$currPos = s4;
+                      s4 = peg$c1;
+                    }
+                  } else {
+                    peg$currPos = s4;
+                    s4 = peg$c1;
+                  }
+                } else {
+                  peg$currPos = s4;
+                  s4 = peg$c1;
+                }
+              } else {
+                peg$currPos = s4;
+                s4 = peg$c1;
+              }
+            }
+          } else {
+            s3 = peg$c1;
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c123(s2, s3);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsejsStatement() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 55,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      if (input.charCodeAt(peg$currPos) === 60) {
+        s1 = peg$c124;
+        peg$currPos++;
+      } else {
+        s1 = peg$FAILED;
+        if (peg$silentFails === 0) { peg$fail(peg$c125); }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        s3 = peg$currPos;
+        if (input.substr(peg$currPos, 2) === peg$c126) {
+          s4 = peg$c126;
+          peg$currPos += 2;
+        } else {
+          s4 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c127); }
+        }
+        if (s4 !== peg$FAILED) {
+          peg$reportedPos = s3;
+          s4 = peg$c128();
+        }
+        s3 = s4;
+        if (s3 === peg$FAILED) {
+          if (peg$c129.test(input.charAt(peg$currPos))) {
+            s3 = input.charAt(peg$currPos);
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c130); }
+          }
+        }
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          s3 = peg$currPos;
+          if (input.substr(peg$currPos, 2) === peg$c126) {
+            s4 = peg$c126;
+            peg$currPos += 2;
+          } else {
+            s4 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c127); }
+          }
+          if (s4 !== peg$FAILED) {
+            peg$reportedPos = s3;
+            s4 = peg$c128();
+          }
+          s3 = s4;
+          if (s3 === peg$FAILED) {
+            if (peg$c129.test(input.charAt(peg$currPos))) {
+              s3 = input.charAt(peg$currPos);
+              peg$currPos++;
+            } else {
+              s3 = peg$FAILED;
+              if (peg$silentFails === 0) { peg$fail(peg$c130); }
+            }
+          }
+        }
+        if (s2 !== peg$FAILED) {
+          if (input.charCodeAt(peg$currPos) === 62) {
+            s3 = peg$c131;
+            peg$currPos++;
+          } else {
+            s3 = peg$FAILED;
+            if (peg$silentFails === 0) { peg$fail(peg$c132); }
+          }
+          if (s3 !== peg$FAILED) {
+            peg$reportedPos = s0;
+            s1 = peg$c133(s2);
+            s0 = s1;
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parsemethod() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 56,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsekeywordPattern();
+      if (s1 === peg$FAILED) {
+        s1 = peg$parsebinaryPattern();
+        if (s1 === peg$FAILED) {
+          s1 = peg$parseunaryPattern();
+        }
+      }
+      if (s1 !== peg$FAILED) {
+        s2 = peg$parsews();
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsesequence();
+          if (s3 === peg$FAILED) {
+            s3 = peg$c41;
+          }
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parsews();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c134(s1, s3);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseassociationSend() {
+      var s0, s1, s2;
+
+      var key    = peg$currPos * 60 + 57,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsebinarySend();
+      if (s1 !== peg$FAILED) {
+        peg$reportedPos = peg$currPos;
+        s2 = peg$c135(s1);
+        if (s2) {
+          s2 = peg$c112;
+        } else {
+          s2 = peg$c1;
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c136(s1);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseassociationList() {
+      var s0, s1, s2, s3, s4;
+
+      var key    = peg$currPos * 60 + 58,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parsews();
+      if (s1 !== peg$FAILED) {
+        if (input.charCodeAt(peg$currPos) === 46) {
+          s2 = peg$c51;
+          peg$currPos++;
+        } else {
+          s2 = peg$FAILED;
+          if (peg$silentFails === 0) { peg$fail(peg$c52); }
+        }
+        if (s2 !== peg$FAILED) {
+          s3 = peg$parsews();
+          if (s3 !== peg$FAILED) {
+            s4 = peg$parseassociationSend();
+            if (s4 !== peg$FAILED) {
+              peg$reportedPos = s0;
+              s1 = peg$c89(s4);
+              s0 = s1;
+            } else {
+              peg$currPos = s0;
+              s0 = peg$c1;
+            }
+          } else {
+            peg$currPos = s0;
+            s0 = peg$c1;
+          }
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    function peg$parseassociations() {
+      var s0, s1, s2, s3;
+
+      var key    = peg$currPos * 60 + 59,
+          cached = peg$cache[key];
+
+      if (cached) {
+        peg$currPos = cached.nextPos;
+        return cached.result;
+      }
+
+      s0 = peg$currPos;
+      s1 = peg$parseassociationSend();
+      if (s1 !== peg$FAILED) {
+        s2 = [];
+        s3 = peg$parseassociationList();
+        while (s3 !== peg$FAILED) {
+          s2.push(s3);
+          s3 = peg$parseassociationList();
+        }
+        if (s2 !== peg$FAILED) {
+          peg$reportedPos = s0;
+          s1 = peg$c137(s1, s2);
+          s0 = s1;
+        } else {
+          peg$currPos = s0;
+          s0 = peg$c1;
+        }
+      } else {
+        peg$currPos = s0;
+        s0 = peg$c1;
+      }
+
+      peg$cache[key] = { nextPos: peg$currPos, result: s0 };
+
+      return s0;
+    }
+
+    peg$result = peg$startRuleFunction();
+
+    if (peg$result !== peg$FAILED && peg$currPos === input.length) {
+      return peg$result;
+    } else {
+      if (peg$result !== peg$FAILED && peg$currPos < input.length) {
+        peg$fail({ type: "end", description: "end of input" });
+      }
+
+      throw peg$buildException(null, peg$maxFailExpected, peg$maxFailPos);
+    }
+  }
+
+  return {
+    SyntaxError: SyntaxError,
+    parse:       parse
+  };
+})();
+});

+ 270 - 0
bower_components/amber/support/parser.pegjs

@@ -0,0 +1,270 @@
+start = method
+
+separator      = [ \t\v\f\u00A0\uFEFF\n\r\u2028\u2029]+
+comments       = ('"' [^"]* '"')+
+ws             = (separator / comments)*
+identifier     = first:[a-zA-Z] others:[a-zA-Z0-9]* {return first + others.join("");}
+keyword        = first:identifier last:":" {return first + last;}
+selector      = first:[a-zA-Z] others:[a-zA-Z0-9\:]* {return first + others.join("");}
+className      = first:[A-Z] others:[a-zA-Z0-9]* {return first + others.join("");}
+string         = "'" val:(("''" {return "'";} / [^'])*) "'" {
+                     return $globals.ValueNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._value_(val.join(""));
+                 }
+character      = "$" char:. 
+                  {
+                      return $globals.ValueNode._new()
+                             ._position_((line()).__at(column()))
+                             ._source_(text())
+                             ._value_(char);
+                  }
+symbol         = "#" rest:bareSymbol {return rest;}
+bareSymbol         = val:(selector / binarySelector / node:string {return node._value();})
+                  {
+                      return $globals.ValueNode._new()
+                             ._position_((line()).__at(column()))
+                             ._source_(text())
+                             ._value_(val);
+                  }
+number         = n:(numberExp / hex / float / integer) {
+                     return $globals.ValueNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._value_(n);
+                 }
+numberExp      = n:((float / integer) "e" integer) {return parseFloat(n.join(""));}
+hex            = neg:"-"? "16r" num:[0-9a-fA-F]+ {return parseInt(((neg || '') + num.join("")), 16);}
+float          = neg:"-"? digits:[0-9]+ "." dec:[0-9]+ {return parseFloat(((neg || '') + digits.join("") + "." + dec.join("")), 10);}
+integer        = neg:"-"? digits:[0-9]+ {return (parseInt((neg || '') + digits.join(""), 10));}
+
+literalArray   = "#(" rest:literalArrayRest {return rest;}
+bareLiteralArray   = "(" rest:literalArrayRest {return rest;}
+literalArrayRest   = lits:(ws lit:(parseTimeLiteral / bareLiteralArray / bareSymbol) {return lit._value();})* ws ")" {
+                     return $globals.ValueNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._value_(lits);
+                 }
+dynamicArray   = "{" ws expressions:expressions? ws "."? "}" {
+                     return $globals.DynamicArrayNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._nodes_(expressions || []);
+                 }
+dynamicDictionary = "#{" ws expressions:associations? ws "}" {
+                        return $globals.DynamicDictionaryNode._new()
+                               ._position_((line()).__at(column()))
+                               ._source_(text())
+                               ._nodes_(expressions || []);
+                    }
+pseudoVariable = val:(
+                   'true' {return true;}
+                 / 'false' {return false;}
+                 / 'nil' {return nil;}) {
+                       return $globals.ValueNode._new()
+                              ._position_((line()).__at(column()))
+                              ._source_(text())
+                              ._value_(val);
+                   }
+parseTimeLiteral        = pseudoVariable / number / literalArray / string / symbol / character
+runtimeLiteral        = dynamicDictionary / dynamicArray / block
+literal        = runtimeLiteral / parseTimeLiteral
+
+
+variable       = identifier:identifier {
+                     return $globals.VariableNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._value_(identifier);
+                 }
+
+reference      = variable
+
+keywordPair    = ws key:keyword ws arg:binarySend {return {key:key, arg:arg};}
+
+binarySelector = bin:[\\+*/=><,@%~|&-]+ {return bin.join("");}
+unarySelector  = identifier
+
+keywordPattern = pairs:(ws key:keyword ws arg:identifier {return {key:key, arg:arg};})+ {
+                     var keywords = [];
+                     var params = [];
+                     var i = 0;
+                     for(i = 0; i < pairs.length; i++){
+                         keywords.push(pairs[i].key);
+                     }
+                     for(i = 0; i < pairs.length; i++){
+                         params.push(pairs[i].arg);
+                     }
+                     return [keywords.join(""), params];
+                 }
+binaryPattern  = ws selector:binarySelector ws arg:identifier {return [selector, [arg]];}
+unaryPattern   = ws selector:unarySelector {return [selector, []];}
+
+expression     = assignment / cascade / keywordSend / binarySend
+
+expressionList = ws "." ws expression:expression {return expression;}
+expressions    = first:expression others:expressionList* { return [first].concat(others); }
+
+assignment     = variable:variable ws ':=' ws expression:expression {
+                     return $globals.AssignmentNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._left_(variable)
+                            ._right_(expression);
+                 }
+
+ret            = '^' ws expression:expression ws '.'? {
+                     return $globals.ReturnNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._nodes_([expression]);
+                 }
+  
+temps          = "|" vars:(ws variable:identifier {return variable;})* ws "|" {return vars;}
+
+blockParamList = params:((ws ":" ws param:identifier {return param;})+) ws "|" {return params;}
+
+subexpression  = '(' ws expression:expression ws ')' {return expression;}
+
+statements     = ret:ret "."* {return [ret];}
+                 / exps:expressions ws "."+ ws ret:ret "."* {
+                       var expressions = exps;
+                       expressions.push(ret);
+                       return expressions;
+                   }
+                 / expressions:expressions? "."* {
+                       return expressions || [];
+                   }
+
+sequence       = jsSequence / stSequence
+
+stSequence     = temps:temps? ws statements:statements? ws {
+                     return $globals.SequenceNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._temps_(temps || [])
+                            ._nodes_(statements || []);
+                 }
+
+jsSequence     = jsStatement
+
+block          = '[' params:blockParamList? ws sequence:sequence? ws ']' {
+                     return $globals.BlockNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._parameters_(params || [])
+                            ._nodes_([sequence._asBlockSequenceNode()]);
+                 }
+
+operand        = literal / reference / subexpression
+
+
+
+unaryMessage   = ws selector:unarySelector !":" {
+                     return $globals.SendNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._selector_(selector);
+                 }
+
+unaryTail      = message:unaryMessage ws tail:unaryTail? ws {
+                     if(tail) {
+                         return tail._valueForReceiver_(message);
+                     }
+                     else {
+                         return message;
+                     }
+                 }
+
+unarySend      = receiver:operand ws tail:unaryTail? {
+                     if(tail) {
+                         return tail._valueForReceiver_(receiver);
+                     }
+                     else {
+                         return receiver;
+                     }
+                 }
+
+binaryMessage  = ws selector:binarySelector ws arg:(unarySend / operand) {
+                     return $globals.SendNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._selector_(selector)
+                            ._arguments_([arg]);
+                 }
+
+binaryTail     = message:binaryMessage tail:binaryTail? {
+                     if(tail) {
+                         return tail._valueForReceiver_(message);
+                      }
+                     else {
+                         return message;
+                     }
+                 }
+
+binarySend     = receiver:unarySend tail:binaryTail? {
+                     if(tail) {
+                         return tail._valueForReceiver_(receiver);
+                     }
+                     else {
+                         return receiver;
+                     }
+                 }
+
+
+keywordMessage = pairs:keywordPair+ {
+                     var selector = [];
+                     var args = [];
+                      for(var i = 0; i < pairs.length; i++) {
+                          selector.push(pairs[i].key);
+                          args.push(pairs[i].arg);
+                      }
+                      return $globals.SendNode._new()
+                             ._position_((line()).__at(column()))
+                             ._source_(text())
+                             ._selector_(selector.join(""))
+                             ._arguments_(args);
+                 }
+
+keywordSend    = receiver:binarySend tail:keywordMessage {
+                     return tail._valueForReceiver_(receiver);
+                 }
+
+message        = binaryMessage / unaryMessage / keywordMessage
+
+cascade        = ws send:(keywordSend / binarySend) messages:(ws ";" ws mess:message {return mess;})+ {
+                     var cascade = [];
+                     cascade.push(send);
+                     for(var i = 0; i < messages.length; i++) {
+                         cascade.push(messages[i]);
+                     }
+                     return $globals.CascadeNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(text())
+                            ._receiver_(send._receiver())
+                            ._nodes_(cascade);
+                 }
+
+jsStatement    = "<" val:((">>" {return ">";} / [^>])*) ">" {
+                     return $globals.JSStatementNode._new()
+                            ._position_((line()).__at(column()))
+                            ._source_(val.join(""))
+                 }
+
+
+method         = pattern:(keywordPattern / binaryPattern / unaryPattern) ws sequence:sequence? ws {
+                      return $globals.MethodNode._new()
+                             ._position_((line()).__at(column()))
+                             ._source_(text())
+                             ._selector_(pattern[0])
+                             ._arguments_(pattern[1])
+                             ._nodes_([sequence]);
+                 }
+
+
+associationSend     = send:binarySend & { return send._selector() === "->" } { return [send._receiver(), send._arguments()[0]]; }
+
+associationList = ws "." ws expression:associationSend {return expression;}
+associations    = first:associationSend others:associationList* { return first.concat.apply(first, others); }

+ 36 - 0
bower_components/amber/support/requirejs/require.min.js

@@ -0,0 +1,36 @@
+/*
+ RequireJS 2.1.14 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
+ Available via the MIT or new BSD license.
+ see: http://github.com/jrburke/requirejs for details
+*/
+var requirejs,require,define;
+(function(ba){function G(b){return"[object Function]"===K.call(b)}function H(b){return"[object Array]"===K.call(b)}function v(b,c){if(b){var d;for(d=0;d<b.length&&(!b[d]||!c(b[d],d,b));d+=1);}}function T(b,c){if(b){var d;for(d=b.length-1;-1<d&&(!b[d]||!c(b[d],d,b));d-=1);}}function t(b,c){return fa.call(b,c)}function m(b,c){return t(b,c)&&b[c]}function B(b,c){for(var d in b)if(t(b,d)&&c(b[d],d))break}function U(b,c,d,e){c&&B(c,function(c,g){if(d||!t(b,g))e&&"object"===typeof c&&c&&!H(c)&&!G(c)&&!(c instanceof
+RegExp)?(b[g]||(b[g]={}),U(b[g],c,d,e)):b[g]=c});return b}function u(b,c){return function(){return c.apply(b,arguments)}}function ca(b){throw b;}function da(b){if(!b)return b;var c=ba;v(b.split("."),function(b){c=c[b]});return c}function C(b,c,d,e){c=Error(c+"\nhttp://requirejs.org/docs/errors.html#"+b);c.requireType=b;c.requireModules=e;d&&(c.originalError=d);return c}function ga(b){function c(a,k,b){var f,l,c,d,e,g,i,p,k=k&&k.split("/"),h=j.map,n=h&&h["*"];if(a){a=a.split("/");l=a.length-1;j.nodeIdCompat&&
+Q.test(a[l])&&(a[l]=a[l].replace(Q,""));"."===a[0].charAt(0)&&k&&(l=k.slice(0,k.length-1),a=l.concat(a));l=a;for(c=0;c<l.length;c++)if(d=l[c],"."===d)l.splice(c,1),c-=1;else if(".."===d&&!(0===c||1==c&&".."===l[2]||".."===l[c-1])&&0<c)l.splice(c-1,2),c-=2;a=a.join("/")}if(b&&h&&(k||n)){l=a.split("/");c=l.length;a:for(;0<c;c-=1){e=l.slice(0,c).join("/");if(k)for(d=k.length;0<d;d-=1)if(b=m(h,k.slice(0,d).join("/")))if(b=m(b,e)){f=b;g=c;break a}!i&&(n&&m(n,e))&&(i=m(n,e),p=c)}!f&&i&&(f=i,g=p);f&&(l.splice(0,
+g,f),a=l.join("/"))}return(f=m(j.pkgs,a))?f:a}function d(a){z&&v(document.getElementsByTagName("script"),function(k){if(k.getAttribute("data-requiremodule")===a&&k.getAttribute("data-requirecontext")===i.contextName)return k.parentNode.removeChild(k),!0})}function e(a){var k=m(j.paths,a);if(k&&H(k)&&1<k.length)return k.shift(),i.require.undef(a),i.makeRequire(null,{skipMap:!0})([a]),!0}function n(a){var k,c=a?a.indexOf("!"):-1;-1<c&&(k=a.substring(0,c),a=a.substring(c+1,a.length));return[k,a]}function p(a,
+k,b,f){var l,d,e=null,g=k?k.name:null,j=a,p=!0,h="";a||(p=!1,a="_@r"+(K+=1));a=n(a);e=a[0];a=a[1];e&&(e=c(e,g,f),d=m(r,e));a&&(e?h=d&&d.normalize?d.normalize(a,function(a){return c(a,g,f)}):-1===a.indexOf("!")?c(a,g,f):a:(h=c(a,g,f),a=n(h),e=a[0],h=a[1],b=!0,l=i.nameToUrl(h)));b=e&&!d&&!b?"_unnormalized"+(O+=1):"";return{prefix:e,name:h,parentMap:k,unnormalized:!!b,url:l,originalName:j,isDefine:p,id:(e?e+"!"+h:h)+b}}function s(a){var k=a.id,b=m(h,k);b||(b=h[k]=new i.Module(a));return b}function q(a,
+k,b){var f=a.id,c=m(h,f);if(t(r,f)&&(!c||c.defineEmitComplete))"defined"===k&&b(r[f]);else if(c=s(a),c.error&&"error"===k)b(c.error);else c.on(k,b)}function w(a,b){var c=a.requireModules,f=!1;if(b)b(a);else if(v(c,function(b){if(b=m(h,b))b.error=a,b.events.error&&(f=!0,b.emit("error",a))}),!f)g.onError(a)}function x(){R.length&&(ha.apply(A,[A.length,0].concat(R)),R=[])}function y(a){delete h[a];delete V[a]}function F(a,b,c){var f=a.map.id;a.error?a.emit("error",a.error):(b[f]=!0,v(a.depMaps,function(f,
+d){var e=f.id,g=m(h,e);g&&(!a.depMatched[d]&&!c[e])&&(m(b,e)?(a.defineDep(d,r[e]),a.check()):F(g,b,c))}),c[f]=!0)}function D(){var a,b,c=(a=1E3*j.waitSeconds)&&i.startTime+a<(new Date).getTime(),f=[],l=[],g=!1,h=!0;if(!W){W=!0;B(V,function(a){var i=a.map,j=i.id;if(a.enabled&&(i.isDefine||l.push(a),!a.error))if(!a.inited&&c)e(j)?g=b=!0:(f.push(j),d(j));else if(!a.inited&&(a.fetched&&i.isDefine)&&(g=!0,!i.prefix))return h=!1});if(c&&f.length)return a=C("timeout","Load timeout for modules: "+f,null,
+f),a.contextName=i.contextName,w(a);h&&v(l,function(a){F(a,{},{})});if((!c||b)&&g)if((z||ea)&&!X)X=setTimeout(function(){X=0;D()},50);W=!1}}function E(a){t(r,a[0])||s(p(a[0],null,!0)).init(a[1],a[2])}function I(a){var a=a.currentTarget||a.srcElement,b=i.onScriptLoad;a.detachEvent&&!Y?a.detachEvent("onreadystatechange",b):a.removeEventListener("load",b,!1);b=i.onScriptError;(!a.detachEvent||Y)&&a.removeEventListener("error",b,!1);return{node:a,id:a&&a.getAttribute("data-requiremodule")}}function J(){var a;
+for(x();A.length;){a=A.shift();if(null===a[0])return w(C("mismatch","Mismatched anonymous define() module: "+a[a.length-1]));E(a)}}var W,Z,i,L,X,j={waitSeconds:7,baseUrl:"./",paths:{},bundles:{},pkgs:{},shim:{},config:{}},h={},V={},$={},A=[],r={},S={},aa={},K=1,O=1;L={require:function(a){return a.require?a.require:a.require=i.makeRequire(a.map)},exports:function(a){a.usingExports=!0;if(a.map.isDefine)return a.exports?r[a.map.id]=a.exports:a.exports=r[a.map.id]={}},module:function(a){return a.module?
+a.module:a.module={id:a.map.id,uri:a.map.url,config:function(){return m(j.config,a.map.id)||{}},exports:a.exports||(a.exports={})}}};Z=function(a){this.events=m($,a.id)||{};this.map=a;this.shim=m(j.shim,a.id);this.depExports=[];this.depMaps=[];this.depMatched=[];this.pluginMaps={};this.depCount=0};Z.prototype={init:function(a,b,c,f){f=f||{};if(!this.inited){this.factory=b;if(c)this.on("error",c);else this.events.error&&(c=u(this,function(a){this.emit("error",a)}));this.depMaps=a&&a.slice(0);this.errback=
+c;this.inited=!0;this.ignore=f.ignore;f.enabled||this.enabled?this.enable():this.check()}},defineDep:function(a,b){this.depMatched[a]||(this.depMatched[a]=!0,this.depCount-=1,this.depExports[a]=b)},fetch:function(){if(!this.fetched){this.fetched=!0;i.startTime=(new Date).getTime();var a=this.map;if(this.shim)i.makeRequire(this.map,{enableBuildCallback:!0})(this.shim.deps||[],u(this,function(){return a.prefix?this.callPlugin():this.load()}));else return a.prefix?this.callPlugin():this.load()}},load:function(){var a=
+this.map.url;S[a]||(S[a]=!0,i.load(this.map.id,a))},check:function(){if(this.enabled&&!this.enabling){var a,b,c=this.map.id;b=this.depExports;var f=this.exports,l=this.factory;if(this.inited)if(this.error)this.emit("error",this.error);else{if(!this.defining){this.defining=!0;if(1>this.depCount&&!this.defined){if(G(l)){if(this.events.error&&this.map.isDefine||g.onError!==ca)try{f=i.execCb(c,l,b,f)}catch(d){a=d}else f=i.execCb(c,l,b,f);this.map.isDefine&&void 0===f&&((b=this.module)?f=b.exports:this.usingExports&&
+(f=this.exports));if(a)return a.requireMap=this.map,a.requireModules=this.map.isDefine?[this.map.id]:null,a.requireType=this.map.isDefine?"define":"require",w(this.error=a)}else f=l;this.exports=f;if(this.map.isDefine&&!this.ignore&&(r[c]=f,g.onResourceLoad))g.onResourceLoad(i,this.map,this.depMaps);y(c);this.defined=!0}this.defining=!1;this.defined&&!this.defineEmitted&&(this.defineEmitted=!0,this.emit("defined",this.exports),this.defineEmitComplete=!0)}}else this.fetch()}},callPlugin:function(){var a=
+this.map,b=a.id,d=p(a.prefix);this.depMaps.push(d);q(d,"defined",u(this,function(f){var l,d;d=m(aa,this.map.id);var e=this.map.name,P=this.map.parentMap?this.map.parentMap.name:null,n=i.makeRequire(a.parentMap,{enableBuildCallback:!0});if(this.map.unnormalized){if(f.normalize&&(e=f.normalize(e,function(a){return c(a,P,!0)})||""),f=p(a.prefix+"!"+e,this.map.parentMap),q(f,"defined",u(this,function(a){this.init([],function(){return a},null,{enabled:!0,ignore:!0})})),d=m(h,f.id)){this.depMaps.push(f);
+if(this.events.error)d.on("error",u(this,function(a){this.emit("error",a)}));d.enable()}}else d?(this.map.url=i.nameToUrl(d),this.load()):(l=u(this,function(a){this.init([],function(){return a},null,{enabled:!0})}),l.error=u(this,function(a){this.inited=!0;this.error=a;a.requireModules=[b];B(h,function(a){0===a.map.id.indexOf(b+"_unnormalized")&&y(a.map.id)});w(a)}),l.fromText=u(this,function(f,c){var d=a.name,e=p(d),P=M;c&&(f=c);P&&(M=!1);s(e);t(j.config,b)&&(j.config[d]=j.config[b]);try{g.exec(f)}catch(h){return w(C("fromtexteval",
+"fromText eval for "+b+" failed: "+h,h,[b]))}P&&(M=!0);this.depMaps.push(e);i.completeLoad(d);n([d],l)}),f.load(a.name,n,l,j))}));i.enable(d,this);this.pluginMaps[d.id]=d},enable:function(){V[this.map.id]=this;this.enabling=this.enabled=!0;v(this.depMaps,u(this,function(a,b){var c,f;if("string"===typeof a){a=p(a,this.map.isDefine?this.map:this.map.parentMap,!1,!this.skipMap);this.depMaps[b]=a;if(c=m(L,a.id)){this.depExports[b]=c(this);return}this.depCount+=1;q(a,"defined",u(this,function(a){this.defineDep(b,
+a);this.check()}));this.errback&&q(a,"error",u(this,this.errback))}c=a.id;f=h[c];!t(L,c)&&(f&&!f.enabled)&&i.enable(a,this)}));B(this.pluginMaps,u(this,function(a){var b=m(h,a.id);b&&!b.enabled&&i.enable(a,this)}));this.enabling=!1;this.check()},on:function(a,b){var c=this.events[a];c||(c=this.events[a]=[]);c.push(b)},emit:function(a,b){v(this.events[a],function(a){a(b)});"error"===a&&delete this.events[a]}};i={config:j,contextName:b,registry:h,defined:r,urlFetched:S,defQueue:A,Module:Z,makeModuleMap:p,
+nextTick:g.nextTick,onError:w,configure:function(a){a.baseUrl&&"/"!==a.baseUrl.charAt(a.baseUrl.length-1)&&(a.baseUrl+="/");var b=j.shim,c={paths:!0,bundles:!0,config:!0,map:!0};B(a,function(a,b){c[b]?(j[b]||(j[b]={}),U(j[b],a,!0,!0)):j[b]=a});a.bundles&&B(a.bundles,function(a,b){v(a,function(a){a!==b&&(aa[a]=b)})});a.shim&&(B(a.shim,function(a,c){H(a)&&(a={deps:a});if((a.exports||a.init)&&!a.exportsFn)a.exportsFn=i.makeShimExports(a);b[c]=a}),j.shim=b);a.packages&&v(a.packages,function(a){var b,
+a="string"===typeof a?{name:a}:a;b=a.name;a.location&&(j.paths[b]=a.location);j.pkgs[b]=a.name+"/"+(a.main||"main").replace(ia,"").replace(Q,"")});B(h,function(a,b){!a.inited&&!a.map.unnormalized&&(a.map=p(b))});if(a.deps||a.callback)i.require(a.deps||[],a.callback)},makeShimExports:function(a){return function(){var b;a.init&&(b=a.init.apply(ba,arguments));return b||a.exports&&da(a.exports)}},makeRequire:function(a,e){function j(c,d,m){var n,q;e.enableBuildCallback&&(d&&G(d))&&(d.__requireJsBuild=
+!0);if("string"===typeof c){if(G(d))return w(C("requireargs","Invalid require call"),m);if(a&&t(L,c))return L[c](h[a.id]);if(g.get)return g.get(i,c,a,j);n=p(c,a,!1,!0);n=n.id;return!t(r,n)?w(C("notloaded",'Module name "'+n+'" has not been loaded yet for context: '+b+(a?"":". Use require([])"))):r[n]}J();i.nextTick(function(){J();q=s(p(null,a));q.skipMap=e.skipMap;q.init(c,d,m,{enabled:!0});D()});return j}e=e||{};U(j,{isBrowser:z,toUrl:function(b){var d,e=b.lastIndexOf("."),k=b.split("/")[0];if(-1!==
+e&&(!("."===k||".."===k)||1<e))d=b.substring(e,b.length),b=b.substring(0,e);return i.nameToUrl(c(b,a&&a.id,!0),d,!0)},defined:function(b){return t(r,p(b,a,!1,!0).id)},specified:function(b){b=p(b,a,!1,!0).id;return t(r,b)||t(h,b)}});a||(j.undef=function(b){x();var c=p(b,a,!0),e=m(h,b);d(b);delete r[b];delete S[c.url];delete $[b];T(A,function(a,c){a[0]===b&&A.splice(c,1)});e&&(e.events.defined&&($[b]=e.events),y(b))});return j},enable:function(a){m(h,a.id)&&s(a).enable()},completeLoad:function(a){var b,
+c,d=m(j.shim,a)||{},g=d.exports;for(x();A.length;){c=A.shift();if(null===c[0]){c[0]=a;if(b)break;b=!0}else c[0]===a&&(b=!0);E(c)}c=m(h,a);if(!b&&!t(r,a)&&c&&!c.inited){if(j.enforceDefine&&(!g||!da(g)))return e(a)?void 0:w(C("nodefine","No define call for "+a,null,[a]));E([a,d.deps||[],d.exportsFn])}D()},nameToUrl:function(a,b,c){var d,e,h;(d=m(j.pkgs,a))&&(a=d);if(d=m(aa,a))return i.nameToUrl(d,b,c);if(g.jsExtRegExp.test(a))d=a+(b||"");else{d=j.paths;a=a.split("/");for(e=a.length;0<e;e-=1)if(h=a.slice(0,
+e).join("/"),h=m(d,h)){H(h)&&(h=h[0]);a.splice(0,e,h);break}d=a.join("/");d+=b||(/^data\:|\?/.test(d)||c?"":".js");d=("/"===d.charAt(0)||d.match(/^[\w\+\.\-]+:/)?"":j.baseUrl)+d}return j.urlArgs?d+((-1===d.indexOf("?")?"?":"&")+j.urlArgs):d},load:function(a,b){g.load(i,a,b)},execCb:function(a,b,c,d){return b.apply(d,c)},onScriptLoad:function(a){if("load"===a.type||ja.test((a.currentTarget||a.srcElement).readyState))N=null,a=I(a),i.completeLoad(a.id)},onScriptError:function(a){var b=I(a);if(!e(b.id))return w(C("scripterror",
+"Script error for: "+b.id,a,[b.id]))}};i.require=i.makeRequire();return i}var g,x,y,D,I,E,N,J,s,O,ka=/(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg,la=/[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g,Q=/\.js$/,ia=/^\.\//;x=Object.prototype;var K=x.toString,fa=x.hasOwnProperty,ha=Array.prototype.splice,z=!!("undefined"!==typeof window&&"undefined"!==typeof navigator&&window.document),ea=!z&&"undefined"!==typeof importScripts,ja=z&&"PLAYSTATION 3"===navigator.platform?/^complete$/:/^(complete|loaded)$/,
+Y="undefined"!==typeof opera&&"[object Opera]"===opera.toString(),F={},q={},R=[],M=!1;if("undefined"===typeof define){if("undefined"!==typeof requirejs){if(G(requirejs))return;q=requirejs;requirejs=void 0}"undefined"!==typeof require&&!G(require)&&(q=require,require=void 0);g=requirejs=function(b,c,d,e){var n,p="_";!H(b)&&"string"!==typeof b&&(n=b,H(c)?(b=c,c=d,d=e):b=[]);n&&n.context&&(p=n.context);(e=m(F,p))||(e=F[p]=g.s.newContext(p));n&&e.configure(n);return e.require(b,c,d)};g.config=function(b){return g(b)};
+g.nextTick="undefined"!==typeof setTimeout?function(b){setTimeout(b,4)}:function(b){b()};require||(require=g);g.version="2.1.14";g.jsExtRegExp=/^\/|:|\?|\.js$/;g.isBrowser=z;x=g.s={contexts:F,newContext:ga};g({});v(["toUrl","undef","defined","specified"],function(b){g[b]=function(){var c=F._;return c.require[b].apply(c,arguments)}});if(z&&(y=x.head=document.getElementsByTagName("head")[0],D=document.getElementsByTagName("base")[0]))y=x.head=D.parentNode;g.onError=ca;g.createNode=function(b){var c=
+b.xhtml?document.createElementNS("http://www.w3.org/1999/xhtml","html:script"):document.createElement("script");c.type=b.scriptType||"text/javascript";c.charset="utf-8";c.async=!0;return c};g.load=function(b,c,d){var e=b&&b.config||{};if(z)return e=g.createNode(e,c,d),e.setAttribute("data-requirecontext",b.contextName),e.setAttribute("data-requiremodule",c),e.attachEvent&&!(e.attachEvent.toString&&0>e.attachEvent.toString().indexOf("[native code"))&&!Y?(M=!0,e.attachEvent("onreadystatechange",b.onScriptLoad)):
+(e.addEventListener("load",b.onScriptLoad,!1),e.addEventListener("error",b.onScriptError,!1)),e.src=d,J=e,D?y.insertBefore(e,D):y.appendChild(e),J=null,e;if(ea)try{importScripts(d),b.completeLoad(c)}catch(m){b.onError(C("importscripts","importScripts failed for "+c+" at "+d,m,[c]))}};z&&!q.skipDataMain&&T(document.getElementsByTagName("script"),function(b){y||(y=b.parentNode);if(I=b.getAttribute("data-main"))return s=I,q.baseUrl||(E=s.split("/"),s=E.pop(),O=E.length?E.join("/")+"/":"./",q.baseUrl=
+O),s=s.replace(Q,""),g.jsExtRegExp.test(s)&&(s=I),q.deps=q.deps?q.deps.concat(s):[s],!0});define=function(b,c,d){var e,g;"string"!==typeof b&&(d=c,c=b,b=null);H(c)||(d=c,c=null);!c&&G(d)&&(c=[],d.length&&(d.toString().replace(ka,"").replace(la,function(b,d){c.push(d)}),c=(1===d.length?["require"]:["require","exports","module"]).concat(c)));if(M){if(!(e=J))N&&"interactive"===N.readyState||T(document.getElementsByTagName("script"),function(b){if("interactive"===b.readyState)return N=b}),e=N;e&&(b||
+(b=e.getAttribute("data-requiremodule")),g=F[e.getAttribute("data-requirecontext")])}(g?g.defQueue:R).push([b,c,d])};define.amd={jQuery:!0};g.exec=function(b){return eval(b)};g(q)}})(this);

+ 546 - 0
bower_components/amber/support/resources/amber.css

@@ -0,0 +1,546 @@
+body.amberBody {
+    margin-bottom: 350px;
+}
+
+#amberTabs, #amber .amber_tabs {
+    margin: 0;
+    padding: 0;
+    background: url("sprite.amber.png") #DBD9C9 0 -27px;
+    height: 22px;
+    width: 100%;
+    list-style: none;
+    font-weight: bold;
+}
+
+#amberTabs li, #amber .amber_tabs li {
+    padding: 0 1px;
+    cursor: pointer;
+    color: #565656;
+	max-width: 200px;
+	float:left;
+}
+#amber li {
+	line-height: 14px;
+
+}
+#amber .ltab, #amber .rtab, #amber .mtab {
+    height: 22px;
+    float: left;
+}
+
+#amber .ltab, #amber .rtab {
+    width: 8px;
+}
+
+#amber .rtab {
+    margin-right: 1px;
+}
+
+#amber .mtab {
+    line-height: 20px;
+}
+
+#amberTabs li:hover .ltab,
+#amber .amber_tabs li:hover .ltab {
+    background: url("sprite.amber.png") -16px -96px;
+}
+
+#amberTabs li:hover .mtab,
+#amber .amber_tabs li:hover .mtab {
+    background: url("sprite.amber.png") 0 -73px;
+}
+
+#amberTabs li:hover .rtab,
+#amber .amber_tabs li:hover .rtab {
+    background: url("sprite.amber.png") -24px -96px;
+}
+
+#amberTabs li.selected,
+#amber .amber_tabs li.selected {
+    color: #111;
+}
+
+#amberTabs li.selected .ltab,
+#amber .amber_tabs li.selected .ltab {
+    background: url("sprite.amber.png") 0px -96px;
+}
+
+#amberTabs li.selected .mtab,
+#amber .amber_tabs li.selected .mtab {
+    background: url("sprite.amber.png") 0 -50px;
+}
+
+#amberTabs li.selected .rtab,
+#amber .amber_tabs li.selected .rtab {
+    background: url("sprite.amber.png") -8px -96px;
+}
+
+#amberTabs li .close {
+    margin-right: 5px;
+    color: #aaa;
+}
+
+#amber {
+       position: fixed;
+       bottom: 0;
+       left: 0;
+       right: 0;
+       height: 350px;
+       z-index: 1000;
+}
+
+#amber, #amber button, #amber input, #amber select {
+       font-family: Lucida Grande, Tahoma, sans-serif;
+       font-size: 11px;
+}
+
+#amber #logo {
+    position: absolute;
+    top: 3px;
+    left: 8px;
+    width: 22px;
+    height: 20px;
+    background: url("tinylogo.amber.png") top left no-repeat;
+}
+
+#amber #amber_toolbar {
+    height: 27px;
+    background: url("sprite.amber.png") 0 0;
+}
+
+#amber #amber_toolbar input {
+    margin-left: 50px;
+    width: 250px;
+    margin-top: 5px;
+}
+
+#amber #amber_toolbar #amber_close {
+    position: absolute;
+    right: 4px;
+    top: 6px;
+    width: 16px;
+    height: 16px;
+    background: url('off.amber.png');
+    cursor: pointer;
+}
+
+#amber #amber_toolbar #amber_close:hover {
+    background: url('offHover.amber.png');
+}
+
+
+#amber .ui-resizable-handle {
+    background-color: transparent;
+    top: 0;
+    cursor: row-resize;
+    height: 5px;
+    left: 0;
+    position: absolute;
+    right: 0;
+    width: auto !important;
+}
+
+.amberTool {
+    width: 100%;
+    color: #333;
+    line-height: 1.3em;
+    padding: 0;
+    margin: 0;
+    position: absolute;
+    bottom: 0;
+    left: 0;
+    top: 49px;
+    z-index: 1000;
+    background: white;
+}
+
+.amberTool .amber_box {
+    width: 100%;
+    margin: 0;
+    position: absolute;
+    top: 0;
+    bottom: 27px;
+}
+
+.amberTool .amber_buttons {
+    position: absolute;
+    bottom: 0;
+    left: 0;
+    right: 0;
+    height: 27px;
+    line-height: 27px;
+    background: url("sprite.amber.png") 0 0 repeat;
+}
+
+.amberTool .amber_buttons .right {
+    float: right;
+}
+
+.amberTool .important {
+    font-weight: bold;
+}
+
+
+.amberTool button {
+    border: 1px solid transparent;
+    background: transparent;
+    padding: 2px 4px;
+    margin-left: 4px;
+    cursor: pointer;
+}
+
+.amberTool button:hover {
+    border-top: 1px solid #fff;
+    border-left: 1px solid #fff;
+    border-right: 1px solid #bbb;
+    border-bottom: 1px solid #bbb;
+}
+
+.amberTool  button:active {
+    border-top: 1px solid #bbb;
+    border-left: 1px solid #bbb;
+    border-right: 1px solid #fff;
+    border-bottom: 1px solid #fff;
+    background: #ddd;
+}
+
+.amberTool select, #amber input {
+    border-top: 1px solid #bbb;
+    border-left: 1px solid #bbb;
+    border-right: 1px solid #fff;
+    border-bottom: 1px solid #fff;
+    background: #fff;
+    display: inline;
+    margin-top: 0;
+    margin-bottom: 0;
+    padding-top: 0;
+    padding-bottom: 0;
+    height: 14px;
+    line-height: normal;
+    box-shadow: none;
+    outline: none;
+    vertical-align:baseline;
+}
+.amberTool select {
+    height:18px;
+    width: auto;
+}
+
+
+
+
+.amberTool li {
+    margin: 0;
+    padding: 0;
+}
+    
+.amberTool .source {
+    height: 100%;
+}
+
+.amberTool textarea,
+.amberTool input {
+    border: 0 none;
+    font-family:  "DejaVu Sans", Helvetica, sans-serif;
+    line-height: 1.3em;
+    font-size: 11px;
+    position: relative;
+    padding: 0;
+}
+
+.amberTool .CodeMirror {
+    border: 0 none;
+    font-family:  "DejaVu Sans", Helvetica, sans-serif;
+    font-size: 11px;
+    line-height: 1.3em;
+    height: 100%;
+    background: white;
+}
+
+.amberTool .CodeMirror-scroll {
+    height: 100%;
+}
+
+.amberTool .CodeMirror-scroll pre {
+    font-family: "DejaVu Sans", Helvetica, sans-serif;
+}
+
+.amberTool .amber_clear {
+    clear: both;
+}
+
+.amberTool .amber_transcript,
+.amberTool .amber_workspace {
+    width: 100%;
+    height: 100%;
+}
+
+.amberTool .amber_packagesButtons {
+    position: absolute;
+    top: 149px;
+    left: 0;
+    z-index: 1;
+}
+
+.amberTool .amber_column {
+    width: 25%;
+    padding: 0;
+    margin: 0;
+    float: left;
+    outline: 1px solid #aaa;
+    border: 0 none;
+    height: 150px;
+    overflow-y: auto;
+    background: #fff;
+    color: #111;
+    position: absolute;
+    top: 0;
+}
+
+.amberTool .amber_column.classes {
+    left: 25%
+}
+
+.amberTool .amber_column.classes ul {
+    margin-left: 0;
+}
+
+.amberTool .amber_column.classes ul li {
+    padding-left: 10px;
+    margin-left: 0;
+}
+
+.amberTool .amber_column.protocols {
+    left: 50%
+}
+
+.amberTool .amber_column.methods {
+    left: 75%
+}
+
+.amberTool .amber_column li {
+    list-style-type: none;
+    padding-left: 5px;
+    cursor: pointer;
+    color: #111;
+    font-weight: bold;
+}
+
+.amberTool .amber_column li.selected {
+	background: #c5c5c5;
+	color: #222;
+}
+
+.amberTool .amber_column li:hover {
+    background: #08c;
+    color: white;
+}
+
+#amber .amberTool .amber_tabs {
+    top: 150px;
+    position: absolute;
+}
+
+#amber .amberTool .amber_tabs.amber_browser {
+    padding-left: 25%;
+}
+
+.amberTool .amber_sourceCode {
+    position: absolute;
+    top: 172px;
+    bottom: 0;
+    left: 0;
+    right: 0;
+}
+
+.amberTool .amber_sourceCode textarea.source {
+    width: 100%;
+    height: 100%;
+}
+
+/* Debugger & inspector */
+
+.amberTool .amber_box .label {
+	width: 100%;
+	font-weight: bold;
+	text-align: center;
+	position: absolute;
+	line-height: 1.5em;
+	font-size: 16px;
+	color: red;
+	background: url("sprite.amber.png") top left repeat;
+	height: 27px;
+}
+
+.amberTool .amber_box .amber_column.debugger {
+    top: 178px;
+}
+
+.amberTool .amber_box .amber_column.debugger.contexts {
+    top: 27px;
+    width: 100%;
+}
+
+.amberTool .amber_sourceCode.debugger {
+    width: 60%;
+    top: 178px;
+}
+
+.amberTool .amber_box .amber_column.debugger.variables {
+    width: 10%;
+    left: 60%;
+    bottom: 0;
+    position: absolute;
+    height: auto;
+}
+
+.amberTool .amber_box .amber_column.debugger.inspector {
+    width: 30%;
+    left: 70%;
+    bottom: 0;
+    position: absolute;
+    height: auto;
+}
+
+.amberTool .amber_button.debugger.inspect {
+    position: absolute;
+    left: 60%;
+}
+
+.amberTool .amber_column.value {
+    left: 25%;
+    width: 75%;
+}
+
+.amberTool .amber_buttons.inspector {
+    position: absolute;
+    top: 150px;
+}
+
+
+/* ReferencesBrowser */
+
+.amberTool .amber_box .implementors {
+	width: 100%
+}
+
+.amberTool .amber_box .amber_column.implementors,
+.amberTool .amber_box .amber_column.senders,
+.amberTool .amber_box .amber_column.referenced_classes,
+.amberTool .amber_box .amber_column.matches {
+	top: 20px;
+	height: auto;
+	bottom: 0;
+	width: 25%;
+}
+
+.amberTool .amber_box .amber_column.senders {
+	left: 25%
+}
+
+.amberTool .amber_box .amber_column.referenced_classes {
+        left: 50%
+}
+
+.amberTool .amber_box .amber_column.matches {
+        left: 75%
+}
+
+.amberTool .amber_box .amber_column.implementors .column_label, 
+.amberTool .amber_box .amber_column.senders .column_label,
+.amberTool .amber_box .amber_column.referenced_classes .column_label,
+.amberTool .amber_box .amber_column.matches .column_label {
+	background: #dbdbdb
+}
+
+.amberTool .amber_box .amber_column.implementors .column_label:hover,
+.amberTool .amber_box .amber_column.senders .column_label:hover,
+.amberTool .amber_box .amber_column.referenced_classes .column_label:hover,
+.amberTool .amber_box .amber_column.matches .column_label:hover {
+	font-weight: bold;
+	color: #000;
+	cursor: default
+}
+
+
+.amberTool .classes .commented {
+		color: #33337F;
+}
+
+
+/* SUnit TestRunner  */
+
+.amberTool .amber_column.sunit.packages,
+.amberTool .amber_column.sunit.classes {
+	height: 100%
+}
+
+.amberTool .amber_column.sunit.classes li.all,
+.amberTool .amber_column.sunit.categories li.all {
+	background: #e3e3e3;
+	font-weight: bold
+}
+
+.amberTool .amber_column.sunit.classes li.all:hover ,
+.amberTool .amber_column.sunit.categories li.all:hover {
+	background: #0088CC;
+	font-weight: bold
+}
+
+.amberTool .sunit.status {
+	position: absolute;
+	left: 50%;
+	width: 50%;
+	outline: 1px solid #aaa;
+	background: white;
+	height: 40px
+}
+
+
+.amberTool .sunit.status.success {
+	background: #43d443;
+}
+
+
+.amberTool .sunit.status.failure {
+	background: #ecd443;
+}
+
+
+.amberTool .sunit.status.error {
+	background: #e56f3b;
+}
+
+.amberTool .progress_bar {
+	position: absolute;
+	left: 50%;
+	width: 50%;
+	top: 40px;
+	background: white;
+	outline: 1px solid #aaa;
+	min-height: 20px
+}
+
+.amberTool .progress_bar div {
+	background: #0088CC;
+	min-height: 20px;
+}
+
+.amberTool .amber_column.results.sunit {
+	left: 50%;
+	height: auto;
+        width: 50%;
+        top: 62px;
+        bottom: 0;
+}
+
+.amberTool .amber_column.sunit.results .errors {
+    color: red;
+}
+
+/*.amberTool .amber_column.sunit.results ul {padding: 0; margin: 0}*/
+
+/* Code mirror overrides */
+.CodeMirror pre {
+	line-height: 14px;
+}

BIN
bower_components/amber/support/resources/off.amber.png


BIN
bower_components/amber/support/resources/offHover.amber.png


BIN
bower_components/amber/support/resources/sprite.amber.png


BIN
bower_components/amber/support/resources/tinylogo.amber.png


+ 42 - 0
bower_components/blockui/.bower.json

@@ -0,0 +1,42 @@
+{
+  "name": "blockUI",
+  "title": "BlockUI",
+  "description": "Simulate synchronous ajax by blocking - not locking - the UI. This plugin lets you block user interaction with the page or with a specific element on the page. Also great at displaying modal dialogs.",
+  "keywords": [
+    "block",
+    "overlay",
+    "dialog",
+    "modal"
+  ],
+  "author": {
+    "name": "M. Alsup",
+    "url": "http://jquery.malsup.com"
+  },
+  "licenses": [
+    {
+      "type": "MIT",
+      "url": "http://malsup.github.com/mit-license.txt"
+    },
+    {
+      "type": "GPL",
+      "url": "http://malsup.github.com/gpl-license-v2.txt"
+    }
+  ],
+  "bugs": "https://github.com/malsup/blockui/issues",
+  "homepage": "http://jquery.malsup.com/block/",
+  "docs": "http://jquery.malsup.com/block/",
+  "download": "http://malsup.github.com/jquery.blockUI.js",
+  "dependencies": {
+    "jquery": ">=1.7"
+  },
+  "main": "jquery.blockUI.js",
+  "_release": "2.65",
+  "_resolution": {
+    "type": "tag",
+    "tag": "2.65",
+    "commit": "b38dd8fce4f887a434b9ac9016e3db3be6d372f6"
+  },
+  "_source": "git://github.com/malsup/blockui.git",
+  "_target": "2.65",
+  "_originalSource": "blockui"
+}

+ 38 - 0
bower_components/blockui/README.md

@@ -0,0 +1,38 @@
+# BlockUI - Page or element overlay
+
+## Getting Started
+Download either the [production version][min] or the [development version][max] of BlockUI.
+
+[min]: http://malsup.github.com/min/jquery.blockUI.min.js
+[max]: http://malsup.github.com/jquery.blockUI.js
+
+In your web page:
+
+<pre>
+&lt;!-- include jQuery -->
+&lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js">&lt;/script>
+&lt;!-- include BlockUI -->
+&lt;script src="http://path/to/your/copy/of/jquery.blockUI.js">&lt;/script>
+&lt;script>
+// invoke blockUI as needed -->
+$(document).on('click', '#myButton', function() {
+   $.blockUI();
+});
+>&lt;/script>
+</pre>
+
+## Documentation, Demos and FAQ
+Everything you need to know can be found here: 
+[http://jquery.malsup.com/block/](http://jquery.malsup.com/block/)
+
+
+## Copyright and License
+Copyright &copy; 2007-2013 M. Alsup.
+
+The BlockUI plugin is dual licensed under the [MIT](http://malsup.github.com/mit-license.txt) and [GPL](http://malsup.github.com/gpl-license-v2.txt) licenses.
+
+You may use either license.  The MIT license is recommended for most projects because it is simple and easy to understand and it places almost no restrictions on what you can do with the plugin.
+
+If the GPL suits your project better you are also free to use the plugin under that license.
+
+You do not have to do anything special to choose one license or the other and you don't have to notify anyone which license you are using. You are free to use the BlockUI plugin in commercial projects as long as the copyright header is left intact.

+ 34 - 0
bower_components/blockui/blockUI.jquery.json

@@ -0,0 +1,34 @@
+{
+  "name": "blockUI",
+  "title": "BlockUI",
+  "description": "Simulate synchronous ajax by blocking - not locking - the UI. This plugin lets you block user interaction with the page or with a specific element on the page. Also great at displaying modal dialogs.",
+  "keywords": [
+    "block",
+    "overlay",
+    "dialog",
+    "modal"
+  ],
+  "version": "2.55.0-2013.01.23",
+  "author": {
+    "name": "M. Alsup",
+    "url": "http://jquery.malsup.com"
+  },
+  "licenses": [
+    {
+      "type": "MIT",
+      "url": "http://malsup.github.com/mit-license.txt"
+    },
+    {
+      "type": "GPL",
+      "url": "http://malsup.github.com/gpl-license-v2.txt"
+    }
+  ],
+  "bugs": "https://github.com/malsup/blockui/issues",
+  "homepage": "http://jquery.malsup.com/block/",
+  "docs": "http://jquery.malsup.com/block/",
+  "download": "http://malsup.github.com/jquery.blockUI.js",
+  "dependencies": {
+    "jquery": ">=1.7"
+  }
+}
+

+ 34 - 0
bower_components/blockui/bower.json

@@ -0,0 +1,34 @@
+{
+  "name": "blockUI",
+  "title": "BlockUI",
+  "description": "Simulate synchronous ajax by blocking - not locking - the UI. This plugin lets you block user interaction with the page or with a specific element on the page. Also great at displaying modal dialogs.",
+  "keywords": [
+    "block",
+    "overlay",
+    "dialog",
+    "modal"
+  ],
+  "version": "2.65",
+  "author": {
+    "name": "M. Alsup",
+    "url": "http://jquery.malsup.com"
+  },
+  "licenses": [
+    {
+      "type": "MIT",
+      "url": "http://malsup.github.com/mit-license.txt"
+    },
+    {
+      "type": "GPL",
+      "url": "http://malsup.github.com/gpl-license-v2.txt"
+    }
+  ],
+  "bugs": "https://github.com/malsup/blockui/issues",
+  "homepage": "http://jquery.malsup.com/block/",
+  "docs": "http://jquery.malsup.com/block/",
+  "download": "http://malsup.github.com/jquery.blockUI.js",
+  "dependencies": {
+    "jquery": ">=1.7"
+  },
+  "main": "jquery.blockUI.js"
+}

+ 619 - 0
bower_components/blockui/jquery.blockUI.js

@@ -0,0 +1,619 @@
+/*!
+ * jQuery blockUI plugin
+ * Version 2.66.0-2013.10.09
+ * Requires jQuery v1.7 or later
+ *
+ * Examples at: http://malsup.com/jquery/block/
+ * Copyright (c) 2007-2013 M. Alsup
+ * Dual licensed under the MIT and GPL licenses:
+ * http://www.opensource.org/licenses/mit-license.php
+ * http://www.gnu.org/licenses/gpl.html
+ *
+ * Thanks to Amir-Hossein Sobhi for some excellent contributions!
+ */
+
+;(function() {
+/*jshint eqeqeq:false curly:false latedef:false */
+"use strict";
+
+	function setup($) {
+		$.fn._fadeIn = $.fn.fadeIn;
+
+		var noOp = $.noop || function() {};
+
+		// this bit is to ensure we don't call setExpression when we shouldn't (with extra muscle to handle
+		// confusing userAgent strings on Vista)
+		var msie = /MSIE/.test(navigator.userAgent);
+		var ie6  = /MSIE 6.0/.test(navigator.userAgent) && ! /MSIE 8.0/.test(navigator.userAgent);
+		var mode = document.documentMode || 0;
+		var setExpr = $.isFunction( document.createElement('div').style.setExpression );
+
+		// global $ methods for blocking/unblocking the entire page
+		$.blockUI   = function(opts) { install(window, opts); };
+		$.unblockUI = function(opts) { remove(window, opts); };
+
+		// convenience method for quick growl-like notifications  (http://www.google.com/search?q=growl)
+		$.growlUI = function(title, message, timeout, onClose) {
+			var $m = $('<div class="growlUI"></div>');
+			if (title) $m.append('<h1>'+title+'</h1>');
+			if (message) $m.append('<h2>'+message+'</h2>');
+			if (timeout === undefined) timeout = 3000;
+
+			// Added by konapun: Set timeout to 30 seconds if this growl is moused over, like normal toast notifications
+			var callBlock = function(opts) {
+				opts = opts || {};
+
+				$.blockUI({
+					message: $m,
+					fadeIn : typeof opts.fadeIn  !== 'undefined' ? opts.fadeIn  : 700,
+					fadeOut: typeof opts.fadeOut !== 'undefined' ? opts.fadeOut : 1000,
+					timeout: typeof opts.timeout !== 'undefined' ? opts.timeout : timeout,
+					centerY: false,
+					showOverlay: false,
+					onUnblock: onClose,
+					css: $.blockUI.defaults.growlCSS
+				});
+			};
+
+			callBlock();
+			var nonmousedOpacity = $m.css('opacity');
+			$m.mouseover(function() {
+				callBlock({
+					fadeIn: 0,
+					timeout: 30000
+				});
+
+				var displayBlock = $('.blockMsg');
+				displayBlock.stop(); // cancel fadeout if it has started
+				displayBlock.fadeTo(300, 1); // make it easier to read the message by removing transparency
+			}).mouseout(function() {
+				$('.blockMsg').fadeOut(1000);
+			});
+			// End konapun additions
+		};
+
+		// plugin method for blocking element content
+		$.fn.block = function(opts) {
+			if ( this[0] === window ) {
+				$.blockUI( opts );
+				return this;
+			}
+			var fullOpts = $.extend({}, $.blockUI.defaults, opts || {});
+			this.each(function() {
+				var $el = $(this);
+				if (fullOpts.ignoreIfBlocked && $el.data('blockUI.isBlocked'))
+					return;
+				$el.unblock({ fadeOut: 0 });
+			});
+
+			return this.each(function() {
+				if ($.css(this,'position') == 'static') {
+					this.style.position = 'relative';
+					$(this).data('blockUI.static', true);
+				}
+				this.style.zoom = 1; // force 'hasLayout' in ie
+				install(this, opts);
+			});
+		};
+
+		// plugin method for unblocking element content
+		$.fn.unblock = function(opts) {
+			if ( this[0] === window ) {
+				$.unblockUI( opts );
+				return this;
+			}
+			return this.each(function() {
+				remove(this, opts);
+			});
+		};
+
+		$.blockUI.version = 2.66; // 2nd generation blocking at no extra cost!
+
+		// override these in your code to change the default behavior and style
+		$.blockUI.defaults = {
+			// message displayed when blocking (use null for no message)
+			message:  '<h1>Please wait...</h1>',
+
+			title: null,		// title string; only used when theme == true
+			draggable: true,	// only used when theme == true (requires jquery-ui.js to be loaded)
+
+			theme: false, // set to true to use with jQuery UI themes
+
+			// styles for the message when blocking; if you wish to disable
+			// these and use an external stylesheet then do this in your code:
+			// $.blockUI.defaults.css = {};
+			css: {
+				padding:	0,
+				margin:		0,
+				width:		'30%',
+				top:		'40%',
+				left:		'35%',
+				textAlign:	'center',
+				color:		'#000',
+				border:		'3px solid #aaa',
+				backgroundColor:'#fff',
+				cursor:		'wait'
+			},
+
+			// minimal style set used when themes are used
+			themedCSS: {
+				width:	'30%',
+				top:	'40%',
+				left:	'35%'
+			},
+
+			// styles for the overlay
+			overlayCSS:  {
+				backgroundColor:	'#000',
+				opacity:			0.6,
+				cursor:				'wait'
+			},
+
+			// style to replace wait cursor before unblocking to correct issue
+			// of lingering wait cursor
+			cursorReset: 'default',
+
+			// styles applied when using $.growlUI
+			growlCSS: {
+				width:		'350px',
+				top:		'10px',
+				left:		'',
+				right:		'10px',
+				border:		'none',
+				padding:	'5px',
+				opacity:	0.6,
+				cursor:		'default',
+				color:		'#fff',
+				backgroundColor: '#000',
+				'-webkit-border-radius':'10px',
+				'-moz-border-radius':	'10px',
+				'border-radius':		'10px'
+			},
+
+			// IE issues: 'about:blank' fails on HTTPS and javascript:false is s-l-o-w
+			// (hat tip to Jorge H. N. de Vasconcelos)
+			/*jshint scripturl:true */
+			iframeSrc: /^https/i.test(window.location.href || '') ? 'javascript:false' : 'about:blank',
+
+			// force usage of iframe in non-IE browsers (handy for blocking applets)
+			forceIframe: false,
+
+			// z-index for the blocking overlay
+			baseZ: 1000,
+
+			// set these to true to have the message automatically centered
+			centerX: true, // <-- only effects element blocking (page block controlled via css above)
+			centerY: true,
+
+			// allow body element to be stetched in ie6; this makes blocking look better
+			// on "short" pages.  disable if you wish to prevent changes to the body height
+			allowBodyStretch: true,
+
+			// enable if you want key and mouse events to be disabled for content that is blocked
+			bindEvents: true,
+
+			// be default blockUI will supress tab navigation from leaving blocking content
+			// (if bindEvents is true)
+			constrainTabKey: true,
+
+			// fadeIn time in millis; set to 0 to disable fadeIn on block
+			fadeIn:  200,
+
+			// fadeOut time in millis; set to 0 to disable fadeOut on unblock
+			fadeOut:  400,
+
+			// time in millis to wait before auto-unblocking; set to 0 to disable auto-unblock
+			timeout: 0,
+
+			// disable if you don't want to show the overlay
+			showOverlay: true,
+
+			// if true, focus will be placed in the first available input field when
+			// page blocking
+			focusInput: true,
+
+            // elements that can receive focus
+            focusableElements: ':input:enabled:visible',
+
+			// suppresses the use of overlay styles on FF/Linux (due to performance issues with opacity)
+			// no longer needed in 2012
+			// applyPlatformOpacityRules: true,
+
+			// callback method invoked when fadeIn has completed and blocking message is visible
+			onBlock: null,
+
+			// callback method invoked when unblocking has completed; the callback is
+			// passed the element that has been unblocked (which is the window object for page
+			// blocks) and the options that were passed to the unblock call:
+			//	onUnblock(element, options)
+			onUnblock: null,
+
+			// callback method invoked when the overlay area is clicked.
+			// setting this will turn the cursor to a pointer, otherwise cursor defined in overlayCss will be used.
+			onOverlayClick: null,
+
+			// don't ask; if you really must know: http://groups.google.com/group/jquery-en/browse_thread/thread/36640a8730503595/2f6a79a77a78e493#2f6a79a77a78e493
+			quirksmodeOffsetHack: 4,
+
+			// class name of the message block
+			blockMsgClass: 'blockMsg',
+
+			// if it is already blocked, then ignore it (don't unblock and reblock)
+			ignoreIfBlocked: false
+		};
+
+		// private data and functions follow...
+
+		var pageBlock = null;
+		var pageBlockEls = [];
+
+		function install(el, opts) {
+			var css, themedCSS;
+			var full = (el == window);
+			var msg = (opts && opts.message !== undefined ? opts.message : undefined);
+			opts = $.extend({}, $.blockUI.defaults, opts || {});
+
+			if (opts.ignoreIfBlocked && $(el).data('blockUI.isBlocked'))
+				return;
+
+			opts.overlayCSS = $.extend({}, $.blockUI.defaults.overlayCSS, opts.overlayCSS || {});
+			css = $.extend({}, $.blockUI.defaults.css, opts.css || {});
+			if (opts.onOverlayClick)
+				opts.overlayCSS.cursor = 'pointer';
+
+			themedCSS = $.extend({}, $.blockUI.defaults.themedCSS, opts.themedCSS || {});
+			msg = msg === undefined ? opts.message : msg;
+
+			// remove the current block (if there is one)
+			if (full && pageBlock)
+				remove(window, {fadeOut:0});
+
+			// if an existing element is being used as the blocking content then we capture
+			// its current place in the DOM (and current display style) so we can restore
+			// it when we unblock
+			if (msg && typeof msg != 'string' && (msg.parentNode || msg.jquery)) {
+				var node = msg.jquery ? msg[0] : msg;
+				var data = {};
+				$(el).data('blockUI.history', data);
+				data.el = node;
+				data.parent = node.parentNode;
+				data.display = node.style.display;
+				data.position = node.style.position;
+				if (data.parent)
+					data.parent.removeChild(node);
+			}
+
+			$(el).data('blockUI.onUnblock', opts.onUnblock);
+			var z = opts.baseZ;
+
+			// blockUI uses 3 layers for blocking, for simplicity they are all used on every platform;
+			// layer1 is the iframe layer which is used to supress bleed through of underlying content
+			// layer2 is the overlay layer which has opacity and a wait cursor (by default)
+			// layer3 is the message content that is displayed while blocking
+			var lyr1, lyr2, lyr3, s;
+			if (msie || opts.forceIframe)
+				lyr1 = $('<iframe class="blockUI" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="'+opts.iframeSrc+'"></iframe>');
+			else
+				lyr1 = $('<div class="blockUI" style="display:none"></div>');
+
+			if (opts.theme)
+				lyr2 = $('<div class="blockUI blockOverlay ui-widget-overlay" style="z-index:'+ (z++) +';display:none"></div>');
+			else
+				lyr2 = $('<div class="blockUI blockOverlay" style="z-index:'+ (z++) +';display:none;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>');
+
+			if (opts.theme && full) {
+				s = '<div class="blockUI ' + opts.blockMsgClass + ' blockPage ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:fixed">';
+				if ( opts.title ) {
+					s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || '&nbsp;')+'</div>';
+				}
+				s += '<div class="ui-widget-content ui-dialog-content"></div>';
+				s += '</div>';
+			}
+			else if (opts.theme) {
+				s = '<div class="blockUI ' + opts.blockMsgClass + ' blockElement ui-dialog ui-widget ui-corner-all" style="z-index:'+(z+10)+';display:none;position:absolute">';
+				if ( opts.title ) {
+					s += '<div class="ui-widget-header ui-dialog-titlebar ui-corner-all blockTitle">'+(opts.title || '&nbsp;')+'</div>';
+				}
+				s += '<div class="ui-widget-content ui-dialog-content"></div>';
+				s += '</div>';
+			}
+			else if (full) {
+				s = '<div class="blockUI ' + opts.blockMsgClass + ' blockPage" style="z-index:'+(z+10)+';display:none;position:fixed"></div>';
+			}
+			else {
+				s = '<div class="blockUI ' + opts.blockMsgClass + ' blockElement" style="z-index:'+(z+10)+';display:none;position:absolute"></div>';
+			}
+			lyr3 = $(s);
+
+			// if we have a message, style it
+			if (msg) {
+				if (opts.theme) {
+					lyr3.css(themedCSS);
+					lyr3.addClass('ui-widget-content');
+				}
+				else
+					lyr3.css(css);
+			}
+
+			// style the overlay
+			if (!opts.theme /*&& (!opts.applyPlatformOpacityRules)*/)
+				lyr2.css(opts.overlayCSS);
+			lyr2.css('position', full ? 'fixed' : 'absolute');
+
+			// make iframe layer transparent in IE
+			if (msie || opts.forceIframe)
+				lyr1.css('opacity',0.0);
+
+			//$([lyr1[0],lyr2[0],lyr3[0]]).appendTo(full ? 'body' : el);
+			var layers = [lyr1,lyr2,lyr3], $par = full ? $('body') : $(el);
+			$.each(layers, function() {
+				this.appendTo($par);
+			});
+
+			if (opts.theme && opts.draggable && $.fn.draggable) {
+				lyr3.draggable({
+					handle: '.ui-dialog-titlebar',
+					cancel: 'li'
+				});
+			}
+
+			// ie7 must use absolute positioning in quirks mode and to account for activex issues (when scrolling)
+			var expr = setExpr && (!$.support.boxModel || $('object,embed', full ? null : el).length > 0);
+			if (ie6 || expr) {
+				// give body 100% height
+				if (full && opts.allowBodyStretch && $.support.boxModel)
+					$('html,body').css('height','100%');
+
+				// fix ie6 issue when blocked element has a border width
+				if ((ie6 || !$.support.boxModel) && !full) {
+					var t = sz(el,'borderTopWidth'), l = sz(el,'borderLeftWidth');
+					var fixT = t ? '(0 - '+t+')' : 0;
+					var fixL = l ? '(0 - '+l+')' : 0;
+				}
+
+				// simulate fixed position
+				$.each(layers, function(i,o) {
+					var s = o[0].style;
+					s.position = 'absolute';
+					if (i < 2) {
+						if (full)
+							s.setExpression('height','Math.max(document.body.scrollHeight, document.body.offsetHeight) - (jQuery.support.boxModel?0:'+opts.quirksmodeOffsetHack+') + "px"');
+						else
+							s.setExpression('height','this.parentNode.offsetHeight + "px"');
+						if (full)
+							s.setExpression('width','jQuery.support.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"');
+						else
+							s.setExpression('width','this.parentNode.offsetWidth + "px"');
+						if (fixL) s.setExpression('left', fixL);
+						if (fixT) s.setExpression('top', fixT);
+					}
+					else if (opts.centerY) {
+						if (full) s.setExpression('top','(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"');
+						s.marginTop = 0;
+					}
+					else if (!opts.centerY && full) {
+						var top = (opts.css && opts.css.top) ? parseInt(opts.css.top, 10) : 0;
+						var expression = '((document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + '+top+') + "px"';
+						s.setExpression('top',expression);
+					}
+				});
+			}
+
+			// show the message
+			if (msg) {
+				if (opts.theme)
+					lyr3.find('.ui-widget-content').append(msg);
+				else
+					lyr3.append(msg);
+				if (msg.jquery || msg.nodeType)
+					$(msg).show();
+			}
+
+			if ((msie || opts.forceIframe) && opts.showOverlay)
+				lyr1.show(); // opacity is zero
+			if (opts.fadeIn) {
+				var cb = opts.onBlock ? opts.onBlock : noOp;
+				var cb1 = (opts.showOverlay && !msg) ? cb : noOp;
+				var cb2 = msg ? cb : noOp;
+				if (opts.showOverlay)
+					lyr2._fadeIn(opts.fadeIn, cb1);
+				if (msg)
+					lyr3._fadeIn(opts.fadeIn, cb2);
+			}
+			else {
+				if (opts.showOverlay)
+					lyr2.show();
+				if (msg)
+					lyr3.show();
+				if (opts.onBlock)
+					opts.onBlock();
+			}
+
+			// bind key and mouse events
+			bind(1, el, opts);
+
+			if (full) {
+				pageBlock = lyr3[0];
+				pageBlockEls = $(opts.focusableElements,pageBlock);
+				if (opts.focusInput)
+					setTimeout(focus, 20);
+			}
+			else
+				center(lyr3[0], opts.centerX, opts.centerY);
+
+			if (opts.timeout) {
+				// auto-unblock
+				var to = setTimeout(function() {
+					if (full)
+						$.unblockUI(opts);
+					else
+						$(el).unblock(opts);
+				}, opts.timeout);
+				$(el).data('blockUI.timeout', to);
+			}
+		}
+
+		// remove the block
+		function remove(el, opts) {
+			var count;
+			var full = (el == window);
+			var $el = $(el);
+			var data = $el.data('blockUI.history');
+			var to = $el.data('blockUI.timeout');
+			if (to) {
+				clearTimeout(to);
+				$el.removeData('blockUI.timeout');
+			}
+			opts = $.extend({}, $.blockUI.defaults, opts || {});
+			bind(0, el, opts); // unbind events
+
+			if (opts.onUnblock === null) {
+				opts.onUnblock = $el.data('blockUI.onUnblock');
+				$el.removeData('blockUI.onUnblock');
+			}
+
+			var els;
+			if (full) // crazy selector to handle odd field errors in ie6/7
+				els = $('body').children().filter('.blockUI').add('body > .blockUI');
+			else
+				els = $el.find('>.blockUI');
+
+			// fix cursor issue
+			if ( opts.cursorReset ) {
+				if ( els.length > 1 )
+					els[1].style.cursor = opts.cursorReset;
+				if ( els.length > 2 )
+					els[2].style.cursor = opts.cursorReset;
+			}
+
+			if (full)
+				pageBlock = pageBlockEls = null;
+
+			if (opts.fadeOut) {
+				count = els.length;
+				els.stop().fadeOut(opts.fadeOut, function() {
+					if ( --count === 0)
+						reset(els,data,opts,el);
+				});
+			}
+			else
+				reset(els, data, opts, el);
+		}
+
+		// move blocking element back into the DOM where it started
+		function reset(els,data,opts,el) {
+			var $el = $(el);
+			if ( $el.data('blockUI.isBlocked') )
+				return;
+
+			els.each(function(i,o) {
+				// remove via DOM calls so we don't lose event handlers
+				if (this.parentNode)
+					this.parentNode.removeChild(this);
+			});
+
+			if (data && data.el) {
+				data.el.style.display = data.display;
+				data.el.style.position = data.position;
+				if (data.parent)
+					data.parent.appendChild(data.el);
+				$el.removeData('blockUI.history');
+			}
+
+			if ($el.data('blockUI.static')) {
+				$el.css('position', 'static'); // #22
+			}
+
+			if (typeof opts.onUnblock == 'function')
+				opts.onUnblock(el,opts);
+
+			// fix issue in Safari 6 where block artifacts remain until reflow
+			var body = $(document.body), w = body.width(), cssW = body[0].style.width;
+			body.width(w-1).width(w);
+			body[0].style.width = cssW;
+		}
+
+		// bind/unbind the handler
+		function bind(b, el, opts) {
+			var full = el == window, $el = $(el);
+
+			// don't bother unbinding if there is nothing to unbind
+			if (!b && (full && !pageBlock || !full && !$el.data('blockUI.isBlocked')))
+				return;
+
+			$el.data('blockUI.isBlocked', b);
+
+			// don't bind events when overlay is not in use or if bindEvents is false
+			if (!full || !opts.bindEvents || (b && !opts.showOverlay))
+				return;
+
+			// bind anchors and inputs for mouse and key events
+			var events = 'mousedown mouseup keydown keypress keyup touchstart touchend touchmove';
+			if (b)
+				$(document).bind(events, opts, handler);
+			else
+				$(document).unbind(events, handler);
+
+		// former impl...
+		//		var $e = $('a,:input');
+		//		b ? $e.bind(events, opts, handler) : $e.unbind(events, handler);
+		}
+
+		// event handler to suppress keyboard/mouse events when blocking
+		function handler(e) {
+			// allow tab navigation (conditionally)
+			if (e.type === 'keydown' && e.keyCode && e.keyCode == 9) {
+				if (pageBlock && e.data.constrainTabKey) {
+					var els = pageBlockEls;
+					var fwd = !e.shiftKey && e.target === els[els.length-1];
+					var back = e.shiftKey && e.target === els[0];
+					if (fwd || back) {
+						setTimeout(function(){focus(back);},10);
+						return false;
+					}
+				}
+			}
+			var opts = e.data;
+			var target = $(e.target);
+			if (target.hasClass('blockOverlay') && opts.onOverlayClick)
+				opts.onOverlayClick(e);
+
+			// allow events within the message content
+			if (target.parents('div.' + opts.blockMsgClass).length > 0)
+				return true;
+
+			// allow events for content that is not being blocked
+			return target.parents().children().filter('div.blockUI').length === 0;
+		}
+
+		function focus(back) {
+			if (!pageBlockEls)
+				return;
+			var e = pageBlockEls[back===true ? pageBlockEls.length-1 : 0];
+			if (e)
+				e.focus();
+		}
+
+		function center(el, x, y) {
+			var p = el.parentNode, s = el.style;
+			var l = ((p.offsetWidth - el.offsetWidth)/2) - sz(p,'borderLeftWidth');
+			var t = ((p.offsetHeight - el.offsetHeight)/2) - sz(p,'borderTopWidth');
+			if (x) s.left = l > 0 ? (l+'px') : '0';
+			if (y) s.top  = t > 0 ? (t+'px') : '0';
+		}
+
+		function sz(el, p) {
+			return parseInt($.css(el,p),10)||0;
+		}
+
+	}
+
+
+	/*global define:true */
+	if (typeof define === 'function' && define.amd && define.amd.jQuery) {
+		define(['jquery'], setup);
+	} else {
+		setup(jQuery);
+	}
+
+})();

+ 21 - 0
bower_components/bootstrap2.3.2/.bower.json

@@ -0,0 +1,21 @@
+{
+  "name": "bootstrap2.3.2",
+  "version": "2.3.2",
+  "main": [
+    "./bootstrap/js/bootstrap.js",
+    "./bootstrap/css/bootstrap.css"
+  ],
+  "dependencies": {
+    "jquery": ">=1.8.0 <2.1.0"
+  },
+  "homepage": "https://github.com/alonisser/bower-bootstrap-2.3.2-legacy",
+  "_release": "2.3.2",
+  "_resolution": {
+    "type": "version",
+    "tag": "v2.3.2",
+    "commit": "3a9f0d6888383a456348ed97c10e65554c7fdc02"
+  },
+  "_source": "git://github.com/alonisser/bower-bootstrap-2.3.2-legacy.git",
+  "_target": "^2.3.2",
+  "_originalSource": "bootstrap2.3.2"
+}

+ 36 - 0
bower_components/bootstrap2.3.2/.gitignore

@@ -0,0 +1,36 @@
+# Numerous always-ignore extensions
+*.diff
+*.err
+*.orig
+*.log
+*.rej
+*.swo
+*.swp
+*.zip
+*.vi
+*~
+*.sass-cache
+
+# OS or Editor folders
+.DS_Store
+._*
+Thumbs.db
+.cache
+.project
+.settings
+.tmproj
+*.esproj
+nbproject
+*.sublime-project
+*.sublime-workspace
+
+# Komodo
+*.komodoproject
+.komodotools
+
+# Folders to ignore
+.hg
+.svn
+.CVS
+.idea
+node_modules

Alguns ficheiros não foram mostrados porque muitos ficheiros mudaram neste diff