[#78633] ruby/spec needs help from CRuby committers — Benoit Daloze <eregontp@...>
Currently, ruby/spec is maintained mostly by individuals and enjoys the
13 messages
2016/12/13
[#78642] Re: ruby/spec needs help from CRuby committers
— Eric Wong <normalperson@...>
2016/12/14
Benoit Daloze <eregontp@gmail.com> wrote:
[#78963] Re: ruby/spec needs help from CRuby committers
— Urabe Shyouhei <shyouhei@...>
2017/01/04
I did ask attendees of last developer meeting to join this
[#79029] Re: ruby/spec needs help from CRuby committers
— Benoit Daloze <eregontp@...>
2017/01/09
Thank you Shyouhei-san for your reply.
[ruby-core:78585] [Ruby trunk Bug#13022] Nested array syntax error returns nil
From:
merch-redmine@...
Date:
2016-12-10 17:28:52 UTC
List:
ruby-core #78585
Issue #13022 has been updated by Jeremy Evans. Yes, this is expected behavior. Ruby parses this as: ~~~ ruby [[1,3], [5,6].[](11, 15), [17,22]] ~~~ And Array#[] returns nil if the starting index (11) is out of range. ---------------------------------------- Bug #13022: Nested array syntax error returns nil https://bugs.ruby-lang.org/issues/13022#change-61971 * Author: Harry Whelchel * Status: Open * Priority: Normal * Assignee: * ruby -v: 2.3.3 * Backport: 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN ---------------------------------------- If you leave out a comma in a nested array, ruby returns `nil` instead of raising a SyntaxError. Is this expected behavior? 1. Create a nested array with a missing comma: [[1,3], [5,6] [11, 15], [17,22]] #=> [[1, 3], nil, [17, 22]] -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>