Move definition of mem.Allocator and log.Logger to package runtime, to reduce import cycle magic
This commit is contained in:
1 parent
7e271310ff
commit
ab52f8d795
11 files changed
+484
-154
No files matched your search
@@ -307,6 +307,14 @@ identity :: proc($T: typeid/[$N][N]$E) -> (m: T) {
|
||||
return m;
|
||||
}
|
||||
|
||||
trace :: proc(m: $T/[$N][N]$E) -> (tr: E) {
|
||||
for i in 0..<N {
|
||||
tr += m[i][i];
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
transpose :: proc(a: $T/[$N][$M]$E) -> (m: T) {
|
||||
for j in 0..<M {
|
||||
for i in 0..<N {
|
||||
|
||||
Reference in new issue
Block a user