aboutsummaryrefslogtreecommitdiff
path: root/tests/core/text
Commit message (Collapse)AuthorAgeFilesLines
* Fix multiline RegEx iterationFeoramund2025-05-261-3/+54
| | | | | | | | | | In `.Multiline` mode: - `^` is now defined to assert the start of the string or that a "\n" or "\r" rune was parsed on last VM dispatch. - `$` is now defined to consume a newline sequence of "\n", "\r", or "\r\n" or to assert the end of the string.
* Add more RegEx testsFeoramund2025-05-241-6/+160
|
* Remove `Global` RegEx flag, default to unanchored patternsFeoramund2025-05-241-12/+12
|
* Make RegEx VM restartable and fix iterator infinite loopFeoramund2025-05-241-2/+3
|
* Optimize regex match iterator.Jeroen van Rijn2025-04-071-2/+1
| | | | Reuse virtual machine and capture groups between matches.
* Return loop index in regex iterator.Jeroen van Rijn2025-04-061-4/+3
|
* {.Glboal} implicit in regex allocator.Jeroen van Rijn2025-04-061-1/+1
|
* Keep -vet happy.Jeroen van Rijn2025-04-061-1/+1
|
* Add iterator for `core:text/regex`.Jeroen van Rijn2025-04-061-0/+57
| | | | | | | | | | | | | | | Usage: ```odin haystack := `xxfoobarxfoobarxx` pattern := `f(o)ob(ar)` it := regex.create_iterator(haystack, pattern, {.Global}) or_return defer regex.destroy(it) for capture in regex.match(&it) { fmt.println(capture) } ```
* Add test for regex preallocated captures.Ycros2024-12-041-0/+37
|
* Fix testsgingerBill2024-08-211-2/+2
|
* Remove debug line from testFeoramund2024-08-051-1/+0
|
* Add explicit test case for Capture `pos`Feoramund2024-08-041-0/+25
|
* Use `regex.destroy` for test capturesFeoramund2024-08-041-4/+1
|
* Test that a RegEx Capture `pos` corresponds to its `groups`Feoramund2024-08-041-0/+7
|
* Remove printing facilities for `Regular_Expression`Feoramund2024-07-241-22/+0
| | | | | | | | | 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.
* Allow configuring of `MAX_CAPTURE_GROUPS` for `n` > 10Feoramund2024-07-241-6/+64
|
* Add test cases for unclosed classes and repetitionFeoramund2024-07-241-97/+66
| | | | Simplified error checking while I was at it, too.
* Add tests for `core:text/regex`Feoramund2024-07-221-0/+1012
|
* Separate the I18N calls for immutable strings and for pluraliseable strings.Maurizio M. Gavioli2024-06-191-19/+21
| | | | Also update tests.
* Port `tests\core\text\match`Jeroen van Rijn2024-06-021-98/+63
|
* Port `testing\core\text\i18n`Jeroen van Rijn2024-06-021-101/+66
|
* Get tests passing againFeoramund2024-06-021-4/+4
| | | | | | | `T` no longer has a writer assigned to it. `test_core_cbor.odin` has global state and is run with `odin test`, so I've set it to use only one thread.
* i18n: Add section merge + duplicate key detection to gettext.Jeroen van Rijn2024-05-171-3/+12
|
* Fix .mo contextsJeroen van Rijn2024-05-171-0/+14
| | | | | | | Fixes #3590 - `get("key")` - `get("context", "key")`
* Fix .mo parser: Number of pluralsJeroen van Rijn2024-05-171-25/+59
| | | | | | Fixes #3591 Added plur.mo to tests
* tests/core: Bring the Makefile more in-sync with build.batYawning Angel2024-02-241-2/+5
|
* Keep `-vet` happy by removing `using`gingerBill2023-07-311-7/+2
|
* Remove `using` where easily possiblegingerBill2023-07-311-0/+1
|
* folder name changedskytrias2022-12-211-25/+25
|
* fix styling issues and use switches in cases its necessary, add comments to ↵skytrias2022-12-201-3/+3
| | | | helpers
* add iter_index and update tests to use easier matcher setupskytrias2022-12-201-50/+22
|
* case insensitive helper callskytrias2022-12-181-24/+28
|
* add proper unicode walkingskytrias2022-12-181-42/+102
|
* balanced string, frontier pattern, gsub_with and their tests addedskytrias2022-12-181-12/+47
|
* create lua strlib text package and testsskytrias2022-12-181-0/+325
|
* [i18n] Add tests.Jeroen van Rijn2022-04-291-0/+165