summaryrefslogtreecommitdiffstats
path: root/third_party/rust/wasm-encoder/src/component/types.rs
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/rust/wasm-encoder/src/component/types.rs')
-rw-r--r--third_party/rust/wasm-encoder/src/component/types.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/third_party/rust/wasm-encoder/src/component/types.rs b/third_party/rust/wasm-encoder/src/component/types.rs
index 537e8c5a00..72e0034b6b 100644
--- a/third_party/rust/wasm-encoder/src/component/types.rs
+++ b/third_party/rust/wasm-encoder/src/component/types.rs
@@ -497,10 +497,10 @@ pub enum PrimitiveValType {
S64,
/// The type is an unsigned 64-bit integer.
U64,
- /// The type is a 32-bit floating point number.
- Float32,
- /// The type is a 64-bit floating point number.
- Float64,
+ /// The type is a 32-bit floating point number with only one NaN.
+ F32,
+ /// The type is a 64-bit floating point number with only one NaN.
+ F64,
/// The type is a Unicode character.
Char,
/// The type is a string.
@@ -519,8 +519,8 @@ impl Encode for PrimitiveValType {
Self::U32 => 0x79,
Self::S64 => 0x78,
Self::U64 => 0x77,
- Self::Float32 => 0x76,
- Self::Float64 => 0x75,
+ Self::F32 => 0x76,
+ Self::F64 => 0x75,
Self::Char => 0x74,
Self::String => 0x73,
});
@@ -540,8 +540,8 @@ impl From<wasmparser::PrimitiveValType> for PrimitiveValType {
wasmparser::PrimitiveValType::U32 => PrimitiveValType::U32,
wasmparser::PrimitiveValType::S64 => PrimitiveValType::S64,
wasmparser::PrimitiveValType::U64 => PrimitiveValType::U64,
- wasmparser::PrimitiveValType::Float32 => PrimitiveValType::Float32,
- wasmparser::PrimitiveValType::Float64 => PrimitiveValType::Float64,
+ wasmparser::PrimitiveValType::F32 => PrimitiveValType::F32,
+ wasmparser::PrimitiveValType::F64 => PrimitiveValType::F64,
wasmparser::PrimitiveValType::Char => PrimitiveValType::Char,
wasmparser::PrimitiveValType::String => PrimitiveValType::String,
}