parser 3.2.0.0 → 3.2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1f610391f493e02fe53d3282d0334cae06d96e736f65f90127a03e737b216eb2
4
- data.tar.gz: 2105182a6079d599d5757205a6dd9400484422be82b02bae9f50f515d2388f2b
3
+ metadata.gz: c4e9c12d9347a88fa7fb419e76b338e1d69a647a841be6c2440b0370f6bf3e5f
4
+ data.tar.gz: 2a297a328b99e43ad62241d9c8a5cf1b73f68dcc13ed5afaabbd0028b547c6f5
5
5
  SHA512:
6
- metadata.gz: 7ea8cc04e8e2d69867bf7f6566001fb88f0ad59fbe3a2e6782e4e939e662a3bdee0a5a77b42aff275b95125e3f51f6adb16ba859ddff7ab5e672a7a119ef323e
7
- data.tar.gz: afeac266aea582d8c84c395e467698d6c7243e1cf7400613f7512f2d7dfb08dd94a3553f20ae07fe99a27035e54da6fcfbfdd20dbf484c7c18e00edb62ed0f18
6
+ metadata.gz: 330a825c26fdcbc939dd171df1994b5879f38ba896c5130ef70bdf703dd26f374eec9b7511363ff3b84daebf4be9470b836e98b6086725510a14300eea5b8dde
7
+ data.tar.gz: aa843389469df522448da099801725c294852d2641d9bc276319fa7fdd1cbfe1af88c898b7edc821cf948bf4d307617f2c1621c7f0bf3372d9bbef8868a724a1
data/lib/parser/all.rb CHANGED
@@ -13,3 +13,4 @@ require 'parser/ruby27'
13
13
  require 'parser/ruby30'
14
14
  require 'parser/ruby31'
15
15
  require 'parser/ruby32'
16
+ require 'parser/ruby33'
@@ -5,8 +5,8 @@ module Parser
5
5
 
6
6
  ##
7
7
  # {Parser::AST::Node} contains information about a single AST node and its
8
- # child nodes. It extends the basic [AST::Node](http://rdoc.info/gems/ast/AST/Node)
9
- # class provided by gem [ast](http://rdoc.info/gems/ast).
8
+ # child nodes. It extends the basic [AST::Node](https://www.rubydoc.info/gems/ast/AST/Node)
9
+ # class provided by gem [ast](https://www.rubydoc.info/gems/ast).
10
10
  #
11
11
  # @api public
12
12
  #
@@ -540,8 +540,13 @@ module Parser
540
540
  def associate(begin_t, pairs, end_t)
541
541
  0.upto(pairs.length - 1) do |i|
542
542
  (i + 1).upto(pairs.length - 1) do |j|
543
- key1, = *pairs[i]
544
- key2, = *pairs[j]
543
+ pair_i = pairs[i]
544
+ pair_j = pairs[j]
545
+
546
+ next if pair_i.type != :pair || pair_j.type != :pair
547
+
548
+ key1, = *pair_i
549
+ key2, = *pair_j
545
550
 
546
551
  do_warn = false
547
552
 
@@ -102,7 +102,7 @@ module Parser
102
102
  CurrentRuby = Ruby31
103
103
 
104
104
  when /^3\.2\./
105
- current_version = '3.2.0'
105
+ current_version = '3.2.1'
106
106
  if RUBY_VERSION != current_version
107
107
  warn_syntax_deviation 'parser/ruby32', current_version
108
108
  end
@@ -110,6 +110,15 @@ module Parser
110
110
  require 'parser/ruby32'
111
111
  CurrentRuby = Ruby32
112
112
 
113
+ when /^3\.3\./
114
+ current_version = '3.3.0-dev'
115
+ if RUBY_VERSION != current_version
116
+ warn_syntax_deviation 'parser/ruby33', current_version
117
+ end
118
+
119
+ require 'parser/ruby33'
120
+ CurrentRuby = Ruby33
121
+
113
122
  else # :nocov:
114
123
  # Keep this in sync with released Ruby.
115
124
  warn_syntax_deviation 'parser/ruby32', '3.2.x'