aboutsummaryrefslogtreecommitdiff
path: root/core/container
Commit message (Collapse)AuthorAgeFilesLines
* Address concerns.Jeroen van Rijn2024-05-241-4/+5
|
* Fix package line.Jeroen van Rijn2024-05-241-1/+1
|
* Add `core:container/rbtree`Jeroen van Rijn2024-05-232-6/+570
| | | | | | | | Add a red-black tree with configurable $Key and $Value. Also includes tests that verify it maintains RB invariants, doesn't leak. Originally based on the CC0 implementation from literateprograms.org. But reworked to the same API used by @Yawning's excellent `core:container/avl` for ease of use.
* Update numerous package declaration namesgingerBill2024-04-182-2/+2
|
* Fix the format of some `doc.odin` files of the `core` library which did not ↵Maurizio M. Gavioli2024-04-141-38/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | made into the documentation. `c/frontend/tokenizer`: add proper "Example:" header to demo example code, removed empty lines. `container/bit_array`: moved comment before package; aligned narrative lines to left margin; converted case lines into bulleted lines ("- "); converted individual examples to single-tab-indented preformatted text. `dynlib`: removed "//+build ignore" line; added newline at EOF. `image/netpmb`: converted indented lines of "Reading", "Wrting" and "Some syntax..." into bulleted lists; "Formats" indented lines kept as they are as the preformatted text seems relevant to keep the alignments; doubly indented lines kept as single-indented to keep them different (as the format does not allow for two-level bulleted lists); removed empy lines. `os/os2`: WIP, not modified `sys/info`: removed "//+build ignore" line; converted tab-indented initial description into regular left-margin comment; moved uncommented sample code within the doc comment as an "Example:"; moved simple- and double-tabbed separate comments with sample Windows and macOS outputs within the doc comment as bulleted headlines with preformatted output listings; removed now empty comments and blank lines after the package line. `text/i18n`: removed "//+build ignore" line; moved the pacakge line at the end; de-indented the tab-indented introductory narrative; moved sample code comments into the doc comment as tab-indented code with a proper "Example:" heading; removed "```" MD attempts at code formatting. `text/table`: unindented the comment lines of a descriptive kind; headlines of major subdivisions are marked as bold; kept code samples as tab-indented preformatted text (as there are several of them, the standard "Example:" and "Output:" headings cannot be used) removing the "```" MD attempts at code formatting; removed in-between blank lines.
* core/container/avl: Initial importYawning Angel2024-02-241-0/+678
|
* Replace `core:*` to `base:*` where appropriategingerBill2024-01-287-11/+11
|
* Add `peek` to priority queue.Jeroen van Rijn2024-01-081-0/+15
|
* Clear up core:container/queueJeroen van Rijn2023-11-151-1/+18
|
* [core]: Remove `do` keyword from the core libraryflysand72023-11-111-5/+7
|
* Make procedures contextless where possiblegingerBill2023-09-121-11/+33
|
* Swap order of `prev` and `next`gingerBill2023-09-121-1/+1
|
* fix queue reserve always doubling in size when there is enough spaceLaytan Laats2023-08-261-1/+1
|
* Replace `x in &y` Use `&v in y` syntax through core & vendor for ↵gingerBill2023-06-261-2/+2
| | | | `switch`/`for` statements
* Correct `queue` usage of `runtime.Allocator_Error`gingerBill2023-05-271-11/+11
|
* added set overload, made make explicitJon Lipstate2023-05-021-24/+17
|
* update docs, add unsafe_get/set, add round up to createJon Lipstate2023-04-301-61/+127
|
* Add more utility procedures to small arrayLucas Perlind2022-12-211-1/+46
|
* Add `contextless` where appropriategingerBill2022-11-111-17/+17
|
* Add bounds check for peeksColin Davidson2022-08-291-2/+4
|
* add peeksColin Davidson2022-08-291-0/+10
|
* Add more queue helpersColin Davidson2022-08-291-0/+7
|
* Remove unused `n` from PQ; add `reflect.is_bit_set`Jeroen van Rijn2022-08-181-1/+0
|
* Merge pull request #1828 from JungerBoyo/patch-2gingerBill2022-06-121-0/+10
|\ | | | | front() and back()
| * front() and back()JungerBoyo2022-06-041-0/+10
| | | | | | based on pop_front(), pop_back()
* | unset functionJungerBoyo2022-06-031-0/+27
|/ | | unset function, clear single bits
* Add missing result parameter namessduman2022-04-281-2/+2
| | | | | This adds some missing result parameters names back to pop_front_safe. Currently it the procedure won't compile since it's referencing missing variable names.
* Add `core:container/intrusive/list`gingerBill2022-04-271-0/+173
|
* Reduce allocationshanabi12242022-04-191-9/+9
|
* Fix bugs in core:container/lruhanabi12242022-04-181-6/+15
|
* Remove `#caller_location` from certain calls in `core:container/small_array`gingerBill2022-04-041-3/+3
|
* [bit_array] Really fix the leak.Jeroen van Rijn2022-03-062-17/+22
|
* Fix leak in `core:container/bit_array`Andrea Piseri2022-03-061-1/+2
| | | | | | calling `clear` on a `bit_array` no longer leaks the previous allocation, instead it sets all bits to `false` preserving the same backing dynamic array.
* replace a branch with `max` in `core:container/bit_array.set`ap296002022-02-051-1/+1
|
* rename iterator proceduresAndrea Piseri2022-02-051-3/+3
|
* Update interface to allow more modes of iterationAndrea Piseri2022-02-051-21/+90
| | | | | | | | | | It's now possible to iterate over: - all keys in the range min_value ..= max_value, with `iterate_all` - all set keys in the bit array, with `iterate_set` - all unset keys in the range min_value ..= max_value, with `iterate_unset` `Bit_Array` now stores the `max_value` provided during construction, and updates it when a key that was previously out of range is set.
* rename `iterator` proc to `next`, add named return valuesap296002022-02-041-1/+1
|
* add `iterator` to `core:container/bit_array`Andrea Piseri2022-02-041-1/+42
|
* `core:container/topological_sort`gingerBill2022-02-041-0/+98
|
* Update `core:container/lru` to support `clear` and take a boolean to ↵gingerBill2022-02-021-14/+23
| | | | indicate whether or not to call the `on_remove` procedure on `clear` or `destroy`
* `core:container/lru`dev-2022-02gingerBill2022-02-011-0/+183
|
* Keep -vet happygingerBill2022-01-251-0/+1
|
* bit_array: Fix initial size.Jeroen van Rijn2022-01-251-1/+1
|
* fix push_back and pop_frontCiD-2022-01-141-1/+4
|
* Add `core:container/queue`gingerBill2022-01-011-0/+205
|
* Correct `_shift_down` logicgingerBill2022-01-011-8/+7
|
* Fix typo in priority_queue.odin and add `default_swap_proc`gingerBill2022-01-011-1/+7
|
* Change the implementation of `Priority_Queue` to have a better interface ↵gingerBill2021-12-301-104/+102
| | | | that allows for a `less` and `swap` procedure
* Add `core:container/priority_queue`gingerBill2021-12-291-0/+140
|
* Minor improvements to `core:container/small_array`gingerBill2021-12-291-3/+3
|