opal 0.9.0.beta2 → 0.9.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (104) hide show
  1. checksums.yaml +4 -4
  2. data/.jshintrc +2 -1
  3. data/.travis.yml +8 -4
  4. data/CHANGELOG.md +270 -251
  5. data/CONTRIBUTING.md +41 -0
  6. data/README.md +8 -8
  7. data/Rakefile +1 -1
  8. data/lib/opal/cli.rb +1 -0
  9. data/lib/opal/cli_options.rb +2 -2
  10. data/lib/opal/cli_runners.rb +1 -0
  11. data/lib/opal/cli_runners/nashorn.rb +58 -0
  12. data/lib/opal/cli_runners/phantom.js +11 -9
  13. data/lib/opal/compiler.rb +2 -0
  14. data/lib/opal/erb.rb +2 -1
  15. data/lib/opal/nodes/def.rb +15 -6
  16. data/lib/opal/nodes/helpers.rb +1 -1
  17. data/lib/opal/nodes/literal.rb +1 -1
  18. data/lib/opal/nodes/masgn.rb +79 -29
  19. data/lib/opal/nodes/module.rb +1 -1
  20. data/lib/opal/nodes/top.rb +6 -2
  21. data/lib/opal/parser.rb +1 -0
  22. data/lib/opal/parser/grammar.rb +3160 -3083
  23. data/lib/opal/parser/grammar.y +39 -11
  24. data/lib/opal/parser/lexer.rb +15 -13
  25. data/lib/opal/parser/sexp.rb +5 -0
  26. data/lib/opal/version.rb +1 -1
  27. data/opal/corelib/array.rb +21 -6
  28. data/opal/corelib/basic_object.rb +17 -4
  29. data/opal/corelib/class.rb +1 -1
  30. data/opal/corelib/constants.rb +2 -2
  31. data/opal/corelib/enumerator.rb +2 -0
  32. data/opal/corelib/hash.rb +50 -50
  33. data/opal/corelib/helpers.rb +1 -1
  34. data/opal/corelib/io.rb +9 -6
  35. data/opal/corelib/kernel.rb +37 -9
  36. data/opal/corelib/module.rb +6 -17
  37. data/opal/corelib/nil.rb +4 -0
  38. data/opal/corelib/number.rb +0 -4
  39. data/opal/corelib/runtime.js +637 -662
  40. data/opal/corelib/struct.rb +7 -3
  41. data/spec/filters/bugs/array.rb +4 -9
  42. data/spec/filters/bugs/basicobject.rb +1 -15
  43. data/spec/filters/bugs/date.rb +4 -26
  44. data/spec/filters/bugs/enumerable.rb +26 -1
  45. data/spec/filters/bugs/enumerator.rb +4 -4
  46. data/spec/filters/bugs/exception.rb +1 -7
  47. data/spec/filters/bugs/float.rb +14 -0
  48. data/spec/filters/bugs/hash.rb +0 -2
  49. data/spec/filters/bugs/integer.rb +1 -1
  50. data/spec/filters/bugs/kernel.rb +47 -66
  51. data/spec/filters/bugs/language.rb +1 -2
  52. data/spec/filters/bugs/module.rb +11 -14
  53. data/spec/filters/bugs/numeric.rb +3 -3
  54. data/spec/filters/bugs/proc.rb +0 -1
  55. data/spec/filters/bugs/range.rb +2 -3
  56. data/spec/filters/bugs/regexp.rb +15 -17
  57. data/spec/filters/bugs/set.rb +2 -2
  58. data/spec/filters/bugs/string.rb +29 -5
  59. data/spec/filters/bugs/{strscan.rb → stringscanner.rb} +9 -10
  60. data/spec/filters/bugs/struct.rb +0 -4
  61. data/spec/filters/bugs/time.rb +2 -3
  62. data/spec/filters/bugs/unboundmethod.rb +3 -0
  63. data/spec/filters/unsupported/freeze.rb +2 -1
  64. data/spec/filters/unsupported/taint.rb +2 -0
  65. data/spec/lib/parser/aref_spec.rb +10 -0
  66. data/spec/lib/parser/lambda_spec.rb +14 -0
  67. data/spec/lib/parser/op_asgn_spec.rb +17 -0
  68. data/spec/lib/parser/return_spec.rb +5 -0
  69. data/spec/lib/parser/unary_spec.rb +4 -0
  70. data/spec/lib/sprockets/erb_spec.rb +1 -1
  71. data/spec/mspec/opal/formatters.rb +159 -0
  72. data/{lib → spec}/mspec/opal/runner.rb +0 -160
  73. data/spec/opal/core/hash/internals_spec.rb +162 -162
  74. data/spec/opal/core/kernel/at_exit_spec.rb +70 -0
  75. data/spec/opal/core/kernel/extend_spec.rb +1 -1
  76. data/spec/opal/core/kernel/instance_variables_spec.rb +56 -0
  77. data/spec/opal/core/language/equal_spec.rb +8 -0
  78. data/spec/opal/core/language/predefined_spec.rb +1 -1
  79. data/spec/opal/core/language/ternary_operator_spec.rb +14 -0
  80. data/spec/opal/core/language/versions/{hash_1.9.rb → hash_1_9_spec.rb} +5 -0
  81. data/spec/opal/core/module/fixtures/classes.rb +11 -1
  82. data/spec/opal/core/module/method_lookup_spec.rb +13 -0
  83. data/spec/opal/core/runtime/super_spec.rb +10 -0
  84. data/spec/opal/stdlib/native/new_spec.rb +84 -0
  85. data/spec/opal/stdlib/strscan/scan_spec.rb +11 -0
  86. data/spec/rubyspecs +6 -9
  87. data/spec/spec_helper.rb +9 -21
  88. data/stdlib/date.rb +121 -1
  89. data/stdlib/js.rb +13 -5
  90. data/stdlib/json.rb +3 -3
  91. data/stdlib/nashorn.rb +5 -0
  92. data/stdlib/nashorn/file.rb +13 -0
  93. data/stdlib/nashorn/io.rb +2 -0
  94. data/stdlib/native.rb +12 -4
  95. data/stdlib/nodejs/io.rb +5 -2
  96. data/stdlib/opal/platform.rb +19 -0
  97. data/stdlib/phantomjs.rb +4 -0
  98. data/stdlib/strscan.rb +1 -1
  99. data/tasks/building.rake +2 -1
  100. data/tasks/testing.rake +29 -34
  101. data/tasks/testing/{phantomjs1-sprockets.js → sprockets-phantomjs.js} +2 -20
  102. data/vendored-minitest/minitest/test.rb +7 -15
  103. metadata +32 -9
  104. data/lib/mspec/opal/main.rb.erb +0 -9
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a71d75efaebcd98ae54fc1221323252c84d83725
4
- data.tar.gz: 81f52eea1fb84c5bb009ccd90bdf4cbc2f8344a8
3
+ metadata.gz: 62af1a23be47ed15ba180aab47ae2b960feb1a1d
4
+ data.tar.gz: 228f0b9d53bb0029c97560efb41b58417e3a1312
5
5
  SHA512:
6
- metadata.gz: c9fa8aa94a8350f9ec2bde008a844c4fb09d5b05917abc21045791b584adef85951106190840e50b29e047ad0f464e0acfbee5e8ac5ba2872ffac59574efc136
7
- data.tar.gz: 3744c8d573fa179442543ad09d876ee64d56b2d0114c151cc2789821741c52206edce4c0ba798658d91ee3c25679aa37b37c3eb5548e6d1611a3a68b42409f5c
6
+ metadata.gz: f2d35d332054d7da0a7c10c617d2c71b3d0f17b9f179d352d027dca887a38725fbca63b09cd963660bd82a358fc79d9fe841b353209981db8400a63e5df843cb
7
+ data.tar.gz: ddb2ce713af79c8414966769b9cce482ee3d3e2cb9b16177ac9f14f4df7600e4a7a5265e8cf0ea4a713be37557d9038f576a0fdc5fec6698931e3b27b84c9289
data/.jshintrc CHANGED
@@ -15,7 +15,8 @@
15
15
  "OpalNode": true,
16
16
  "callPhantom": true,
17
17
  "JSON": true,
18
- "Pippo": true
18
+ "Pippo": true,
19
+ "Java": true
19
20
  },
20
21
 
21
22
  "browser": true,
data/.travis.yml CHANGED
@@ -18,22 +18,25 @@ matrix:
18
18
  env: RUN=jshint SUITE=stdlib
19
19
 
20
20
  - rvm: 2.2
21
- env: RUN=mspec_opal_node
21
+ env: RUN=mspec_opal_nodejs
22
22
 
23
23
  - rvm: 2.2
24
- env: RUN=mspec_rubyspec_node TZ="/usr/share/zoneinfo/Pacific/Fiji"
24
+ env: RUN=mspec_rubyspec_nodejs TZ="/usr/share/zoneinfo/Pacific/Fiji"
25
25
 
26
26
  - rvm: 2.2.3
27
- env: RUN=mspec_rubyspec_phantom
27
+ env: RUN=mspec_rubyspec_sprockets_phantomjs
28
28
 
29
29
  - rvm: 2.2
30
30
  env: RUN=rspec TILT_VERSION=2.0.1
31
31
 
32
+ - rvm: ruby-head
33
+ env: RUN=rspec
34
+
32
35
  - rvm: 2.1
33
36
  env: RUN=rspec
34
37
 
35
38
  - rvm: 2.0
36
- env: RUN="rspec"
39
+ env: RUN=rspec
37
40
 
38
41
  - rvm: 1.9.3
39
42
  env: RUN=rspec
@@ -54,6 +57,7 @@ matrix:
54
57
  - rvm: 1.9.3
55
58
  - rvm: 2.1
56
59
  - rvm: 2.0
60
+ - rvm: ruby-head
57
61
  - rvm: rbx
58
62
  - rvm: jruby
59
63
  - rvm: jruby-head
data/CHANGELOG.md CHANGED
@@ -1,47 +1,57 @@
1
1
  ## 0.9.0 (edge)
2
2
 
3
- * A `console` wrapper has been added to the stdlib, requiring it will make available the `$console` global variable.
3
+ * Fixed usage of JS keywords as instance variable names for:
4
+ * `Kernel#instance_variable_set`
5
+ * `Kernel#instance_variable_get`
6
+ * `Kernel#instance_variables`
4
7
 
5
- * `Kernel#pp` no longer forwards arguments directly to `console.log`, this behavior has been * `replaced by stdlib's own `console.rb` (see above).
8
+ * Renamed:
9
+ * `Hash.keys` => `Hash.$$keys`
10
+ * `Hash.map` => `Hash.$$map`
11
+ * `Hash.smap` => `Hash.$$smap`
6
12
 
7
- * `method_added`, `method_removed` and `method_undefined` reflection now works.
13
+ * A `console` wrapper has been added to the stdlib, requiring it will make available the `$console` global variable.
8
14
 
9
- * `singleton_method_added`, `singleton_method_removed` and `singleton_method_undefined` reflection now works.
15
+ * `Kernel#pp` no longer forwards arguments directly to `console.log`, this behavior has been replaced by stdlib's own `console.rb` (see above).
10
16
 
11
- * Now you can bridge a native class to a Ruby class that inherits from another Ruby class
17
+ * `method_added`, `method_removed` and `method_undefined` reflection now works.
12
18
 
13
- * `Numeric` semantics are now compliant with Ruby.
19
+ * `singleton_method_added`, `singleton_method_removed` and `singleton_method_undefined` reflection now works.
14
20
 
15
- * `Complex` has been fully implemented.
21
+ * Now you can bridge a native class to a Ruby class that inherits from another Ruby class
16
22
 
17
- * `Rational` has been fully implemented.
23
+ * `Numeric` semantics are now compliant with Ruby.
18
24
 
19
- * `Opal::Sprockets.javascript_include_tag` has been add to allow easy debug mode (i.e. with source maps) when including a sprockets asset into an HTML page.
25
+ * `Complex` has been fully implemented.
20
26
 
21
- * `Opal::Processor.load_asset_code(sprockets, name)` has been deprecated in favor of `Opal::Sprockets.load_asset(name, sprockets)`.
27
+ * `Rational` has been fully implemented.
22
28
 
23
- * `Struct#hash` now works properly based on struct contents
29
+ * `Opal::Sprockets.javascript_include_tag` has been add to allow easy debug mode (i.e. with source maps) when including a sprockets asset into an HTML page.
24
30
 
25
- * No longer crashes when calling a method with an opt arg followed by an optional kwarg when called without the kwarg
31
+ * `Opal::Processor.load_asset_code(sprockets, name)` has been deprecated in favor of `Opal::Sprockets.load_asset(name, sprockets)`.
26
32
 
27
- * Newly compliant with RubySpec:
28
- * `Enumerable#chunk`
29
- * `Enumerable#each_cons`
30
- * `Enumerable#minmax`
33
+ * `Struct#hash` now works properly based on struct contents
31
34
 
32
- * Operator methods (e.g. `+`, `<`, etc.) can be handled by `method_missing`
35
+ * No longer crashes when calling a method with an opt arg followed by an optional kwarg when called without the kwarg
33
36
 
34
- * `OpenStruct` - fixed `#method missing`, `#inspect`, `#to_s`, `#delete_field`. Fully compliant except for frozen and marshal behavior.
37
+ * Newly compliant with RubySpec:
38
+ * `Enumerable#chunk`
39
+ * `Enumerable#each_cons`
40
+ * `Enumerable#minmax`
35
41
 
36
- * Fix issue where passing a block after a parameter and a hash was causing block to not be passed (e.g. `method1 some_param, 'a' => 1, &block`)
42
+ * Operator methods (e.g. `+`, `<`, etc.) can be handled by `method_missing`
37
43
 
38
- * `Kernel#raise` now properly re-raises exceptions (regardless of how many levels deep you are) and works properly if supplied a class that has an exception method.
44
+ * `OpenStruct` - fixed `#method missing`, `#inspect`, `#to_s`, `#delete_field`. Fully compliant except for frozen and marshal behavior.
39
45
 
40
- * `Exception#exception`, `Exception::exception`, `Exception#message`, and `Exception#to_s` are fully implemented
46
+ * Fix issue where passing a block after a parameter and a hash was causing block to not be passed (e.g. `method1 some_param, 'a' => 1, &block`)
41
47
 
42
- * Method defs issued inside `Module#instance_eval` and `Class#instance_eval`, and the respective `exec` now create class methods
48
+ * `Kernel#raise` now properly re-raises exceptions (regardless of how many levels deep you are) and works properly if supplied a class that has an exception method.
43
49
 
44
- * You can make direct JavaScript method calls on using the `recv.JS.method`syntax. Has support for method calls, final callback (as a block), property getter and setter (via `#[]` and `#[]=`), splats, JavaScript keywords (via the `::JS` module) and global functions (after `require "js"`).
50
+ * `Exception#exception`, `Exception::exception`, `Exception#message`, and `Exception#to_s` are fully implemented
51
+
52
+ * Method defs issued inside `Module#instance_eval` and `Class#instance_eval`, and the respective `exec` now create class methods
53
+
54
+ * You can make direct JavaScript method calls on using the `recv.JS.method`syntax. Has support for method calls, final callback (as a block), property getter and setter (via `#[]` and `#[]=`), splats, JavaScript keywords (via the `::JS` module) and global functions (after `require "js"`).
45
55
 
46
56
  * `Set#superset?`, `Set#subset?`, and the respective 'proper_' variant of each are now implemented
47
57
 
@@ -57,253 +67,262 @@
57
67
 
58
68
  * `Regexp#options` has been optimized and correctly returns 0 when called on a Regexp literal without any options (e.g. //)
59
69
 
70
+ * Fix `Kernel#exit` to allow exit inside `#at_exit`
71
+
72
+ * `BasicObject#instance_eval` now compliant with a string argument (needs `require "opal-parser"`)
73
+
74
+ * Fixed `Native()` when used with `Array` instances containing native objects (which weren't wrapped properly) – #1212
75
+
76
+ * Adds Nashorn (Java 8+ Javascript engine) runner `bundle exec bin/opal -R nashorn -r nashorn hello.rb`
77
+
78
+ * Fixed a number of syntax errors (e.g. #1224 #1225 #1227 #1231 #1233 #1226)
60
79
 
61
80
  ## 0.8.1 2015-10-12
62
81
 
63
- * Use official Sprockets processor cache keys API:
82
+ * Use official Sprockets processor cache keys API:
64
83
  The old cache key hack has been removed.
65
84
  Add `Opal::Processor.cache_key` and `Opal::Processor.reset_cache_key!` to
66
85
  reset it as it’s cached but should change whenever `Opal::Config` changes.
67
86
 
68
- * Fix an issue for which a Pathname was passed instead of a String to Sprockets.
87
+ * Fix an issue for which a Pathname was passed instead of a String to Sprockets.
69
88
 
70
89
  ## 0.8.0 2015-07-16
71
90
 
72
- * Update to Sprockets v3.0.
91
+ * Update to Sprockets v3.0.
73
92
 
74
- * Delegate dependency management directly to Sprockets (when used) making sourcemaps swift again.
93
+ * Delegate dependency management directly to Sprockets (when used) making sourcemaps swift again.
75
94
  This means code generated by sprockets will always need to be bootstrapped via `Opal.load` or `Opal.require`.
76
95
  Luckily `Opal::Processor.load_asset_code(sprockets, name)` does just that in the right way.
77
96
 
78
- * Enable operator inlining by default in the compiler.
97
+ * Enable operator inlining by default in the compiler.
79
98
 
80
- * Fix `Promise#always`.
99
+ * Fix `Promise#always`.
81
100
 
82
- * Update to Sprockets v3.0.
101
+ * Update to Sprockets v3.0.
83
102
 
84
- * Delegate dependency management directly to Sprockets (when used) making sourcemaps swift again.
103
+ * Delegate dependency management directly to Sprockets (when used) making sourcemaps swift again.
85
104
  This means code generated by sprockets will always need to be bootstrapped via `Opal.load` or `Opal.require`.
86
105
  Luckily `Opal::Processor.load_asset_code(sprockets, name)` does just that in the right way.
87
106
 
88
- * Enable operator inlining by default in the compiler.
107
+ * Enable operator inlining by default in the compiler.
89
108
 
90
- * Fix `Promise#always`.
109
+ * Fix `Promise#always`.
91
110
 
92
- * Fix `String#split` when no match is found and a limit is provided
111
+ * Fix `String#split` when no match is found and a limit is provided
93
112
 
94
- * Fix `require_tree(".")` when used from file at the root of the assets paths
113
+ * Fix `require_tree(".")` when used from file at the root of the assets paths
95
114
 
96
- * `Hash[]` implementation fully compliant with rubyspec
115
+ * `Hash[]` implementation fully compliant with rubyspec
97
116
 
98
- * Removed `minitest` from stdlib. It's not part of MRI and it never belonged there, checkout the `opal-minitest` gem instead.
117
+ * Removed `minitest` from stdlib. It's not part of MRI and it never belonged there, checkout the `opal-minitest` gem instead.
99
118
 
100
- * Parser: Allow trailing comma in paren arglists, after normal args as
119
+ * Parser: Allow trailing comma in paren arglists, after normal args as
101
120
  well as assoc args.
102
121
 
103
- * Parser: Fix parsing of parens following divide operator without a
122
+ * Parser: Fix parsing of parens following divide operator without a
104
123
  space.
105
124
 
106
- * Parser: Fix bug where keyword arguments could not be parsed if
125
+ * Parser: Fix bug where keyword arguments could not be parsed if
107
126
  method definition did not have parens around arguments.
108
127
 
109
- * Newly compliant with RubySpec:
110
- * `Array#bsearch`
111
- * `Array#combination`
112
- * `Array#permutation`
113
- * `Array#product`
114
- * `Array#rotate!`
115
- * `Array#rotate`
116
- * `Array#sample`
117
- * `Array#to_h`
118
- * `Array#values_at`
119
- * `Array#zip`
120
- * `Enumerator#with_index`
121
- * `Kernel#===`
122
- * `Kernel#Array`
123
- * `Kernel#Float`
124
- * `Kernel#Hash`
125
- * `Kernel#Integer`
126
- * `Kernel#String`
127
- * `Kernel#format`
128
- * `Kernel#sprintf`
129
- * `MatchData#==`
130
- * `MatchData#eql?`
131
- * `MatchData#values_at`
132
- * `Module#instance_methods`
133
- * `Regexp#match`
134
- * `String#%`
135
- * `String#===`
136
- * `String#==`
137
- * `String#[]`
138
- * `String#each_line`
139
- * `String#eql?`
140
- * `String#index`
141
- * `String#inspect`
142
- * `String#lines`
143
- * `String#match`
144
- * `String#next`
145
- * `String#oct`
146
- * `String#scan`
147
- * `String#slice`
148
- * `String#split`
149
- * `String#succ`
150
- * `String#to_i`
151
- * `String#try_convert`
152
-
153
- * Misc corelib fixes:
154
- * `Module#const_get` accepts a scoped constant name
155
- * `Regexp#===` sets global match data vars
128
+ * Newly compliant with RubySpec:
129
+ * `Array#bsearch`
130
+ * `Array#combination`
131
+ * `Array#permutation`
132
+ * `Array#product`
133
+ * `Array#rotate!`
134
+ * `Array#rotate`
135
+ * `Array#sample`
136
+ * `Array#to_h`
137
+ * `Array#values_at`
138
+ * `Array#zip`
139
+ * `Enumerator#with_index`
140
+ * `Kernel#===`
141
+ * `Kernel#Array`
142
+ * `Kernel#Float`
143
+ * `Kernel#Hash`
144
+ * `Kernel#Integer`
145
+ * `Kernel#String`
146
+ * `Kernel#format`
147
+ * `Kernel#sprintf`
148
+ * `MatchData#==`
149
+ * `MatchData#eql?`
150
+ * `MatchData#values_at`
151
+ * `Module#instance_methods`
152
+ * `Regexp#match`
153
+ * `String#%`
154
+ * `String#===`
155
+ * `String#==`
156
+ * `String#[]`
157
+ * `String#each_line`
158
+ * `String#eql?`
159
+ * `String#index`
160
+ * `String#inspect`
161
+ * `String#lines`
162
+ * `String#match`
163
+ * `String#next`
164
+ * `String#oct`
165
+ * `String#scan`
166
+ * `String#slice`
167
+ * `String#split`
168
+ * `String#succ`
169
+ * `String#to_i`
170
+ * `String#try_convert`
171
+
172
+ * Misc corelib fixes:
173
+ * `Module#const_get` accepts a scoped constant name
174
+ * `Regexp#===` sets global match data vars
156
175
 
157
176
  ## 0.7.2 2015-04-23
158
177
 
159
- * Remove Sprockets 3.0 support (focus moved to upcoming 0.8)
178
+ * Remove Sprockets 3.0 support (focus moved to upcoming 0.8)
160
179
 
161
- * Fix version number consistency.
180
+ * Fix version number consistency.
162
181
 
163
182
  ## 0.7.1 2015-02-14
164
183
 
165
- * CLI options `-d` and `-v` now set respectively `$DEBUG` and `$VERBOSE`
184
+ * CLI options `-d` and `-v` now set respectively `$DEBUG` and `$VERBOSE`
166
185
 
167
- * Fixed a bug that would make the `-v` CLI option wait for STDIN input
186
+ * Fixed a bug that would make the `-v` CLI option wait for STDIN input
168
187
 
169
- * Add the `-E` / `--no-exit` CLI option to skip implicit `Kernel#exit` call
188
+ * Add the `-E` / `--no-exit` CLI option to skip implicit `Kernel#exit` call
170
189
 
171
- * Now the CLI implicitly calls `Kernel#exit` at the end of the script, thus making `at_exit` blocks be respected.
190
+ * Now the CLI implicitly calls `Kernel#exit` at the end of the script, thus making `at_exit` blocks be respected.
172
191
 
173
192
  ## 0.7.0 2015-02-01
174
193
 
175
- * Stop keyword-arg variable names leaking to global javascript scope
194
+ * Stop keyword-arg variable names leaking to global javascript scope
176
195
 
177
- * `Class#native_class` now also exposes `MyClass.new` (Ruby) as `Opal.global.MyClass.new()` (JS)
196
+ * `Class#native_class` now also exposes `MyClass.new` (Ruby) as `Opal.global.MyClass.new()` (JS)
178
197
 
179
- * Add CRuby (MRI) tests harness to start checking Opal against them too.
198
+ * Add CRuby (MRI) tests harness to start checking Opal against them too.
180
199
 
181
- * Add Minitest to the stdlib.
200
+ * Add Minitest to the stdlib.
182
201
 
183
- * Add `Date#<=>` with specs.
202
+ * Add `Date#<=>` with specs.
184
203
 
185
- * Show extended info and context upon parsing, compiling and building errors.
204
+ * Show extended info and context upon parsing, compiling and building errors.
186
205
 
187
- * Support keyword arguments in method calls and definitions.
206
+ * Support keyword arguments in method calls and definitions.
188
207
 
189
- * Fix `begin`/`rescue` blocks to evaluate to last expression.
208
+ * Fix `begin`/`rescue` blocks to evaluate to last expression.
190
209
 
191
- * Add support for `RUBY_ENGINE/RUBY_PLATFORM != "opal"` pre-processor directives.
210
+ * Add support for `RUBY_ENGINE/RUBY_PLATFORM != "opal"` pre-processor directives.
192
211
 
193
212
  if RUBY_ENGINE != "opal"
194
213
  # this code never compiles
195
214
  end
196
215
 
197
- * Fix donating methods defined in modules. This ensures that if a class includes more than one module, then the methods defined on the class respect the order in which the modules are included.
216
+ * Fix donating methods defined in modules. This ensures that if a class includes more than one module, then the methods defined on the class respect the order in which the modules are included.
198
217
 
199
- * Improved support for recursive `Hash` for both `#inspect` and `#hash`.
218
+ * Improved support for recursive `Hash` for both `#inspect` and `#hash`.
200
219
 
201
- * Optimized `Hash` implementation for `String` and `Symbol`, they have a separate hash-table in which they're used as both keys and hashes.
220
+ * Optimized `Hash` implementation for `String` and `Symbol`, they have a separate hash-table in which they're used as both keys and hashes.
202
221
 
203
- * Added real `#hash` / `eql?` support, previously was relying on `.toString()`.
222
+ * Added real `#hash` / `eql?` support, previously was relying on `.toString()`.
204
223
 
205
- * `String#to_proc` now uses `__send__` instead of `send` for calling
224
+ * `String#to_proc` now uses `__send__` instead of `send` for calling
206
225
  methods on receivers.
207
226
 
208
- * Deprecated `Opal::Sprockets::Environment`. It can easily be replaced by `Opal::Server` or by appending `Opal.paths` to a `Sprockets::Environment`:
227
+ * Deprecated `Opal::Sprockets::Environment`. It can easily be replaced by `Opal::Server` or by appending `Opal.paths` to a `Sprockets::Environment`:
209
228
 
210
229
  Sprockets::Environment.new.tap { |e| Opal.paths.each {|p| e.append_path(p)} }
211
230
 
212
- * Add `Set` methods `#classify`, `#collect!`, `#map!`, `#subtract` `#replace`,
231
+ * Add `Set` methods `#classify`, `#collect!`, `#map!`, `#subtract` `#replace`,
213
232
  `#difference` and `#eql?`
214
233
 
215
- * Support `module_function` without args to toggle module functions.
234
+ * Support `module_function` without args to toggle module functions.
216
235
 
217
- * Fix bug where command calls with no space and sym arg were incorrectly parsed.
236
+ * Fix bug where command calls with no space and sym arg were incorrectly parsed.
218
237
 
219
- * Add some `StringScanner` methods.
238
+ * Add some `StringScanner` methods.
220
239
 
221
- * Add `Date#<<` and `Date#>>` implementations.
240
+ * Add `Date#<<` and `Date#>>` implementations.
222
241
 
223
- * Support nested directories using `require_tree` directive.
242
+ * Support nested directories using `require_tree` directive.
224
243
 
225
- * Fix bug where Exception subclasses could not have methods defined on them.
244
+ * Fix bug where Exception subclasses could not have methods defined on them.
226
245
 
227
- * Fix symbols with interpolations `:"#{foo}"`
246
+ * Fix symbols with interpolations `:"#{foo}"`
228
247
 
229
- * Implement $1..N matchers and rewrite support for $~, $', $& and $\`.
248
+ * Implement $1..N matchers and rewrite support for $~, $', $& and $\`.
230
249
 
231
- * Implement `Regexp.last_match`.
250
+ * Implement `Regexp.last_match`.
232
251
 
233
- * Fixed `-@` unary op. precedence with a numeric and followed by a method call (e.g. `-1.foo` was parsed as `-(1.foo)`)
252
+ * Fixed `-@` unary op. precedence with a numeric and followed by a method call (e.g. `-1.foo` was parsed as `-(1.foo)`)
234
253
 
235
- * `require_relative` (with strings) is now preprocessed, expanded and added to `Compiler#requires`
254
+ * `require_relative` (with strings) is now preprocessed, expanded and added to `Compiler#requires`
236
255
 
237
- * Rewritten the require system to respect requires position (previously all the requires were stacked up at the top of the file)
256
+ * Rewritten the require system to respect requires position (previously all the requires were stacked up at the top of the file)
238
257
 
239
- * Implement for-loop syntax
258
+ * Implement for-loop syntax
240
259
 
241
- * Add Array#|
260
+ * Add Array#|
242
261
 
243
- * Fix Range.new to raise `ArgumentError` on contructor values that cannot
262
+ * Fix Range.new to raise `ArgumentError` on contructor values that cannot
244
263
  be compared
245
264
 
246
- * Fix compiler bug where Contiguous strings were not getting concatenated.
265
+ * Fix compiler bug where Contiguous strings were not getting concatenated.
247
266
 
248
- * Cleanup generated code for constant access. All constant lookups now go through `$scope.get('CONST_NAME')` to produce cleaner code and a unified place for const missing dispatch.
267
+ * Cleanup generated code for constant access. All constant lookups now go through `$scope.get('CONST_NAME')` to produce cleaner code and a unified place for const missing dispatch.
249
268
 
250
- * Remove `const_missing` option from compiler. All constant lookups are now strict.
269
+ * Remove `const_missing` option from compiler. All constant lookups are now strict.
251
270
 
252
- * Add initial support for Module#autoload.
271
+ * Add initial support for Module#autoload.
253
272
 
254
- * Fix `Enumerator#with_index`, `Numeric#round`.
273
+ * Fix `Enumerator#with_index`, `Numeric#round`.
255
274
 
256
275
  ## 0.6.2 2014-04-25
257
276
 
258
- * Added Range#size
277
+ * Added Range#size
259
278
 
260
- * `opal` executable now reads STDIN when no file or `-e` are passed
279
+ * `opal` executable now reads STDIN when no file or `-e` are passed
261
280
 
262
- * `opal` executable doesn't exit after showing version on `-v` if other options are passed
281
+ * `opal` executable doesn't exit after showing version on `-v` if other options are passed
263
282
 
264
- * (Internal) improved the mspec runner
283
+ * (Internal) improved the mspec runner
265
284
 
266
285
  ## 0.6.1 2014-04-15
267
286
 
268
- * Updated RubySpecs to master and added `rubysl-*` specs. Thanks to Mike Owens (@mieko)
287
+ * Updated RubySpecs to master and added `rubysl-*` specs. Thanks to Mike Owens (@mieko)
269
288
 
270
- * Added `Kernel#require_remote(url)` in `opal-parser` that requires files with basic synchronous ajax
289
+ * Added `Kernel#require_remote(url)` in `opal-parser` that requires files with basic synchronous ajax
271
290
  GET requests. It is used to load `<scripts type="text/ruby" src="…url…">`.
272
291
 
273
- * Various parsing fixes (Hash parsing, `def` returns method name, cleanup `core/util`, Enumerator fixes)
292
+ * Various parsing fixes (Hash parsing, `def` returns method name, cleanup `core/util`, Enumerator fixes)
274
293
 
275
- * Added `#native_reader`, `#native_writer` and `#native_accessor`as class methods
294
+ * Added `#native_reader`, `#native_writer` and `#native_accessor`as class methods
276
295
  donated by `include Native`
277
296
 
278
- * Added specs for Sprockets' processors (both .js.rb and .opalerb), backported from `opal-rails`
297
+ * Added specs for Sprockets' processors (both .js.rb and .opalerb), backported from `opal-rails`
279
298
 
280
- * Set 2.1.1 as RUBY_VERSION
299
+ * Set 2.1.1 as RUBY_VERSION
281
300
 
282
- * Add `opal-build` command utility to easily build libraries to js
301
+ * Add `opal-build` command utility to easily build libraries to js
283
302
 
284
- * Add `opal-repl` to gemspec executables,
303
+ * Add `opal-repl` to gemspec executables,
285
304
  previously was only available by using Opal from source
286
305
 
287
- * Fix parsing `=>` in hash literals where it would sometimes incorrectly
306
+ * Fix parsing `=>` in hash literals where it would sometimes incorrectly
288
307
  parse as a key name.
289
308
 
290
309
  ## 0.6.0 2014-03-05
291
310
 
292
- * Fix parsing of escapes in single-strings ('foo\n'). Only ' and \
311
+ * Fix parsing of escapes in single-strings ('foo\n'). Only ' and \
293
312
  characters now get escaped in single quoted strings. Also, more escape
294
313
  sequences in double-quoted strings are now supported: `\a`, `\v`, `\f`,
295
314
  `\e`, `\s`, octal (`\314`), hex (`\xff`) and unicode (`\u1234`).
296
315
 
297
- * Sourcemaps revamp. Lexer now tracks column and line info for every token to
316
+ * Sourcemaps revamp. Lexer now tracks column and line info for every token to
298
317
  produce much more accurate sourcemaps. All method calls are now located on
299
318
  the correct source line, and multi-line xstrings are now split to generate
300
319
  a map line-to-line for long inline javascript parts.
301
320
 
302
- * Merged sprockets support from `opal-sprockets` directly into Opal. For the
321
+ * Merged sprockets support from `opal-sprockets` directly into Opal. For the
303
322
  next release, the exernal `opal-sprockets` gem is no longer needed. This
304
323
  commit adds `Opal::Processor`, `Opal::Server` and `Opal::Environment`.
305
324
 
306
- * Introduce pre-processed if directives to hide code from Opal. Two special
325
+ * Introduce pre-processed if directives to hide code from Opal. Two special
307
326
  constant checks now take place in the compiler. Either `RUBY_ENGINE` or
308
327
  `RUBY_PLATFORM` when `== "opal"`. Both if and unless statements can pick
309
328
  up these logic checks:
@@ -323,316 +342,316 @@
323
342
  This is particularly useful for avoiding `require()` statements being
324
343
  picked up, which are included at compile time.
325
344
 
326
- * Add special `debugger` method to compiler. Compiles down to javascript
345
+ * Add special `debugger` method to compiler. Compiles down to javascript
327
346
  `debugger` keyword to start in-browser debug console.
328
347
 
329
- * Add missing string escapes to `read_escape` in lexer. Now most ruby escape
348
+ * Add missing string escapes to `read_escape` in lexer. Now most ruby escape
330
349
  sequences are properly detected and handled in string parsing.
331
350
 
332
- * Disable escapes inside x-strings. This means no more double escaping all
351
+ * Disable escapes inside x-strings. This means no more double escaping all
333
352
  characters in x-strings and backticks. (`\n` => `\n`).
334
353
 
335
- * Add `time.rb` to stdlib and moved `Time.parse()` and `Time.iso8601()`
354
+ * Add `time.rb` to stdlib and moved `Time.parse()` and `Time.iso8601()`
336
355
  methods there.
337
356
 
338
- * `!` is now treated as an unary method call on the object. Opal now parsed
357
+ * `!` is now treated as an unary method call on the object. Opal now parsed
339
358
  `!` as a def method name, and implements the method on `BasicObject`,
340
359
  `NilClass` and `Boolean`.
341
360
 
342
- * Fixed bug where true/false as object literals from javascript were not
361
+ * Fixed bug where true/false as object literals from javascript were not
343
362
  correctly being detected as truthy/falsy respectively. This is due to the
344
363
  javascript "feature" where `new Boolean(false) !== false`.
345
364
 
346
- * Moved `native.rb` to stdlib. Native support must now be explicitly required
365
+ * Moved `native.rb` to stdlib. Native support must now be explicitly required
347
366
  into Opal. `Native` is also now a module, instead of a top level class.
348
367
  Also added `Native::Object#respond_to?`.
349
368
 
350
- * Remove all core `#as_json()` methods from `json.rb`. Added them externally
369
+ * Remove all core `#as_json()` methods from `json.rb`. Added them externally
351
370
  to `opal-activesupport`.
352
371
 
353
- * `Kernel#respond_to?` now calls `#respond_to_missing?` for compliance.
372
+ * `Kernel#respond_to?` now calls `#respond_to_missing?` for compliance.
354
373
 
355
- * Fix various `String` methods and add relevant rubyspecs for them. `#chars`,
374
+ * Fix various `String` methods and add relevant rubyspecs for them. `#chars`,
356
375
  `#to_f`, `#clone`, `#split`.
357
376
 
358
- * Fix `Array` method compliance: `#first`, `#fetch`, `#insert`, `#delete_at`,
377
+ * Fix `Array` method compliance: `#first`, `#fetch`, `#insert`, `#delete_at`,
359
378
  `#last`, `#splice`, `.try_convert`.
360
379
 
361
- * Fix compliance of `Kernel#extend` and ensure it calls `#extended()` hook.
380
+ * Fix compliance of `Kernel#extend` and ensure it calls `#extended()` hook.
362
381
 
363
- * Fix bug where sometimes the wrong regexp flags would be generated in the
382
+ * Fix bug where sometimes the wrong regexp flags would be generated in the
364
383
  output javascript.
365
384
 
366
- * Support parsing `__END__` constructs in ruby code, inside the lexer. The
385
+ * Support parsing `__END__` constructs in ruby code, inside the lexer. The
367
386
  content is gathered up by use of the parser. The special constant `DATA`
368
387
  is then available inside the ruby code to read the content.
369
388
 
370
- * Support single character strings (using ? prefix) with escaped characters.
389
+ * Support single character strings (using ? prefix) with escaped characters.
371
390
 
372
- * Fix lexer to detect dereferencing on local variables even when whitespace
391
+ * Fix lexer to detect dereferencing on local variables even when whitespace
373
392
  is present (`a = 0; a [0]` parses as a deference on a).
374
393
 
375
- * Fix various `Struct` methods. Fixed `#each` and `#each_pair` to return
394
+ * Fix various `Struct` methods. Fixed `#each` and `#each_pair` to return
376
395
  self. Add `Struct.[]` as synonym for `Struct.new`.
377
396
 
378
- * Implemented some `Enumerable` methods: `#collect_concat`, `#flat_map`,
397
+ * Implemented some `Enumerable` methods: `#collect_concat`, `#flat_map`,
379
398
  `#reject`, `#reverse_each`, `#partition` and `#zip`.
380
399
 
381
- * Support any Tilt template for `index_path` in `Opal::Server`. All index
400
+ * Support any Tilt template for `index_path` in `Opal::Server`. All index
382
401
  files are now run through `Tilt` (now supports haml etc).
383
402
 
384
- * Fix code generation of `op_asgn_1` calls (`foo[val] += 10`).
403
+ * Fix code generation of `op_asgn_1` calls (`foo[val] += 10`).
385
404
 
386
- * Add `base64` to stdlib.
405
+ * Add `base64` to stdlib.
387
406
 
388
- * Add promises implementation to stdlib.
407
+ * Add promises implementation to stdlib.
389
408
 
390
- * Add `Math` module to corelib.
409
+ * Add `Math` module to corelib.
391
410
 
392
- * Use `//#` instead of `//@` deprecated syntax for sourceMappingURL.
411
+ * Use `//#` instead of `//@` deprecated syntax for sourceMappingURL.
393
412
 
394
- * Implicitly require `erb` from stdlib when including erb templates.
413
+ * Implicitly require `erb` from stdlib when including erb templates.
395
414
 
396
- * Fix `Regexp.escape` to also escape '(' character.
415
+ * Fix `Regexp.escape` to also escape '(' character.
397
416
 
398
- * Support '<' and '>' as matching pairs in string boundrys `%q<hi>`.
417
+ * Support '<' and '>' as matching pairs in string boundrys `%q<hi>`.
399
418
 
400
- * `Opal::Server` no longer searches for an index file if not specified.
419
+ * `Opal::Server` no longer searches for an index file if not specified.
401
420
 
402
- * Move `Math` and `Encoding` to stdlib. Can be required using
421
+ * Move `Math` and `Encoding` to stdlib. Can be required using
403
422
  `require 'math'`, etc.
404
423
 
405
- * Fix some stdlib `Date` methods.
424
+ * Fix some stdlib `Date` methods.
406
425
 
407
- * Fix `Regexp.escape` to properly escape \n, \t, \r, \f characters.
426
+ * Fix `Regexp.escape` to properly escape \n, \t, \r, \f characters.
408
427
 
409
- * Add `Regexp.quote` as an alias of `escape`.
428
+ * Add `Regexp.quote` as an alias of `escape`.
410
429
 
411
430
  ## 0.5.5 2013-11-25
412
431
 
413
- * Fix regression: add `%i[foo bar]` style words back to lexer
432
+ * Fix regression: add `%i[foo bar]` style words back to lexer
414
433
 
415
- * Move corelib from `opal/core` to `opal/corelib`. This stops files in
434
+ * Move corelib from `opal/core` to `opal/corelib`. This stops files in
416
435
  `core/` clashing with user files.
417
436
 
418
437
  ## 0.5.4 2013-11-20
419
438
 
420
- * Reverted `RUBY_VERSION` to `1.9.3`. Opal `0.6.0` will be the first release
439
+ * Reverted `RUBY_VERSION` to `1.9.3`. Opal `0.6.0` will be the first release
421
440
  for `2.0.0`.
422
441
 
423
442
  ## 0.5.3 2013-11-12
424
443
 
425
- * Opal now targets ruby 2.0.0
444
+ * Opal now targets ruby 2.0.0
426
445
 
427
- * Named function inside class body now generates with `$` prefix, e.g.
446
+ * Named function inside class body now generates with `$` prefix, e.g.
428
447
  `$MyClass`. This makes it easier to wrap/bridge native functions.
429
448
 
430
- * Support Array subclasses
449
+ * Support Array subclasses
431
450
 
432
- * Various fixes to `String`, `Kernel` and other core classes
451
+ * Various fixes to `String`, `Kernel` and other core classes
433
452
 
434
- * Fix `Method#call` to use correct receiver
453
+ * Fix `Method#call` to use correct receiver
435
454
 
436
- * Fix `Module#define_method` to call `#to_proc` on explicit argument
455
+ * Fix `Module#define_method` to call `#to_proc` on explicit argument
437
456
 
438
- * Fix `super()` dispatches on class methods
457
+ * Fix `super()` dispatches on class methods
439
458
 
440
- * Support `yield()` calls from inside a block (inside a method)
459
+ * Support `yield()` calls from inside a block (inside a method)
441
460
 
442
- * Cleanup string parsing inside lexer
461
+ * Cleanup string parsing inside lexer
443
462
 
444
- * Cleanup parser/lexer to use `t` and `k` prefixes for all tokens
463
+ * Cleanup parser/lexer to use `t` and `k` prefixes for all tokens
445
464
 
446
465
  ## 0.5.2 2013-11-11
447
466
 
448
- * Include native into corelib for 0.5.x
467
+ * Include native into corelib for 0.5.x
449
468
 
450
469
  ## 0.5.1 2013-11-10
451
470
 
452
- * Move all corelib under `core/` directory to prevent filename clashes with
471
+ * Move all corelib under `core/` directory to prevent filename clashes with
453
472
  `require`
454
473
 
455
- * Move `native.rb` into stdlib - must now be explicitly required
474
+ * Move `native.rb` into stdlib - must now be explicitly required
456
475
 
457
- * Implement `BasicObject#__id__`
476
+ * Implement `BasicObject#__id__`
458
477
 
459
- * Cleanup and fix various `Enumerable` methods
478
+ * Cleanup and fix various `Enumerable` methods
460
479
 
461
480
  ## 0.5.0 2013-11-03
462
481
 
463
- * WIP: https://gist.github.com/elia/7747460
482
+ * WIP: https://gist.github.com/elia/7747460
464
483
 
465
484
  ## 0.4.2 2013-07-03
466
485
 
467
- * Added `Kernel#rand`. (fntzr)
486
+ * Added `Kernel#rand`. (fntzr)
468
487
 
469
- * Restored the `bin/opal` executable in gemspec.
488
+ * Restored the `bin/opal` executable in gemspec.
470
489
 
471
- * Now `.valueOf()` is used in `#to_n` of Boolean, Numeric, Regexp and String
490
+ * Now `.valueOf()` is used in `#to_n` of Boolean, Numeric, Regexp and String
472
491
  to return the naked JavaScript value instead of a wrapping object.
473
492
 
474
- * Parser now wraps or-ops in paranthesis to stop variable order from
493
+ * Parser now wraps or-ops in paranthesis to stop variable order from
475
494
  leaking out when minified by uglify. We now have code in this
476
495
  format: `(((tmp = lhs) !== false || !==nil) ? tmp : rhs)`.
477
496
 
478
497
  ## 0.4.1 2013-06-16
479
498
 
480
- * Move sprockets logic out to external opal-sprockets gem. That now
499
+ * Move sprockets logic out to external opal-sprockets gem. That now
481
500
  handles the compiling and loading of opal files in sprockets.
482
501
 
483
502
  ## 0.4.0 2013-06-15
484
503
 
485
- * Added fragments to parser. All parser methods now generate one or
504
+ * Added fragments to parser. All parser methods now generate one or
486
505
  more Fragments which store the original sexp. This allows us to
487
506
  enumerate over them after parsing to map generated lines back to
488
507
  original line numbers.
489
508
 
490
- * Reverted `null` for `nil`. Too buggy at this time.
509
+ * Reverted `null` for `nil`. Too buggy at this time.
491
510
 
492
- * Add Opal::SprocketsParser as Parser subclass for handling parsing
511
+ * Add Opal::SprocketsParser as Parser subclass for handling parsing
493
512
  for sprockets environment. This subclass handles require statements
494
513
  and stores them for sprockets to use.
495
514
 
496
- * Add :irb option to parser to keep top level lvars stored inside
515
+ * Add :irb option to parser to keep top level lvars stored inside
497
516
  opal runtime so that an irb session can be persisted and maintain
498
517
  access to local variables.
499
518
 
500
- * Add Opal::Environment#use_gem() helper to add a gem to opals load
519
+ * Add Opal::Environment#use_gem() helper to add a gem to opals load
501
520
  path.
502
521
 
503
- * Stop pre-setting ivars to `nil`. This is no longer needed as `nil`
522
+ * Stop pre-setting ivars to `nil`. This is no longer needed as `nil`
504
523
  is now `null` or `undefined`.
505
524
 
506
- * Use `null` as `nil` in opal. This allows us to send methods to
525
+ * Use `null` as `nil` in opal. This allows us to send methods to
507
526
  `null` and `undefined`, and both act as `nil`. This makes opal a
508
527
  much better javascript citizen. **REVERTED**
509
528
 
510
- * Add Enumerable#none? with specs.
529
+ * Add Enumerable#none? with specs.
511
530
 
512
- * Add Opal.block_send() runtime helper for sending methods to an
531
+ * Add Opal.block_send() runtime helper for sending methods to an
513
532
  object which uses a block.
514
533
 
515
- * Remove \_klass variable for denoting ruby classes, and use
534
+ * Remove \_klass variable for denoting ruby classes, and use
516
535
  constructor instead. constructor is a javascript property used for
517
536
  the same purpose, and this makes opal fit in as a better js citizen.
518
537
 
519
- * Add Class.bridge\_class method to bridge a native constructor into an
538
+ * Add Class.bridge\_class method to bridge a native constructor into an
520
539
  opal class which will set it up with all methods from Object, as
521
540
  well as giving it a scope and name.
522
541
 
523
- * Added native #[]= and #to_h methods, for setting properties and
542
+ * Added native #[]= and #to_h methods, for setting properties and
524
543
  converting to a hash respectivaly.
525
544
 
526
- * Fix bug where '::' was parsed as :colon2 instead of :colon3 when in
545
+ * Fix bug where '::' was parsed as :colon2 instead of :colon3 when in
527
546
  an args scope. Fixes #213
528
547
 
529
- * Remove lots of properties added to opal classes. This makes normal
548
+ * Remove lots of properties added to opal classes. This makes normal
530
549
  js constructors a lot closer to opal classes, making is easier to
531
550
  treat js classes as opal classes.
532
551
 
533
- * Merge Hash.from_native into Hash.new
552
+ * Merge Hash.from_native into Hash.new
534
553
 
535
554
  ## 0.3.44 2013-05-31
536
555
 
537
- * Cleanup runtime, and remove various flags and functions from opal
556
+ * Cleanup runtime, and remove various flags and functions from opal
538
557
  objects and classes (moving them to runtime methods).
539
558
 
540
- * Remove some activesupport methods into external lib.
559
+ * Remove some activesupport methods into external lib.
541
560
 
542
- * Add/fix lots of String methods, with specs.
561
+ * Add/fix lots of String methods, with specs.
543
562
 
544
- * Add more methods to MatchData class.
563
+ * Add more methods to MatchData class.
545
564
 
546
- * Implement $' and $` variables.
565
+ * Implement $' and $` variables.
547
566
 
548
- * Opal can now call methods on all native objects, via method missing
567
+ * Opal can now call methods on all native objects, via method missing
549
568
  dispatcher.
550
569
 
551
- * Add Opal::Environment as custom sprockets subclass which adds all
570
+ * Add Opal::Environment as custom sprockets subclass which adds all
552
571
  opal load paths automatically.
553
572
 
554
573
  ## 0.3.43 2013-05-02
555
574
 
556
- * Stop inlining respond_to? inside the parser. This now fully respects
575
+ * Stop inlining respond_to? inside the parser. This now fully respects
557
576
  an object overriding respond_to?.
558
577
 
559
- * Expose `Opal.eval()` function when parser is loaded for parsing
578
+ * Expose `Opal.eval()` function when parser is loaded for parsing
560
579
  and running strings of ruby code.
561
580
 
562
- * Add erb to corelib (as well as compiler to gem lib). ERB files with
581
+ * Add erb to corelib (as well as compiler to gem lib). ERB files with
563
582
  .opalerb extension will automatically be compiled into Template
564
583
  constant.
565
584
 
566
- * Added some examples into examples/ dir.
585
+ * Added some examples into examples/ dir.
567
586
 
568
- * Add Opal.send() javascript function for sending methods to ruby
587
+ * Add Opal.send() javascript function for sending methods to ruby
569
588
  objects.
570
589
 
571
- * Native class for wrapping and interacting with native objects and
590
+ * Native class for wrapping and interacting with native objects and
572
591
  function calls.
573
592
 
574
- * Add local_storage to stdlib as a basic wrapper around localStorage.
593
+ * Add local_storage to stdlib as a basic wrapper around localStorage.
575
594
 
576
- * Make method_missing more performant by reusing same dispatch function
595
+ * Make method_missing more performant by reusing same dispatch function
577
596
  instead of reallocating one for each run.
578
597
 
579
- * Fix Kernel#format to work in firefox. String.prototype.replace() had
598
+ * Fix Kernel#format to work in firefox. String.prototype.replace() had
580
599
  different semantics for empty matching groups which was breaking
581
600
  Kernel#format.
582
601
 
583
602
  ## 0.3.42 2013-03-21
584
603
 
585
- * Fix/add lots of language specs.
604
+ * Fix/add lots of language specs.
586
605
 
587
- * Seperate sprockets support out to opal-sprockets gem.
606
+ * Seperate sprockets support out to opal-sprockets gem.
588
607
 
589
- * Support %r[foo] style regexps.
608
+ * Support %r[foo] style regexps.
590
609
 
591
- * Use mspec to run specs on corelib and runtime. Rubyspecs are now
610
+ * Use mspec to run specs on corelib and runtime. Rubyspecs are now
592
611
  used, where possible to be as compliant as possible.
593
612
 
594
613
  ## 0.3.41 2013-02-26
595
614
 
596
- * Remove bin/opal - no longer required for building sources.
615
+ * Remove bin/opal - no longer required for building sources.
597
616
 
598
- * Depreceate Opal::Environment. The Opal::Server class provides a better
617
+ * Depreceate Opal::Environment. The Opal::Server class provides a better
599
618
  method of using the opal load paths. Opal.paths still stores a list of
600
619
  load paths for generic sprockets based apps to use.
601
620
 
602
621
  ## 0.3.40 2013-02-23
603
622
 
604
- * Add Opal::Server as an easy to configure rack server for testing and
623
+ * Add Opal::Server as an easy to configure rack server for testing and
605
624
  running Opal based apps.
606
625
 
607
- * Added optional arity check mode for parser. When turned on, every method
626
+ * Added optional arity check mode for parser. When turned on, every method
608
627
  will have code which checks the argument arity. Off by default.
609
628
 
610
- * Exception subclasses now relfect their name in webkit/firefox debuggers
629
+ * Exception subclasses now relfect their name in webkit/firefox debuggers
611
630
  to show both their class name and message.
612
631
 
613
- * Add Class#const_set. Trying to access undefined constants by a literal
632
+ * Add Class#const_set. Trying to access undefined constants by a literal
614
633
  constant will now also raise a NameError.
615
634
 
616
635
  ## 0.3.39 2013-02-20
617
636
 
618
- * Fix bug where methods defined on a parent class after subclass was defined
637
+ * Fix bug where methods defined on a parent class after subclass was defined
619
638
  would not given subclass access to method. Subclasses are now also tracked
620
639
  by superclass, by a private '_inherited' property.
621
640
 
622
- * Fix bug where classes defined by `Class.new` did not have a constant scope.
641
+ * Fix bug where classes defined by `Class.new` did not have a constant scope.
623
642
 
624
- * Move Date out of opal.rb loading, as it is part of stdlib not corelib.
643
+ * Move Date out of opal.rb loading, as it is part of stdlib not corelib.
625
644
 
626
- * Fix for defining methods inside metaclass, or singleton_class scopes.
645
+ * Fix for defining methods inside metaclass, or singleton_class scopes.
627
646
 
628
647
  ## 0.3.38 2013-02-13
629
648
 
630
- * Add Native module used for wrapping objects to forward calls as native
649
+ * Add Native module used for wrapping objects to forward calls as native
631
650
  calls.
632
651
 
633
- * Support method_missing for all objects. Feature can be enabled/disabled on
652
+ * Support method_missing for all objects. Feature can be enabled/disabled on
634
653
  Opal::Processor.
635
654
 
636
- * Hash can now use any ruby object as a key.
655
+ * Hash can now use any ruby object as a key.
637
656
 
638
- * Move to Sprockets based building via `Opal::Processor`.
657
+ * Move to Sprockets based building via `Opal::Processor`.