Forum: Ruby-core Allow use of quotes in symbol syntactic sugar for hashes

Posted by Nobuyoshi Nakada (nobu)
on 2013-01-27 03:27
(Received via mailing list)
Issue #4276 has been updated by nobu (Nobuyoshi Nakada).


One of the reason I didn't introduce this was, a few bundled scripts had 
compatibility issue when once I tried.
----------------------------------------
Feature #4276: Allow use of quotes in symbol syntactic sugar for hashes
https://bugs.ruby-lang.org/issues/4276#change-35672

Author: tbenst (Tyler Benster)
Status: Assigned
Priority: Low
Assignee: matz (Yukihiro Matsumoto)
Category: core
Target version: next minor


=begin
 Current syntactic sugar allows this:
 hash = {Alabama: "AL"}

 This feature request is to also allow symbols delimited by quotes (and 
thus able to contain a whitespace) to use an equivalent syntactic sugar:
 hash2 = {"Rhode Island": "RI"}
=end
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.