mirror of
https://github.com/odin-lang/Odin.git
synced 2026-04-19 21:10:30 +00:00
Correct and improve type inference for swizzling expressions
This commit is contained in:
@@ -8,6 +8,9 @@ import "core:time"
|
||||
import "core:reflect"
|
||||
import "core:runtime"
|
||||
import "intrinsics"
|
||||
import "core:encoding/json"
|
||||
|
||||
_ :: json;
|
||||
|
||||
/*
|
||||
The Odin programming language is fast, concise, readable, pragmatic and open sourced.
|
||||
@@ -1203,6 +1206,12 @@ array_programming :: proc() {
|
||||
return i - j;
|
||||
}
|
||||
|
||||
cross_shorter :: proc(a, b: Vector3) -> Vector3 {
|
||||
i := a.yzx * b.zxy;
|
||||
j := a.zxy * b.yzx;
|
||||
return i - j;
|
||||
}
|
||||
|
||||
blah :: proc(a: Vector3) -> f32 {
|
||||
return a.x + a.y + a.z;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user