From: 7stud -- Date: 2007-09-23T05:28:34+09:00 Subject: Re: %w| a b c| %w_a b c_ %w all work 7stud -- wrote: > > "Following the type character is a delimiter, which can be any > nonalphabetic or nonmultibyte character. If the delimiter is one of the > characters (, [, {, or <, ....blah, blah, blah...[the ending character > must be: ), ], }, or > respectively]. For all other delimiters, [the > ending character is the next occurrence of the starting delimiter]." I just wanted to point out that the statement that the delimiter can be any "nonalphabetic or nonmultibyte" character appears to be false. The character '2' meets the condition of being "nonalphabetic or nonmultibyte", yet it produces an error: arr = %w_a b c_ p arr #["a", "b", "c"] arr = %w2a b c2 p arr r4test.rb:4: unknown type of %string arr = %w1a b c1 ^ r4test.rb:4: syntax error arr = %w1a b c1 ^ It looks like the docs should say: > ...a delimiter, which can be any character > that is nonalphabetic *and* nonmultibyte." -- Posted via http://www.ruby-forum.com/.