liutao-liu added the bug label to Issue #7467.
liutao-liu opened issue #7467:
Similar to this issue, nan:0x200000 and -nan:0x200000 cannot be parsed, and the same error message "invalid float literal" is reported.
In addition,
-nan
is parsed intonan
, which is incorrect.nan
and-nan
represent different meanings, and their bits are different.
liutao-liu edited issue #7467:
Similar to this issue,
nan:0x200000
and-nan:0x200000
cannot be parsed, and the same error message "invalid float literal" is reported.In addition,
-nan
is parsed intonan
, which is incorrect.nan
and-nan
represent different meanings, and their bits are different.
alexcrichton commented on issue #7467:
Yes this is expected as the CLI uses the Rust standard libray to parse floats right now, which is not the same as the text format of WebAssembly.
liutao-liu commented on issue #7467:
Yes this is expected as the CLI uses the Rust standard libray to parse floats right now, which is not the same as the text format of WebAssembly.
Is that going to fix the problem?
alexcrichton commented on issue #7467:
Sorry I'm not sure if I understand your question?
To clarify what I'm saying, the parsing of f32/f64 in the CLI isn't specified right now in Wasmtime and it's "whatever rust libstd happens to implement". The syntax you're describing here I think is probably coming from the text format of WebAssembly, however, which isn't plumbed into this part of Wasmtime right now. Assuming you want the same text format of WebAssembly then yes I believe that will resolve this issue.
liutao-liu commented on issue #7467:
Yes brother, I shouldn't describe it as a problem, this format is from webAssembly. It would be great if wasmtime should support this format in the future.
liutao-liu closed issue #7467:
Similar to this issue,
nan:0x200000
and-nan:0x200000
cannot be parsed, and the same error message "invalid float literal" is reported.In addition,
-nan
is parsed intonan
, which is incorrect.nan
and-nan
represent different meanings, and their bits are different.
Last updated: Nov 22 2024 at 16:03 UTC