Browse Source

Merge pull request #25 from tomrake/gh-pages

update trysmalltalk to amber 0.14.3
Hannes Hirzel 9 years ago
parent
commit
bc812f63a6
100 changed files with 2996 additions and 1121 deletions
  1. 1 0
      .gitignore
  2. 11 1
      README.md
  3. 1 1
      _layouts/index.html
  4. 34 34
      bower.json
  5. 50 0
      bower_components/amber-attic/.bower.json
  6. 80 0
      bower_components/amber-attic/Gruntfile.js
  7. 1 1
      bower_components/amber-attic/LICENSE-MIT
  8. 17 0
      bower_components/amber-attic/README.md
  9. 41 0
      bower_components/amber-attic/bower.json
  10. 0 0
      bower_components/amber-attic/codemirror.amd.json
  11. 10 0
      bower_components/amber-attic/deploy.js
  12. 8 0
      bower_components/amber-attic/devel.js
  13. 23 0
      bower_components/amber-attic/index.html
  14. 0 0
      bower_components/amber-attic/jquery-ui.amd.json
  15. 6 0
      bower_components/amber-attic/local.amd.json
  16. 37 0
      bower_components/amber-attic/package.json
  17. 0 0
      bower_components/amber-attic/require-css.amd.json
  18. 0 0
      bower_components/amber-attic/resources/amber.css
  19. 0 0
      bower_components/amber-attic/resources/off.amber.png
  20. 0 0
      bower_components/amber-attic/resources/offHover.amber.png
  21. 0 0
      bower_components/amber-attic/resources/sprite.amber.png
  22. 0 0
      bower_components/amber-attic/resources/tinylogo.amber.png
  23. 3 3
      bower_components/amber-attic/src/Benchfib.js
  24. 0 0
      bower_components/amber-attic/src/Benchfib.st
  25. 3 3
      bower_components/amber-attic/src/Examples.js
  26. 0 0
      bower_components/amber-attic/src/Examples.st
  27. 4 3
      bower_components/amber-attic/src/IDE.js
  28. 1 0
      bower_components/amber-attic/src/IDE.st
  29. 6 10
      bower_components/amber/.bower.json
  30. 81 0
      bower_components/amber/API-CHANGES.txt
  31. 54 15
      bower_components/amber/CHANGELOG
  32. 2 0
      bower_components/amber/CONTRIBUTING.md
  33. 3 4
      bower_components/amber/Gruntfile.js
  34. 7 3
      bower_components/amber/README.md
  35. 2 6
      bower_components/amber/bower.json
  36. 0 5
      bower_components/amber/es5-shim.amd.json
  37. 0 3
      bower_components/amber/local.amd.json
  38. 3 3
      bower_components/amber/package.json
  39. 1 1
      bower_components/amber/src/Compiler-AST.js
  40. 33 5
      bower_components/amber/src/Compiler-Core.js
  41. 11 1
      bower_components/amber/src/Compiler-Core.st
  42. 1 1
      bower_components/amber/src/Compiler-Exceptions.js
  43. 1 1
      bower_components/amber/src/Compiler-IR.js
  44. 1 1
      bower_components/amber/src/Compiler-Inlining.js
  45. 1 1
      bower_components/amber/src/Compiler-Interpreter.js
  46. 1 1
      bower_components/amber/src/Compiler-Semantic.js
  47. 1 1
      bower_components/amber/src/Compiler-Tests.js
  48. 16 73
      bower_components/amber/src/Kernel-Announcements.js
  49. 8 23
      bower_components/amber/src/Kernel-Announcements.st
  50. 109 27
      bower_components/amber/src/Kernel-Classes.js
  51. 31 9
      bower_components/amber/src/Kernel-Classes.st
  52. 4 56
      bower_components/amber/src/Kernel-Collections.js
  53. 6 13
      bower_components/amber/src/Kernel-Collections.st
  54. 4 4
      bower_components/amber/src/Kernel-Exceptions.js
  55. 6 2
      bower_components/amber/src/Kernel-Exceptions.st
  56. 263 65
      bower_components/amber/src/Kernel-ImportExport.js
  57. 65 21
      bower_components/amber/src/Kernel-ImportExport.st
  58. 545 181
      bower_components/amber/src/Kernel-Infrastructure.js
  59. 127 41
      bower_components/amber/src/Kernel-Infrastructure.st
  60. 627 57
      bower_components/amber/src/Kernel-Methods.js
  61. 156 14
      bower_components/amber/src/Kernel-Methods.st
  62. 174 200
      bower_components/amber/src/Kernel-Objects.js
  63. 46 40
      bower_components/amber/src/Kernel-Objects.st
  64. 1 1
      bower_components/amber/src/Kernel-Tests.js
  65. 1 1
      bower_components/amber/src/Kernel-Transcript.js
  66. 1 1
      bower_components/amber/src/SUnit-Tests.js
  67. 4 4
      bower_components/amber/src/SUnit.js
  68. 8 6
      bower_components/amber/src/SUnit.st
  69. 11 9
      bower_components/amber/src/Web.js
  70. 8 3
      bower_components/amber/src/Web.st
  71. 3 8
      bower_components/amber/support/boot.js
  72. 10 5
      bower_components/amber/support/browser-compatibility.js
  73. 2 0
      bower_components/amber/support/deploy.js
  74. 0 3
      bower_components/amber/support/deprecated-vm-files/_st.js
  75. 0 3
      bower_components/amber/support/deprecated-vm-files/as-receiver.js
  76. 0 3
      bower_components/amber/support/deprecated-vm-files/boot.js
  77. 0 3
      bower_components/amber/support/deprecated-vm-files/globals.js
  78. 0 3
      bower_components/amber/support/deprecated-vm-files/nil.js
  79. 0 4
      bower_components/amber/support/deprecated-vm-files/smalltalk.js
  80. 6 11
      bower_components/amber/support/devel.js
  81. 0 10
      bower_components/amber/support/ensure-console.js
  82. 1 18
      bower_components/amber/support/helpers.js
  83. 4 6
      bower_components/amber/support/lang.js
  84. 0 36
      bower_components/amber/support/requirejs/require.min.js
  85. 4 4
      bower_components/codemirror/.bower.json
  86. 4 0
      bower_components/codemirror/AUTHORS
  87. 14 7
      bower_components/codemirror/addon/edit/closetag.js
  88. 4 0
      bower_components/codemirror/addon/fold/foldcode.js
  89. 4 2
      bower_components/codemirror/addon/fold/foldgutter.js
  90. 5 1
      bower_components/codemirror/addon/merge/merge.js
  91. 1 1
      bower_components/codemirror/addon/mode/simple.js
  92. 6 4
      bower_components/codemirror/addon/scroll/simplescrollbars.js
  93. 95 0
      bower_components/codemirror/addon/selection/selection-pointer.js
  94. 1 1
      bower_components/codemirror/bower.json
  95. 1 0
      bower_components/codemirror/keymap/emacs.js
  96. 22 3
      bower_components/codemirror/keymap/vim.js
  97. 35 19
      bower_components/codemirror/lib/codemirror.js
  98. 4 4
      bower_components/codemirror/mode/clike/clike.js
  99. 2 2
      bower_components/codemirror/mode/css/css.js
  100. 7 1
      bower_components/codemirror/mode/javascript/javascript.js

+ 1 - 0
.gitignore

@@ -1,2 +1,3 @@
 _site
 /.DS_Store
+node_modules/*

+ 11 - 1
README.md

@@ -1,4 +1,14 @@
 amber-website
 =============
+January 23, 2015
 
-Amber's website (http://amber-lang.net)
+The gh-pages branch of this repo ( https://github.com/amber-smalltalk/amber-website.git ) hosts the front pages of the http://amber-lang.net/ website. 
+
+The pages provided are:
+
+http://amber-lang.net/index.html
+http://amber-lang.net/learn.html
+
+The documentation part of the website (http://doc.amber-lang.net/) is hosted from https://github.com/amber-smalltalk/amber-documentation.git
+
+To maintain the app you need to ensure you have the tooling portions of amber by by doing a `npm install` as well as having amber-cli installed globally.

+ 1 - 1
_layouts/index.html

@@ -108,7 +108,7 @@
 
       <div id="footer">
 	<div class="main">
-	  <p>Copyright © 2011-2014 <a href="http://www.nicolas-petton.fr">Nicolas Petton</a> and <a href="https://github.com/amber-smalltalk/amber/contributors">Amber contributors</a>.</p>
+	  <p>Copyright © 2011-2015 <a href="http://www.nicolas-petton.fr">Nicolas Petton</a> and <a href="https://github.com/amber-smalltalk/amber/contributors">Amber contributors</a>.</p>
 	  <p>The content of this website in licensed under <a href="http://creativecommons.org/licenses/by-nc/3.0/">CC-BY-NC 3.0</a>.</p> 
 	  <p>Amber is released under the <a href="https://github.com/amber-smalltalk/amber/blob/master/LICENSE">MIT</a> license.</p>
 	</div> 

+ 34 - 34
bower.json

@@ -1,36 +1,36 @@
 {
-    "name": "trysmalltalkdemo",
-    "description": "A demo of the trysmalltalk",
-    "version": "0.1.0",
-    "ignore": [
-        "**/.*",
-        "node_modules",
-        "bower_components",
-        "/test_runner.js",
-        "test",
-        "tests"
-    ],
-    "authors": [
-        {
-            "name": "Thomas Rake",
-            "email": "tom.rake@gmail.com"
-        }
-    ],
-    "homepage": "https://github.com/tomrake/trysmalltalk",
-    "keywords": [
-        "Amber",
-        "Smalltalk"
-    ],
-    "license": [
-        "MIT"
-    ],
-    "private": false,
-    "dependencies": {
-        "amber": "^0.13.3",
-        "trysmalltalk": "git://github.com/tomrake/trysmalltalk#0.0.2"
-    },
-    "devDependencies": {
-        "amber-ide-starter-dialog": "^0.1.0",
-        "helios": "^0.3.0"
+  "name": "trysmalltalkdemo",
+  "description": "A demo of the trysmalltalk",
+  "version": "0.1.0",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/test_runner.js",
+    "test",
+    "tests"
+  ],
+  "authors": [
+    {
+      "name": "Thomas Rake",
+      "email": "tom.rake@gmail.com"
     }
-}
+  ],
+  "homepage": "https://github.com/amber-smalltalk/trysmalltalk",
+  "keywords": [
+    "Amber",
+    "Smalltalk"
+  ],
+  "license": [
+    "MIT"
+  ],
+  "private": false,
+  "dependencies": {
+    "amber": "0.14.3",
+    "trysmalltalk": "0.1.1"
+  },
+  "devDependencies": {
+    "amber-ide-starter-dialog": "^0.1.0",
+    "helios": "^0.3.0"
+  }
+}

+ 50 - 0
bower_components/amber-attic/.bower.json

@@ -0,0 +1,50 @@
+{
+  "name": "amber-attic",
+  "description": "Legacy IDE and a few other old non-core packages",
+  "version": "0.1.3",
+  "ignore": [
+    "**/.*",
+    "node_modules",
+    "bower_components",
+    "/test_runner.js",
+    "/config.js",
+    "/the.js",
+    "test",
+    "tests"
+  ],
+  "authors": [
+    {
+      "name": "Herbert Vojčík",
+      "email": "herby@mailbox.sk"
+    }
+  ],
+  "homepage": "https://github.com/amber-smalltalk/amber-attic",
+  "keywords": [
+    "Amber",
+    "Smalltalk"
+  ],
+  "license": [
+    "MIT"
+  ],
+  "private": false,
+  "dependencies": {
+    "amber": ">=0.14.1",
+    "jquery-ui": ">=1.9.2",
+    "codemirror": "^4.7.0",
+    "require-css": "^0.1.2"
+  },
+  "devDependencies": {
+    "amber-ide-starter-dialog": "^0.1.0",
+    "amber": ">=0.14.3",
+    "helios": "^0.3.2"
+  },
+  "_release": "0.1.3",
+  "_resolution": {
+    "type": "version",
+    "tag": "0.1.3",
+    "commit": "0896995751413cf1686f2c756af16d3d3290e523"
+  },
+  "_source": "git://github.com/amber-smalltalk/amber-attic.git",
+  "_target": "^0.1.1",
+  "_originalSource": "amber-attic"
+}

+ 80 - 0
bower_components/amber-attic/Gruntfile.js

@@ -0,0 +1,80 @@
+'use strict';
+
+var fs = require('fs'),
+    path = require('path');
+
+function findAmberPath(options) {
+    var result;
+    options.some(function (x) {
+        var candidate = path.join(__dirname, x);
+        return fs.existsSync(path.join(candidate, 'support/boot.js')) && (result = candidate);
+    });
+    return result;
+}
+
+module.exports = function (grunt) {
+    var path = require('path');
+
+    // These plugins provide necessary tasks.
+    grunt.loadNpmTasks('grunt-contrib-requirejs');
+    grunt.loadNpmTasks('amber-dev');
+
+    // Default task.
+    grunt.registerTask('default', ['amberc:all']);
+    grunt.registerTask('devel', ['amdconfig:app', 'requirejs:devel']);
+    grunt.registerTask('deploy', ['amdconfig:app', 'requirejs:deploy']);
+
+    // Project configuration.
+    grunt.initConfig({
+        // Metadata.
+        // pkg: grunt.file.readJSON(''),
+        banner: '/*! <%= pkg.title || pkg.name %> - v<%= pkg.version %> - ' +
+            '<%= grunt.template.today("yyyy-mm-dd") %>\n' +
+            '<%= pkg.homepage ? "* " + pkg.homepage + "\\n" : "" %>' +
+            '* Copyright (c) <%= grunt.template.today("yyyy") %> <%= pkg.author.name %>;' +
+            ' Licensed <%= _.pluck(pkg.licenses, "type").join(", ") %> */\n',
+        // task configuration
+        amberc: {
+            options: {
+                amber_dir: findAmberPath(['../..', 'bower_components/amber']),
+                library_dirs: ['src'],
+                closure_jar: ''
+            },
+            all: {
+                src: [
+                    'src/Benchfib.st', 'src/Examples.st', 'src/IDE.st' // list all sources in dependency order
+                    // list all tests in dependency order
+                ],
+                amd_namespace: 'amber-attic',
+                libraries: ['Web']
+            }
+        },
+
+        amdconfig: {app: {dest: 'config.js'}},
+
+        requirejs: {
+            deploy: {options: {
+                mainConfigFile: "config.js",
+                onBuildWrite: function (moduleName, path, contents) {
+                    return moduleName === "config" ? contents + "\nrequire.config({map:{'*':{app:'deploy'}}});" : contents;
+                },
+                pragmas: {
+                    excludeIdeData: true,
+                    excludeDebugContexts: true
+                },
+                include: ['config', 'node_modules/requirejs/require', 'deploy'],
+                out: "the.js"
+            }},
+            devel: {options: {
+                mainConfigFile: "config.js",
+                onBuildWrite: function (moduleName, path, contents) {
+                    return moduleName === "config" ? contents + "\nrequire.config({map:{'*':{app:'devel'}}});" : contents;
+                },
+                include: ['config', 'node_modules/requirejs/require'],
+                out: "the.js"
+            }}
+        }
+
+    });
+
+};

+ 1 - 1
node_modules/grunt/node_modules/getobject/LICENSE-MIT → bower_components/amber-attic/LICENSE-MIT

@@ -1,4 +1,4 @@
-Copyright (c) 2013 "Cowboy" Ben Alman
+Copyright (c) 2015 Herbert Vojčík
 
 Permission is hereby granted, free of charge, to any person
 obtaining a copy of this software and associated documentation

+ 17 - 0
bower_components/amber-attic/README.md

@@ -0,0 +1,17 @@
+# Amber legacy items
+
+Legacy IDE and a few other old non-core packages
+
+## Getting Started
+
+To bring project alive (for example after `git clone`):
+
+```sh
+npm install
+bower install
+grunt devel
+```
+
+Developing the project (after brought alive):
+ 
+Start server with `amber serve` and go to `http://localhost:4000/` in your browser and follow the instructions

+ 41 - 0
bower_components/amber-attic/bower.json

@@ -0,0 +1,41 @@
+{
+    "name": "amber-attic",
+    "description": "Legacy IDE and a few other old non-core packages",
+    "version": "0.1.3",
+    "ignore": [
+        "**/.*",
+        "node_modules",
+        "bower_components",
+        "/test_runner.js",
+        "/config.js",
+        "/the.js",
+        "test",
+        "tests"
+    ],
+    "authors": [
+        {
+            "name": "Herbert Vojčík",
+            "email": "herby@mailbox.sk"
+        }
+    ],
+    "homepage": "",
+    "keywords": [
+        "Amber",
+        "Smalltalk"
+    ],
+    "license": [
+        "MIT"
+    ],
+    "private": false,
+    "dependencies": {
+        "amber": ">=0.14.1",
+        "jquery-ui": ">=1.9.2",
+        "codemirror": "^4.7.0",
+        "require-css": "^0.1.2"
+    },
+    "devDependencies": {
+        "amber-ide-starter-dialog": "^0.1.0",
+        "amber": ">=0.14.3",
+        "helios": "^0.3.2"
+    }
+}

+ 0 - 0
bower_components/amber/codemirror.amd.json → bower_components/amber-attic/codemirror.amd.json


+ 10 - 0
bower_components/amber-attic/deploy.js

@@ -0,0 +1,10 @@
+define([
+    'amber/deploy',
+    // --- packages to be deployed begin here ---
+    'amber-attic/Benchfib',
+    'amber-attic/Examples',
+    'amber-attic/IDE'
+    // --- packages to be deployed end here ---
+], function (amber) {
+    return amber;
+});

+ 8 - 0
bower_components/amber-attic/devel.js

@@ -0,0 +1,8 @@
+define([
+    'amber/devel',
+    './deploy'
+    // --- packages used only during development begin here ---
+    // --- packages used only during development end here ---
+], function (amber) {
+    return amber;
+});

+ 23 - 0
bower_components/amber-attic/index.html

@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<html>
+
+  <head>
+    <title>Amber legacy items</title>
+    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
+    <meta name="author" content="Herbert Vojčík" />
+    <script type='text/javascript' src='the.js'></script>
+  </head>
+
+  <body>
+  <script type='text/javascript'>
+      require(['app'], function (amber) {
+          amber.initialize({
+            //used for all new packages in IDE
+            'transport.defaultAmdNamespace': "amber-attic"
+          });
+          require(["amber-ide-starter-dialog"], function (dlg) { dlg.start(); });
+      });
+  </script>
+  </body>
+
+</html>

+ 0 - 0
bower_components/amber/jquery-ui.amd.json → bower_components/amber-attic/jquery-ui.amd.json


+ 6 - 0
bower_components/amber-attic/local.amd.json

@@ -0,0 +1,6 @@
+{
+    "paths": {
+        "amber-attic": "src",
+        "amber-attic/resources": "resources"
+    }
+}

+ 37 - 0
bower_components/amber-attic/package.json

@@ -0,0 +1,37 @@
+{
+  "name": "amber-attic",
+  "title": "Amber legacy items",
+  "description": "Legacy IDE and a few other old non-core packages",
+  "version": "0.1.3",
+  "homepage": "",
+  "author": {
+    "name": "Herbert Vojčík",
+    "email": "herby@mailbox.sk"
+  },
+  "repository": {
+    "type": "git",
+    "url": "git://guthub.com/amber-smalltalk/amber-attic.git"
+  },
+  "licenses": [
+    {
+      "type": "MIT",
+      "url": "/blob/master/LICENSE-MIT"
+    }
+  ],
+  "engines": {
+    "node": ">= 0.8.0"
+  },
+  "scripts": {
+    "test": "grunt test"
+  },
+  "devDependencies": {
+    "amber-dev": "^0.3.0",
+    "grunt": "^0.4.5",
+    "grunt-contrib-requirejs": "^0.4.4",
+    "requirejs": "^2.1.15"
+  },
+  "keywords": [
+    "Amber",
+    "Smalltalk"
+  ]
+}

+ 0 - 0
bower_components/amber/require-css.amd.json → bower_components/amber-attic/require-css.amd.json


+ 0 - 0
bower_components/amber/support/resources/amber.css → bower_components/amber-attic/resources/amber.css


+ 0 - 0
bower_components/amber/support/resources/off.amber.png → bower_components/amber-attic/resources/off.amber.png


+ 0 - 0
bower_components/amber/support/resources/offHover.amber.png → bower_components/amber-attic/resources/offHover.amber.png


+ 0 - 0
bower_components/amber/support/resources/sprite.amber.png → bower_components/amber-attic/resources/sprite.amber.png


+ 0 - 0
bower_components/amber/support/resources/tinylogo.amber.png → bower_components/amber-attic/resources/tinylogo.amber.png


+ 3 - 3
bower_components/amber/src/Benchfib.js → bower_components/amber-attic/src/Benchfib.js

@@ -1,8 +1,8 @@
-define("amber_core/Benchfib", ["amber/boot", "amber_core/Kernel-Objects"], function($boot){
+define("amber-attic/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.packages["Benchfib"].innerEval = function (expr) { return eval(expr); };
+$core.packages["Benchfib"].transport = {"type":"amd","amdNamespace":"amber-attic"};
 
 $core.addClass('Benchfib', $globals.Object, [], 'Benchfib');
 

+ 0 - 0
bower_components/amber/src/Benchfib.st → bower_components/amber-attic/src/Benchfib.st


+ 3 - 3
bower_components/amber/src/Examples.js → bower_components/amber-attic/src/Examples.js

@@ -1,8 +1,8 @@
-define("amber_core/Examples", ["amber/boot", "amber_core/Web"], function($boot){
+define("amber-attic/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.packages["Examples"].innerEval = function (expr) { return eval(expr); };
+$core.packages["Examples"].transport = {"type":"amd","amdNamespace":"amber-attic"};
 
 $core.addClass('Counter', $globals.Widget, ['count', 'header'], 'Examples');
 //>>excludeStart("ide", pragmas.excludeIdeData);

+ 0 - 0
bower_components/amber/src/Examples.st → bower_components/amber-attic/src/Examples.st


+ 4 - 3
bower_components/amber/src/IDE.js → bower_components/amber-attic/src/IDE.js

@@ -1,8 +1,9 @@
-define("amber_core/IDE", ["amber/boot", "amber_core/Web", "amber_core/Kernel-Objects", "amber_core/Kernel-Collections", "amber_core/Kernel-Methods"], function($boot){
+define("amber-attic/IDE", ["amber/boot", "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", "css!./resources/amber", "amber_core/Web", "amber_core/Kernel-Objects", "amber_core/Kernel-Collections", "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('IDE');
-$core.packages["IDE"].transport = {"type":"amd","amdNamespace":"amber_core"};
+$core.packages["IDE"].innerEval = function (expr) { return eval(expr); };
+$core.packages["IDE"].imports = ["codemirror/addon/hint/show-hint", "codemirror/lib/codemirror", "codemirror/mode/smalltalk/smalltalk", "css!./resources/amber", "css!codemirror/addon/hint/show-hint", "css!codemirror/lib/codemirror", "css!codemirror/theme/ambiance", "jquery-ui"];
+$core.packages["IDE"].transport = {"type":"amd","amdNamespace":"amber-attic"};
 
 $core.addClass('ClassesList', $globals.Widget, ['browser', 'ul', 'nodes'], 'IDE');
 $core.addMethod(

+ 1 - 0
bower_components/amber/src/IDE.st → bower_components/amber-attic/src/IDE.st

@@ -1,4 +1,5 @@
 Smalltalk createPackage: 'IDE'!
+(Smalltalk packageAt: 'IDE') imports: {'codemirror/addon/hint/show-hint'. 'codemirror/lib/codemirror'. 'codemirror/mode/smalltalk/smalltalk'. 'css!./resources/amber'. 'css!codemirror/addon/hint/show-hint'. 'css!codemirror/lib/codemirror'. 'css!codemirror/theme/ambiance'. 'jquery-ui'}!
 Widget subclass: #ClassesList
 	instanceVariableNames: 'browser ul nodes'
 	package: 'IDE'!

+ 6 - 10
bower_components/amber/.bower.json

@@ -1,6 +1,6 @@
 {
   "name": "amber",
-  "version": "0.13.3",
+  "version": "0.14.3",
   "main": "support/amber.js",
   "ignore": [
     "**/.*",
@@ -15,23 +15,19 @@
     "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"
+    "jquery": ">=1.7.0"
   },
   "devDependencies": {
     "jquery": ">=1.7.0 <2.1.0"
   },
   "homepage": "https://github.com/amber-smalltalk/amber",
-  "_release": "0.13.3",
+  "_release": "0.14.3",
   "_resolution": {
     "type": "version",
-    "tag": "0.13.3",
-    "commit": "863290215dc130475cc3427a909c13eaf94d03d4"
+    "tag": "0.14.3",
+    "commit": "4fdd701043d2883990a725aa2911d412efef493d"
   },
   "_source": "git://github.com/amber-smalltalk/amber.git",
-  "_target": "^0.13.3",
+  "_target": "0.14.3",
   "_originalSource": "amber"
 }

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

@@ -1,3 +1,64 @@
+0.14.3:
+
+* #heliosClass is now #classTag
+
++ Compiler >>
+  + eval:forPackage:
++ Behavior >>
+  + packageOfProtocol:
++ Exporter >>
+  + exportPackageContextOf:on:
+  + exportPackageImportsOf:on:
++ Package >>
+  + basicImports
+  + imports
+  + imports:
+  + importsDefinition
+  + importsFromJson:
+  + importsAsJson
+  + sortedImportsAsArray
+  + validateImports:
++ Package class >>
+  + named:imports:transport:
++ Association >>
+  + importsString
++ String >>
+  + importsString
+
+
+0.14.1:
+
+* NativeFunction class >> constructor:[value:...] deprecated
+
++ NativeFunction class >>
+  + constructorNamed:
+  + constructorNamed:value:
+  + constructorNamed:value:value:
+  + constructorNamed:value:value:value:
+  + constructorOf:
+  + constructorOf:value:
+  + constructorOf:value:value:
+  + constructorOf:value:value:value:
+  + functionNamed:
+  + functionNamed:value:
+  + functionNamed:value:value:
+  + functionNamed:value:value:value:
+  + functionNamed:valueWithArgs:
+  + functionOf:
+  + functionOf:value:
+  + functionOf:value:value:
+  + functionOf:value:value:value:
+  + functionOf:valueWithArgs:
+  + methodOf:this:
+  + methodOf:this:value:
+  + methodOf:this:value:value:
+  + methodOf:this:value:value:value:
+  + methodOf:this:valueWithArgs:
++ SmalltalkImage >>
+  + optOut:
+  + cancelOptOut:
+
+
 0.14.0:
 
 + Object >>
@@ -7,6 +68,26 @@
   + asJQuery
   + asJQueryInContext:
 
+- AnnouncementSubscription >>
+  - block
+  - block:
+- Collection >>
+  - contains:
+- String >>
+  - asSelector
+  - asJavaScriptSelector
+- SmalltalkImage >>
+  - at:
+  - at:ifAbsent:
+  - at:put:
+  - current
+  - vm
+  - createPackage:properties:
+- MethodContext >>
+  - temps
+- Object >>
+  - try:catch:
+
 
 0.13.2:
 

+ 54 - 15
bower_components/amber/CHANGELOG

@@ -1,17 +1,56 @@
-1st Jan 2015 - Release 0.14.0
+?? January 2015 - Release 0.14.3
+===================================
+
+Highlights:
+
+* Package can specify external dependencies and import them as package-global vars.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.14.2...0.14.3
+Issues: https://github.com/amber-smalltalk/amber/issues?q=milestone%3A0.14.3+is%3Aclosed
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+11 January 2015 - Release 0.14.2
+===================================
+
+Highlights:
+
+* Slimmed core - es5-shim and IE8 compatibilty tweaks in amber-compat-* repos.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.14.1...0.14.2
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+8 January 2015 - Release 0.14.1
+===================================
+
+Highlights:
+
+* Slimmed core - legacy IDE, Examples and Benchfib in own repo.
+* Smalltalk optOut: used instead allowJavaScriptCalls to make jQuery work.
+
+Commits: https://github.com/amber-smalltalk/amber/compare/0.14.0...0.14.1
+
+For the most important API related changes see the file API-CHANGES.txt.
+
+
+1 January 2015 - Release 0.14.0
 ===================================
 
 Highlights:
 
 * Removed deprecated stuff and backward compatibility support code.
+* You can wrap any object using #asJQuery.
 
-Commits: https://github.com/amber-smalltalk/amber/compare/0.13.0...0.14.0
+Commits: https://github.com/amber-smalltalk/amber/compare/0.13.2...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
+31 December 2014 - Release 0.13.3
 ===================================
 
 This is a planned maintenance release.
@@ -20,7 +59,7 @@ 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
+22 October 2014 - Release 0.13.2
 ===================================
 
 This is maintenance release to upgrade CodeMirror
@@ -37,7 +76,7 @@ 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
+10 October 2014 - Release 0.13.1
 ===================================
 
 Highlights:
@@ -60,7 +99,7 @@ Issues:  https://github.com/amber-smalltalk/amber/issues?q=is%3Aissue+is%3Aclose
 For the most important API related changes see the file API-CHANGES.txt.
 
 
-1st July 2014 - Release 0.12.6
+1 July 2014 - Release 0.12.6
 ===================================
 
 Highlights:
@@ -83,7 +122,7 @@ Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=13&state=clos
 For the most important API related changes see the file API-CHANGES.txt.
 
 
-11th April 2014 - Release 0.12.4
+11 April 2014 - Release 0.12.4
 ===================================
 
 Highlights:
@@ -102,7 +141,7 @@ Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=12&state=clos
 For the most important API related changes see the file API-CHANGES.txt.
 
 
-22nd Jan 2014 - Release 0.12.3
+22 January 2014 - Release 0.12.3
 ===================================
 
 Highlights:
@@ -120,7 +159,7 @@ Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=11&state=clos
 For the most important API related changes see the file API-CHANGES.txt.
 
 
-03rd December 2013 - Release 0.12.2
+3 December 2013 - Release 0.12.2
 ===================================
 
 Highlights:
@@ -137,7 +176,7 @@ Issues:  https://github.com/amber-smalltalk/amber/issues?milestone=10&state=clos
 For the most important API related changes see the file API-CHANGES.txt.
 
 
-14th November 2013 - Release 0.12.1
+14 November 2013 - Release 0.12.1
 ===================================
 
 Fixes a bug in Helios preventing class definitions from being compiled
@@ -146,7 +185,7 @@ 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
+11 November 2013 - Release 0.12.0
 ===================================
 
 After 3 months of work we are pleased to announce the 0.12.0 release of Amber.
@@ -248,7 +287,7 @@ comes handy when integrating; ask on the mailing list if problems arise.
 [4] https://github.com/amber-smalltalk/amber/wiki/How-to-load-amber
 
 
-09th July 2013 - Release 0.11.0
+9 July 2013 - Release 0.11.0
 ===============================
 
 Three months have passed and we are happy to announce the release
@@ -301,7 +340,7 @@ recompiling is needed in order to get contexts working:
 For API related changes see the file API-CHANGES.txt.
 
 
-13th March 2013 - Release 0.10.0
+13 March 2013 - Release 0.10.0
 ================================
 
 Here's a summary of change since the 0.9.1 release:
@@ -332,7 +371,7 @@ Here's a summary of change since the 0.9.1 release:
 
 
 
-16th January 2012 - Release 0.9.1
+16 January 2012 - Release 0.9.1
 =================================
 
 Here's a summary of changes since the 0.9 release:
@@ -354,7 +393,7 @@ Here's a summary of changes since the 0.9 release:
 - 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
+13 September 2011 - Release 0.9
 =================================
 Amber has been evolving furiously since the presentation at ESUG 2011 in Edinburgh less than 3 weeks ago.
 

+ 2 - 0
bower_components/amber/CONTRIBUTING.md

@@ -18,6 +18,8 @@ To get your clone, follow this list:
 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. Get your copy of legacy IDE into directory `my/amber-attic`:
+  ```git clone git@github.com:amber-smalltalk/amber-attic.git my/amber-attic```.
 1. Run ```grunt devel```. Prepares some transient files.
 1. Run ```amber serve```. Starts the integrated development server.
 

+ 3 - 4
bower_components/amber/Gruntfile.js

@@ -10,7 +10,7 @@ module.exports = function(grunt) {
   grunt.loadNpmTasks('grunt-execute');
 
   grunt.registerTask('default', ['peg', 'amberc:all']);
-  grunt.registerTask('amberc:all', ['amberc:amber', 'amberc:cli']);
+  grunt.registerTask('amberc:all', ['amberc:amber', 'amberc:attic', 'amberc:cli']);
   grunt.registerTask('test', ['amberc:test_runner', 'execute:test_runner', 'clean:test_runner']);
   grunt.registerTask('devel', ['amdconfig:amber']);
 
@@ -45,9 +45,8 @@ module.exports = function(grunt) {
               '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'
+              'src/Web.st', 'src/SUnit.st',
+              'src/Kernel-Tests.st', 'src/Compiler-Tests.st', 'src/SUnit-Tests.st'
               ],
         jsGlobals: ['navigator']
       },

+ 7 - 3
bower_components/amber/README.md

@@ -42,13 +42,17 @@ and as a library to be used by projects in a [bower](https://github.com/bower/bo
 
 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
-    
+    # Install the CLI tool `amber-cli` and supporting tools
+    npm install -g amber-cli bower grunt-cli
+
     # Initialize your project (directory must be empty)
     cd /path/to/myproject
     amber init
 
+    # (optional) Install backward compatibility
+    bower install amber-compat-es5 --save   # be loadable in older browsers
+    bower install amber-compat-ie8 --save   # additional tweaks to load in IE8
+
     # Serve amber on localhost:4000
     amber serve
 

+ 2 - 6
bower_components/amber/bower.json

@@ -1,6 +1,6 @@
 {
   "name": "amber",
-  "version": "0.13.3",
+  "version": "0.14.3",
   "main": "support/amber.js",
   "ignore": [
     "**/.*",
@@ -15,11 +15,7 @@
     "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"
+    "jquery": ">=1.7.0"
   },
   "devDependencies": {
     "jquery": ">=1.7.0 <2.1.0"

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

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

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

@@ -1,9 +1,6 @@
 {
     "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": {

+ 3 - 3
bower_components/amber/package.json

@@ -1,6 +1,6 @@
 {
   "name": "amber",
-  "version": "0.13.3",
+  "version": "0.14.3",
   "description": "An implementation of the Smalltalk language that runs on top of the JS runtime.",
   "homepage": "http://amber-lang.net",
   "keywords": [
@@ -20,7 +20,7 @@
   },
   "repository": {
     "type": "git",
-    "url": "git://github.com/amber-smalltalk/amber.git#0.13.3"
+    "url": "git://github.com/amber-smalltalk/amber.git#0.14.3"
   },
   "engines": {
     "node": ">=0.8.0"
@@ -29,7 +29,7 @@
     "test": "grunt test && cd external && cd amber-cli && npm test && cd .. && cd .."
   },
   "devDependencies": {
-    "amber-dev": "^0.2.2",
+    "amber-dev": "^0.3.0",
     "grunt": "^0.4.0",
     "grunt-contrib-clean": "^0.6.0",
     "grunt-contrib-jshint": "^0.10.0",

+ 1 - 1
bower_components/amber/src/Compiler-AST.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-AST"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('Node', $globals.Object, ['parent', 'position', 'source', 'nodes', 'shouldBeInlined', 'shouldBeAliased'], 'Compiler-AST');

+ 33 - 5
bower_components/amber/src/Compiler-Core.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Core"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('AbstractCodeGenerator', $globals.Object, ['currentClass', 'source'], 'Compiler-Core');
@@ -577,6 +577,32 @@ messageSends: []
 }),
 $globals.Compiler);
 
+$core.addMethod(
+$core.method({
+selector: "eval:forPackage:",
+protocol: 'compiling',
+fn: function (aString,aPackage){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return aPackage && aPackage.innerEval
+		? aPackage.innerEval(aString)
+		: eval(aString);
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"eval:forPackage:",{aString:aString,aPackage:aPackage},$globals.Compiler)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "aPackage"],
+source: "eval: aString forPackage: aPackage\x0a\x09<return aPackage && aPackage.innerEval\x0a\x09\x09? aPackage.innerEval(aString)\x0a\x09\x09: eval(aString)>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Compiler);
+
 $core.addMethod(
 $core.method({
 selector: "evaluateExpression:",
@@ -644,23 +670,25 @@ selector: "install:forClass:protocol:",
 protocol: 'compiling',
 fn: function (aString,aBehavior,anotherString){
 var self=this;
+var compiledMethod;
 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);
+compiledMethod=self._eval_forPackage_(self._compile_forClass_(aString,aBehavior),$recv(aBehavior)._packageOfProtocol_(anotherString));
+$1=$recv($recv($ClassBuilder())._new())._installMethod_forClass_protocol_(compiledMethod,aBehavior,anotherString);
 return $1;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"install:forClass:protocol:",{aString:aString,aBehavior:aBehavior,anotherString:anotherString},$globals.Compiler)});
+}, function($ctx1) {$ctx1.fill(self,"install:forClass:protocol:",{aString:aString,aBehavior:aBehavior,anotherString:anotherString,compiledMethod:compiledMethod},$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",
+source: "install: aString forClass: aBehavior protocol: anotherString\x0a\x09| compiledMethod |\x0a\x09compiledMethod := self\x0a\x09\x09eval: (self compile: aString forClass: aBehavior)\x0a\x09\x09forPackage: (aBehavior packageOfProtocol: anotherString).\x0a\x09^ ClassBuilder new\x0a\x09\x09installMethod: compiledMethod\x0a\x09\x09forClass: aBehavior\x0a\x09\x09protocol: anotherString",
 referencedClasses: ["ClassBuilder"],
 //>>excludeEnd("ide");
-messageSends: ["installMethod:forClass:protocol:", "new", "eval:", "compile:forClass:"]
+messageSends: ["eval:forPackage:", "compile:forClass:", "packageOfProtocol:", "installMethod:forClass:protocol:", "new"]
 }),
 $globals.Compiler);
 

+ 11 - 1
bower_components/amber/src/Compiler-Core.st

@@ -158,6 +158,12 @@ eval: aString
 	<return eval(aString)>
 !
 
+eval: aString forPackage: aPackage
+	<return aPackage && aPackage.innerEval
+		? aPackage.innerEval(aString)
+		: eval(aString)>
+!
+
 evaluateExpression: aString
 	"Unlike #eval: evaluate a Smalltalk expression and answer the returned object"
 	^ self evaluateExpression: aString on: DoIt new
@@ -175,8 +181,12 @@ evaluateExpression: aString on: anObject
 !
 
 install: aString forClass: aBehavior protocol: anotherString
+	| compiledMethod |
+	compiledMethod := self
+		eval: (self compile: aString forClass: aBehavior)
+		forPackage: (aBehavior packageOfProtocol: anotherString).
 	^ ClassBuilder new
-		installMethod: (self eval: (self compile: aString forClass: aBehavior))
+		installMethod: compiledMethod
 		forClass: aBehavior
 		protocol: anotherString
 !

+ 1 - 1
bower_components/amber/src/Compiler-Exceptions.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Exceptions"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('CompilerError', $globals.Error, [], 'Compiler-Exceptions');

+ 1 - 1
bower_components/amber/src/Compiler-IR.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-IR"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('IRASTTranslator', $globals.NodeVisitor, ['source', 'theClass', 'method', 'sequence', 'nextAlias'], 'Compiler-IR');

+ 1 - 1
bower_components/amber/src/Compiler-Inlining.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Inlining"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('IRInlinedAssignment', $globals.IRAssignment, [], 'Compiler-Inlining');

+ 1 - 1
bower_components/amber/src/Compiler-Interpreter.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Interpreter"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('AIBlockClosure', $globals.BlockClosure, ['node', 'outerContext'], 'Compiler-Interpreter');

+ 1 - 1
bower_components/amber/src/Compiler-Semantic.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Semantic"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('LexicalScope', $globals.Object, ['node', 'instruction', 'temps', 'args', 'outerScope', 'blockIndex'], 'Compiler-Semantic');

+ 1 - 1
bower_components/amber/src/Compiler-Tests.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Compiler-Tests"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ASTParsingTest', $globals.TestCase, [], 'Compiler-Tests');

+ 16 - 73
bower_components/amber/src/Kernel-Announcements.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Announcements"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('AnnouncementSubscription', $globals.Object, ['valuable', 'announcementClass'], 'Kernel-Announcements');
@@ -47,57 +47,6 @@ 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:",
@@ -707,8 +656,8 @@ $globals.SystemAnnouncement.comment="I am the superclass of all system announcem
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "announcement";
@@ -716,7 +665,7 @@ return "announcement";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'announcement'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'announcement'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -1115,35 +1064,29 @@ 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;
+var $2,$1,$receiver;
+$2=self._theClass();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
+} else {
+var class_;
+class_=$receiver;
+$1=$recv(class_)._packageOfProtocol_(self._protocol());
 };
-$4=$recv($Package())._named_ifAbsent_($recv(self._protocol())._allButFirst(),(function(){
-return nil;
-
-}));
-return $4;
+return $1;
 //>>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"],
+source: "package\x0a\x09\x0a\x09^ self theClass ifNotNil: [ :class | class packageOfProtocol: self protocol ]",
+referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["ifFalse:", "beginsWith:", "protocol", "package", "theClass", "named:ifAbsent:", "allButFirst"]
+messageSends: ["ifNotNil:", "theClass", "packageOfProtocol:", "protocol"]
 }),
 $globals.ProtocolAnnouncement);
 

+ 8 - 23
bower_components/amber/src/Kernel-Announcements.st

@@ -16,20 +16,6 @@ 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
 !
@@ -203,9 +189,13 @@ Object subclass: #SystemAnnouncement
 !SystemAnnouncement commentStamp!
 I am the superclass of all system announcements!
 
-!SystemAnnouncement class methodsFor: 'helios'!
+!SystemAnnouncement class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'announcement'
 ! !
 
@@ -400,13 +390,8 @@ 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 ]
+	
+	^ self theClass ifNotNil: [ :class | class packageOfProtocol: self protocol ]
 !
 
 protocol

+ 109 - 27
bower_components/amber/src/Kernel-Classes.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Classes"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('Behavior', $globals.Object, [], 'Kernel-Classes');
@@ -1272,6 +1272,40 @@ messageSends: ["reject:", "protocols", "match:"]
 }),
 $globals.Behavior);
 
+$core.addMethod(
+$core.method({
+selector: "packageOfProtocol:",
+protocol: 'accessing',
+fn: function (aString){
+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,$2,$3;
+$1=$recv(aString)._beginsWith_("*");
+if(!$core.assert($1)){
+$2=self._package();
+return $2;
+};
+$3=$recv($Package())._named_ifAbsent_($recv(aString)._allButFirst(),(function(){
+return nil;
+
+}));
+return $3;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"packageOfProtocol:",{aString:aString},$globals.Behavior)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "packageOfProtocol: aString\x0a\x09\x22Answer the package the method of receiver belongs to:\x0a\x09- if it is an extension method, answer the corresponding package\x0a\x09- else answer the receiver's package\x22\x0a\x09\x0a\x09(aString beginsWith: '*') ifFalse: [\x0a\x09\x09^ self package ].\x0a\x09\x09\x0a\x09^ Package \x0a\x09\x09named: aString allButFirst\x0a\x09\x09ifAbsent: [ nil ]",
+referencedClasses: ["Package"],
+//>>excludeEnd("ide");
+messageSends: ["ifFalse:", "beginsWith:", "package", "named:ifAbsent:", "allButFirst"]
+}),
+$globals.Behavior);
+
 $core.addMethod(
 $core.method({
 selector: "protocols",
@@ -1557,19 +1591,18 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
-$1=self._class();
-return $1;
+self._subclassResponsibility();
+return self;
 //>>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",
+source: "theMetaClass\x0a\x09self subclassResponsibility",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["class"]
+messageSends: ["subclassResponsibility"]
 }),
 $globals.Behavior);
 
@@ -1579,15 +1612,21 @@ selector: "theNonMetaClass",
 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,"theNonMetaClass",{},$globals.Behavior)});
+//>>excludeEnd("ctx");
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "theNonMetaClass\x0a\x09^ self",
+source: "theNonMetaClass\x0a\x09self subclassResponsibility",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: []
+messageSends: ["subclassResponsibility"]
 }),
 $globals.Behavior);
 
@@ -1709,6 +1748,24 @@ messageSends: ["ifNil:ifNotNil:", "package", "name"]
 }),
 $globals.Class);
 
+$core.addMethod(
+$core.method({
+selector: "classTag",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "class";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'class'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Class);
+
 $core.addMethod(
 $core.method({
 selector: "definition",
@@ -1816,24 +1873,6 @@ messageSends: ["streamContents:", "nextPutAll:", "asString", "superclass", "name
 }),
 $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",
@@ -2099,6 +2138,49 @@ messageSends: []
 }),
 $globals.Class);
 
+$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.Class)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "theMetaClass\x0a\x09^ self class",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["class"]
+}),
+$globals.Class);
+
+$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.Class);
+
 
 
 $core.addClass('Metaclass', $globals.Behavior, [], 'Kernel-Classes');

+ 31 - 9
bower_components/amber/src/Kernel-Classes.st

@@ -184,6 +184,19 @@ ownProtocols
 		each match: '^\*' ]
 !
 
+packageOfProtocol: aString
+	"Answer the package the method of receiver belongs to:
+	- if it is an extension method, answer the corresponding package
+	- else answer the receiver's package"
+	
+	(aString beginsWith: '*') ifFalse: [
+		^ self package ].
+		
+	^ Package 
+		named: aString allButFirst
+		ifAbsent: [ nil ]
+!
+
 protocols
 	^ self organization elements sorted
 !
@@ -211,11 +224,11 @@ superclass
 !
 
 theMetaClass
-	^ self class
+	self subclassResponsibility
 !
 
 theNonMetaClass
-	^ self
+	self subclassResponsibility
 !
 
 withAllSubclasses
@@ -365,6 +378,14 @@ category
 	^ self package ifNil: [ 'Unclassified' ] ifNotNil: [ self package name ]
 !
 
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
+	^ 'class'
+!
+
 definition
 	^ String streamContents: [ :stream |
 		stream
@@ -383,13 +404,6 @@ definition
 			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'
 !
@@ -417,6 +431,14 @@ rename: aString
 
 subclasses
 	<return self.subclasses._copy()>
+!
+
+theMetaClass
+	^ self class
+!
+
+theNonMetaClass
+	^ self
 ! !
 
 !Class methodsFor: 'browsing'!

+ 4 - 56
bower_components/amber/src/Kernel-Collections.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Collections"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('Association', $globals.Object, ['key', 'value'], 'Kernel-Collections');
@@ -782,32 +782,6 @@ messageSends: ["writeStream", "new", "class", "do:", "nextPut:", "value:", "cont
 }),
 $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:",
@@ -1675,8 +1649,8 @@ $globals.Collection);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "collection";
@@ -1684,7 +1658,7 @@ return "collection";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'collection'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'collection'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -6307,32 +6281,6 @@ 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",

+ 6 - 13
bower_components/amber/src/Kernel-Collections.st

@@ -352,12 +352,6 @@ 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: 
@@ -398,9 +392,13 @@ notEmpty
 	^ self isEmpty not
 ! !
 
-!Collection class methodsFor: 'helios'!
+!Collection class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'collection'
 ! !
 
@@ -1529,11 +1527,6 @@ asRegexp
 	^ RegularExpression fromString: self
 !
 
-asSelector
-	self deprecatedAPI: 'Use #asJavaScriptMethodName'.
-	^ self asJavaScriptMethodName
-!
-
 asString
 	^ self
 !

+ 4 - 4
bower_components/amber/src/Kernel-Exceptions.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Exceptions"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('Error', $globals.Object, ['messageText'], 'Kernel-Exceptions');
@@ -374,8 +374,8 @@ $globals.Error);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "exception";
@@ -383,7 +383,7 @@ return "exception";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'exception'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'exception'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []

+ 6 - 2
bower_components/amber/src/Kernel-Exceptions.st

@@ -92,9 +92,13 @@ wasHandled
 	<return self.amberHandled || false>
 ! !
 
-!Error class methodsFor: 'helios'!
+!Error class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'exception'
 ! !
 

+ 263 - 65
bower_components/amber/src/Kernel-ImportExport.js

@@ -1,38 +1,13 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $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:",
@@ -209,6 +184,31 @@ $core.addClass('ChunkExporter', $globals.AbstractExporter, [], 'Kernel-ImportExp
 //>>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: "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.ChunkExporter)});
+//>>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.ChunkExporter);
+
 $core.addMethod(
 $core.method({
 selector: "exportCategoryEpilogueOf:on:",
@@ -536,18 +536,19 @@ var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$2;
 self._exportPackageDefinitionOf_on_(aPackage,aStream);
+$1=self._exportPackageImportsOf_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);
+$2=self._ownMethodProtocolsOfClass_(each);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["ownMethodProtocolsOfClass:"]=1;
 //>>excludeEnd("ctx");
-self._exportProtocols_on_($1,aStream);
+self._exportProtocols_on_($2,aStream);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["exportProtocols:on:"]=1;
 //>>excludeEnd("ctx");
@@ -568,10 +569,10 @@ return self;
 },
 //>>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",
+source: "exportPackage: aPackage on: aStream\x0a\x0a\x09self\x0a\x09\x09exportPackageDefinitionOf: aPackage on: aStream;\x0a\x09\x09exportPackageImportsOf: 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:"]
+messageSends: ["exportPackageDefinitionOf:on:", "exportPackageImportsOf:on:", "do:", "sortedClasses", "exportDefinitionOf:on:", "exportProtocols:on:", "ownMethodProtocolsOfClass:", "exportMetaDefinitionOf:on:", "class", "extensionProtocolsOfPackage:"]
 }),
 $globals.ChunkExporter);
 
@@ -605,6 +606,57 @@ messageSends: ["nextPutAll:", ",", "name", "lf"]
 }),
 $globals.ChunkExporter);
 
+$core.addMethod(
+$core.method({
+selector: "exportPackageImportsOf:on:",
+protocol: 'output',
+fn: function (aPackage,aStream){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1;
+$recv($recv(aPackage)._imports())._ifNotEmpty_((function(imports){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("(Smalltalk packageAt: '");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(aPackage)._name());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("') imports: ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(aPackage)._importsDefinition());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("!");
+$1=$recv(aStream)._lf();
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({imports:imports},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageImportsOf:on:",{aPackage:aPackage,aStream:aStream},$globals.ChunkExporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageImportsOf: aPackage on: aStream\x0a\x09aPackage imports ifNotEmpty: [ :imports |\x0a\x09\x09aStream\x0a\x09\x09\x09nextPutAll: '(Smalltalk packageAt: ''';\x0a\x09\x09\x09nextPutAll: aPackage name;\x0a\x09\x09\x09nextPutAll: ''') imports: ';\x0a\x09\x09\x09nextPutAll: aPackage importsDefinition;\x0a\x09\x09\x09nextPutAll: '!';\x0a\x09\x09\x09lf ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotEmpty:", "imports", "nextPutAll:", "name", "importsDefinition", "lf"]
+}),
+$globals.ChunkExporter);
+
 $core.addMethod(
 $core.method({
 selector: "exportProtocol:on:",
@@ -1379,6 +1431,8 @@ return $core.withContext(function($ctx1) {
 var $1,$2;
 self._exportPackagePrologueOf_on_(aPackage,aStream);
 self._exportPackageDefinitionOf_on_(aPackage,aStream);
+self._exportPackageContextOf_on_(aPackage,aStream);
+self._exportPackageImportsOf_on_(aPackage,aStream);
 $1=self._exportPackageTransportOf_on_(aPackage,aStream);
 $recv($recv(aPackage)._sortedClasses())._do_((function(each){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
@@ -1444,10 +1498,52 @@ return self;
 },
 //>>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",
+source: "exportPackage: aPackage on: aStream\x0a\x09\x0a\x09self \x0a\x09\x09exportPackagePrologueOf: aPackage on: aStream;\x0a\x09\x09exportPackageDefinitionOf: aPackage on: aStream;\x0a\x09\x09exportPackageContextOf: aPackage on: aStream;\x0a\x09\x09exportPackageImportsOf: 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:"]
+messageSends: ["exportPackagePrologueOf:on:", "exportPackageDefinitionOf:on:", "exportPackageContextOf:on:", "exportPackageImportsOf:on:", "exportPackageTransportOf:on:", "do:", "sortedClasses", "exportDefinitionOf:on:", "ownMethods", "exportMethod:on:", "exportMetaDefinitionOf:on:", "class", "extensionMethodsOfPackage:", "exportPackageEpilogueOf:on:"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageContextOf: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_("].innerEval = ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("function (expr) { return eval(expr); }");
+//>>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,"exportPackageContextOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageContextOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '$core.packages[';\x0a\x09\x09nextPutAll: aPackage name asJavascript;\x0a\x09\x09nextPutAll: '].innerEval = ';\x0a\x09\x09nextPutAll: 'function (expr) { return eval(expr); }';\x0a\x09\x09nextPutAll: ';';\x0a\x09\x09lf",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["nextPutAll:", "asJavascript", "name", "lf"]
 }),
 $globals.Exporter);
 
@@ -1494,9 +1590,7 @@ 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();
+self._subclassResponsibility();
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"exportPackageEpilogueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
@@ -1504,10 +1598,65 @@ return self;
 },
 //>>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",
+source: "exportPackageEpilogueOf: aPackage on: aStream\x0a\x09self subclassResponsibility",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["nextPutAll:", "lf"]
+messageSends: ["subclassResponsibility"]
+}),
+$globals.Exporter);
+
+$core.addMethod(
+$core.method({
+selector: "exportPackageImportsOf: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($recv(aPackage)._importsAsJson())._ifNotEmpty_((function(imports){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("$core.packages[");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$1=$recv($recv(aPackage)._name())._asJavascript();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["asJavascript"]=1;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($1);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=2;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_("].imports = ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=3;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_($recv(imports)._asJavascript());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=4;
+//>>excludeEnd("ctx");
+$recv(aStream)._nextPutAll_(";");
+$2=$recv(aStream)._lf();
+return $2;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({imports:imports},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exportPackageImportsOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackage", "aStream"],
+source: "exportPackageImportsOf: aPackage on: aStream\x0a\x09aPackage importsAsJson ifNotEmpty: [ :imports |\x0a\x09\x09aStream\x0a\x09\x09\x09nextPutAll: '$core.packages[';\x0a\x09\x09\x09nextPutAll: aPackage name asJavascript;\x0a\x09\x09\x09nextPutAll: '].imports = ';\x0a\x09\x09\x09nextPutAll: imports asJavascript;\x0a\x09\x09\x09nextPutAll: ';';\x0a\x09\x09\x09lf ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNotEmpty:", "importsAsJson", "nextPutAll:", "asJavascript", "name", "lf"]
 }),
 $globals.Exporter);
 
@@ -1520,9 +1669,7 @@ 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();
+self._subclassResponsibility();
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.Exporter)});
@@ -1530,10 +1677,10 @@ return self;
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: ["aPackage", "aStream"],
-source: "exportPackagePrologueOf: aPackage on: aStream\x0a\x09aStream\x0a\x09\x09nextPutAll: '(function(smalltalk,nil,_st){';\x0a\x09\x09lf",
+source: "exportPackagePrologueOf: aPackage on: aStream\x0a\x09self subclassResponsibility",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["nextPutAll:", "lf"]
+messageSends: ["subclassResponsibility"]
 }),
 $globals.Exporter);
 
@@ -1807,10 +1954,36 @@ selector: "exportPackagePrologueOf:on:",
 protocol: 'output',
 fn: function (aPackage,aStream){
 var self=this;
+var namedImports,anonImports,importVarNames,loadDependencies;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $1;
+var $1,$5,$4,$3,$2,$6;
+namedImports=[];
+anonImports=[];
+importVarNames=[];
+$recv($recv(aPackage)._imports())._do_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(each)._isString();
+if($core.assert($1)){
+return $recv(anonImports)._add_(each);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=1;
+//>>excludeEnd("ctx");
+} else {
+$recv(namedImports)._add_($recv(each)._value());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["add:"]=2;
+//>>excludeEnd("ctx");
+return $recv(importVarNames)._add_($recv(each)._key());
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+loadDependencies=self._amdNamesOfPackages_($recv(aPackage)._loadDependencies());
 $recv(aStream)._nextPutAll_("define(\x22");
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["nextPutAll:"]=1;
@@ -1831,39 +2004,52 @@ $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());
+$5=["amber/boot"].__comma(namedImports);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=3;
+//>>excludeEnd("ctx");
+$4=$recv($5).__comma(anonImports);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__comma(loadDependencies);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3)._asJavascript();
+$recv(aStream)._nextPutAll_($2);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["nextPutAll:"]=6;
 //>>excludeEnd("ctx");
-$recv(aStream)._nextPutAll_(", function($boot){");
+$recv(aStream)._nextPutAll_(", function(");
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.sendIdx["nextPutAll:"]=7;
 //>>excludeEnd("ctx");
-$recv(aStream)._lf();
+$recv(aStream)._nextPutAll_($recv(["$boot"].__comma(importVarNames))._join_(","));
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-$ctx1.sendIdx["lf"]=1;
+$ctx1.sendIdx["nextPutAll:"]=8;
 //>>excludeEnd("ctx");
-$recv(aStream)._nextPutAll_("var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;");
+$recv(aStream)._nextPutAll_("){");
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-$ctx1.sendIdx["nextPutAll:"]=8;
+$ctx1.sendIdx["nextPutAll:"]=9;
 //>>excludeEnd("ctx");
 $recv(aStream)._lf();
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-$ctx1.sendIdx["lf"]=2;
+$ctx1.sendIdx["lf"]=1;
 //>>excludeEnd("ctx");
-$recv(aStream)._nextPutAll_("var smalltalk=$core,_st=$recv,globals=$globals;");
-$1=$recv(aStream)._lf();
+$recv(aStream)._nextPutAll_("var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;");
+$6=$recv(aStream)._lf();
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream},$globals.AmdExporter)});
+}, function($ctx1) {$ctx1.fill(self,"exportPackagePrologueOf:on:",{aPackage:aPackage,aStream:aStream,namedImports:namedImports,anonImports:anonImports,importVarNames:importVarNames,loadDependencies:loadDependencies},$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",
+source: "exportPackagePrologueOf: aPackage on: aStream\x0a\x09| namedImports anonImports importVarNames loadDependencies |\x0a\x09namedImports := #().\x0a\x09anonImports := #().\x0a\x09importVarNames := #().\x0a\x09aPackage imports do: [ :each | each isString\x0a\x09\x09ifTrue: [ anonImports add: each ]\x0a\x09\x09ifFalse: [ namedImports add: each value.\x0a\x09\x09\x09importVarNames add: each key ]].\x0a\x09loadDependencies := self amdNamesOfPackages: aPackage loadDependencies.\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'), namedImports, anonImports, loadDependencies) asJavascript;\x0a\x09\x09nextPutAll: ', function(';\x0a\x09\x09nextPutAll: (#('$boot'), importVarNames join: ',');\x0a\x09\x09nextPutAll: '){';\x0a\x09\x09lf;\x0a\x09\x09nextPutAll: 'var $core=$boot.api,nil=$boot.nil,$recv=$boot.asReceiver,$globals=$boot.globals;';\x0a\x09\x09lf",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["nextPutAll:", "amdNamespaceOfPackage:", "name", "asJavascript", ",", "amdNamesOfPackages:", "loadDependencies", "lf"]
+messageSends: ["do:", "imports", "ifTrue:ifFalse:", "isString", "add:", "value", "key", "amdNamesOfPackages:", "loadDependencies", "nextPutAll:", "amdNamespaceOfPackage:", "name", "asJavascript", ",", "join:", "lf"]
 }),
 $globals.AmdExporter);
 
@@ -2659,16 +2845,21 @@ selector: "exporterClass",
 protocol: 'accessing',
 fn: function (){
 var self=this;
-function $Exporter(){return $globals.Exporter||(typeof Exporter=="undefined"?nil:Exporter)}
-return $Exporter();
-
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._subclassResponsibility();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"exporterClass",{},$globals.PackageHandler)});
+//>>excludeEnd("ctx");
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "exporterClass\x0a\x09^ Exporter",
-referencedClasses: ["Exporter"],
+source: "exporterClass\x0a\x09self subclassResponsibility",
+referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: []
+messageSends: ["subclassResponsibility"]
 }),
 $globals.PackageHandler);
 
@@ -3337,9 +3528,11 @@ selector: "initialize",
 protocol: 'initialization',
 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 $1;
 (
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = true, 
@@ -3348,8 +3541,13 @@ $globals.PackageTransport.klass.superclass.fn.prototype._initialize.apply($recv(
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx1.supercall = false;
 //>>excludeEnd("ctx");;
+$1=self.__eq_eq($PackageTransport());
+if($core.assert($1)){
 self["@registry"]=$globals.HashedCollection._newFromPairs_([]);
+self["@registry"];
+} else {
 self._register();
+};
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.PackageTransport.klass)});
@@ -3357,10 +3555,10 @@ return self;
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "initialize\x0a\x09super initialize.\x0a\x09registry := #{}.\x0a\x09self register",
-referencedClasses: [],
+source: "initialize\x0a\x09super initialize.\x0a\x09self == PackageTransport\x0a\x09\x09ifTrue: [ registry := #{} ]\x0a\x09\x09ifFalse: [ self register ]",
+referencedClasses: ["PackageTransport"],
 //>>excludeEnd("ide");
-messageSends: ["initialize", "register"]
+messageSends: ["initialize", "ifTrue:ifFalse:", "==", "register"]
 }),
 $globals.PackageTransport.klass);
 

+ 65 - 21
bower_components/amber/src/Kernel-ImportExport.st

@@ -44,12 +44,6 @@ extensionProtocolsOfPackage: aPackage
 
 !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' ]
@@ -117,6 +111,14 @@ ownMethodProtocolsOfClass: aClass
 		ExportMethodProtocol name: each theClass: aClass ]
 ! !
 
+!ChunkExporter methodsFor: 'convenience'!
+
+chunkEscape: aString
+	"Replace all occurrences of !! with !!!! and trim at both ends."
+
+	^ (aString replace: '!!' with: '!!!!') trimBoth
+! !
+
 !ChunkExporter methodsFor: 'output'!
 
 exportCategoryEpilogueOf: aCategory on: aStream
@@ -170,7 +172,9 @@ exportMethod: aMethod on: aStream
 
 exportPackage: aPackage on: aStream
 
-	self exportPackageDefinitionOf: aPackage on: aStream.
+	self
+		exportPackageDefinitionOf: aPackage on: aStream;
+		exportPackageImportsOf: aPackage on: aStream.
 	
 	aPackage sortedClasses do: [ :each |
 		self exportDefinitionOf: each on: aStream.
@@ -196,6 +200,17 @@ exportPackageDefinitionOf: aPackage on: aStream
 		lf
 !
 
+exportPackageImportsOf: aPackage on: aStream
+	aPackage imports ifNotEmpty: [ :imports |
+		aStream
+			nextPutAll: '(Smalltalk packageAt: ''';
+			nextPutAll: aPackage name;
+			nextPutAll: ''') imports: ';
+			nextPutAll: aPackage importsDefinition;
+			nextPutAll: '!!';
+			lf ]
+!
+
 exportProtocol: aProtocol on: aStream
 	self exportProtocolPrologueOf: aProtocol on: aStream.
 	aProtocol methods do: [ :method | 
@@ -321,6 +336,8 @@ exportPackage: aPackage on: aStream
 	self 
 		exportPackagePrologueOf: aPackage on: aStream;
 		exportPackageDefinitionOf: aPackage on: aStream;
+		exportPackageContextOf: aPackage on: aStream;
+		exportPackageImportsOf: aPackage on: aStream;
 		exportPackageTransportOf: aPackage on: aStream.
 	
 	aPackage sortedClasses do: [ :each |
@@ -338,6 +355,16 @@ exportPackage: aPackage on: aStream
 	self exportPackageEpilogueOf: aPackage on: aStream
 !
 
+exportPackageContextOf: aPackage on: aStream
+	aStream
+		nextPutAll: '$core.packages[';
+		nextPutAll: aPackage name asJavascript;
+		nextPutAll: '].innerEval = ';
+		nextPutAll: 'function (expr) { return eval(expr); }';
+		nextPutAll: ';';
+		lf
+!
+
 exportPackageDefinitionOf: aPackage on: aStream
 	aStream
 		nextPutAll: '$core.addPackage(';
@@ -346,15 +373,22 @@ exportPackageDefinitionOf: aPackage on: aStream
 !
 
 exportPackageEpilogueOf: aPackage on: aStream
-	aStream
-		nextPutAll: '})(global_smalltalk,global_nil,global__st);';
-		lf
+	self subclassResponsibility
+!
+
+exportPackageImportsOf: aPackage on: aStream
+	aPackage importsAsJson ifNotEmpty: [ :imports |
+		aStream
+			nextPutAll: '$core.packages[';
+			nextPutAll: aPackage name asJavascript;
+			nextPutAll: '].imports = ';
+			nextPutAll: imports asJavascript;
+			nextPutAll: ';';
+			lf ]
 !
 
 exportPackagePrologueOf: aPackage on: aStream
-	aStream
-		nextPutAll: '(function(smalltalk,nil,_st){';
-		lf
+	self subclassResponsibility
 !
 
 exportPackageTransportOf: aPackage on: aStream
@@ -382,18 +416,27 @@ exportPackageEpilogueOf: aPackage on: aStream
 !
 
 exportPackagePrologueOf: aPackage on: aStream
+	| namedImports anonImports importVarNames loadDependencies |
+	namedImports := #().
+	anonImports := #().
+	importVarNames := #().
+	aPackage imports do: [ :each | each isString
+		ifTrue: [ anonImports add: each ]
+		ifFalse: [ namedImports add: each value.
+			importVarNames add: each key ]].
+	loadDependencies := self amdNamesOfPackages: aPackage loadDependencies.
 	aStream
 		nextPutAll: 'define("';
 		nextPutAll: (self amdNamespaceOfPackage: aPackage);
-		nextPutAll: '/';
+		nextPutAll: '/'; 
 		nextPutAll: aPackage name;
 		nextPutAll: '", ';
-		nextPutAll: (#('amber/boot'), (self amdNamesOfPackages: aPackage loadDependencies)) asJavascript;
-		nextPutAll: ', function($boot){';
+		nextPutAll: (#('amber/boot'), namedImports, anonImports, loadDependencies) asJavascript;
+		nextPutAll: ', function(';
+		nextPutAll: (#('$boot'), importVarNames join: ',');
+		nextPutAll: '){';
 		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
 ! !
 
@@ -582,7 +625,7 @@ contentsFor: aPackage
 !
 
 exporterClass
-	^ Exporter
+	self subclassResponsibility
 ! !
 
 !PackageHandler methodsFor: 'committing'!
@@ -811,8 +854,9 @@ type
 
 initialize
 	super initialize.
-	registry := #{}.
-	self register
+	self == PackageTransport
+		ifTrue: [ registry := #{} ]
+		ifFalse: [ self register ]
 ! !
 
 !PackageTransport class methodsFor: 'instance creation'!

+ 545 - 181
bower_components/amber/src/Kernel-Infrastructure.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Infrastructure"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ConsoleErrorHandler', $globals.Object, [], 'Kernel-Infrastructure');
@@ -2061,10 +2061,34 @@ $globals.PackageOrganizer.comment="I am an organizer specific to packages. I hol
 //>>excludeEnd("ide");
 
 
-$core.addClass('Package', $globals.Object, ['transport', 'dirty'], 'Kernel-Infrastructure');
+$core.addClass('Package', $globals.Object, ['transport', 'imports', '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: "basicImports",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+return self.imports || [];
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"basicImports",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "basicImports\x0a\x09\x22Answer the imports literal JavaScript object as setup in the JavaScript file, if any\x22\x0a\x09\x0a\x09<return self.imports || []>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Package);
+
 $core.addMethod(
 $core.method({
 selector: "basicName:",
@@ -2290,7 +2314,7 @@ function $String(){return $globals.String||(typeof String=="undefined"?nil:Strin
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-var $2,$4,$5,$3,$7,$6,$8,$9,$1;
+var $2,$4,$5,$3,$7,$6,$9,$10,$8,$11,$12,$1;
 $1=$recv($String())._streamContents_((function(stream){
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx2) {
@@ -2319,7 +2343,7 @@ $recv(stream)._nextPutAll_($3);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["nextPutAll:"]=2;
 //>>excludeEnd("ctx");
-$recv(stream)._nextPutAll_(" named: ");
+$recv(stream)._nextPutAll_("named: ");
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["nextPutAll:"]=3;
 //>>excludeEnd("ctx");
@@ -2335,7 +2359,15 @@ $recv(stream)._nextPutAll_($6);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["nextPutAll:"]=4;
 //>>excludeEnd("ctx");
-$8=$recv($recv($String())._lf()).__comma($recv($String())._tab());
+$9=$recv($String())._lf();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["lf"]=2;
+//>>excludeEnd("ctx");
+$10=$recv($String())._tab();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["tab"]=2;
+//>>excludeEnd("ctx");
+$8=$recv($9).__comma($10);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx[","]=4;
 //>>excludeEnd("ctx");
@@ -2343,12 +2375,28 @@ $recv(stream)._nextPutAll_($8);
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["nextPutAll:"]=5;
 //>>excludeEnd("ctx");
-$recv(stream)._nextPutAll_(" transport: (");
+$recv(stream)._nextPutAll_("imports: ");
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 $ctx2.sendIdx["nextPutAll:"]=6;
 //>>excludeEnd("ctx");
-$9=$recv(stream)._nextPutAll_($recv($recv(self._transport())._definition()).__comma(")"));
-return $9;
+$recv(stream)._nextPutAll_(self._importsDefinition());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=7;
+//>>excludeEnd("ctx");
+$11=$recv($recv($String())._lf()).__comma($recv($String())._tab());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=5;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_($11);
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=8;
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("transport: (");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=9;
+//>>excludeEnd("ctx");
+$12=$recv(stream)._nextPutAll_($recv($recv(self._transport())._definition()).__comma(")"));
+return $12;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx2) {$ctx2.fillBlock({stream:stream},$ctx1,1)});
 //>>excludeEnd("ctx");
@@ -2360,10 +2408,215 @@ return $1;
 },
 //>>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, ')' ]",
+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: 'imports: ';\x0a\x09\x09\x09nextPutAll: self importsDefinition;\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", "importsDefinition", "definition", "transport"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "imports",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1,$receiver;
+$2=self["@imports"];
+if(($receiver = $2) == null || $receiver.isNil){
+var parsed;
+parsed=self._importsFromJson_(self._basicImports());
+parsed;
+self._imports_(parsed);
+$1=self["@imports"];
+} else {
+$1=$2;
+};
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"imports",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "imports\x0a\x09^ imports ifNil: [\x0a\x09\x09| parsed |\x0a\x09\x09parsed := self importsFromJson: self basicImports.\x0a\x09\x09self imports: parsed.\x0a\x09\x09imports ]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["ifNil:", "importsFromJson:", "basicImports", "imports:"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "imports:",
+protocol: 'accessing',
+fn: function (anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+self._validateImports_(anArray);
+self["@imports"]=$recv(anArray)._asSet();
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"imports:",{anArray:anArray},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArray"],
+source: "imports: anArray\x0a\x09self validateImports: anArray.\x0a\x09imports := anArray asSet",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["validateImports:", "asSet"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "importsAsJson",
+protocol: 'converting',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv(self._sortedImportsAsArray())._collect_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$2=$recv(each)._isString();
+if($core.assert($2)){
+return each;
+} else {
+return $recv($recv($recv(each)._key()).__comma("=")).__comma($recv(each)._value());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx[","]=1;
+//>>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,"importsAsJson",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "importsAsJson\x0a\x0a\x09^ self sortedImportsAsArray collect: [ :each |\x0a\x09\x09each isString\x0a\x09\x09\x09ifTrue: [ each ]\x0a\x09\x09\x09ifFalse: [ each key, '=', each value ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "sortedImportsAsArray", "ifTrue:ifFalse:", "isString", ",", "key", "value"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "importsDefinition",
+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 $1;
+$1=$recv($String())._streamContents_((function(stream){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$recv(stream)._nextPutAll_("{");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["nextPutAll:"]=1;
+//>>excludeEnd("ctx");
+$recv(self._sortedImportsAsArray())._do_separatedBy_((function(each){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+return $recv(stream)._nextPutAll_($recv(each)._importsString());
+//>>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(stream)._nextPutAll_(". ");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["nextPutAll:"]=3;
+//>>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,"importsDefinition",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "importsDefinition\x0a\x09^ String streamContents: [ :stream |\x0a\x09\x09stream nextPutAll: '{'.\x0a\x09\x09self sortedImportsAsArray\x0a\x09\x09\x09do: [ :each | stream nextPutAll: each importsString ]\x0a\x09\x09\x09separatedBy: [ stream nextPutAll: '. ' ].\x0a\x09\x09stream nextPutAll: '}' ]",
 referencedClasses: ["String"],
 //>>excludeEnd("ide");
-messageSends: ["streamContents:", "nextPutAll:", "name", "class", ",", "lf", "tab", "definition", "transport"]
+messageSends: ["streamContents:", "nextPutAll:", "do:separatedBy:", "sortedImportsAsArray", "importsString"]
+}),
+$globals.Package);
+
+$core.addMethod(
+$core.method({
+selector: "importsFromJson:",
+protocol: 'converting',
+fn: function (anArray){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $2,$1;
+$1=$recv(anArray)._collect_((function(each){
+var split;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+split=$recv(each)._tokenize_("=");
+split;
+$2=$recv($recv(split)._size()).__eq((1));
+if($core.assert($2)){
+return $recv(split)._first();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["first"]=1;
+//>>excludeEnd("ctx");
+} else {
+return $recv($recv(split)._first()).__minus_gt($recv(split)._second());
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({each:each,split:split},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"importsFromJson:",{anArray:anArray},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anArray"],
+source: "importsFromJson: anArray\x0a\x09\x22Parses array of string, eg. #('asdf' 'qwer=tyuo')\x0a\x09into array of Strings and Associations,\x0a\x09eg. {'asdf'. 'qwer'->'tyuo'}\x22\x0a\x0a\x09^ anArray collect: [ :each |\x0a\x09\x09| split |\x0a\x09\x09split := each tokenize: '='.\x0a\x09\x09split size = 1\x0a\x09\x09\x09ifTrue: [ split first ]\x0a\x09\x09\x09ifFalse: [ split first -> split second ]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["collect:", "tokenize:", "ifTrue:ifFalse:", "=", "size", "first", "->", "second"]
 }),
 $globals.Package);
 
@@ -2705,6 +2958,74 @@ messageSends: ["sortedClasses:", "class", "classes"]
 }),
 $globals.Package);
 
+$core.addMethod(
+$core.method({
+selector: "sortedImportsAsArray",
+protocol: 'private',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $4,$3,$5,$2,$7,$6,$8,$1;
+$1=$recv($recv(self._imports())._asArray())._sorted_((function(a,b){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$4=$recv(a)._isString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["isString"]=1;
+//>>excludeEnd("ctx");
+$3=$recv($4)._not();
+$5=$recv(b)._isString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["isString"]=2;
+//>>excludeEnd("ctx");
+$2=$recv($3).__and($5);
+return $recv($2)._or_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx3) {
+//>>excludeEnd("ctx");
+$7=$recv(a)._isString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx3.sendIdx["isString"]=3;
+//>>excludeEnd("ctx");
+$6=$recv($7).__eq($recv(b)._isString());
+return $recv($6)._and_((function(){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx4) {
+//>>excludeEnd("ctx");
+$8=$recv(a)._value();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx4.sendIdx["value"]=1;
+//>>excludeEnd("ctx");
+return $recv($8).__lt_eq($recv(b)._value());
+//>>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);
+}, function($ctx2) {$ctx2.fillBlock({a:a,b:b},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"sortedImportsAsArray",{},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "sortedImportsAsArray\x0a\x09\x22Answer imports sorted first by type (associations first),\x0a\x09then by value\x22\x0a\x0a\x09^ self imports asArray\x0a\x09\x09sorted: [ :a :b |\x0a\x09\x09\x09a isString not & b isString or: [\x0a\x09\x09\x09\x09a isString = b isString and: [\x0a\x09\x09\x09\x09\x09a value <= b value ]]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["sorted:", "asArray", "imports", "or:", "&", "not", "isString", "and:", "=", "<=", "value"]
+}),
+$globals.Package);
+
 $core.addMethod(
 $core.method({
 selector: "transport",
@@ -2765,6 +3086,70 @@ messageSends: ["package:"]
 }),
 $globals.Package);
 
+$core.addMethod(
+$core.method({
+selector: "validateImports:",
+protocol: 'validation',
+fn: function (aCollection){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $1,$2,$5,$4,$3,$6;
+$recv(aCollection)._do_((function(import_){
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx2) {
+//>>excludeEnd("ctx");
+$1=$recv(import_)._isString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["isString"]=1;
+//>>excludeEnd("ctx");
+if(!$core.assert($1)){
+$2=$recv(import_)._respondsTo_("key");
+if(!$core.assert($2)){
+self._error_("Imports must be Strings or Associations");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["error:"]=1;
+//>>excludeEnd("ctx");
+};
+$5=$recv(import_)._key();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["key"]=1;
+//>>excludeEnd("ctx");
+$4=$recv($5)._isString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["isString"]=2;
+//>>excludeEnd("ctx");
+$3=$recv($4).__and($recv($recv(import_)._value())._isString());
+if(!$core.assert($3)){
+self._error_("Key and value must be Strings");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx2.sendIdx["error:"]=2;
+//>>excludeEnd("ctx");
+};
+$6=$recv($recv(import_)._key())._match_("^[a-zA-Z][a-zA-Z0-9]*$");
+if(!$core.assert($6)){
+return self._error_("Keys must be identifiers");
+};
+};
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx2) {$ctx2.fillBlock({import_:import_},$ctx1,1)});
+//>>excludeEnd("ctx");
+}));
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"validateImports:",{aCollection:aCollection},$globals.Package)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aCollection"],
+source: "validateImports: aCollection\x0a\x0a\x09aCollection do: [ :import |\x0a\x09\x09import isString ifFalse: [\x0a\x09\x09\x09(import respondsTo: #key) ifFalse: [\x0a\x09\x09\x09\x09self error: 'Imports must be Strings or Associations' ].\x0a\x09\x09\x09import key isString & import value isString ifFalse: [\x0a\x09\x09\x09\x09self error: 'Key and value must be Strings' ].\x0a\x09\x09\x09(import key match: '^[a-zA-Z][a-zA-Z0-9]*$') ifFalse: [\x0a\x09\x09\x09\x09self error: 'Keys must be identifiers' ]]]",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["do:", "ifFalse:", "isString", "respondsTo:", "error:", "&", "key", "value", "match:"]
+}),
+$globals.Package);
+
 
 $globals.Package.klass.iVarNames = ['defaultCommitPathJs','defaultCommitPathSt'];
 $core.addMethod(
@@ -2827,6 +3212,35 @@ messageSends: ["packageAt:ifAbsent:"]
 }),
 $globals.Package.klass);
 
+$core.addMethod(
+$core.method({
+selector: "named:imports:transport:",
+protocol: 'accessing',
+fn: function (aPackageName,anArray,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_)._imports_(anArray);
+$recv(package_)._transport_(aTransport);
+$1=package_;
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"named:imports:transport:",{aPackageName:aPackageName,anArray:anArray,aTransport:aTransport,package_:package_},$globals.Package.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aPackageName", "anArray", "aTransport"],
+source: "named: aPackageName imports: anArray transport: aTransport\x0a\x09| package |\x0a\x09\x0a\x09package := self named: aPackageName.\x0a\x09package imports: anArray.\x0a\x09package transport: aTransport.\x0a\x09\x0a\x09^ package",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["named:", "imports:", "transport:"]
+}),
+$globals.Package.klass);
+
 $core.addMethod(
 $core.method({
 selector: "named:transport:",
@@ -4196,100 +4610,72 @@ $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){
+selector: "basicCreatePackage:",
+protocol: 'private',
+fn: function (packageName){
 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;
+return $core.addPackage(packageName);
+return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"at:ifAbsent:",{aKey:aKey,aBlock:aBlock},$globals.SmalltalkImage)});
+}, function($ctx1) {$ctx1.fill(self,"basicCreatePackage:",{packageName:packageName},$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",
+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: ["deprecatedAPI", "at:ifAbsent:", "globals"]
+messageSends: []
 }),
 $globals.SmalltalkImage);
 
 $core.addMethod(
 $core.method({
-selector: "at:put:",
-protocol: 'accessing',
-fn: function (aString,anObject){
+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;
-self._deprecatedAPI();
-$1=$recv(self._globals())._at_put_(aString,anObject);
+$1=$recv($SmalltalkParser())._parse_(aString);
 return $1;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"at:put:",{aString:aString,anObject:anObject},$globals.SmalltalkImage)});
+}, function($ctx1) {$ctx1.fill(self,"basicParse:",{aString:aString},$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: [],
+args: ["aString"],
+source: "basicParse: aString\x0a\x09^ SmalltalkParser parse: aString",
+referencedClasses: ["SmalltalkParser"],
 //>>excludeEnd("ide");
-messageSends: ["deprecatedAPI", "at:put:", "globals"]
+messageSends: ["parse:"]
 }),
 $globals.SmalltalkImage);
 
 $core.addMethod(
 $core.method({
-selector: "basicCreatePackage:",
+selector: "basicRegisterPackage:",
 protocol: 'private',
-fn: function (packageName){
+fn: function (aPackage){
 var self=this;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
-return $core.addPackage(packageName);
+$core.packages[aPackage.pkgName]=aPackage;
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"basicCreatePackage:",{packageName:packageName},$globals.SmalltalkImage)});
+}, function($ctx1) {$ctx1.fill(self,"basicRegisterPackage:",{aPackage:aPackage},$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)>",
+args: ["aPackage"],
+source: "basicRegisterPackage: aPackage\x0a\x09\x22Put aPackage in $core.packages object.\x22\x0a\x09<$core.packages[aPackage.pkgName]=aPackage>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -4298,27 +4684,25 @@ $globals.SmalltalkImage);
 
 $core.addMethod(
 $core.method({
-selector: "basicParse:",
-protocol: 'private',
-fn: function (aString){
+selector: "cancelOptOut:",
+protocol: 'accessing',
+fn: function (anObject){
 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;
+delete anObject.klass;
+return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"basicParse:",{aString:aString},$globals.SmalltalkImage)});
+}, function($ctx1) {$ctx1.fill(self,"cancelOptOut:",{anObject:anObject},$globals.SmalltalkImage)});
 //>>excludeEnd("ctx");
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
-args: ["aString"],
-source: "basicParse: aString\x0a\x09^ SmalltalkParser parse: aString",
-referencedClasses: ["SmalltalkParser"],
+args: ["anObject"],
+source: "cancelOptOut: anObject\x0a\x09\x22A Smalltalk object has a 'klass' property.\x0a\x09If this property is shadowed for anObject by optOut:,\x0a\x09the object is treated as plain JS object.\x0a\x09This removes the shadow and anObject is Smalltalk object\x0a\x09again if it was before.\x22\x0a\x09\x0a\x09<delete anObject.klass>",
+referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["parse:"]
+messageSends: []
 }),
 $globals.SmalltalkImage);
 
@@ -4404,60 +4788,6 @@ messageSends: ["basicCreatePackage:", "package:", "new", "yourself", "announce:"
 }),
 $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",
@@ -4677,6 +5007,30 @@ messageSends: []
 }),
 $globals.SmalltalkImage);
 
+$core.addMethod(
+$core.method({
+selector: "optOut:",
+protocol: 'accessing',
+fn: function (anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+anObject.klass = null;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"optOut:",{anObject:anObject},$globals.SmalltalkImage)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["anObject"],
+source: "optOut: anObject\x0a\x09\x22A Smalltalk object has a 'klass' property.\x0a\x09This shadows the property for anObject.\x0a\x09The object is treated as plain JS object following this.\x22\x0a\x09\x0a\x09<anObject.klass = null>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.SmalltalkImage);
+
 $core.addMethod(
 $core.method({
 selector: "packageAt:",
@@ -5009,8 +5363,8 @@ $2;
 } else {
 self._error_("Already exists a package called: ".__comma(newName));
 };
-$recv(self._at_("packages"))._at_put_(newName,pkg);
 $recv(pkg)._name_(newName);
+self._basicRegisterPackage_(pkg);
 self._deletePackage_(packageName);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
@@ -5019,10 +5373,10 @@ return self;
 },
 //>>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.",
+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\x09pkg name: newName.\x0a\x09self basicRegisterPackage: pkg.\x0a\x09self deletePackage: packageName.",
 referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["packageAt:ifAbsent:", "error:", ",", "ifNotNil:", "packageAt:", "at:put:", "at:", "name:", "deletePackage:"]
+messageSends: ["packageAt:ifAbsent:", "error:", ",", "ifNotNil:", "packageAt:", "name:", "basicRegisterPackage:", "deletePackage:"]
 }),
 $globals.SmalltalkImage);
 
@@ -5075,44 +5429,18 @@ selector: "version",
 protocol: 'accessing',
 fn: function (){
 var self=this;
-return "0.13.3";
+return "0.14.3";
 
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "version\x0a\x09\x22Answer the version string of Amber\x22\x0a\x09\x0a\x09^ '0.13.3'",
+source: "version\x0a\x09\x22Answer the version string of Amber\x22\x0a\x09\x0a\x09^ '0.14.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(
@@ -5204,6 +5532,39 @@ messageSends: ["shouldNotImplement"]
 }),
 $globals.SmalltalkImage.klass);
 
+$core.addMethod(
+$core.method({
+selector: "importsString",
+protocol: '*Kernel-Infrastructure',
+fn: function (){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+var $3,$2,$1;
+$3=$recv(self._key())._importsString();
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx["importsString"]=1;
+//>>excludeEnd("ctx");
+$2=$recv($3).__comma(" -> ");
+$1=$recv($2).__comma($recv(self._value())._importsString());
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
+return $1;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"importsString",{},$globals.Association)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "importsString\x0a\x09\x22This is for use by package exporter.\x0a\x09It can fail for non-string keys and values.\x22\x0a\x0a\x09^ self key importsString, ' -> ', self value importsString",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: [",", "importsString", "key", "value"]
+}),
+$globals.Association);
+
 $core.addMethod(
 $core.method({
 selector: "do:displayingProgress:",
@@ -5255,49 +5616,50 @@ $globals.String);
 
 $core.addMethod(
 $core.method({
-selector: "asJavaScriptSelector",
+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=self._asJavaScriptPropertyName();
+$1=$recv($Setting())._at_ifAbsent_(self,nil);
 return $1;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"asJavaScriptSelector",{},$globals.String)});
+}, function($ctx1) {$ctx1.fill(self,"asSetting",{},$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: [],
+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: ["asJavaScriptPropertyName"]
+messageSends: ["at:ifAbsent:"]
 }),
 $globals.String);
 
 $core.addMethod(
 $core.method({
-selector: "asSetting",
+selector: "asSettingIfAbsent:",
 protocol: '*Kernel-Infrastructure',
-fn: function (){
+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,nil);
+$1=$recv($Setting())._at_ifAbsent_(self,aDefaultValue);
 return $1;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"asSetting",{},$globals.String)});
+}, function($ctx1) {$ctx1.fill(self,"asSettingIfAbsent:",{aDefaultValue:aDefaultValue},$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",
+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:"]
@@ -5306,27 +5668,29 @@ $globals.String);
 
 $core.addMethod(
 $core.method({
-selector: "asSettingIfAbsent:",
+selector: "importsString",
 protocol: '*Kernel-Infrastructure',
-fn: function (aDefaultValue){
+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,aDefaultValue);
+$1=$recv("'".__comma(self._replace_with_("'","''"))).__comma("'");
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+$ctx1.sendIdx[","]=1;
+//>>excludeEnd("ctx");
 return $1;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
-}, function($ctx1) {$ctx1.fill(self,"asSettingIfAbsent:",{aDefaultValue:aDefaultValue},$globals.String)});
+}, function($ctx1) {$ctx1.fill(self,"importsString",{},$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"],
+args: [],
+source: "importsString\x0a\x09\x22Answer receiver as Smalltalk expression\x22\x0a\x09^ '''', (self replace: '''' with: ''''''), ''''",
+referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["at:ifAbsent:"]
+messageSends: [",", "replace:with:"]
 }),
 $globals.String);
 

+ 127 - 41
bower_components/amber/src/Kernel-Infrastructure.st

@@ -526,7 +526,7 @@ Organizer subclass: #PackageOrganizer
 I am an organizer specific to packages. I hold classes categorization information.!
 
 Object subclass: #Package
-	instanceVariableNames: 'transport dirty'
+	instanceVariableNames: 'transport imports 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.
@@ -583,13 +583,38 @@ definition
 		stream 
 			nextPutAll: self class name;
 			nextPutAll: String lf, String tab;
-			nextPutAll: ' named: ';
+			nextPutAll: 'named: ';
 			nextPutAll: '''', self name, '''';
 			nextPutAll: String lf, String tab;
-			nextPutAll:  ' transport: (';
+			nextPutAll: 'imports: ';
+			nextPutAll: self importsDefinition;
+			nextPutAll: String lf, String tab;
+			nextPutAll: 'transport: (';
 			nextPutAll: self transport definition, ')' ]
 !
 
+imports
+	^ imports ifNil: [
+		| parsed |
+		parsed := self importsFromJson: self basicImports.
+		self imports: parsed.
+		imports ]
+!
+
+imports: anArray
+	self validateImports: anArray.
+	imports := anArray asSet
+!
+
+importsDefinition
+	^ String streamContents: [ :stream |
+		stream nextPutAll: '{'.
+		self sortedImportsAsArray
+			do: [ :each | stream nextPutAll: each importsString ]
+			separatedBy: [ stream nextPutAll: '. ' ].
+		stream nextPutAll: '}' ]
+!
+
 name
 	<return self.pkgName>
 !
@@ -633,6 +658,29 @@ sortedClasses
 	^ self class sortedClasses: self classes
 ! !
 
+!Package methodsFor: 'converting'!
+
+importsAsJson
+
+	^ self sortedImportsAsArray collect: [ :each |
+		each isString
+			ifTrue: [ each ]
+			ifFalse: [ each key, '=', each value ]]
+!
+
+importsFromJson: anArray
+	"Parses array of string, eg. #('asdf' 'qwer=tyuo')
+	into array of Strings and Associations,
+	eg. {'asdf'. 'qwer'->'tyuo'}"
+
+	^ anArray collect: [ :each |
+		| split |
+		split := each tokenize: '='.
+		split size = 1
+			ifTrue: [ split first ]
+			ifFalse: [ split first -> split second ]]
+! !
+
 !Package methodsFor: 'dependencies'!
 
 loadDependencies
@@ -671,6 +719,12 @@ printOn: aStream
 
 !Package methodsFor: 'private'!
 
+basicImports
+	"Answer the imports literal JavaScript object as setup in the JavaScript file, if any"
+	
+	<return self.imports || []>
+!
+
 basicName: aString
 	<self.pkgName = aString>
 !
@@ -679,6 +733,17 @@ basicTransport
 	"Answer the transport literal JavaScript object as setup in the JavaScript file, if any"
 	
 	<return self.transport>
+!
+
+sortedImportsAsArray
+	"Answer imports sorted first by type (associations first),
+	then by value"
+
+	^ self imports asArray
+		sorted: [ :a :b |
+			a isString not & b isString or: [
+				a isString = b isString and: [
+					a value <= b value ]]]
 ! !
 
 !Package methodsFor: 'testing'!
@@ -691,6 +756,20 @@ isPackage
 	^ true
 ! !
 
+!Package methodsFor: 'validation'!
+
+validateImports: aCollection
+
+	aCollection do: [ :import |
+		import isString ifFalse: [
+			(import respondsTo: #key) ifFalse: [
+				self error: 'Imports must be Strings or Associations' ].
+			import key isString & import value isString ifFalse: [
+				self error: 'Key and value must be Strings' ].
+			(import key match: '^[a-zA-Z][a-zA-Z0-9]*$') ifFalse: [
+				self error: 'Keys must be identifiers' ]]]
+! !
+
 Package class instanceVariableNames: 'defaultCommitPathJs defaultCommitPathSt'!
 
 !Package class methodsFor: 'accessing'!
@@ -706,6 +785,16 @@ named: aPackageName ifAbsent: aBlock
 	^ Smalltalk packageAt: aPackageName ifAbsent: aBlock
 !
 
+named: aPackageName imports: anArray transport: aTransport
+	| package |
+	
+	package := self named: aPackageName.
+	package imports: anArray.
+	package transport: aTransport.
+	
+	^ package
+!
+
 named: aPackageName transport: aTransport
 	| package |
 	
@@ -1126,31 +1215,20 @@ It requires the `Compiler` package and the `support/parser.js` parser file in or
 
 !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
+cancelOptOut: anObject
+	"A Smalltalk object has a 'klass' property.
+	If this property is shadowed for anObject by optOut:,
+	the object is treated as plain JS object.
+	This removes the shadow and anObject is Smalltalk object
+	again if it was before."
+	
+	<delete anObject.klass>
 !
 
 core
 	<return $core>
 !
 
-current
-	"Backward compatibility for Smalltalk current ..."
-	self deprecatedAPI.
-	^ self
-!
-
 globals
 	<return $globals>
 !
@@ -1159,6 +1237,14 @@ includesKey: aKey
 	<return $core.hasOwnProperty(aKey)>
 !
 
+optOut: anObject
+	"A Smalltalk object has a 'klass' property.
+	This shadows the property for anObject.
+	The object is treated as plain JS object following this."
+	
+	<anObject.klass = null>
+!
+
 parse: aString
 	| result |
 	
@@ -1190,12 +1276,7 @@ settings
 version
 	"Answer the version string of Amber"
 	
-	^ '0.13.3'
-!
-
-vm
-	self deprecatedAPI: 'Use #core'.
-	^self core
+	^ '0.14.3'
 ! !
 
 !SmalltalkImage methodsFor: 'accessing amd'!
@@ -1309,8 +1390,8 @@ renamePackage: packageName to: newName
 	| 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 basicRegisterPackage: pkg.
 	self deletePackage: packageName.
 ! !
 
@@ -1325,12 +1406,9 @@ 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
+basicRegisterPackage: aPackage
+	"Put aPackage in $core.packages object."
+	<$core.packages[aPackage.pkgName]=aPackage>
 !
 
 deleteClass: aClass
@@ -1375,6 +1453,15 @@ new
 	self shouldNotImplement
 ! !
 
+!Association methodsFor: '*Kernel-Infrastructure'!
+
+importsString
+	"This is for use by package exporter.
+	It can fail for non-string keys and values."
+
+	^ self key importsString, ' -> ', self value importsString
+! !
+
 !SequenceableCollection methodsFor: '*Kernel-Infrastructure'!
 
 do: aBlock displayingProgress: aString
@@ -1390,12 +1477,6 @@ 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."
@@ -1408,6 +1489,11 @@ asSettingIfAbsent: aDefaultValue
 	^ Setting at: self ifAbsent: aDefaultValue
 !
 
+importsString
+	"Answer receiver as Smalltalk expression"
+	^ '''', (self replace: '''' with: ''''''), ''''
+!
+
 settingValue
 	^ self asSetting value
 !

+ 627 - 57
bower_components/amber/src/Kernel-Methods.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Methods"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('BlockClosure', $globals.Object, [], 'Kernel-Methods');
@@ -1003,44 +1003,29 @@ 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;
+var $2,$1,$receiver;
+$2=self._methodClass();
+if(($receiver = $2) == null || $receiver.isNil){
+$1=$2;
 } 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;
+var class_;
+class_=$receiver;
+$1=$recv(class_)._packageOfProtocol_(self._protocol());
 };
-$5=$recv($Package())._named_ifAbsent_($recv(self._protocol())._allButFirst(),(function(){
-return nil;
-
-}));
-return $5;
+return $1;
 //>>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"],
+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\x09^ self methodClass ifNotNil: [ :class | class packageOfProtocol: self protocol ]",
+referencedClasses: [],
 //>>excludeEnd("ide");
-messageSends: ["ifNil:", "methodClass", "ifFalse:", "beginsWith:", "protocol", "package", "named:ifAbsent:", "allButFirst"]
+messageSends: ["ifNotNil:", "methodClass", "packageOfProtocol:", "protocol"]
 }),
 $globals.CompiledMethod);
 
@@ -2719,32 +2704,6 @@ 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');
@@ -2762,6 +2721,7 @@ var self=this;
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
 
+		self._deprecatedAPI_("Use constructorNamed:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc();
 	;
@@ -2772,7 +2732,7 @@ return self;
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: ["aString"],
-source: "constructor: aString\x0a\x09<\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc();\x0a\x09>",
+source: "constructor: aString\x0a\x09<\x0a\x09\x09self._deprecatedAPI_(\x22Use constructorNamed:\x22);\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc();\x0a\x09>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -2789,6 +2749,7 @@ var self=this;
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
 
+		self._deprecatedAPI_("Use constructorNamed:value:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject);
 	;
@@ -2799,7 +2760,7 @@ return self;
 },
 //>>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>",
+source: "constructor: aString value:anObject\x0a\x09<\x0a\x09\x09self._deprecatedAPI_(\x22Use constructorNamed:value:\x22);\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc(anObject);\x0a\x09>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -2816,6 +2777,7 @@ var self=this;
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
 
+		self._deprecatedAPI_("Use constructorNamed:value:value:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject,anObject2);
 	;
@@ -2826,7 +2788,7 @@ return self;
 },
 //>>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>",
+source: "constructor: aString value:anObject value: anObject2\x0a\x09<\x0a\x09\x09self._deprecatedAPI_(\x22Use constructorNamed:value:value:\x22);\x0a\x09\x09var nativeFunc=eval(aString);\x0a\x09\x09return new nativeFunc(anObject,anObject2);\x0a\x09>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -2843,6 +2805,7 @@ var self=this;
 return $core.withContext(function($ctx1) {
 //>>excludeEnd("ctx");
 
+		self._deprecatedAPI_("Use constructorNamed:value:value:value");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject,anObject2, anObject3);
 	;
@@ -2853,7 +2816,219 @@ return self;
 },
 //>>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>",
+source: "constructor: aString value:anObject value: anObject2 value:anObject3\x0a\x09<\x0a\x09\x09self._deprecatedAPI_(\x22Use constructorNamed:value:value:value\x22);\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: "constructorNamed:",
+protocol: 'instance creation',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorNamed:",{aString:aString},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "constructorNamed: aString\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return new nativeFunc();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorNamed:value:",
+protocol: 'instance creation',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorNamed:value:",{aString:aString,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "constructorNamed: aString value: anObject\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return new nativeFunc(anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorNamed: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=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorNamed:value:value:",{aString:aString,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "anObject2"],
+source: "constructorNamed: aString value: anObject value: anObject2\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return new nativeFunc(anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorNamed: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=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorNamed: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: "constructorNamed: aString value: anObject value: anObject2 value: anObject3\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return new nativeFunc(anObject,anObject2, anObject3);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorOf:",
+protocol: 'instance creation',
+fn: function (nativeFunc){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return new nativeFunc();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorOf:",{nativeFunc:nativeFunc},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc"],
+source: "constructorOf: nativeFunc\x0a\x09<\x0a\x09\x09return new nativeFunc();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorOf:value:",
+protocol: 'instance creation',
+fn: function (nativeFunc,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return new nativeFunc(anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorOf:value:",{nativeFunc:nativeFunc,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject"],
+source: "constructorOf: nativeFunc value: anObject\x0a\x09<\x0a\x09\x09return new nativeFunc(anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorOf:value:value:",
+protocol: 'instance creation',
+fn: function (nativeFunc,anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return new nativeFunc(anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorOf:value:value:",{nativeFunc:nativeFunc,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject", "anObject2"],
+source: "constructorOf: nativeFunc value: anObject value: anObject2\x0a\x09<\x0a\x09\x09return new nativeFunc(anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "constructorOf:value:value:value:",
+protocol: 'instance creation',
+fn: function (nativeFunc,anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return new nativeFunc(anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"constructorOf:value:value:value:",{nativeFunc:nativeFunc,anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject", "anObject2", "anObject3"],
+source: "constructorOf: nativeFunc value: anObject value: anObject2 value: anObject3\x0a\x09<\x0a\x09\x09return new nativeFunc(anObject,anObject2, anObject3);\x0a\x09>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -2886,6 +3061,401 @@ messageSends: ["existsGlobal:"]
 }),
 $globals.NativeFunction.klass);
 
+$core.addMethod(
+$core.method({
+selector: "functionNamed:",
+protocol: 'function calling',
+fn: function (aString){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionNamed:",{aString:aString},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString"],
+source: "functionNamed: aString\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return nativeFunc();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionNamed:value:",
+protocol: 'function calling',
+fn: function (aString,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionNamed:value:",{aString:aString,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject"],
+source: "functionNamed: aString value: anObject\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return nativeFunc(anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionNamed:value:value:",
+protocol: 'function calling',
+fn: function (aString,anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionNamed:value:value:",{aString:aString,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "anObject", "anObject2"],
+source: "functionNamed: aString value: anObject value: anObject2\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return nativeFunc(anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionNamed:value:value:value:",
+protocol: 'function calling',
+fn: function (aString,anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionNamed: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: "functionNamed: aString value: anObject value: anObject2 value: anObject3\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return nativeFunc(anObject,anObject2, anObject3);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionNamed:valueWithArgs:",
+protocol: 'function calling',
+fn: function (aString,args){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		var nativeFunc=(new Function('return this'))()[aString];
+		return Function.prototype.apply.call(nativeFunc, null, args);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionNamed:valueWithArgs:",{aString:aString,args:args},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["aString", "args"],
+source: "functionNamed: aString valueWithArgs: args\x0a\x09<\x0a\x09\x09var nativeFunc=(new Function('return this'))()[aString];\x0a\x09\x09return Function.prototype.apply.call(nativeFunc, null, args);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionOf:",
+protocol: 'function calling',
+fn: function (nativeFunc){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return nativeFunc();
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionOf:",{nativeFunc:nativeFunc},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc"],
+source: "functionOf: nativeFunc\x0a\x09<\x0a\x09\x09return nativeFunc();\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionOf:value:",
+protocol: 'function calling',
+fn: function (nativeFunc,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return nativeFunc(anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionOf:value:",{nativeFunc:nativeFunc,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject"],
+source: "functionOf: nativeFunc value: anObject\x0a\x09<\x0a\x09\x09return nativeFunc(anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionOf:value:value:",
+protocol: 'function calling',
+fn: function (nativeFunc,anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return nativeFunc(anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionOf:value:value:",{nativeFunc:nativeFunc,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject", "anObject2"],
+source: "functionOf: nativeFunc value: anObject value: anObject2\x0a\x09<\x0a\x09\x09return nativeFunc(anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionOf:value:value:value:",
+protocol: 'function calling',
+fn: function (nativeFunc,anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return nativeFunc(anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionOf:value:value:value:",{nativeFunc:nativeFunc,anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "anObject", "anObject2", "anObject3"],
+source: "functionOf: nativeFunc value: anObject value: anObject2 value: anObject3\x0a\x09<\x0a\x09\x09return nativeFunc(anObject,anObject2, anObject3);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "functionOf:valueWithArgs:",
+protocol: 'function calling',
+fn: function (nativeFunc,args){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.apply.call(nativeFunc, null, args);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"functionOf:valueWithArgs:",{nativeFunc:nativeFunc,args:args},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "args"],
+source: "functionOf: nativeFunc valueWithArgs: args\x0a\x09<\x0a\x09\x09return Function.prototype.apply.call(nativeFunc, null, args);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "methodOf:this:",
+protocol: 'method calling',
+fn: function (nativeFunc,thisObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.call.call(nativeFunc, thisObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodOf:this:",{nativeFunc:nativeFunc,thisObject:thisObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "thisObject"],
+source: "methodOf: nativeFunc this: thisObject\x0a\x09<\x0a\x09\x09return Function.prototype.call.call(nativeFunc, thisObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "methodOf:this:value:",
+protocol: 'method calling',
+fn: function (nativeFunc,thisObject,anObject){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.call.call(nativeFunc, thisObject, anObject);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodOf:this:value:",{nativeFunc:nativeFunc,thisObject:thisObject,anObject:anObject},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "thisObject", "anObject"],
+source: "methodOf: nativeFunc this: thisObject value: anObject\x0a\x09<\x0a\x09\x09return Function.prototype.call.call(nativeFunc, thisObject, anObject);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "methodOf:this:value:value:",
+protocol: 'method calling',
+fn: function (nativeFunc,thisObject,anObject,anObject2){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodOf:this:value:value:",{nativeFunc:nativeFunc,thisObject:thisObject,anObject:anObject,anObject2:anObject2},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "thisObject", "anObject", "anObject2"],
+source: "methodOf: nativeFunc this: thisObject value: anObject value: anObject2\x0a\x09<\x0a\x09\x09return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "methodOf:this:value:value:value:",
+protocol: 'method calling',
+fn: function (nativeFunc,thisObject,anObject,anObject2,anObject3){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2, anObject3);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodOf:this:value:value:value:",{nativeFunc:nativeFunc,thisObject:thisObject,anObject:anObject,anObject2:anObject2,anObject3:anObject3},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "thisObject", "anObject", "anObject2", "anObject3"],
+source: "methodOf: nativeFunc this: thisObject value: anObject value: anObject2 value: anObject3\x0a\x09<\x0a\x09\x09return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2, anObject3);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
+$core.addMethod(
+$core.method({
+selector: "methodOf:this:valueWithArgs:",
+protocol: 'method calling',
+fn: function (nativeFunc,thisObject,args){
+var self=this;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+return $core.withContext(function($ctx1) {
+//>>excludeEnd("ctx");
+
+		return Function.prototype.apply.call(nativeFunc, thisObject, args);
+	;
+return self;
+//>>excludeStart("ctx", pragmas.excludeDebugContexts);
+}, function($ctx1) {$ctx1.fill(self,"methodOf:this:valueWithArgs:",{nativeFunc:nativeFunc,thisObject:thisObject,args:args},$globals.NativeFunction.klass)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: ["nativeFunc", "thisObject", "args"],
+source: "methodOf: nativeFunc this: thisObject valueWithArgs: args\x0a\x09<\x0a\x09\x09return Function.prototype.apply.call(nativeFunc, thisObject, args);\x0a\x09>",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.NativeFunction.klass);
+
 
 $core.addClass('Timeout', $globals.Object, ['rawTimeout'], 'Kernel-Methods');
 //>>excludeStart("ide", pragmas.excludeIdeData);

+ 156 - 14
bower_components/amber/src/Kernel-Methods.st

@@ -239,14 +239,7 @@ package
 	- 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 ]
+	^ self methodClass ifNotNil: [ :class | class packageOfProtocol: self protocol ]
 !
 
 protocol
@@ -650,12 +643,6 @@ sendIndexes
 
 supercall
 	<return self.supercall == true>
-!
-
-temps
-	self deprecatedAPI.
-	
-	^ self locals
 ! !
 
 !MethodContext methodsFor: 'converting'!
@@ -708,10 +695,78 @@ Created instances will most probably be instance of `JSObjectProxy`.
 	ws := NativeFunction constructor: 'WebSocket' value: 'ws://localhost'.
 	ws at: 'onopen' put: [ ws send: 'hey there from Amber' ]!
 
+!NativeFunction class methodsFor: 'function calling'!
+
+functionNamed: aString
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc();
+	>
+!
+
+functionNamed: aString value: anObject
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject);
+	>
+!
+
+functionNamed: aString value: anObject value: anObject2
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject,anObject2);
+	>
+!
+
+functionNamed: aString value: anObject value: anObject2 value: anObject3
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return nativeFunc(anObject,anObject2, anObject3);
+	>
+!
+
+functionNamed: aString valueWithArgs: args
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return Function.prototype.apply.call(nativeFunc, null, args);
+	>
+!
+
+functionOf: nativeFunc
+	<
+		return nativeFunc();
+	>
+!
+
+functionOf: nativeFunc value: anObject
+	<
+		return nativeFunc(anObject);
+	>
+!
+
+functionOf: nativeFunc value: anObject value: anObject2
+	<
+		return nativeFunc(anObject,anObject2);
+	>
+!
+
+functionOf: nativeFunc value: anObject value: anObject2 value: anObject3
+	<
+		return nativeFunc(anObject,anObject2, anObject3);
+	>
+!
+
+functionOf: nativeFunc valueWithArgs: args
+	<
+		return Function.prototype.apply.call(nativeFunc, null, args);
+	>
+! !
+
 !NativeFunction class methodsFor: 'instance creation'!
 
 constructor: aString
 	<
+		self._deprecatedAPI_("Use constructorNamed:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc();
 	>
@@ -719,6 +774,7 @@ constructor: aString
 
 constructor: aString value:anObject
 	<
+		self._deprecatedAPI_("Use constructorNamed:value:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject);
 	>
@@ -726,6 +782,7 @@ constructor: aString value:anObject
 
 constructor: aString value:anObject value: anObject2
 	<
+		self._deprecatedAPI_("Use constructorNamed:value:value:");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject,anObject2);
 	>
@@ -733,9 +790,94 @@ constructor: aString value:anObject value: anObject2
 
 constructor: aString value:anObject value: anObject2 value:anObject3
 	<
+		self._deprecatedAPI_("Use constructorNamed:value:value:value");
 		var nativeFunc=eval(aString);
 		return new nativeFunc(anObject,anObject2, anObject3);
 	>
+!
+
+constructorNamed: aString
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc();
+	>
+!
+
+constructorNamed: aString value: anObject
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject);
+	>
+!
+
+constructorNamed: aString value: anObject value: anObject2
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject,anObject2);
+	>
+!
+
+constructorNamed: aString value: anObject value: anObject2 value: anObject3
+	<
+		var nativeFunc=(new Function('return this'))()[aString];
+		return new nativeFunc(anObject,anObject2, anObject3);
+	>
+!
+
+constructorOf: nativeFunc
+	<
+		return new nativeFunc();
+	>
+!
+
+constructorOf: nativeFunc value: anObject
+	<
+		return new nativeFunc(anObject);
+	>
+!
+
+constructorOf: nativeFunc value: anObject value: anObject2
+	<
+		return new nativeFunc(anObject,anObject2);
+	>
+!
+
+constructorOf: nativeFunc value: anObject value: anObject2 value: anObject3
+	<
+		return new nativeFunc(anObject,anObject2, anObject3);
+	>
+! !
+
+!NativeFunction class methodsFor: 'method calling'!
+
+methodOf: nativeFunc this: thisObject
+	<
+		return Function.prototype.call.call(nativeFunc, thisObject);
+	>
+!
+
+methodOf: nativeFunc this: thisObject value: anObject
+	<
+		return Function.prototype.call.call(nativeFunc, thisObject, anObject);
+	>
+!
+
+methodOf: nativeFunc this: thisObject value: anObject value: anObject2
+	<
+		return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2);
+	>
+!
+
+methodOf: nativeFunc this: thisObject value: anObject value: anObject2 value: anObject3
+	<
+		return Function.prototype.call.call(nativeFunc, thisObject,anObject,anObject2, anObject3);
+	>
+!
+
+methodOf: nativeFunc this: thisObject valueWithArgs: args
+	<
+		return Function.prototype.apply.call(nativeFunc, thisObject, args);
+	>
 ! !
 
 !NativeFunction class methodsFor: 'testing'!

+ 174 - 200
bower_components/amber/src/Kernel-Objects.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Objects"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ProtoObject', null, [], 'Kernel-Objects');
@@ -195,6 +195,99 @@ messageSends: []
 }),
 $globals.ProtoObject);
 
+$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.ProtoObject);
+
+$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.ProtoObject)});
+//>>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.ProtoObject);
+
+$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.ProtoObject)});
+//>>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.ProtoObject);
+
+$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.ProtoObject)});
+//>>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.ProtoObject);
+
 $core.addMethod(
 $core.method({
 selector: "initialize",
@@ -334,6 +427,49 @@ messageSends: ["ifTrue:ifFalse:", "isMemberOf:", "inheritsFrom:", "class"]
 }),
 $globals.ProtoObject);
 
+$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.ProtoObject);
+
+$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.ProtoObject)});
+//>>excludeEnd("ctx");
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "notNil\x0a\x09^ self isNil not",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: ["not", "isNil"]
+}),
+$globals.ProtoObject);
+
 $core.addMethod(
 $core.method({
 selector: "perform:",
@@ -1023,99 +1159,6 @@ 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:",
@@ -1291,24 +1334,6 @@ 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",
@@ -1399,31 +1424,6 @@ 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",
@@ -1619,32 +1619,6 @@ 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",
@@ -3064,6 +3038,24 @@ messageSends: []
 $globals.Date);
 
 
+$core.addMethod(
+$core.method({
+selector: "classTag",
+protocol: 'accessing',
+fn: function (){
+var self=this;
+return "magnitude";
+
+},
+//>>excludeStart("ide", pragmas.excludeIdeData);
+args: [],
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'magnitude'",
+referencedClasses: [],
+//>>excludeEnd("ide");
+messageSends: []
+}),
+$globals.Date.klass);
+
 $core.addMethod(
 $core.method({
 selector: "fromMilliseconds:",
@@ -3139,24 +3131,6 @@ 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:",
@@ -4896,22 +4870,16 @@ $globals.Number);
 
 $core.addMethod(
 $core.method({
-selector: "e",
-protocol: 'instance creation',
+selector: "classTag",
+protocol: 'accessing',
 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");
+return "magnitude";
+
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "e\x0a\x09<return Math.E;>",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'magnitude'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -4920,16 +4888,22 @@ $globals.Number.klass);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "e",
+protocol: 'instance creation',
 fn: function (){
 var self=this;
-return "magnitude";
-
+//>>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: "heliosClass\x0a\x09^ 'magnitude'",
+source: "e\x0a\x09<return Math.E;>",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []
@@ -5581,8 +5555,8 @@ $globals.Point);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "magnitude";
@@ -5590,7 +5564,7 @@ return "magnitude";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'magnitude'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'magnitude'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []

+ 46 - 40
bower_components/amber/src/Kernel-Objects.st

@@ -114,10 +114,38 @@ printString
 
 !ProtoObject 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
+!
+
 isKindOf: aClass
 	^ (self isMemberOf: aClass)
 		ifTrue: [ true ]
 		ifFalse: [ self class inheritsFrom: aClass ]
+!
+
+isNil
+	^ false
+!
+
+notNil
+	^ self isNil not
 ! !
 
 !ProtoObject class methodsFor: 'initialization'!
@@ -283,12 +311,6 @@ subclassResponsibility
 
 throw: anObject
 	< throw anObject >
-!
-
-try: aBlock catch: anotherBlock
-	self deprecatedAPI.
-	
-	^ aBlock tryCatch: anotherBlock
 ! !
 
 !Object methodsFor: 'inspecting'!
@@ -322,26 +344,6 @@ putOn: aStream
 
 !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
 !
@@ -370,10 +372,6 @@ isMetaclass
 	^ false
 !
 
-isNil
-	^ false
-!
-
 isNumber
 	^ false
 !
@@ -394,10 +392,6 @@ isSymbol
 	^ false
 !
 
-notNil
-	^ self isNil not
-!
-
 respondsTo: aSelector
 	^ self class canUnderstand: aSelector
 ! !
@@ -718,9 +712,13 @@ printOn: aStream
 	aStream nextPutAll: self asString
 ! !
 
-!Date class methodsFor: 'helios'!
+!Date class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'magnitude'
 ! !
 
@@ -1100,9 +1098,13 @@ positive
 	^ self >= 0
 ! !
 
-!Number class methodsFor: 'helios'!
+!Number class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'magnitude'
 ! !
 
@@ -1239,9 +1241,13 @@ translateBy: delta
 	^ (delta x + x) @ (delta y + y)
 ! !
 
-!Point class methodsFor: 'helios'!
+!Point class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'magnitude'
 ! !
 

+ 1 - 1
bower_components/amber/src/Kernel-Tests.js

@@ -1,7 +1,7 @@
 define("amber_core/Kernel-Tests", ["amber/boot", "amber_core/SUnit", "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-Tests');
+$core.packages["Kernel-Tests"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Tests"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('AnnouncementSubscriptionTest', $globals.TestCase, [], 'Kernel-Tests');

+ 1 - 1
bower_components/amber/src/Kernel-Transcript.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["Kernel-Transcript"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ConsoleTranscript', $globals.Object, ['textarea'], 'Kernel-Transcript');

+ 1 - 1
bower_components/amber/src/SUnit-Tests.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["SUnit-Tests"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ExampleSetTest', $globals.TestCase, ['empty', 'full'], 'SUnit-Tests');

+ 4 - 4
bower_components/amber/src/SUnit.js

@@ -1,7 +1,7 @@
 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"].innerEval = function (expr) { return eval(expr); };
 $core.packages["SUnit"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('ResultAnnouncement', $globals.Object, ['result'], 'SUnit');
@@ -658,8 +658,8 @@ $globals.TestCase.klass);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "test";
@@ -667,7 +667,7 @@ return "test";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'test'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'test'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []

+ 8 - 6
bower_components/amber/src/SUnit.st

@@ -160,6 +160,14 @@ buildSuite
 	^ self allTestSelectors collect: [ :each | self selector: each ]
 !
 
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
+	^ 'test'
+!
+
 lookupHierarchyRoot
 	^ TestCase
 !
@@ -174,12 +182,6 @@ testSelectors
 	^ self methodDictionary keys select: [ :each | each match: '^test' ]
 ! !
 
-!TestCase class methodsFor: 'helios'!
-
-heliosClass
-	^ 'test'
-! !
-
 !TestCase class methodsFor: 'testing'!
 
 isAbstract

+ 11 - 9
bower_components/amber/src/Web.js

@@ -1,7 +1,8 @@
-define("amber_core/Web", ["amber/boot", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Methods", "amber_core/Kernel-Collections"], function($boot){
+define("amber_core/Web", ["amber/boot", "jquery", "amber_core/Kernel-Objects", "amber_core/Kernel-Infrastructure", "amber_core/Kernel-Methods", "amber_core/Kernel-Collections"], function($boot,jQuery){
 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"].innerEval = function (expr) { return eval(expr); };
+$core.packages["Web"].imports = ["jQuery=jquery"];
 $core.packages["Web"].transport = {"type":"amd","amdNamespace":"amber_core"};
 
 $core.addClass('BrowserInterface', $globals.Object, [], 'Web');
@@ -3058,10 +3059,11 @@ selector: "initialize",
 protocol: 'initialization',
 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(jQuery)._basicAt_put_("allowJavaScriptCalls",true);
+$recv($Smalltalk())._optOut_(jQuery);
 return self;
 //>>excludeStart("ctx", pragmas.excludeDebugContexts);
 }, function($ctx1) {$ctx1.fill(self,"initialize",{},$globals.HTMLCanvas.klass)});
@@ -3069,10 +3071,10 @@ return self;
 },
 //>>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: [],
+source: "initialize\x0a\x09\x22Allow JS method calls for the jQuery object.\x0a\x09See boot.js DNU handling.\x22\x0a\x09\x0a\x09Smalltalk optOut: jQuery",
+referencedClasses: ["Smalltalk"],
 //>>excludeEnd("ide");
-messageSends: ["basicAt:put:"]
+messageSends: ["optOut:"]
 }),
 $globals.HTMLCanvas.klass);
 
@@ -5332,8 +5334,8 @@ $globals.Widget);
 
 $core.addMethod(
 $core.method({
-selector: "heliosClass",
-protocol: 'helios',
+selector: "classTag",
+protocol: 'accessing',
 fn: function (){
 var self=this;
 return "widget";
@@ -5341,7 +5343,7 @@ return "widget";
 },
 //>>excludeStart("ide", pragmas.excludeIdeData);
 args: [],
-source: "heliosClass\x0a\x09^ 'widget'",
+source: "classTag\x0a\x09\x22Returns a tag or general category for this class.\x0a\x09Typically used to help tools do some reflection.\x0a\x09Helios, for example, uses this to decide what icon the class should display.\x22\x0a\x09\x0a\x09^ 'widget'",
 referencedClasses: [],
 //>>excludeEnd("ide");
 messageSends: []

+ 8 - 3
bower_components/amber/src/Web.st

@@ -1,4 +1,5 @@
 Smalltalk createPackage: 'Web'!
+(Smalltalk packageAt: 'Web') imports: {'jQuery' -> 'jquery'}!
 Object subclass: #BrowserInterface
 	instanceVariableNames: ''
 	package: 'Web'!
@@ -555,7 +556,7 @@ initialize
 	"Allow JS method calls for the jQuery object.
 	See boot.js DNU handling."
 	
-	jQuery basicAt: 'allowJavaScriptCalls' put: true
+	Smalltalk optOut: jQuery
 ! !
 
 !HTMLCanvas class methodsFor: 'instance creation'!
@@ -1095,9 +1096,13 @@ renderOn: html
 	self
 ! !
 
-!Widget class methodsFor: 'helios'!
+!Widget class methodsFor: 'accessing'!
 
-heliosClass
+classTag
+	"Returns a tag or general category for this class.
+	Typically used to help tools do some reflection.
+	Helios, for example, uses this to decide what icon the class should display."
+	
 	^ 'widget'
 ! !
 

+ 3 - 8
bower_components/amber/support/boot.js

@@ -98,7 +98,7 @@ define("amber/boot", [ 'require', './browser-compatibility' ], function (require
 
 	var globals = {};
 	globals.SmalltalkSettings = {};
-	var api = Object.create(globals);
+	var api = {};
 	var brikz = new Brikz(api);
 
 	function RootBrik(brikz, st) {
@@ -567,8 +567,7 @@ define("amber/boot", [ 'require', './browser-compatibility' ], function (require
 			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.protocol          = spec.protocol;
 			that.source            = spec.source;
 			that.messageSends      = spec.messageSends || [];
 			that.referencedClasses = spec.referencedClasses || [];
@@ -1092,10 +1091,6 @@ define("amber/boot", [ 'require', './browser-compatibility' ], function (require
 			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 */
@@ -1158,5 +1153,5 @@ define("amber/boot", [ 'require', './browser-compatibility' ], function (require
 		brikz.rebuild();
 	}
 
-	return { api: api, /*deprecated:*/vm: api, nil: brikz.root.nil, globals: globals, asReceiver: brikz.asReceiver.asReceiver };
+	return { api: api, nil: brikz.root.nil, globals: globals, asReceiver: brikz.asReceiver.asReceiver };
 });

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

@@ -1,5 +1,10 @@
-define([
-    './ensure-console',
-    'amber_lib/es5-shim/es5-shim.min',
-    'amber_lib/es5-shim/es5-sham.min'
-], {});
+/* Make sure that console is defined */
+if(typeof console === "undefined") {
+	this.console = {
+		log: function() {},
+		warn: function() {},
+		info: function() {},
+		debug: function() {},
+		error: function() {}
+	};
+}

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

@@ -1,6 +1,7 @@
 define([
     './helpers',
     'jquery',
+    // --- packages of the core Amber begin here ---
     'amber_core/Kernel-Objects',
     'amber_core/Kernel-Classes',
     'amber_core/Kernel-Methods',
@@ -10,4 +11,5 @@ define([
     'amber_core/Kernel-Transcript',
     'amber_core/Kernel-Announcements',
     'amber_core/Web'
+    // --- packages of the core Amber end here ---
 ], function (amber) { return amber; });

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

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

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

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

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

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

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

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

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

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

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

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

+ 6 - 11
bower_components/amber/support/devel.js

@@ -2,15 +2,10 @@ 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'
+    // --- packages of the development only Amber begin here ---
+    'amber_core/SUnit',
+    'amber_core/Compiler-Tests',
+    'amber_core/Kernel-Tests',
+    'amber_core/SUnit-Tests'
+    // --- packages of the development only Amber end here ---
 ], function (amber) { return amber; });

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

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

+ 1 - 18
bower_components/amber/support/helpers.js

@@ -1,6 +1,6 @@
 define("amber/helpers", ["amber/boot", "require"], function (boot, require) {
     var globals = boot.globals,
-        exports = Object.create(globals), // backward compatibility, use {} later
+        exports = {},
         api = boot.api,
         nil = boot.nil;
 
@@ -59,27 +59,10 @@ define("amber/helpers", ["amber/boot", "require"], function (boot, require) {
     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;

+ 4 - 6
bower_components/amber/support/lang.js

@@ -1,7 +1,8 @@
 define([
 	'./helpers', // pre-fetch, dep of ./deploy
 	'./deploy',
-	'amber/parser',
+	'./parser',
+	// --- packages for the Amber reflection begin here ---
 	'amber_core/Kernel-ImportExport',
 	'amber_core/Compiler-Exceptions',
 	'amber_core/Compiler-Core',
@@ -9,9 +10,6 @@ define([
 	'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'
+	'amber_core/Compiler-Interpreter'
+	// --- packages for the Amber reflection end here ---
 ], function (amber) { return amber; });

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

@@ -1,36 +0,0 @@
-/*
- 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);

+ 4 - 4
bower_components/codemirror/.bower.json

@@ -1,6 +1,6 @@
 {
   "name": "codemirror",
-  "version": "4.10.0",
+  "version": "4.12.0",
   "main": [
     "lib/codemirror.js",
     "lib/codemirror.css"
@@ -17,11 +17,11 @@
     "package.json"
   ],
   "homepage": "https://github.com/marijnh/CodeMirror",
-  "_release": "4.10.0",
+  "_release": "4.12.0",
   "_resolution": {
     "type": "version",
-    "tag": "4.10.0",
-    "commit": "f6f427c2af6fa8557854552404761e97c7a7acc6"
+    "tag": "4.12.0",
+    "commit": "bed3de39aa62616393db2bab4b5fec6ee2238747"
   },
   "_source": "git://github.com/marijnh/CodeMirror.git",
   "_target": "^4.7.0",

+ 4 - 0
bower_components/codemirror/AUTHORS

@@ -43,6 +43,7 @@ Andy Kimball
 Andy Li
 angelozerr
 angelo.zerr@gmail.com
+Ankit
 Ankit Ahuja
 Ansel Santosa
 Anthony Grimes
@@ -138,6 +139,7 @@ flack
 ForbesLindesay
 Forbes Lindesay
 Ford_Lawnmower
+Forrest Oliphant
 Frank Wiegand
 Gabriel Gheorghian
 Gabriel Horner
@@ -256,6 +258,7 @@ Marcel Gerber
 Marco Aurélio
 Marco Munizaga
 Marcus Bointon
+Marek Rudnicki
 Marijn Haverbeke
 Mário Gonçalves
 Mario Pietsch
@@ -383,6 +386,7 @@ stoskov
 Taha Jahangir
 Takuji Shimokawa
 Tarmil
+tel
 tfjgeorge
 Thaddee Tyl
 TheHowl

+ 14 - 7
bower_components/codemirror/addon/edit/closetag.js

@@ -94,15 +94,15 @@
     }
   }
 
-  function autoCloseSlash(cm) {
-    if (cm.getOption("disableInput")) return CodeMirror.Pass;
+  function autoCloseCurrent(cm, typingSlash) {
     var ranges = cm.listSelections(), replacements = [];
+    var head = typingSlash ? "/" : "</";
     for (var i = 0; i < ranges.length; i++) {
       if (!ranges[i].empty()) return CodeMirror.Pass;
       var pos = ranges[i].head, tok = cm.getTokenAt(pos);
       var inner = CodeMirror.innerMode(cm.getMode(), tok.state), state = inner.state;
-      if (tok.type == "string" || tok.string.charAt(0) != "<" ||
-          tok.start != pos.ch - 1)
+      if (typingSlash && (tok.type == "string" || tok.string.charAt(0) != "<" ||
+                          tok.start != pos.ch - 1))
         return CodeMirror.Pass;
       // Kludge to get around the fact that we are not in XML mode
       // when completing in JS/CSS snippet in htmlmixed mode. Does not
@@ -110,16 +110,16 @@
       // way to go from a mixed mode to its current XML state).
       if (inner.mode.name != "xml") {
         if (cm.getMode().name == "htmlmixed" && inner.mode.name == "javascript")
-          replacements[i] = "/script>";
+          replacements[i] = head + "script>";
         else if (cm.getMode().name == "htmlmixed" && inner.mode.name == "css")
-          replacements[i] = "/style>";
+          replacements[i] = head + "style>";
         else
           return CodeMirror.Pass;
       } else {
         if (!state.context || !state.context.tagName ||
             closingTagExists(cm, state.context.tagName, pos, state))
           return CodeMirror.Pass;
-        replacements[i] = "/" + state.context.tagName + ">";
+        replacements[i] = head + state.context.tagName + ">";
       }
     }
     cm.replaceSelections(replacements);
@@ -129,6 +129,13 @@
         cm.indentLine(ranges[i].head.line);
   }
 
+  function autoCloseSlash(cm) {
+    if (cm.getOption("disableInput")) return CodeMirror.Pass;
+    autoCloseCurrent(cm, true);
+  }
+
+  CodeMirror.commands.closeTag = function(cm) { return autoCloseCurrent(cm); };
+
   function indexOf(collection, elt) {
     if (collection.indexOf) return collection.indexOf(elt);
     for (var i = 0, e = collection.length; i < e; ++i)

+ 4 - 0
bower_components/codemirror/addon/fold/foldcode.js

@@ -142,4 +142,8 @@
       return editorOptions[name];
     return defaultOptions[name];
   }
+
+  CodeMirror.defineExtension("foldOption", function(options, name) {
+    return getOption(this, options, name);
+  });
 });

+ 4 - 2
bower_components/codemirror/addon/fold/foldgutter.js

@@ -67,14 +67,16 @@
 
   function updateFoldInfo(cm, from, to) {
     var opts = cm.state.foldGutter.options, cur = from;
+    var minSize = cm.foldOption(opts, "minFoldSize");
+    var func = cm.foldOption(opts, "rangeFinder");
     cm.eachLine(from, to, function(line) {
       var mark = null;
       if (isFolded(cm, cur)) {
         mark = marker(opts.indicatorFolded);
       } else {
-        var pos = Pos(cur, 0), func = opts.rangeFinder || CodeMirror.fold.auto;
+        var pos = Pos(cur, 0);
         var range = func && func(cm, pos);
-        if (range && range.from.line + 1 < range.to.line)
+        if (range && range.to.line - range.from.line >= minSize)
           mark = marker(opts.indicatorOpen);
       }
       cm.setGutterMarker(line, opts.gutter, mark);

+ 5 - 1
bower_components/codemirror/addon/merge/merge.js

@@ -259,11 +259,13 @@
   function makeConnections(dv) {
     if (!dv.showDifferences) return;
 
-    var align = dv.mv.options.connect == "align";
+    var align = dv.mv.options.connect == "align", oldScrollEdit, oldScrollOrig;
     if (align) {
       if (!dv.orig.curOp) return dv.orig.operation(function() {
         makeConnections(dv);
       });
+      oldScrollEdit = dv.edit.getScrollInfo().top;
+      oldScrollOrig = dv.orig.getScrollInfo().top;
       for (var i = 0; i < dv.aligners.length; i++)
         dv.aligners[i].clear();
       dv.aligners.length = 0;
@@ -293,6 +295,8 @@
         dv.aligners.push(padBelow(dv.edit, 0, extraSpaceAbove.edit));
       if (extraSpaceAbove.orig)
         dv.aligners.push(padBelow(dv.orig, 0, extraSpaceAbove.orig));
+      dv.edit.scrollTo(null, oldScrollEdit);
+      dv.orig.scrollTo(null, oldScrollOrig);
     }
   }
 

+ 1 - 1
bower_components/codemirror/addon/mode/simple.js

@@ -116,7 +116,7 @@
       var curState = states[state.state];
       for (var i = 0; i < curState.length; i++) {
         var rule = curState[i];
-        var matches = stream.match(rule.regex);
+        var matches = (!rule.data.sol || stream.sol()) && stream.match(rule.regex);
         if (matches) {
           if (rule.data.next) {
             state.state = rule.data.next;

+ 6 - 4
bower_components/codemirror/addon/scroll/simplescrollbars.js

@@ -27,14 +27,16 @@
       CodeMirror.e_preventDefault(e);
       var axis = self.orientation == "horizontal" ? "pageX" : "pageY";
       var start = e[axis], startpos = self.pos;
+      function done() {
+        CodeMirror.off(document, "mousemove", move);
+        CodeMirror.off(document, "mouseup", done);
+      }
       function move(e) {
-        if (e.which != 1) {
-          CodeMirror.off(document, "mousemove", move);
-          return;
-        }
+        if (e.which != 1) return done();
         self.moveTo(startpos + (e[axis] - start) * (self.total / self.size));
       }
       CodeMirror.on(document, "mousemove", move);
+      CodeMirror.on(document, "mouseup", done);
     });
 
     CodeMirror.on(this.node, "click", function(e) {

+ 95 - 0
bower_components/codemirror/addon/selection/selection-pointer.js

@@ -0,0 +1,95 @@
+// CodeMirror, copyright (c) by Marijn Haverbeke and others
+// Distributed under an MIT license: http://codemirror.net/LICENSE
+
+(function(mod) {
+  if (typeof exports == "object" && typeof module == "object") // CommonJS
+    mod(require("../../lib/codemirror"));
+  else if (typeof define == "function" && define.amd) // AMD
+    define(["../../lib/codemirror"], mod);
+  else // Plain browser env
+    mod(CodeMirror);
+})(function(CodeMirror) {
+  "use strict";
+
+  CodeMirror.defineOption("selectionPointer", false, function(cm, val) {
+    var data = cm.state.selectionPointer;
+    if (data) {
+      CodeMirror.off(cm.getWrapperElement(), "mousemove", data.mousemove);
+      CodeMirror.off(cm.getWrapperElement(), "mouseout", data.mouseout);
+      cm.off("cursorActivity", reset);
+      cm.off("scroll", reset);
+      cm.state.selectionPointer = null;
+      cm.display.lineDiv.style.cursor = "";
+    }
+    if (val) {
+      data = cm.state.selectionPointer = {
+        value: typeof val == "string" ? val : "default",
+        mousemove: function(event) { mousemove(cm, event); },
+        mouseout: function(event) { mouseout(cm, event); },
+        rects: null,
+        mouseX: null, mouseY: null,
+        willUpdate: false
+      };
+      CodeMirror.on(cm.getWrapperElement(), "mousemove", data.mousemove);
+      CodeMirror.on(cm.getWrapperElement(), "mouseout", data.mouseout);
+      cm.on("cursorActivity", reset);
+      cm.on("scroll", reset);
+    }
+  });
+
+  function mousemove(cm, event) {
+    var data = cm.state.selectionPointer;
+    if (event.buttons == null ? event.which : event.buttons) {
+      data.mouseX = data.mouseY = null;
+    } else {
+      data.mouseX = event.clientX;
+      data.mouseY = event.clientY;
+    }
+    scheduleUpdate(cm);
+  }
+
+  function mouseout(cm, event) {
+    if (!cm.getWrapperElement().contains(event.relatedTarget)) {
+      var data = cm.state.selectionPointer;
+      data.mouseX = data.mouseY = null;
+      scheduleUpdate(cm);
+    }
+  }
+
+  function reset(cm) {
+    cm.state.selectionPointer.rects = null;
+    scheduleUpdate(cm);
+  }
+
+  function scheduleUpdate(cm) {
+    if (!cm.state.selectionPointer.willUpdate) {
+      cm.state.selectionPointer.willUpdate = true;
+      setTimeout(function() {
+        update(cm);
+        cm.state.selectionPointer.willUpdate = false;
+      }, 50);
+    }
+  }
+
+  function update(cm) {
+    var data = cm.state.selectionPointer;
+    if (!data) return;
+    if (data.rects == null && data.mouseX != null) {
+      data.rects = [];
+      if (cm.somethingSelected()) {
+        for (var sel = cm.display.selectionDiv.firstChild; sel; sel = sel.nextSibling)
+          data.rects.push(sel.getBoundingClientRect());
+      }
+    }
+    var inside = false;
+    if (data.mouseX != null) for (var i = 0; i < data.rects.length; i++) {
+      var rect = data.rects[i];
+      if (rect.left <= data.mouseX && rect.right >= data.mouseX &&
+          rect.top <= data.mouseY && rect.bottom >= data.mouseY)
+        inside = true;
+    }
+    var cursor = inside ? data.value : "";
+    if (cm.display.lineDiv.style.cursor != cursor)
+      cm.display.lineDiv.style.cursor = cursor;
+  }
+});

+ 1 - 1
bower_components/codemirror/bower.json

@@ -1,6 +1,6 @@
 {
   "name": "codemirror",
-  "version":"4.10.0",
+  "version":"4.12.0",
   "main": ["lib/codemirror.js", "lib/codemirror.css"],
   "ignore": [
     "**/.*",

+ 1 - 0
bower_components/codemirror/keymap/emacs.js

@@ -395,6 +395,7 @@
     "Ctrl-X U": repeated("undo"),
     "Ctrl-X K": "close",
     "Ctrl-X Delete": function(cm) { kill(cm, cm.getCursor(), bySentence(cm, cm.getCursor(), 1), true); },
+    "Ctrl-X H": "selectAll",
 
     "Ctrl-Q Tab": repeated("insertTab"),
     "Ctrl-U": addPrefixMap

+ 22 - 3
bower_components/codemirror/keymap/vim.js

@@ -3469,6 +3469,12 @@
       },
       setReversed: function(reversed) {
         vimGlobalState.isReversed = reversed;
+      },
+      getScrollbarAnnotate: function() {
+        return this.annotate;
+      },
+      setScrollbarAnnotate: function(annotate) {
+        this.annotate = annotate;
       }
     };
     function getSearchState(cm) {
@@ -3747,14 +3753,21 @@
       };
     }
     function highlightSearchMatches(cm, query) {
-      var overlay = getSearchState(cm).getOverlay();
+      var searchState = getSearchState(cm);
+      var overlay = searchState.getOverlay();
       if (!overlay || query != overlay.query) {
         if (overlay) {
           cm.removeOverlay(overlay);
         }
         overlay = searchOverlay(query);
         cm.addOverlay(overlay);
-        getSearchState(cm).setOverlay(overlay);
+        if (cm.showMatchesOnScrollbar) {
+          if (searchState.getScrollbarAnnotate()) {
+            searchState.getScrollbarAnnotate().clear();
+          }
+          searchState.setScrollbarAnnotate(cm.showMatchesOnScrollbar(query));
+        }
+        searchState.setOverlay(overlay);
       }
     }
     function findNext(cm, prev, query, repeat) {
@@ -3779,8 +3792,13 @@
       });
     }
     function clearSearchHighlight(cm) {
+      var state = getSearchState(cm);
       cm.removeOverlay(getSearchState(cm).getOverlay());
-      getSearchState(cm).setOverlay(null);
+      state.setOverlay(null);
+      if (state.getScrollbarAnnotate()) {
+        state.getScrollbarAnnotate().clear();
+        state.setScrollbarAnnotate(null);
+      }
     }
     /**
      * Check if pos is in the specified range, INCLUSIVE.
@@ -4789,6 +4807,7 @@
       var macroModeState = vimGlobalState.macroModeState;
       var lastChange = macroModeState.lastInsertModeChanges;
       var keyName = CodeMirror.keyName(e);
+      if (!keyName) { return; }
       function onKeyFound() {
         lastChange.changes.push(new InsertModeKey(keyName));
         return true;

+ 35 - 19
bower_components/codemirror/lib/codemirror.js

@@ -112,6 +112,11 @@
     maybeUpdateLineNumberWidth(this);
     for (var i = 0; i < initHooks.length; ++i) initHooks[i](this);
     endOperation(this);
+    // Suppress optimizelegibility in Webkit, since it breaks text
+    // measuring on line wrapping boundaries.
+    if (webkit && options.lineWrapping &&
+        getComputedStyle(display.lineDiv).textRendering == "optimizelegibility")
+      display.lineDiv.style.textRendering = "auto";
   }
 
   // DISPLAY CONSTRUCTOR
@@ -719,7 +724,7 @@
     // width and height.
     removeChildren(display.cursorDiv);
     removeChildren(display.selectionDiv);
-    display.heightForcer.style.top = display.gutters.style.height = 0;
+    display.gutters.style.height = 0;
 
     if (different) {
       display.lastWrapHeight = update.wrapperHeight;
@@ -777,9 +782,9 @@
 
   function setDocumentHeight(cm, measure) {
     cm.display.sizer.style.minHeight = measure.docHeight + "px";
-    var plusGap = measure.docHeight + scrollGap(cm);
-    cm.display.heightForcer.style.top = plusGap + "px";
-    cm.display.gutters.style.height = Math.max(plusGap, measure.clientHeight) + "px";
+    var total = measure.docHeight + cm.display.barHeight;
+    cm.display.heightForcer.style.top = total + "px";
+    cm.display.gutters.style.height = Math.max(total + scrollGap(cm), measure.clientHeight) + "px";
   }
 
   // Read the actual heights of the rendered lines, and update their
@@ -1847,7 +1852,8 @@
 
   // Converts a {top, bottom, left, right} box from line-local
   // coordinates into another coordinate system. Context may be one of
-  // "line", "div" (display.lineDiv), "local"/null (editor), or "page".
+  // "line", "div" (display.lineDiv), "local"/null (editor), "window",
+  // or "page".
   function intoCoordSystem(cm, lineObj, rect, context) {
     if (lineObj.widgets) for (var i = 0; i < lineObj.widgets.length; ++i) if (lineObj.widgets[i].above) {
       var size = widgetHeight(lineObj.widgets[i]);
@@ -2759,7 +2765,9 @@
   // Return true when the given mouse event happened in a widget
   function eventInWidget(display, e) {
     for (var n = e_target(e); n != display.wrapper; n = n.parentNode) {
-      if (!n || n.getAttribute("cm-ignore-events") == "true" || n.parentNode == display.sizer && n != display.mover) return true;
+      if (!n || (n.nodeType == 1 && n.getAttribute("cm-ignore-events") == "true") ||
+          (n.parentNode == display.sizer && n != display.mover))
+        return true;
     }
   }
 
@@ -3788,7 +3796,9 @@
 
     var lendiff = change.text.length - (to.line - from.line) - 1;
     // Remember that these lines changed, for updating the display
-    if (from.line == to.line && change.text.length == 1 && !isWholeLineUpdate(cm.doc, change))
+    if (change.full)
+      regChange(cm);
+    else if (from.line == to.line && change.text.length == 1 && !isWholeLineUpdate(cm.doc, change))
       regLineChange(cm, from.line, "text");
     else
       regChange(cm, from.line, to.line + 1, lendiff);
@@ -5570,6 +5580,7 @@
   // spans partially within the change. Returns an array of span
   // arrays with one element for each line in (after) the change.
   function stretchSpansOverChange(doc, change) {
+    if (change.full) return null;
     var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans;
     var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans;
     if (!oldFirst && !oldLast) return null;
@@ -5879,7 +5890,9 @@
     if (!contains(document.body, widget.node)) {
       var parentStyle = "position: relative;";
       if (widget.coverGutter)
-        parentStyle += "margin-left: -" + widget.cm.getGutterElement().offsetWidth + "px;";
+        parentStyle += "margin-left: -" + widget.cm.display.gutters.offsetWidth + "px;";
+      if (widget.noHScroll)
+        parentStyle += "width: " + widget.cm.display.wrapper.clientWidth + "px;";
       removeChildrenAndAdd(widget.cm.display.measure, elt("div", [widget.node], null, parentStyle));
     }
     return widget.height = widget.node.offsetHeight;
@@ -6342,17 +6355,24 @@
       updateLine(line, text, spans, estimateHeight);
       signalLater(line, "change", line, change);
     }
+    function linesFor(start, end) {
+      for (var i = start, result = []; i < end; ++i)
+        result.push(new Line(text[i], spansFor(i), estimateHeight));
+      return result;
+    }
 
     var from = change.from, to = change.to, text = change.text;
     var firstLine = getLine(doc, from.line), lastLine = getLine(doc, to.line);
     var lastText = lst(text), lastSpans = spansFor(text.length - 1), nlines = to.line - from.line;
 
     // Adjust the line structure
-    if (isWholeLineUpdate(doc, change)) {
+    if (change.full) {
+      doc.insert(0, linesFor(0, text.length));
+      doc.remove(text.length, doc.size - text.length);
+    } else if (isWholeLineUpdate(doc, change)) {
       // This is a whole-line replace. Treated specially to make
       // sure line objects move the way they are supposed to.
-      for (var i = 0, added = []; i < text.length - 1; ++i)
-        added.push(new Line(text[i], spansFor(i), estimateHeight));
+      var added = linesFor(0, text.length - 1);
       update(lastLine, lastLine.text, lastSpans);
       if (nlines) doc.remove(from.line, nlines);
       if (added.length) doc.insert(from.line, added);
@@ -6360,8 +6380,7 @@
       if (text.length == 1) {
         update(firstLine, firstLine.text.slice(0, from.ch) + lastText + firstLine.text.slice(to.ch), lastSpans);
       } else {
-        for (var added = [], i = 1; i < text.length - 1; ++i)
-          added.push(new Line(text[i], spansFor(i), estimateHeight));
+        var added = linesFor(1, text.length - 1);
         added.push(new Line(lastText + firstLine.text.slice(to.ch), lastSpans, estimateHeight));
         update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
         doc.insert(from.line + 1, added);
@@ -6372,8 +6391,7 @@
     } else {
       update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
       update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans);
-      for (var i = 1, added = []; i < text.length - 1; ++i)
-        added.push(new Line(text[i], spansFor(i), estimateHeight));
+      var added = linesFor(1, text.length - 1);
       if (nlines > 1) doc.remove(from.line + 1, nlines - 1);
       doc.insert(from.line + 1, added);
     }
@@ -6584,7 +6602,7 @@
     setValue: docMethodOp(function(code) {
       var top = Pos(this.first, 0), last = this.first + this.size - 1;
       makeChange(this, {from: top, to: Pos(last, getLine(this, last).text.length),
-                        text: splitLines(code), origin: "setValue"}, true);
+                        text: splitLines(code), origin: "setValue", full: true}, true);
       setSelection(this, simpleSelection(top));
     }),
     replaceRange: function(code, from, to, origin) {
@@ -7464,13 +7482,11 @@
       if (array[i] == elt) return i;
     return -1;
   }
-  if ([].indexOf) indexOf = function(array, elt) { return array.indexOf(elt); };
   function map(array, f) {
     var out = [];
     for (var i = 0; i < array.length; i++) out[i] = f(array[i], i);
     return out;
   }
-  if ([].map) map = function(array, f) { return array.map(f); };
 
   function createObj(base, props) {
     var inst;
@@ -8023,7 +8039,7 @@
 
   // THE END
 
-  CodeMirror.version = "4.10.0";
+  CodeMirror.version = "4.12.0";
 
   return CodeMirror;
 });

+ 4 - 4
bower_components/codemirror/mode/clike/clike.js

@@ -408,7 +408,7 @@ CodeMirror.defineMode("clike", function(config, parserConfig) {
                     "vec2 vec3 vec4 ivec2 ivec3 ivec4 bvec2 bvec3 bvec4 " +
                     "mat2 mat3 mat4 " +
                     "sampler1D sampler2D sampler3D samplerCube " +
-                    "sampler1DShadow sampler2DShadow" +
+                    "sampler1DShadow sampler2DShadow " +
                     "const attribute uniform varying " +
                     "break continue discard return " +
                     "for while do if else struct " +
@@ -416,7 +416,7 @@ CodeMirror.defineMode("clike", function(config, parserConfig) {
     blockKeywords: words("for while do if else struct"),
     builtin: words("radians degrees sin cos tan asin acos atan " +
                     "pow exp log exp2 sqrt inversesqrt " +
-                    "abs sign floor ceil fract mod min max clamp mix step smootstep " +
+                    "abs sign floor ceil fract mod min max clamp mix step smoothstep " +
                     "length distance dot cross normalize ftransform faceforward " +
                     "reflect refract matrixCompMult " +
                     "lessThan lessThanEqual greaterThan greaterThanEqual " +
@@ -433,12 +433,12 @@ CodeMirror.defineMode("clike", function(config, parserConfig) {
                 "gl_FragColor gl_SecondaryColor gl_Normal gl_Vertex " +
                 "gl_MultiTexCoord0 gl_MultiTexCoord1 gl_MultiTexCoord2 gl_MultiTexCoord3 " +
                 "gl_MultiTexCoord4 gl_MultiTexCoord5 gl_MultiTexCoord6 gl_MultiTexCoord7 " +
-                "gl_FogCoord " +
+                "gl_FogCoord gl_PointCoord " +
                 "gl_Position gl_PointSize gl_ClipVertex " +
                 "gl_FrontColor gl_BackColor gl_FrontSecondaryColor gl_BackSecondaryColor " +
                 "gl_TexCoord gl_FogFragCoord " +
                 "gl_FragCoord gl_FrontFacing " +
-                "gl_FragColor gl_FragData gl_FragDepth " +
+                "gl_FragData gl_FragDepth " +
                 "gl_ModelViewMatrix gl_ProjectionMatrix gl_ModelViewProjectionMatrix " +
                 "gl_TextureMatrix gl_NormalMatrix gl_ModelViewMatrixInverse " +
                 "gl_ProjectionMatrixInverse gl_ModelViewProjectionMatrixInverse " +

+ 2 - 2
bower_components/codemirror/mode/css/css.js

@@ -525,14 +525,14 @@ CodeMirror.defineMode("css", function(config, parserConfig) {
     "ethiopic-halehame-sid-et", "ethiopic-halehame-so-et",
     "ethiopic-halehame-ti-er", "ethiopic-halehame-ti-et",
     "ethiopic-halehame-tig", "ew-resize", "expanded", "extra-condensed",
-    "extra-expanded", "fantasy", "fast", "fill", "fixed", "flat", "footnotes",
+    "extra-expanded", "fantasy", "fast", "fill", "fixed", "flat", "flex", "footnotes",
     "forwards", "from", "geometricPrecision", "georgian", "graytext", "groove",
     "gujarati", "gurmukhi", "hand", "hangul", "hangul-consonant", "hebrew",
     "help", "hidden", "hide", "higher", "highlight", "highlighttext",
     "hiragana", "hiragana-iroha", "horizontal", "hsl", "hsla", "icon", "ignore",
     "inactiveborder", "inactivecaption", "inactivecaptiontext", "infinite",
     "infobackground", "infotext", "inherit", "initial", "inline", "inline-axis",
-    "inline-block", "inline-table", "inset", "inside", "intrinsic", "invert",
+    "inline-block", "inline-flex", "inline-table", "inset", "inside", "intrinsic", "invert",
     "italic", "justify", "kannada", "katakana", "katakana-iroha", "keep-all", "khmer",
     "landscape", "lao", "large", "larger", "left", "level", "lighter",
     "line-through", "linear", "lines", "list-item", "listbox", "listitem",

+ 7 - 1
bower_components/codemirror/mode/javascript/javascript.js

@@ -600,6 +600,12 @@ CodeMirror.defineMode("javascript", function(config, parserConfig) {
     if (type == "if") return cont(expression, comprehension);
   }
 
+  function isContinuedStatement(state, textAfter) {
+    return state.lastType == "operator" || state.lastType == "," ||
+      isOperatorChar.test(textAfter.charAt(0)) ||
+      /[,.]/.test(textAfter.charAt(0));
+  }
+
   // Interface
 
   return {
@@ -651,7 +657,7 @@ CodeMirror.defineMode("javascript", function(config, parserConfig) {
       else if (type == "form" && firstChar == "{") return lexical.indented;
       else if (type == "form") return lexical.indented + indentUnit;
       else if (type == "stat")
-        return lexical.indented + (state.lastType == "operator" || state.lastType == "," ? statementIndent || indentUnit : 0);
+        return lexical.indented + (isContinuedStatement(state, textAfter) ? statementIndent || indentUnit : 0);
       else if (lexical.info == "switch" && !closing && parserConfig.doubleIndentSwitch != false)
         return lexical.indented + (/^(?:case|default)\b/.test(textAfter) ? indentUnit : 2 * indentUnit);
       else if (lexical.align) return lexical.column + (closing ? 0 : 1);

Some files were not shown because too many files changed in this diff