| Age | Commit message (Collapse) | Author |
|
https://github.com/ruby/prism/commit/e838eaff6f
|
|
https://github.com/ruby/prism/commit/115b6a2fc6
|
|
A lot of tools use Ripper/RubyVM::AbstractSyntaxTree to determine
if a source is valid. These tools both create an AST instead of
providing an API that will return a boolean only.
This new API only creates the C structs, but doesn't bother
reifying them into Ruby/the serialization API. Instead it only
returns true/false, which is significantly more efficient.
https://github.com/ruby/prism/commit/7014740118
|
|
Previously numbered parameters were a field on blocks and lambdas
that indicated the maximum number of numbered parameters in either
the block or lambda, respectively. However they also had a
parameters field that would always be nil in these cases.
This changes it so that we introduce a NumberedParametersNode that
goes in place of parameters, which has a single uint8_t maximum
field on it. That field contains the maximum numbered parameter in
either the block or lambda.
As a part of the PR, I'm introducing a new UInt8Field type that
can be used on nodes, which is just to make it a little more
explicit what the maximum values can be (the maximum is actually 9,
since it only goes up to _9). Plus we can do a couple of nice
things in serialization like just read a single byte.
https://github.com/ruby/prism/commit/2d87303903
|
|
Ruby allows for 0 or negative line start, this is often used
with `eval` calls to get a correct offset when prefixing a snippet.
e.g.
```ruby
caller = caller_locations(1, 1).first
class_eval <<~RUBY, caller.path, caller.line - 2
# frozen_string_literal: true
def some_method
#{caller_provided_code_snippet}
end
RUBY
```
https://github.com/ruby/prism/commit/0d14ed1452
|
|
Line numbers may be negative, so we need to introduce signed varint,
so renaming unsigned ones first avoid confusion.
https://github.com/ruby/prism/commit/90d862361e
|
|
https://github.com/ruby/prism/commit/42b60b6e95
|
|
(https://github.com/ruby/prism/pull/1787)
https://github.com/ruby/prism/commit/5acc38a2f3
|
|
https://github.com/ruby/prism/commit/4cec275fff
|
|
https://github.com/ruby/prism/commit/0c762ee68a
|
|
https://github.com/ruby/prism/commit/4f3a3e3ec1
|
|
https://github.com/ruby/prism/commit/5a2252e3ac
|
|
https://github.com/ruby/prism/commit/f0aa8ad93b
|
|
https://github.com/ruby/prism/commit/99e81619de
|
|
https://github.com/ruby/prism/commit/77d4056766
|
|
https://github.com/ruby/prism/commit/9c648ce615
|
|
https://github.com/ruby/prism/commit/69323d3df4
|
|
https://github.com/ruby/prism/commit/857f72e1f4
|
|
https://github.com/ruby/prism/commit/e2e29bef2d
|
|
https://github.com/ruby/prism/commit/5b72f84480
|
|
https://github.com/ruby/prism/commit/3193902c43
|
|
https://github.com/ruby/prism/commit/160df9a687
|
|
https://github.com/ruby/prism/commit/6d8358c083
|
|
https://github.com/ruby/prism/commit/7c9cf63d4c
|
|
https://github.com/ruby/prism/commit/73c44b0b9c
|
|
https://github.com/ruby/prism/commit/6f4fab362e
|
|
https://github.com/ruby/prism/commit/1985a9ba51
|
|
https://github.com/ruby/prism/commit/d469a56e7e
|
|
https://github.com/ruby/prism/commit/c7ef25a79a
|
|
Moves the common flag bits to the top. This lets us eliminate the `COMMON`
constant, and also allows us to group encoding flags on a nibble so we
can more easily mask them.
https://github.com/ruby/prism/commit/895508659e
|
|
https://github.com/ruby/prism/commit/6f243de0c7
|
|
|
|
|