| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
* Provide a new API compile_file_prism which mirrors compile_file
but uses prism to parse/compile.
* Provide the ability to run test-all with RUBY_ISEQ_DUMP_DEBUG set
to "prism". If it is, we'll use the new compile_file_prism API to
load iseqs during the test run.
|
|
|
|
|
|
|
|
| |
This PR implements the once node on interpolated regexes.
There is a bug in Prism where the interpolated regex with the once flag
only works when there is not a local variable so the test uses a "1".
We'll need to fix that.
|
| |
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1886)
https://github.com/ruby/prism/commit/41462400b7
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1853)
* Add and test ibm863
* Remove dup encoding and add alias
* Update test/prism/encoding_test.rb
Co-authored-by: Kevin Newton <kddnewton@gmail.com>
* Readd bitfield table lol
---------
https://github.com/ruby/prism/commit/4cd756d7ff
Co-authored-by: Kevin Newton <kddnewton@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Avoid some needless malloc churn
```
compare-ruby: ruby 3.3.0dev (2023-11-20T02:02:55Z master 701b0650de) [arm64-darwin22]
last_commit=[ruby/prism] feat: add encoding for IBM865 (https://github.com/ruby/prism/pull/1884)
built-ruby: ruby 3.3.0dev (2023-11-20T16:23:07Z embedded-methods e35284bfaa) [arm64-darwin22]
warming up..
| |compare-ruby|built-ruby|
|:------------------------|-----------:|---------:|
|allocate_method | 8.413M| 12.333M|
| | -| 1.47x|
|allocate_unbound_method | 8.083M| 11.607M|
| | -| 1.44x|
```
```
prelude: |
class SomeClass
def foo
end
end
some_object = SomeClass.new
benchmark:
allocate_method: some_object.method(:foo)
allocate_unbound_method: SomeClass.instance_method(:foo)
```
|
|
|
|
| |
This avoid a bit of needless malloc churn.
|
|
|
|
| |
This saves some malloc churn for small pin lists.
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1797)
https://github.com/ruby/prism/commit/c13165e6aa
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1880)
* feat: Adds macCroatian encoding
- Based on:
https://en.wikipedia.org/wiki/Mac_OS_Croatian_encoding
https://www.unicode.org/Public/MAPPINGS/VENDORS/APPLE/CROATIAN.TXT
Co-authored-by: Josefine Rost <nijrost@gmail.com>
* Use output from bin/encodings and adds to docs/encoding.md
---------
https://github.com/ruby/prism/commit/019a82d8f3
Co-authored-by: Josefine Rost <nijrost@gmail.com>
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1809)
https://github.com/ruby/prism/commit/d493ccd093
|
|
|
|
|
|
|
|
|
| |
assignments
(https://github.com/ruby/prism/pull/1879)
Fix https://github.com/ruby/prism/pull/1541
https://github.com/ruby/prism/commit/9fb276e1f4
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1787)
https://github.com/ruby/prism/commit/5acc38a2f3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1882)
* Fix parsing `...` in arguments
Fix https://github.com/ruby/prism/pull/1830
Fix https://github.com/ruby/prism/pull/1831
* Rename the constant name to PM_ERR_ARGUMENT_FORWARDING_UNBOUND
https://github.com/ruby/prism/pull/1882#discussion_r1398461156
https://github.com/ruby/prism/commit/519653aec2
|
| |
|
|
|
|
|
| |
This changes the first argument in `pm_interpolated_node_compile` to use
a pointer.
|
|
|
|
| |
Co-authored-by: Jean Boussier <byroot@ruby-lang.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`String#+@` is 2-3 times faster than `String#dup` because it can
directly go through `rb_str_dup` instead of using the generic
much slower `rb_obj_dup`.
This fact led to the existance of the ugly `Performance/UnfreezeString`
rubocop performance rule that encourage users to rewrite the much
more readable and convenient `"foo".dup` into the ugly `(+"foo")`.
Let's make that rubocop rule useless.
```
compare-ruby: ruby 3.3.0dev (2023-11-20T02:02:55Z master 701b0650de) [arm64-darwin22]
last_commit=[ruby/prism] feat: add encoding for IBM865 (https://github.com/ruby/prism/pull/1884)
built-ruby: ruby 3.3.0dev (2023-11-20T12:51:45Z faster-str-lit-dup 6b745bbc5d) [arm64-darwin22]
warming up..
| |compare-ruby|built-ruby|
|:------|-----------:|---------:|
|uplus | 16.312M| 16.332M|
| | -| 1.00x|
|dup | 5.912M| 16.329M|
| | -| 2.76x|
```
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1884)
* feat: add encoding for IBM865
* style: fix incorrect autoformat
https://github.com/ruby/prism/commit/14c6ae0182
|
| |
|
|
|
|
|
|
| |
(https://github.com/ruby/open3/pull/20)
https://github.com/ruby/open3/commit/4c9e7492eb
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1836)
* Don't add an invalid identifier capture to locals
Fix https://github.com/ruby/prism/pull/1815
* Delay creating a MatchWriteNode
https://github.com/ruby/prism/pull/1836#discussion_r1393716600
https://github.com/ruby/prism/commit/635f595a36
|
|
|
|
|
|
|
|
|
|
|
|
| |
(https://github.com/ruby/prism/pull/1864)
Add encoding for ibm866
---------
https://github.com/ruby/prism/commit/1a96cc71f7
Co-authored-by: Kevin Newton <kddnewton@gmail.com>
|
|
|
|
| |
https://github.com/ruby/prism/commit/78d3fa7172
|
|
|
|
| |
https://github.com/ruby/prism/commit/220b40921a
|
|
|
|
| |
https://github.com/ruby/prism/commit/16b3d19758
|
| |
|
|
|
|
| |
https://github.com/ruby/prism/commit/3ca9823eb4
|
|
|
|
|
|
|
| |
Fixes https://github.com/ruby/prism/pull/1868
Related #1843
https://github.com/ruby/prism/commit/abc136dfc9
|
|
|
|
| |
https://github.com/ruby/prism/commit/23a68dcda2
|
|
|
|
| |
https://github.com/ruby/prism/commit/ff95edbd99
|
|
|
|
|
|
| |
(https://github.com/ruby/irb/pull/764)
https://github.com/ruby/irb/commit/07e4d540cc
|
|
|
|
|
|
|
|
| |
Commit e87d0882910001ef3b0c2ccd43bf00cee8c34a0c introduced a
regression where the keyword splat object passed by the caller
would be directly used by callee as keyword splat parameters,
if it implemented #to_hash. The return value of #to_hash would be
ignored in this case.
|
| |
|
|
|
|
| |
https://github.com/ruby/prism/commit/4cec275fff
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Found through GC.stress + GC.auto_compact crashes in GH-8932.
Previously, the compaction run within `rb_method_entry_alloc()` could
move the `def->body.iseq.cref` and `iseqptr` set up before the call and
leave the `def` pointing to moved addresses. Nothing was marking `def`
during that GC run.
Low probability reproducer:
GC.stress = true
GC.auto_compact = true
arr = []
alloc = 1000.times.map { [] }
alloc = nil
a = arr.first
GC.start
|
|
|
|
| |
Now the documentation that was already in the codebase for
`File::Stat#directory?` shows up.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reproduction script:
```
o = Object.new
10.times { |i| o.instance_variable_set(:"@a#{i}", i) }
i = 0
a = Object.new
while RubyVM::Shape.shapes_available > 2
a.instance_variable_set(:"@i#{i}", 1)
i += 1
end
o.remove_instance_variable(:@a0)
puts o.instance_variable_get(:@a1)
```
Before this patch, it would incorrectly output `2` and now it correctly
outputs `1`.
|
|
|
|
| |
https://github.com/ruby/prism/commit/0c762ee68a
|
|
|
|
| |
https://github.com/ruby/prism/commit/68112c556e
|
|
|
|
| |
https://github.com/ruby/prism/commit/0670dd3b9a
|
|
|
|
| |
https://github.com/ruby/prism/commit/56508c2201
|
|
|
|
| |
https://github.com/ruby/prism/commit/f654058f50
|
|
|
|
| |
https://github.com/ruby/prism/commit/42b20ee399
|
|
|
|
| |
https://github.com/ruby/prism/commit/440557fddc
|
|
|
|
| |
https://github.com/ruby/prism/commit/f1d56da58f
|
|
|
|
| |
https://github.com/ruby/prism/commit/f0f057b055
|
|
|
|
| |
https://github.com/ruby/prism/commit/8f40536431
|
| |
|