477 Commits

Author SHA1 Message Date
braginini 87b7b6cc79 Update copyright v0.9.2 2026-04-21 12:23:20 +02:00
Nicolas S. Dade 89250dbfdd Support for json:",omitzero" tag (#429)
* add support for the json:",omitzero" tag

omitzero was added to the go stdlib encoder/json in go 1.24

* add case which omitempty missed: uintptr is encodable in json

and does accept omitempty in the go stdlib encoder/json.

* add omitzero test cases for pointer-to-"" and pointer-to-{}

(both should marshal to something in order to match stdlib json, and
they do)

* fix and add tests for the case when omitzero is combined with omitempty

Without a special case the generated code can look like

   if v != nil && v != nil {
or
   if v != "" && v != "" {

and that gets flagged by go vet (go 1.25.5)
2026-03-14 17:51:56 +03:00
Vasily Romanov 7dcf6870f0 Merge pull request #423 from AndreiBerezin/fix-null-string
fix null after MarshalText work
2025-09-15 21:18:01 +03:00
Vasily Romanov ef22ec5d0f Merge pull request #421 from dmitrybarsukov/bugfix/invalid-json-on-NaN-or-Inf
Bugfix: do not generate invalid JSON when float value is +Inf, -Inf or NaN
2025-09-15 21:16:52 +03:00
Vasily Romanov 58eb6f54b3 Merge pull request #424 from stickpro/issue-415
feat: Add version and commit information to easyjson generator
v0.9.1
2025-09-15 21:14:26 +03:00
Vladislav Bulagakov ffa0b23ade feat: Add version and commit information to easyjson generator
Closes #415
2025-09-15 11:14:50 +03:00
Andrey Berezin 9b7ae67e7e fix null after MarshalText work 2025-06-06 10:19:01 +03:00
dmitrybarsukov 31b2360af5 Return error if trying to marshal +Inf, -Inf or NaN 2025-05-25 23:23:23 +02:00
Vasily Romanov fe2707c07a Merge pull request #411 from neal/bugfix/unmarshal-unexpected-null
Fix unmarshal null values for non-pointer fields
2025-01-11 22:28:08 +03:00
Neal Patel baefa5cf6e Fix decoding null values on non-pointer fields 2025-01-09 11:27:28 -08:00
Vasily Romanov 8580601f28 Merge pull request #407 from Neal/bugfix/unmarshal-null
Fix unmarshal null to existing value
2024-12-21 18:08:13 +03:00
Neal Patel 529b1f6f7e Fix unmarshal null to existing value 2024-12-18 21:43:31 -08:00
Vasily Romanov 5e854fb809 Merge pull request #388 from testwill/string
chore: use ret.String() instead of string(ret.Bytes())
v0.9.0
2024-12-14 21:24:10 +03:00
Vasily Romanov 78171e8003 Merge pull request #396 from SolidShake/fix-null-map-key
Fix null key in map
2024-12-14 21:22:41 +03:00
Vasily Romanov 907f46a3eb up go version to 1.20 2024-12-14 21:21:20 +03:00
Vasily Romanov 0e683d55cb only default tests 2024-12-14 21:18:23 +03:00
Vasily Romanov 8ef38d7618 upd test version 2024-12-14 21:16:31 +03:00
Vasily Romanov c2f6bad9b5 Merge pull request #405 from IakovLeven/patch-1
Fix Unmarshaler interface description
2024-12-14 20:58:47 +03:00
Vasily Romanov d48874ae4a Merge pull request #381 from niallnsec/master
Copy byte array when unmarshalling RawMessage
2024-12-14 20:58:31 +03:00
IakovLeven 46715aab06 Fix Unmarshaler interface description 2024-11-21 10:22:44 +03:00
Artem Utkin 3229627294 Fix null key in map 2024-04-19 11:06:38 +03:00
Niall Newman 34d2f3ad1a Only add tags to run command if set 2024-01-28 19:13:32 +00:00
Vasily Romanov 141f9c7d7f Merge pull request #393 from iamtakingiteasy/master
Make current token kind public and accessible via Lexer.CurrentToken
2024-01-09 14:12:31 +03:00
Alexander Tumin 3bd36b7ac9 Make current token kind public and accessible via Lexer.CurrentToken
Updated implementation of #308
2024-01-06 18:17:55 +03:00
guoguangwu 37cdbe9d67 chore: use ret.String() instead of string(ret.Bytes()) 2023-06-29 15:18:48 +08:00