Fix some preload bugs.

This commit is contained in:
Ginger Bill
2017-07-18 11:42:16 +01:00
parent 9a8759efef
commit f7d8ba408c
2 changed files with 31 additions and 26 deletions

View File

@@ -41,8 +41,8 @@ expand :: proc(table: ^$T/Table) {
}
}
put :: proc(table: ^$T/Table, key: T.Key, value: T.Value) {
// put :: proc(table: ^Table($K, $V), key: K, value: V) {
// put :: proc(table: ^$T/Table, key: T.Key, value: T.Value) {
put :: proc(table: ^Table($Key, $Value), key: Key, value: Value) {
hash := get_hash(key); // Ad-hoc method which would fail in differentcope
index := find_index(table, key, hash);
if index < 0 {
@@ -142,6 +142,7 @@ foo3 :: proc(a: type/Vector(3, $T)) {fmt.println("foo3", a{}); }
main :: proc() {
foo1(Vector(3, f32));
foo1(Vector3);