mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-21 14:41:07 +08:00
compiler: always initialize mpfr in integer import
Test case is https://go.dev/cl/413980. Fixes golang/go#52862 Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/413981
This commit is contained in:
parent
a1f8a3860f
commit
722750a44a
@ -1,4 +1,4 @@
|
||||
6a7ba754e5d98efe0875f1f41f40098e976e7958
|
||||
6edae0ef6521569e8f949aaaafa9dc1139825051
|
||||
|
||||
The first line of this file holds the git revision number of the last
|
||||
merge done from the gofrontend repository.
|
||||
|
@ -2715,7 +2715,7 @@ Integer_expression::do_import(Import_expression* imp, Location loc)
|
||||
return Expression::make_error(loc);
|
||||
}
|
||||
if (pos == std::string::npos)
|
||||
mpfr_set_ui(real, 0, MPFR_RNDN);
|
||||
mpfr_init_set_ui(real, 0, MPFR_RNDN);
|
||||
else
|
||||
{
|
||||
std::string real_str = num.substr(0, pos);
|
||||
|
Loading…
x
Reference in New Issue
Block a user