mirror of
https://github.com/ggerganov/whisper.cpp.git
synced 2025-06-30 06:20:07 +02:00
Remove C++20 requirement (#257)
* Remove C++20 requirement * Roll back C features not supported in VS2017
This commit is contained in:
6
ggml.c
6
ggml.c
@ -155,7 +155,8 @@ static inline float fp32_from_bits(uint32_t w) {
|
||||
union {
|
||||
uint32_t as_bits;
|
||||
float as_value;
|
||||
} fp32 = { w };
|
||||
} fp32;
|
||||
fp32.as_bits = w;
|
||||
return fp32.as_value;
|
||||
}
|
||||
|
||||
@ -163,7 +164,8 @@ static inline uint32_t fp32_to_bits(float f) {
|
||||
union {
|
||||
float as_value;
|
||||
uint32_t as_bits;
|
||||
} fp32 = { f };
|
||||
} fp32;
|
||||
fp32.as_value = f;
|
||||
return fp32.as_bits;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user