From: "nobu (Nobuyoshi Nakada)" Date: 2022-07-03T05:59:25+00:00 Subject: [ruby-core:109121] [Ruby master Bug#18890] parse.y: pattern label is newline-sensitive if it is dynamic Issue #18890 has been updated by nobu (Nobuyoshi Nakada). https://github.com/ruby/ruby/pull/6087 ---------------------------------------- Bug #18890: parse.y: pattern label is newline-sensitive if it is dynamic https://bugs.ruby-lang.org/issues/18890#change-98263 * Author: qnighy (Masaki Hara) * Status: Open * Priority: Normal * ruby -v: ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [x86_64-linux] * Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN ---------------------------------------- The two patterns in the code below behave differently: ```ruby def f(obj) case obj in foo: 0 true in "bar": 0 true else false end end p f({ foo: 42 }) # => true p f({ bar: 42 }) # => false ``` which does not seem an intended behavior. -- https://bugs.ruby-lang.org/ Unsubscribe: