From: smacgaha@... Date: 2015-11-05T21:23:25+00:00 Subject: [ruby-core:71356] [Ruby trunk - Bug #11663] [Open] Segfault when using multiple keywords if the first keyword is invalid Issue #11663 has been reported by Sean MacGahan. ---------------------------------------- Bug #11663: Segfault when using multiple keywords if the first keyword is invalid https://bugs.ruby-lang.org/issues/11663 * Author: Sean MacGahan * Status: Open * Priority: Normal * Assignee: * ruby -v: 2.2.3 * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN ---------------------------------------- When loading a method with an invalid keyword (such as one that ends in a question mark), a syntax error occurs as is expected. However, when loading a method with multiple keywords, if the first keyword is invalid then a segmentation fault occurs. ``` def foo(arg1?:) end #=> syntax error def foo(arg1?:, arg2) end #=> syntax error (tIDENTIFIER as expected) def foo(arg1:) end #=> no syntax error def foo(arg1:, arg2?:) end #=> syntax error def foo(arg1, arg2?:) end #=> syntax error def foo(arg1?:, arg2:) end #=> segfault def foo(arg1?:, arg2?:) end #=> segfault ``` -- https://bugs.ruby-lang.org/