mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 14:47:19 -04:00
- permit comments to have no content following them.
This commit is contained in:
parent
b3e64b5907
commit
d1fff7536d
2 changed files with 2 additions and 7 deletions
|
@ -152,12 +152,7 @@ module LogStashConfig
|
|||
break
|
||||
end
|
||||
end
|
||||
if s5.empty?
|
||||
@index = i5
|
||||
r5 = nil
|
||||
else
|
||||
r5 = instantiate_node(SyntaxNode,input, i5...index, s5)
|
||||
end
|
||||
r5 = instantiate_node(SyntaxNode,input, i5...index, s5)
|
||||
s1 << r5
|
||||
if r5
|
||||
if has_terminal?("\r", false, index)
|
||||
|
|
|
@ -7,7 +7,7 @@ grammar LogStashConfig
|
|||
end
|
||||
|
||||
rule comment
|
||||
(whitespace? "#" [^\r\n]+ "\r"? "\n")+ <LogStash::Config::AST::Comment>
|
||||
(whitespace? "#" [^\r\n]* "\r"? "\n")+ <LogStash::Config::AST::Comment>
|
||||
end
|
||||
|
||||
rule _
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue