ruby-next-core 0.13.2 → 0.13.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +3 -3
- data/lib/.rbnext/2.1/ruby-next/core.rb +1 -1
- data/lib/.rbnext/2.7/ruby-next/core.rb +1 -1
- data/lib/ruby-next/core.rb +1 -1
- data/lib/ruby-next/language/rewriters/shorthand_hash.rb +4 -6
- data/lib/ruby-next/rubocop.rb +4 -0
- data/lib/ruby-next/version.rb +1 -1
- metadata +22 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8c37d70af44462c4f2a42db64ca27a9b99fa08e9278d5e308dd3ba5fb67aa7b3
|
4
|
+
data.tar.gz: fb832052e7479e0c5719e57904b105f47721d1688e9ec47f4d58d7f75de9fffb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd6760a195e2ca5aa0b47295069526fbe67aa183e28dc36d6076aa3fc0d3b58411320d043f1c7f2a9c19803193b6b84ff4a640cfa0fe3e14d813032340fe0ad4
|
7
|
+
data.tar.gz: 6f2bf81c74312a1e1e3b68ac24df8ca2eb7ce679f8de9c8009c9550e880b0f8a0c18d7532f0570e003cd9511502af6607219f44e065be8d54d975a44e5dd12e5
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -522,14 +522,14 @@ require "ruby-next/language/runtime"
|
|
522
522
|
|
523
523
|
### Supported edge features
|
524
524
|
|
525
|
-
|
526
|
-
|
527
|
-
- Shorthand Hash/kwarg notation (`data = {x:, y:}` or `foo(x:, y:)`) ([#15236](https://bugs.ruby-lang.org/issues/15236)).
|
525
|
+
`Array#intersect?` ([#15198](https://bugs.ruby-lang.org/issues/15198))
|
528
526
|
|
529
527
|
### Supported proposed features
|
530
528
|
|
531
529
|
- _Method reference_ operator (`.:`) ([#13581](https://bugs.ruby-lang.org/issues/13581)).
|
532
530
|
|
531
|
+
- Shorthand Hash/kwarg notation (`data = {x, y}` or `foo(x:, y:)`) ([#15236](https://bugs.ruby-lang.org/issues/15236)).
|
532
|
+
|
533
533
|
## Contributing
|
534
534
|
|
535
535
|
Bug reports and pull requests are welcome on GitHub at [https://github.com/ruby-next/ruby-next](ttps://github.com/ruby-next/ruby-next).
|
@@ -62,7 +62,7 @@ module RubyNext
|
|
62
62
|
mod_name = singleton? ? singleton.name : mod.name
|
63
63
|
camelized_method_name = method_name.to_s.split("_").map(&:capitalize).join
|
64
64
|
|
65
|
-
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
65
|
+
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
66
66
|
end
|
67
67
|
|
68
68
|
def build_location(trace_locations)
|
@@ -62,7 +62,7 @@ module RubyNext
|
|
62
62
|
mod_name = singleton? ? singleton.name : mod.name
|
63
63
|
camelized_method_name = method_name.to_s.split("_").map(&:capitalize).join
|
64
64
|
|
65
|
-
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
65
|
+
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
66
66
|
end
|
67
67
|
|
68
68
|
def build_location(trace_locations)
|
data/lib/ruby-next/core.rb
CHANGED
@@ -62,7 +62,7 @@ module RubyNext
|
|
62
62
|
mod_name = singleton? ? singleton.name : mod.name
|
63
63
|
camelized_method_name = method_name.to_s.split("_").map(&:capitalize).join
|
64
64
|
|
65
|
-
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
65
|
+
"#{mod_name}#{camelized_method_name}".gsub(/\W/, "")
|
66
66
|
end
|
67
67
|
|
68
68
|
def build_location(trace_locations)
|
@@ -5,15 +5,13 @@ module RubyNext
|
|
5
5
|
module Rewriters
|
6
6
|
class ShorthandHash < Base
|
7
7
|
NAME = "shorthand-hash"
|
8
|
-
SYNTAX_PROBE = "data = {x
|
9
|
-
MIN_SUPPORTED_VERSION = Gem::Version.new(
|
10
|
-
|
11
|
-
def on_pair(node)
|
12
|
-
return super(node) unless node.children[0].loc.last_column == node.children[1].loc.last_column
|
8
|
+
SYNTAX_PROBE = "data = {x}"
|
9
|
+
MIN_SUPPORTED_VERSION = Gem::Version.new(RubyNext::NEXT_VERSION)
|
13
10
|
|
11
|
+
def on_ipair(node)
|
14
12
|
context.track! self
|
15
13
|
|
16
|
-
|
14
|
+
ident, = *node.children
|
17
15
|
|
18
16
|
key = key_from_ident(ident)
|
19
17
|
|
data/lib/ruby-next/rubocop.rb
CHANGED
data/lib/ruby-next/version.rb
CHANGED
metadata
CHANGED
@@ -1,20 +1,23 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-next-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.13.
|
4
|
+
version: 0.13.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vladimir Dementyev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-12-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby-next-parser
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 3.0.0.3
|
20
|
+
- - "<"
|
18
21
|
- !ruby/object:Gem::Version
|
19
22
|
version: 3.1.0.0
|
20
23
|
type: :development
|
@@ -22,6 +25,9 @@ dependencies:
|
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
23
26
|
requirements:
|
24
27
|
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 3.0.0.3
|
30
|
+
- - "<"
|
25
31
|
- !ruby/object:Gem::Version
|
26
32
|
version: 3.1.0.0
|
27
33
|
- !ruby/object:Gem::Dependency
|
@@ -38,6 +44,20 @@ dependencies:
|
|
38
44
|
- - "~>"
|
39
45
|
- !ruby/object:Gem::Version
|
40
46
|
version: 0.6.0
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: parser
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
50
|
+
requirements:
|
51
|
+
- - "<"
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: 3.0.3.0
|
54
|
+
type: :development
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
requirements:
|
58
|
+
- - "<"
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: 3.0.3.0
|
41
61
|
description: "\n Ruby Next Core is a zero deps version of Ruby Next meant to be
|
42
62
|
used\n as as dependency in your gems.\n\n It contains all the polyfills and
|
43
63
|
utility files but doesn't require transpiler\n dependencies to be install.\n
|