We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c6fa667 commit 1b8e211Copy full SHA for 1b8e211
core/kernel/Float_spec.rb
@@ -231,6 +231,10 @@ def to_f() 1.2 end
231
@object.send(:Float, "0x0f").should == 15.0
232
end
233
234
+ it "interprets negative hex value" do
235
+ @object.send(:Float, "-0x10").should == -16.0
236
+ end
237
+
238
it "accepts embedded _ if the number does not contain a-f" do
239
@object.send(:Float, "0x1_0").should == 16.0
240
0 commit comments