James Duran
13640620ce
Fix captures not begin zeroed when haystack length is 0
2025-01-15 15:56:40 -08:00
James Duran
a7971f9f6f
Allow captures in gfind and gmatch to be used in-loop
2025-01-15 11:02:46 -08:00
Ycros
7edc46f1b9
fix: regex's match_with_preallocated_capture returning num_groups
2024-12-04 13:51:27 +11:00
Doeke Wartena
b492b73ff2
Update scanner.odin
...
remove duplicated wording in comment
2024-11-07 20:15:22 +01:00
Laytan Laats
288312a812
core: improve package doc comments for the documentation generator
2024-09-03 19:59:04 +02:00
gingerBill
eb799393d5
Fix -vet-tabs issues
2024-08-24 13:56:41 +01:00
gingerBill
58e811eea5
Merge pull request #3962 from Feoramund/regex
...
Add `core:text/regex`
2024-08-21 13:55:11 +01:00
Laytan Laats
c9b69d76b0
text/edit: fix undo_state_push wrong builder check
2024-08-07 17:21:56 +02:00
Feoramund
8f5b838a07
Review manual for loops in core:text/regex
2024-08-05 03:49:29 -04:00
Feoramund
14858309f0
Add explicit license info to core:text/regex
2024-08-04 19:18:16 -04:00
Feoramund
e17fc8272b
Document rationale behind RegEx shorthand classes
2024-08-04 19:12:46 -04:00
Feoramund
dde42f0ebc
Add more documentation for core:text/regex API
2024-08-04 18:56:29 -04:00
Feoramund
1ccb0b2558
Remove unused code
2024-08-04 18:56:29 -04:00
Feoramund
babdc432e9
Move Flag_To_Letter to core:text/regex/common
2024-08-04 18:56:25 -04:00
Feoramund
d3a51e208d
Hide Regular_Expression values
...
We don't directly support printing these.
To prevent future issues being raised about the pattern being missing if
someone tries to print one, hide everything.
2024-08-04 18:40:27 -04:00
Feoramund
6252712363
Add missing features to regex package documentation
2024-08-04 13:21:13 -04:00
Feoramund
90f1f7fbdf
Use unaligned_store in regex too
2024-07-24 16:48:49 -04:00
Feoramund
ff492e615c
Use unaligned_load for regex virtual machine
...
This should hopefully avoid any issues with loading operands greater
than 8 bits on alignment-sensitive platforms.
2024-07-24 16:27:20 -04:00
Feoramund
042f6de478
Remove printing facilities for Regular_Expression
...
The `original_pattern` introduced a tenuous dependency to the expression
value as a whole, and after some consideration, I decided that it would
be better for the developer to manage their own pattern strings.
In the event you need to print the text representation of a pattern,
it's usually better that you manage the memory of it as well.
2024-07-24 16:27:20 -04:00
Feoramund
c52a8a5f86
Allow configuring of MAX_CAPTURE_GROUPS for n > 10
2024-07-24 16:27:08 -04:00
Feoramund
16b644ad79
Use slice.zero instead
2024-07-24 15:23:20 -04:00
Feoramund
e642be8550
Fix handling of unclosed regex classes and repetitions
2024-07-24 15:17:37 -04:00
Feoramund
cb0704d51c
Add core:text/regex
2024-07-22 14:25:12 -04:00
gingerBill
8642d719f0
Imply #no_capture to all variadic parameters
2024-07-14 12:19:47 +01:00
gingerBill
c7bd954752
Add more uses of #no_capture
2024-07-14 11:56:04 +01:00
Feoramund
ba354e0524
Add documentation for write_decorated_table
2024-06-26 12:53:34 -04:00
Feoramund
f13d30ad23
Add write_decorated_table API
2024-06-26 12:50:43 -04:00
Feoramund
8b05ec1765
Add string caching example documentation
2024-06-24 15:11:43 -04:00
Feoramund
fbd609fa37
Add complete example showcasing Unicode support
2024-06-24 15:04:45 -04:00
Feoramund
f325a08e57
Make core:text/table examples more complete
...
They should be completely copy-and-paste friendly now, without the
assumption of someone using `using table`.
2024-06-24 15:04:45 -04:00
Feoramund
7a43404ea1
Add Width_Proc documentation
2024-06-24 15:04:45 -04:00
Feoramund
7da96c484d
Remove table.dirty
2024-06-24 14:28:05 -04:00
Feoramund
e397bdf11d
Let WIDTH_PROC be specified as proc argument to write_*_table
2024-06-24 13:38:59 -04:00
Feoramund
67b4cb0038
Crunch the ranges
2024-06-24 13:18:54 -04:00
Feoramund
bf44a94065
Update core:text/table documentation
2024-06-20 18:22:03 -04:00
Feoramund
82d92dc46c
Use log.error instead of eprintf
2024-06-20 17:53:45 -04:00
Feoramund
b81458073e
Add new API to core:text/table
...
- `header/row_of_values`, same `header/row`, more verbose name
- `aligned_header/row_of_values`, set alignment for an entire row
- `header/row_of_aligned_values`, set alignment per value
2024-06-20 17:53:45 -04:00
Feoramund
585747bbbf
Clarify error message
2024-06-20 17:53:34 -04:00
Feoramund
99c955d124
Remove unneeded loc argument
2024-06-20 15:26:00 -04:00
Feoramund
fd28199178
Optimize printing of markdown tables
...
Check only once if the table has a header row, instead of every row.
2024-06-20 15:01:09 -04:00
Feoramund
dd099d9dd6
Add Unicode support to core:text/table
2024-06-20 15:01:09 -04:00
Feoramund
2241ca8e72
Use tabs to indent HTML tables
2024-06-20 13:06:32 -04:00
Feoramund
b66b960e7e
Don't build HTML tables
...
`build` only recalculates length and width information, and this is not
needed for HTML tables.
2024-06-20 13:06:32 -04:00
Feoramund
4a3684c5e8
Rename write_ascii_table to write_plain_table
2024-06-20 13:06:28 -04:00
Jeroen van Rijn
322b7f1f2f
Spell check i18n.odin.
2024-06-19 11:41:58 +02:00
Jeroen van Rijn
e0de52efa1
Spell check doc.odin.
2024-06-19 11:15:17 +02:00
Maurizio M. Gavioli
53755824fb
Separate the I18N calls for immutable strings and for pluraliseable strings.
...
Also update tests.
2024-06-19 10:10:26 +02:00
Jeroen van Rijn
d7bfbe0552
Port testing\core\text\i18n
2024-06-02 14:47:08 -04:00
Håkon Stormo
4328562e2c
Satisfy -vet
2024-05-23 23:50:26 +02:00
Håkon Stormo
d3bbe29faa
text_edit: better handle failure to resize underlying buffer
2024-05-23 23:28:39 +02:00