Change the decl searching api while figuring out how to implement
function overloading
This commit is contained in:
@@ -50,20 +50,6 @@ Vec3_Add :: (a: Vec3, b: Vec3): Vec3 ;; return Vec3{a.x+b.x, a.y+b.y, a.z+b.
|
||||
Vec3_Div :: (a: Vec3, b: Vec3): Vec3 ;; return Vec3{a.x/b.x, a.y/b.y, a.z/b.z}
|
||||
Vec3_Sub :: (a: Vec3, b: Vec3): Vec3 ;; return Vec3{a.x-b.x, a.y-b.y, a.z-b.z}
|
||||
|
||||
/*
|
||||
@todo: Add function overloading
|
||||
Current plan:
|
||||
* allow insert_into_scope to insert multiple lambdas
|
||||
* change resolve_name and search_for_decl to something
|
||||
that can seek multiple lambda declarations
|
||||
resolve them and return a match to hash or type
|
||||
* change the order of lambda call resolution, probably would have to
|
||||
hash the arguments first to match the lambda call
|
||||
|
||||
*/
|
||||
// Add :: (a: Vec3, b: Vec3): Vec3 ;; return Vec3{a.x+b.x, a.y+b.y, a.z+b.z}
|
||||
// Add :: (a: Vec2, b: Vec2): Vec2 ;; return Vec2{a.x+b.x, a.y+b.y}
|
||||
|
||||
F32_Clamp :: (min: F32, value: F32, max: F32): F32
|
||||
if value > max;; return max
|
||||
if value < min;; return min
|
||||
|
||||
Reference in New Issue
Block a user