From a69d5d43b79a4f2cf5aaccc50b2275bf0dab4aba Mon Sep 17 00:00:00 2001 From: Kornelius Kalnbach Date: Mon, 10 Jun 2013 23:29:14 +0200 Subject: accept all idents as Ruby 1.9 hash keys (#126) --- lib/coderay/scanners/ruby.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/coderay/scanners/ruby.rb') diff --git a/lib/coderay/scanners/ruby.rb b/lib/coderay/scanners/ruby.rb index c5cf1e2..c282f31 100644 --- a/lib/coderay/scanners/ruby.rb +++ b/lib/coderay/scanners/ruby.rb @@ -96,7 +96,7 @@ module Scanners /#{patterns::METHOD_NAME}/o) kind = patterns::IDENT_KIND[match] - if kind == :ident && value_expected != :colon_expected && scan(/:(?!:)/) + if value_expected != :colon_expected && scan(/:(?!:)/) value_expected = true encoder.text_token match, :key encoder.text_token ':', :operator -- cgit v1.2.1