aboutsummaryrefslogtreecommitdiff
path: root/core/encoding
Commit message (Collapse)AuthorAgeFilesLines
* Fix bug unmarshalling JSON with assertions disabledWilliam Roe2022-07-281-2/+2
| | | | | | | | | When asserts are disabled, code within the assert isn't run. Having expect_token within an assert means that the state of the Parser is mutated when asserts are run, but not when they aren't. There's already a wrapper procedure for this pattern, which I have reused here.
* Correct naming in testsgingerBill2022-07-112-2/+2
|
* Rename strings.Builder procedures to be consistent with the rest of the core ↵gingerBill2022-07-112-6/+6
| | | | library
* Rename to SJSON for the Simplified JSON notation variantgingerBill2022-06-162-3/+4
|
* Minor fixgingerBill2022-06-111-1/+1
|
* Deprecate `a..b` based ranges in favour of `..=`dev-2022-06gingerBill2022-06-012-4/+4
|
* Merge functionality of `#maybe` with the standard 'union' functionalitygingerBill2022-05-231-1/+1
|
* Allow CSV/TSV reader to read multi-line fields.Jeroen van Rijn2022-05-131-21/+65
|
* Add `core:encoding/endian`gingerBill2022-05-122-0/+176
|
* Minor style change in leb128.odingingerBill2022-05-121-6/+4
|
* Minor name changes within `core:encoding/xml` for consistencygingerBill2022-05-123-28/+26
|
* [xml] Add `parse_from_string` overload.Jeroen van Rijn2022-04-301-3/+10
| | | | | `parse` now takes either a `[]u8` slice or a string. `load_from_file` takes a path string.
* [i18n] QT Linguist TS reader.Jeroen van Rijn2022-04-291-1/+0
|
* [xml] Speedup.Jeroen van Rijn2022-04-285-174/+236
|
* Merge branch 'master' into xmlJeroen van Rijn2022-04-278-43/+264
|\
| * [json/unmarshal] Fix quoted strings.Jeroen van Rijn2022-04-191-0/+6
| |
| * Revert "Fix unmarshal for escaped strings."Jeroen van Rijn2022-04-191-5/+0
| | | | | | | | This reverts commit 581255bf23af90b77bb2b6e2671b40e2b565754e.
| * Fix unmarshal for escaped strings.Jeroen van Rijn2022-04-191-0/+5
| |
| * [LEB128] Add byte-at-a-time ILEB decoder.Jeroen van Rijn2022-04-161-14/+28
| |
| * Merge pull request #1718 from Kelimion/varint_streamedJeroen van Rijn2022-04-161-20/+32
| |\ | | | | | | Add uleb128 byte-at-a-time decoder.
| | * Add uleb128 byte-at-a-time decoder.Jeroen van Rijn2022-04-161-20/+32
| | |
| * | [varint] Clear up doc.odin.Jeroen van Rijn2022-04-131-13/+14
| |/
| * Utilize `union #shared_nil` in more placesgingerBill2022-03-241-3/+4
| |
| * Fix some core:encoding/hxa stuff (error handling, header, max -> min)gitlost2022-03-162-7/+28
| | | | | | | | | | Also add missing f16 case to core:reflect as_u64 & as_f64 Add tests for above & add previous tests missing from test/core/build.bat
| * [varint] Add doc.odinJeroen van Rijn2022-03-081-0/+27
| |
| * [varint] Tighten max input bounds.Jeroen van Rijn2022-03-081-2/+2
| |
| * [varint] Add additional LEB128 tests.Jeroen van Rijn2022-03-081-2/+6
| |
| * [varint] Add signed LEB128 encoding.Jeroen van Rijn2022-03-081-14/+82
| |
| * [varint] Add LEB128 decoding + testsJeroen van Rijn2022-03-081-0/+67
| | | | | | | | Also make tests in general less spammy: Don't print [PASS] for each successful test, only report failures and progress.
| * Simplify docs to hide the copyrightgingerBill2022-01-171-6/+6
| |
| * `ODIN_ENDIAN` changed to an enum constant; `ODIN_ENUM_STRING` is the new ↵gingerBill2022-01-151-2/+2
| | | | | | | | string version of the old constant
| * Fix 'unmarsal' typoPhil H2021-12-051-25/+25
| |
* | [xml] Initial optimization.Jeroen van Rijn2021-12-061-22/+46
| |
* | [xml] Add option.Jeroen van Rijn2021-12-053-28/+55
| |
* | [xml] Improve XML tests, test `core:encoding/entity`.Jeroen van Rijn2021-12-053-1/+9
| |
* | [xml] Implement optional unboxing of CDATA and decoding of tag values.Jeroen van Rijn2021-12-054-93/+56
| |
* | [core:encoding/entity] Add new package to decode &<entity>; entities.Jeroen van Rijn2021-12-056-2/+8020
| | | | | | | | Includes generator to generate a lookup for named entitiess.
* | [xml] Improvements.Jeroen van Rijn2021-12-054-32/+94
| |
* | [xml] Improve CDATA + comment handling in tag body.Jeroen van Rijn2021-12-052-57/+96
| |
* | [xml] Slight optimization.Jeroen van Rijn2021-12-052-28/+38
| | | | | | | | | | | | About a 5% speed bump. More rigorous optimization later.
* | [xml] Robustness improvement.Jeroen van Rijn2021-12-052-24/+55
| | | | | | | | Can now parse https://www.w3.org/2003/entities/2007xml/unicode.xml no problem.
* | [xml] Allow multi-line bodies w/o CDATA. Strip trailing whitespace.Jeroen van Rijn2021-12-052-6/+24
| |
* | [xml] Tab indentation in debug printer.Jeroen van Rijn2021-12-051-4/+3
| |
* | [xml] Use `io.Writer` for `xml.print(doc)`.Jeroen van Rijn2021-12-053-25/+36
| |
* | [xml] Small cleanup.Jeroen van Rijn2021-12-051-11/+1
| |
* | [xml] Initial implementation of `core:encoding/xml`.Jeroen van Rijn2021-12-054-0/+1118
|/ | | | | | | | | | | | | | | | | | | | | | | | A from-scratch XML implementation, loosely modeled on the [spec](https://www.w3.org/TR/2006/REC-xml11-20060816). Features: - Supports enough of the XML 1.0/1.1 spec to handle the 99.9% of XML documents in common current usage. - Simple to understand and use. Small. Caveats: - We do NOT support HTML in this package, as that may or may not be valid XML. If it works, great. If it doesn't, that's not considered a bug. - We do NOT support UTF-16. If you have a UTF-16 XML file, please convert it to UTF-8 first. Also, our condolences. - <[!ELEMENT and <[!ATTLIST are not supported, and will be either ignored or return an error depending on the parser options. TODO: - Optional CDATA unboxing. - Optional `&gt;`, `&#32;`, `&#x20;` and other escape substitution in tag bodies. - Test suite MAYBE: - XML writer? - Serialize/deserialize Odin types?
* Fix minor issue with unmarshal for booleansgingerBill2021-11-131-0/+1
|
* Add json encoding test + fix enum not being set on success.Daniel Gavin2021-11-072-5/+6
|
* Fix json.marshal for MatrixgingerBill2021-10-201-0/+3
|
* Remove dead codegingerBill2021-10-021-17/+0
|