зеркало из https://github.com/github/ruby.git
[Bug #19087] Fix an assertion of `String#to_c`
This commit is contained in:
Родитель
c0dc717c45
Коммит
c94cd8534a
|
@ -24,8 +24,10 @@ describe "String#to_c" do
|
||||||
'NaN'.to_c.should == Complex(0, 0)
|
'NaN'.to_c.should == Complex(0, 0)
|
||||||
end
|
end
|
||||||
|
|
||||||
it "understands a sequence of _" do
|
ruby_bug "[Bug #19087]", ""..."3.2" do
|
||||||
'7__9+4__0i'.to_c.should == Complex(79, 40)
|
it "disallows a sequence of _" do
|
||||||
|
'7__9+4__0i'.to_c.should == 7
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
it "allows null-byte" do
|
it "allows null-byte" do
|
||||||
|
|
Загрузка…
Ссылка в новой задаче