Skip to content

Commit

Permalink
+ ruby27.y: branch parser. (#546)
Browse files Browse the repository at this point in the history
  • Loading branch information
iliabylich committed Feb 12, 2019
1 parent bfaf61c commit eced2e2
Show file tree
Hide file tree
Showing 10 changed files with 2,436 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -28,5 +28,6 @@ lib/parser/ruby23.rb
lib/parser/ruby24.rb
lib/parser/ruby25.rb
lib/parser/ruby26.rb
lib/parser/ruby27.rb
lib/parser/macruby.rb
lib/parser/rubymotion.rb
1 change: 1 addition & 0 deletions Rakefile
Expand Up @@ -31,6 +31,7 @@ GENERATED_FILES = %w(lib/parser/lexer.rb
lib/parser/ruby24.rb
lib/parser/ruby25.rb
lib/parser/ruby26.rb
lib/parser/ruby27.rb
lib/parser/macruby.rb
lib/parser/rubymotion.rb)

Expand Down
1 change: 1 addition & 0 deletions lib/parser/all.rb
Expand Up @@ -9,3 +9,4 @@
require 'parser/ruby24'
require 'parser/ruby25'
require 'parser/ruby26'
require 'parser/ruby27'
9 changes: 9 additions & 0 deletions lib/parser/current.rb
Expand Up @@ -74,6 +74,15 @@ def warn_syntax_deviation(feature, version)
require 'parser/ruby26'
CurrentRuby = Ruby26

when /^2\.7\./
current_version = '2.7.0-dev'
if RUBY_VERSION != current_version
warn_syntax_deviation 'parser/ruby27', current_version
end

require 'parser/ruby27'
CurrentRuby = Ruby27

else # :nocov:
# Keep this in sync with released Ruby.
warn_syntax_deviation 'parser/ruby25', '2.5.x'
Expand Down

0 comments on commit eced2e2

Please sign in to comment.