lib/rouge/lexers/hcl.rb in rouge-4.1.2 vs lib/rouge/lexers/hcl.rb in rouge-4.1.3

- old
+ new

@@ -54,11 +54,11 @@ def self.builtins @builtins ||= %w() end - id = /[$a-z_][a-z0-9_]*/io + id = /[$a-z_\-][a-z0-9_\-]*/io state :root do mixin :comments_and_whitespace mixin :primitives @@ -112,19 +112,20 @@ end state :hash do mixin :comments_and_whitespace + rule %r/[.,()\\\/*]/, Punctuation rule %r/\=/, Punctuation rule %r/\}/, Punctuation, :pop! mixin :root end state :array do mixin :comments_and_whitespace - rule %r/,/, Punctuation + rule %r/[.,()\\\/*]/, Punctuation rule %r/\]/, Punctuation, :pop! mixin :root end