syncing
authorBrendan Hansen <brendan.f.hansen@gmail.com>
Sun, 28 Nov 2021 01:18:38 +0000 (19:18 -0600)
committerBrendan Hansen <brendan.f.hansen@gmail.com>
Sun, 28 Nov 2021 01:18:38 +0000 (19:18 -0600)
core/container/bucket_array.onyx
docs/logos/logo.svg

index 863cedf7d095c172f9a8ed7c643442e9fdec4f51..2786749c8ffa92097d27c803e0e0130f5ba2e7e9 100644 (file)
@@ -3,6 +3,7 @@
 package core.bucket_array
 
 #local array :: package core.array
+#local iter  :: package core.iter
 
 Bucket_Array :: struct (T: type_expr) {
     allocator : Allocator;
@@ -101,6 +102,7 @@ for_each :: macro (b: Bucket_Array($T), body: Code) {
     }
 }
 
+#match iter.as_iterator iterator
 iterator :: (b: ^Bucket_Array($T)) -> Iterator(T) {
     Context :: struct (T: type_expr) {
         ba         : ^Bucket_Array(T);
@@ -129,12 +131,10 @@ iterator :: (b: ^Bucket_Array($T)) -> Iterator(T) {
         return bucket.data[elem_idx], true;
     }
 
-    close :: (x: rawptr) => cfree(x);
-
     return .{
         data = c,
         next = #solidify next { T=T },
-        close = close,
+        close = cfree,
     };
 }
 
index 357bea880431ef5acbfd8f49eb5ef62e5d9b9db6..d64d2adf8d62cb622f8c32dac50f0b32125f4a9b 100644 (file)
@@ -9,6 +9,9 @@
    id="svg5"
    inkscape:version="1.1.1 (3bf5ae0d25, 2021-09-20)"
    sodipodi:docname="logo.svg"
+   inkscape:export-filename="C:\dev\onyx\docs\logos\logo.png"
+   inkscape:export-xdpi="256"
+   inkscape:export-ydpi="256"
    xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
    xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
    xmlns="http://www.w3.org/2000/svg"
      inkscape:pagecheckerboard="1"
      inkscape:document-units="mm"
      showgrid="false"
-     inkscape:zoom="12.443434"
-     inkscape:cx="30.337284"
-     inkscape:cy="41.507834"
-     inkscape:window-width="2560"
+     inkscape:zoom="8.7988366"
+     inkscape:cx="48.585969"
+     inkscape:cy="60.519365"
+     inkscape:window-width="2498"
      inkscape:window-height="1417"
-     inkscape:window-x="2552"
+     inkscape:window-x="54"
      inkscape:window-y="-8"
      inkscape:window-maximized="1"
      inkscape:current-layer="layer1"
      id="layer1">
     <path
        id="path31"
-       style="fill:#333333;fill-rule:evenodd;stroke-width:0.029711"
-       d="M 11.801522,3.1905759 0.86090001,9.5071294 6.3312111,12.665378 11.801522,9.5071294 Z" />
+       style="fill:#4d4d4d;fill-rule:evenodd;stroke-width:0.112294"
+       d="M 44.603516 12.058594 L 3.2539062 35.931641 L 23.929688 47.869141 L 44.603516 12.058594 z "
+       transform="scale(0.26458333)" />
+    <path
+       id="path537"
+       style="fill:#333333;fill-rule:evenodd;stroke-width:0.112294"
+       d="M 44.603516 12.058594 L 23.929688 47.869141 L 44.603516 35.931641 L 44.603516 12.058594 z "
+       transform="scale(0.26458333)" />
     <path
        id="path1180"
        style="fill:#999999;fill-rule:evenodd;stroke-width:0.029711"