mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 07:08:48 +00:00
Fix some core:encoding/hxa stuff (error handling, header, max -> min)
Also add missing f16 case to core:reflect as_u64 & as_f64 Add tests for above & add previous tests missing from test/core/build.bat
This commit is contained in:
@@ -1054,6 +1054,7 @@ as_u64 :: proc(a: any) -> (value: u64, valid: bool) {
|
||||
case Type_Info_Float:
|
||||
valid = true
|
||||
switch v in a {
|
||||
case f16: value = u64(v)
|
||||
case f32: value = u64(v)
|
||||
case f64: value = u64(v)
|
||||
case f32le: value = u64(v)
|
||||
@@ -1159,6 +1160,7 @@ as_f64 :: proc(a: any) -> (value: f64, valid: bool) {
|
||||
case Type_Info_Float:
|
||||
valid = true
|
||||
switch v in a {
|
||||
case f16: value = f64(v)
|
||||
case f32: value = f64(v)
|
||||
case f64: value = (v)
|
||||
case f32le: value = f64(v)
|
||||
|
||||
Reference in New Issue
Block a user