diff options
| author | gingerBill <bill@gingerbill.org> | 2018-06-03 15:06:40 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2018-06-03 15:06:40 +0100 |
| commit | d556fa2cd8570363a66a7d8a2a5abf5ba306e954 (patch) | |
| tree | e7ceed61e3bdfba8515f5c4048066b5567b71a7a /examples | |
| parent | 9bd7f023b204974264fc99ee268fd9e8a5df9570 (diff) | |
Remove special shared scope for runtime stuff
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/demo/demo.odin | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/demo/demo.odin b/examples/demo/demo.odin index 54a895d0a..fbb6da8c5 100644 --- a/examples/demo/demo.odin +++ b/examples/demo/demo.odin @@ -8,13 +8,13 @@ import "core:hash" import "core:math" import "core:math/rand" import "core:os" -import "core:raw" import "core:sort" import "core:strings" import "core:types" import "core:unicode/utf16" import "core:unicode/utf8" import "core:c" +import "core:runtime" when os.OS == "windows" { import "core:atomics" @@ -352,7 +352,7 @@ parametric_polymorphism :: proc() { TABLE_SIZE_MIN :: 32; Table :: struct(Key, Value: type) { count: int, - allocator: Allocator, + allocator: mem.Allocator, slots: []Table_Slot(Key, Value), } @@ -495,12 +495,12 @@ threading_example :: proc() { fmt.println("# threading_example"); unordered_remove :: proc(array: ^[dynamic]$T, index: int, loc := #caller_location) { - __bounds_check_error_loc(loc, index, len(array)); + runtime.bounds_check_error_loc(loc, index, len(array)); array[index] = array[len(array)-1]; pop(array); } ordered_remove :: proc(array: ^[dynamic]$T, index: int, loc := #caller_location) { - __bounds_check_error_loc(loc, index, len(array)); + runtime.bounds_check_error_loc(loc, index, len(array)); copy(array[index..], array[index+1..]); pop(array); } |