Jeroen van Rijn
d97fe41834
Mark deux
2024-06-24 22:45:12 +02:00
Jeroen van Rijn
d3d73590d3
Fix CSV comments.
2024-06-24 22:43:14 +02:00
Jeroen van Rijn
2fe961cbcd
Fold XML attribute whitespace.
2024-06-12 13:30:00 +02:00
Jeroen van Rijn
ebadff555d
Update XML reader to normalize whitespace, part 1.
2024-06-12 12:52:48 +02:00
Jeroen van Rijn
601df0e8f7
Port tests\core\encoding\json
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
1b32e27aa4
Port tests\core\encoding\hxa
...
And fix a few leaks in `core:encoding/hxa` while at it.
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
3404dea8ac
Port tests\encoding\hex
2024-06-02 14:47:08 -04:00
Jeroen van Rijn
a27b167218
Update tests\core\encoding\cbor to use new test runner.
...
It was leaky and required a substantial number of `loc := #caller_location` additions to parts of the core library to make it easier to track down how and where it leaked.
The tests now run fine multi-threaded.
2024-06-02 14:47:07 -04:00
Feoramund
fc4f6b87bb
Add core:encoding/ansi package
2024-06-02 14:34:30 -04:00
gingerBill
31a9b3f428
core:encoding/ini
2024-05-31 16:35:30 +01:00
Jeroen van Rijn
cfadca04f9
Merge pull request #3628 from IllusionMan1212/bitset-json-marshalling-fix
...
fix(core/encoding/json): remove Unsupported_Type return when marshalling bit_set
2024-05-25 08:34:59 +02:00
IllusionMan1212
65a4a56a83
fix(core/encoding/json): remove Unsupported_Type return when marshalling bit_set
2024-05-25 00:45:30 +02:00
Jeroen van Rijn
2a4ddbb7be
Remove core:mem import in example.
2024-05-24 13:35:32 +02:00
Jeroen van Rijn
3b739dc5cc
Add iterator_next(&r) to CSV.
2024-05-24 13:26:12 +02:00
korvahkh
9b759f39fc
encoding/json: Properly marshal #no_nil unions
...
Previously the first variant of a `#no_nil` would always be output as
`null`, and following variants would be treated as the wrong type.
2024-05-11 14:36:56 -05:00
Feoramund
309a770cbf
Fix omitempty in json.marshal
2024-04-27 05:24:59 -04:00
gingerBill
20223345a4
Return partial reads
2024-04-19 00:33:31 +01:00
gingerBill
3812d5e002
Only override the comma value on *_init if it is "invalid"
2024-04-19 00:19:02 +01:00
gingerBill
334e08c750
Update numerous package declaration names
2024-04-18 12:17:39 +01:00
gingerBill
38c1fd5824
Keep -vet happy
2024-04-15 14:35:51 +01:00
gingerBill
d5e6d722d3
Merge pull request #3045 from laytan/cbor
...
encoding/cbor
2024-04-15 14:28:52 +01:00
gingerBill
fd487f66bc
Add json:"name,omitempty"
2024-04-10 13:40:25 +01:00
gingerBill
d0dc7395e9
Allow for comma-separate json names json:"name,flag"
2024-04-10 13:29:10 +01:00
Laytan Laats
3a0df80066
correct newly found vets
2024-04-03 00:52:58 +02:00
Franz Höltermann
a422aba578
Json: improved unmarshalling of using _: T fields.
...
`using _: T` fields will now have their members unmarshalled to their
parent types reflecting the new behaviour of json.marshall.
Example:
```go
A :: struct {
using _: B,
}
B :: struct {
field: string,
}
data := `{"field": "Hello World"}`
a: A
json.unmarshal_string(data, &a)
```
2024-03-27 15:46:44 +01:00
Franz Höltermann
92a5666c1c
Json: fields on structs like 'using _: T' will now have T's fields
...
marshalled directly into the parent type without an '"_":{ ... }'.
This seems like desirable behavior to me, since you can't access the
fields with 'Parent_Type._.field' either.
2024-03-26 20:22:51 +01:00
gingerBill
c05a92ab3e
Merge pull request #3215 from blob1807/json-better-enum-support
...
core:encoding/json Add support for writing enum value names
2024-03-06 14:56:19 +00:00
gingerBill
8d496dc3d0
Fix #3173
2024-03-06 14:51:56 +00:00
gingerBill
6d3a57b4ac
Zero intrinsics.alloca
2024-03-06 13:48:37 +00:00
gingerBill
c7b8f1fb0a
Use intrinsics.alloca rather than context.temp_allocator in json.unmarshal_object
2024-03-06 13:42:38 +00:00
gingerBill
5eef29290c
Fix #3250
2024-03-06 11:49:17 +00:00
Laytan Laats
04bd3cc525
encoding/cbor: rename diagnose to to_diagnostic_format to be clearer
2024-03-04 17:26:19 +01:00
Laytan
2a39c60fe4
encoding/cbor: respect default to panic allocator
2024-03-04 17:26:19 +01:00
Laytan
b11d839fb6
encoding/cbor: make temp allocations more explicit
2024-03-04 17:26:19 +01:00
Laytan
0076c07076
encoding/cbor: core -> base
2024-03-04 17:26:19 +01:00
Laytan
a664d9804f
encoding/cbor: remove usage of incl_elem and excl_elem
2024-03-04 17:26:19 +01:00
Laytan Laats
c4e45d509a
encoding/cbor: adhere to new quaternion rules of master
2024-03-04 17:26:19 +01:00
Laytan Laats
c1cf6c1a95
encoding/cbor: add general docs and example
2024-03-04 17:26:19 +01:00
Laytan Laats
317931a3c5
encoding/cbor: deterministically store bit sets as big endian
2024-03-04 17:26:19 +01:00
Laytan Laats
759d095548
encoding/cbor: ignore struct fields with cbor:"-"
2024-03-04 17:26:19 +01:00
Laytan Laats
72d5b87b52
encoding/cbor: clean
2024-03-04 17:26:19 +01:00
Laytan Laats
154e0d41c6
encoding/cbor: fix wrong allocator bug
2024-03-04 17:26:19 +01:00
Laytan Laats
3fccc77829
encoding/cbor: clean and fixup some allocations
2024-03-04 17:26:19 +01:00
Laytan Laats
85f1a60cf3
encoding/cbor: cleanup comments about tags
2024-03-04 17:26:19 +01:00
Laytan Laats
cb8bb8bfd8
encoding/cbor: cleanup default temp allocator
2024-03-04 17:26:19 +01:00
Laytan Laats
46b58ad48d
encoding/cbor: don't zero bytes we are going to write/read to/from anyway
2024-03-04 17:26:19 +01:00
Laytan Laats
7283b5e75c
encoding/cbor: minor things
2024-03-04 17:26:19 +01:00
Laytan Laats
21e6e28a3a
encoding/cbor: add decoder flags and protect from malicious untrusted input
2024-03-04 17:26:19 +01:00
Laytan Laats
d77ae9abab
encoding/cbor: fully support marshal/unmarshal of unions
2024-03-04 17:26:19 +01:00
Laytan Laats
363769d4d3
encoding/cbor: cleanup base64 tag
2024-03-04 17:26:19 +01:00