23 Commits
Author SHA1 Message Date
Unknwon 1d1add4bb9 struct_test: fix test cases for Go 1.10
Added Go 1.10 to CI.
2018-03-06 06:02:36 -05:00
Luis Gustavo S. Barretoand无闻 7ddae1ffd1 struct: fix integer overflow in time.Duration conversion (#126)
* Add specific test for time.Duration conversion

This test will fail on 32 bits system

* Fix integer overflow in time.Duration conversion

According to the Go documentation, a time.Duration is represented by
int64 nanoseconds count, so we need to cast to int64 to avoid integer
overflow in 32 bits systems.
2017-10-26 14:12:52 -04:00
Unknwon 7006dbe48c TESTING: improve overall code quality 2017-10-23 06:27:56 -04:00
Peter Vacziand无闻 476f0ee051 struct: map slices in strict mode too (#119) 2017-10-14 05:14:50 -04:00
Unknwon 496647f2d0 struct: support reflect/map comment tag
Closes #113
2017-10-14 04:43:12 -04:00
Unknwon d3de07a94d struct: add strict mode to MapTo series (#96) 2017-06-02 16:46:24 -04:00
Unknwon 300e940a92 struct: support map to []int and []int64 (#92) 2017-03-13 00:11:30 -04:00
Unknwon 7e015cd18f struct: support shadows for MapTo (#92)
Only works for []string type field.
2017-03-10 21:49:06 -05:00
James Bowesand无闻 3e15c67543 Support omitempty in tags during MapTo (#65)
omitempty must be ignored when unmarshalling into a struct, so that the
key name is parsed correctly.
2016-08-26 19:59:36 -07:00
Unknwon 088ac83a7d #60 minor fix and update docs 2016-08-05 11:03:21 -07:00
Radek Simkoand无闻 8e15fc6d72 Add support for omitempty tag option (#60) 2016-08-05 10:45:33 -07:00
Unknwon cf53f9204d Fix Go1.4 backward compatibility 2016-07-09 01:31:50 +08:00
Unknwon 959d90aa69 #48 support more slice types when MapTo/ReflectFrom struct
This allows int, int64, uint, uint64 and float64 to be slice element type.
2016-07-09 00:38:25 +08:00
Brian Shore 18cc772ced Add support for Uint types 2015-11-04 23:52:40 +00:00
Unknwon 18a90d4a80 update README 2015-08-07 23:06:16 +08:00
Unknwon 7fd539083a reflect from struct 2015-08-07 22:25:06 +08:00
Unknwon 7767e5c547 modifications on #7 2015-07-25 06:04:22 +08:00
Unknwon a2b4016f46 fix #11 2015-07-25 05:10:29 +08:00
Unknwon f571fe1a1f able set default value of struct when map 2015-02-21 01:03:13 -05:00
Unknwon dae74d1713 add delim tag 2015-01-02 19:36:38 +08:00
Unknwon 9400c4cd86 rename getter to mapper 2015-01-02 01:08:56 +08:00
Unknwon afcdaa289f Add two builtin name getter 2015-01-02 01:00:31 +08:00
Unknwon 302c8c1bb3 add map to struct support 2015-01-02 00:29:38 +08:00