Commit Graph

26 Commits

Author SHA1 Message Date
Jeroen van Rijn
248b0fe9e1 More package lines 2025-10-09 16:11:33 +02:00
Jeroen van Rijn
5a154a1775 Add more package lines for the docs 2025-10-09 14:41:22 +02:00
Laytan Laats
bd45900257 container/bit_array: add 'init' procedure 2024-09-29 10:57:42 +02:00
gingerBill
a4fd0c133e Merge pull request #4191 from laytan/improve-package-doc-comments
core: improve package doc comments for the documentation generator
2024-09-04 21:37:48 +01:00
Feoramund
c3bd94a27e Change Bit_Array.max_index to length
This will allow correct iteration of empty `bit_array`s.
2024-09-03 16:56:02 -04:00
Feoramund
d86e56089a Fix iteration of biased Bit_Array 2024-09-03 15:34:38 -04:00
Laytan Laats
288312a812 core: improve package doc comments for the documentation generator 2024-09-03 19:59:04 +02:00
Feoramund
b8f8cb9582 Add bit_array.shrink 2024-09-03 13:33:15 -04:00
Feoramund
001b2b9d8f Let bit_array.create make zero-length arrays 2024-09-03 13:33:11 -04:00
gingerBill
663661db53 Update core to -strict-style 2024-06-29 19:16:32 +01:00
gingerBill
5413a8b744 Even more style fixes 2024-06-29 19:11:36 +01:00
gingerBill
334e08c750 Update numerous package declaration names 2024-04-18 12:17:39 +01:00
Maurizio M. Gavioli
a0cff82320 Fix the format of some doc.odin files of the core library which did not 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.
2024-04-14 17:18:08 +02:00
gingerBill
3e7e779abf Replace core:* to base:* where appropriate 2024-01-28 22:18:51 +00:00
Jon Lipstate
bcb01bdc52 added set overload, made make explicit 2023-05-02 18:21:52 -07:00
Jon Lipstate
075193af1d update docs, add unsafe_get/set, add round up to create 2023-04-30 16:56:05 -07:00
JungerBoyo
ad6b3bd95f unset function
unset function, clear single bits
2022-06-03 15:53:14 +02:00
Jeroen van Rijn
ce057ff755 [bit_array] Really fix the leak. 2022-03-06 12:29:17 +01:00
Andrea Piseri
bff3426d25 Fix leak in core:container/bit_array
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.
2022-03-06 10:21:46 +01:00
ap29600
697f8c7ee6 replace a branch with max in core:container/bit_array.set 2022-02-05 18:46:25 +01:00
Andrea Piseri
b6ebfe4b2c rename iterator procedures 2022-02-05 18:11:48 +01:00
Andrea Piseri
bccbdefde9 Update interface to allow more modes of iteration
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.
2022-02-05 18:00:59 +01:00
ap29600
b54fc96b1e rename iterator proc to next, add named return values 2022-02-04 22:39:47 +01:00
Andrea Piseri
48af78e469 add iterator to core:container/bit_array 2022-02-04 22:12:07 +01:00
Jeroen van Rijn
515fd2a228 bit_array: Fix initial size. 2022-01-25 17:08:32 +01:00
Jeroen van Rijn
53e30e4621 [core:container/bit_vector] Create new package.
A dynamic bit array, optionally allowing negative indices.
2021-12-28 15:38:12 +01:00