From: Joseph Jones Date: 2015-12-17T21:13:07-07:00 Subject: [ruby-core:72332] [Ruby trunk - Bug #11802] [Open] Hash.new and {} have different behaviour --567387d3_6a5f7029_16c Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Joseph Jones liked your message with Boxer. On December 10, 2015 at 08:26= :40 MST, aufi.cz=40gmail.com wrote:Issue =2311802 has been reported by Ma= rek Aufart.----------------------------------------Bug =2311802: Hash.new= and =7B=7D have different behaviourhttps://bugs.ruby-lang.org/issues/118= 02* Author: Marek Aufart* Status: Open* Priority: Normal* Assignee: * rub= y -v: ruby 2.2.3p173 (2015-08-18 revision 51636) =5Bx86=5F64-linux=5D* Ba= ckport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN-----------------------= -----------------It looks that =7B=7D is not recognized as a variable som= etimes.irb(main):001:0> p Hash.new=7B=7D=3D> =7B=7Dirb(main):002:0> p =7B= =7D=3D> nilSimilar in rspec test:expect(subject.something).to eq =7B=7D =23= fails on not given argument for eqexpect(subject.something).to eq(=7B=7D= ) =23 works-- https://bugs.ruby-lang.org/ --567387d3_6a5f7029_16c Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Joseph Jones liked your message with Boxer.


= On December 10, 2015 at 08:26:40 MST, aufi.cz=40gmail.com wrote:
Issue =2311802 has been report= ed by Marek Aufart.

----------------------------------------Bug =2311802: Hash.new and =7B=7D have different behaviour
https= ://bugs.ruby-lang.org/issues/11802

* Author: Marek Aufart
* Status: Open
* Priority: Normal
* Assignee:
* ruby -v:= ruby 2.2.3p173 (2015-08-18 revision 51636) =5Bx86=5F64-linux=5D
* B= ackport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN
----------------= ------------------------
It looks that =7B=7D is not recognized as a= variable sometimes.

irb(main):001:0> p Hash.new
=7B=7D=3D> =7B=7D
irb(main):002:0> p =7B=7D
=3D> nil

S= imilar in rspec test:

expect(subject.something).to eq =7B=7D =23= fails on not given argument for eq
expect(subject.something).to eq(= =7B=7D) =23 works




--
https://bugs.ruby= -lang.org/
--567387d3_6a5f7029_16c--