Commit Graph

61 Commits

Author SHA1 Message Date
Zahary Karadjov 501f94ad61
Allow checking if the serialization tracing is enabled 2020-05-29 21:32:44 +03:00
Zahary Karadjov 16e6bcd16d
More tests with derived types 2020-05-27 11:33:02 +03:00
Zahary Karadjov 2baaccd50e
Add roundtrip tests using inheritance 2020-05-26 19:38:03 +03:00
Zahary Karadjov 8a25451fce
Add an easier way to enable the serializaton tracing 2020-05-22 15:20:24 +03:00
Zahary Karadjov 8a013591bd
Add a pragma for customizing the field names in formats such as Json 2020-05-20 13:48:14 +03:00
Zahary Karadjov b61fcb51ad
Work-around a scary issue affecting the SSZ serialization 2020-05-19 13:42:56 +03:00
Zahary Karadjov 7ff764ca1f
Flush happens automatically on close 2020-05-13 11:40:04 +03:00
Zahary Karadjov 5ecae14972
Add stream.readValue 2020-05-13 11:40:04 +03:00
Zahary Karadjov dccba1e22b
Rename appendValue to writeValue for consistency 2020-05-13 11:40:04 +03:00
Zahary Karadjov d7ed9c84d3
Switch back to memory mapped files in 'loadFile' 2020-05-13 11:40:04 +03:00
Zahary Karadjov 5e8ec3485c
Use the latest FastStreams API 2020-05-13 11:40:00 +03:00
Alexander Ivanov f310607d04 Test for non-string keys of table 2020-05-08 16:57:33 +03:00
Jacek Sieka 9f085c33a9
nim 1.2 2020-04-24 08:56:54 +02:00
Zahary Karadjov 1989a55145
Remove a warning triggered by not nil types 2020-04-23 01:50:25 +03:00
Zahary Karadjov 0476902c92
Don't raise IOError from encode and decode 2020-04-23 01:50:20 +03:00
Zahary Karadjov db037cbece
Don't rely on the filestream destructors 2020-04-22 21:26:02 +03:00
Zahary Karadjov 67bb6a77bb
Address some TODO items in loadFile and saveFile 2020-04-14 19:34:44 +03:00
Zahary Karadjov 8f6e86350e
Take advantage of some improvements in Nim 1.2 2020-04-13 16:58:25 +03:00
Zahary Karadjov 23bbf4b6a5
Use the latest FastStreams API 2020-04-09 23:13:42 +03:00
Zahary Karadjov 68e9ef7901 More comprehensive test suite; Depends on Fixes in Nim 1.2 2020-04-09 19:25:07 +03:00
Zahary Karadjov 0eab8cfeee
nimble test will now test with threading enabled/disabled 2020-03-24 16:34:38 +02:00
Zahary Karadjov ae60eef4e8
Reduce warnings in Nim 1.0.2; Fix #16 2019-11-04 18:55:12 +00:00
Mamy Ratsimbazafy 448a03ed4b
replace defer by try/finally to avoid 0.19.6 compiler bug (#15) 2019-09-11 14:09:58 -04:00
Mamy Ratsimbazafy 80da30b031
prevent null dereference (#13) 2019-09-11 12:41:51 -04:00
Mamy Ratsimbazafy 24474e69d1
ByteStreamVar doesn't autodereference to ByteStream, fix https://github.com/status-im/nim-beacon-chain/pull/436#issuecomment-530391076 (#12) 2019-09-11 12:16:51 -04:00
Mamy Ratsimbazafy 7a42cab625
Merge pull request #10 from status-im/autoclose-streams
autoclose streams, fix #9
2019-09-10 22:25:24 -04:00
mratsim cb6055a8be autoclose streams, fix #9 2019-09-10 20:26:25 -04:00
Zahary Karadjov e874ae6766
A fix for SSZ.saveFile 2019-09-07 17:58:32 -04:00
Ștefan Talpalaru e6c59d86be
add AppVeyor badge 2019-08-24 05:22:46 +02:00
Ștefan Talpalaru 43ff99a809
CI: update script path 2019-08-24 05:14:20 +02:00
Zahary Karadjov 5ef8130c79
Add a very basic test and a CI config 2019-08-14 17:33:14 +02:00
Zahary Karadjov 463fb8addb
wip 2019-08-14 12:25:02 +03:00
Zahary Karadjov 3bd550eb68
Add tests for tuples 2019-08-12 17:50:50 +03:00
Alexander Ivanov 034a6c8efe
Implement unnamed tuple support 2019-08-08 23:18:36 +03:00
Zahary Karadjov b42502b512
Some needed support for custom field serialization in Json 2019-08-07 01:19:32 +03:00
Zahary Karadjov 56ad4b18de
Transfer some of the complexity in handling case objects from SSZ to the general serialization lib 2019-08-05 16:54:17 +03:00
Zahary Karadjov e97e0b0684
Add roundtrip tests for tables 2019-08-05 16:54:17 +03:00
Zahary Karadjov 897a6638cf
Extract common test cases and patterns used by both SSZ and JSON 2019-08-05 16:54:17 +03:00
Zahary Karadjov 8e907c46fc
Fix a build issue affecting Nim 0.20.2 2019-08-05 16:54:17 +03:00
Zahary Karadjov e26985dec3
Fix a compilation issue in the roundtripTest when used with case objects 2019-08-05 16:54:17 +03:00
Zahary Karadjov 99daa96284
Custom serialization for object fields (initial version) 2019-08-05 16:54:17 +03:00
Zahary Karadjov e126d48e6c
Use the new fixed hasCustomPragma definition 2019-08-05 16:54:17 +03:00
Zahary Karadjov 60613bac5d
Better support for case objects; Some internal documentation 2019-08-05 16:54:17 +03:00
Ștefan Talpalaru 171dbde4b1
fix README 2019-07-13 17:05:06 +02:00
Jacek Sieka 5c2d0c7253
std_shims -> stew 2019-07-07 11:50:26 +02:00
Jacek Sieka 6025b5d3a7
fix typo 2019-06-28 09:51:28 +02:00
Zahary Karadjov 6bbde4d3a0 Ergonomic improvements for roundtripTest 2019-06-24 17:37:30 +03:00
Zahary Karadjov 0546444876 WIP README 2019-06-24 17:36:18 +03:00
Zahary Karadjov 3a56635499 New roundtripTest helper that checks the serialized value as well 2019-06-24 16:46:23 +03:00
Zahary Karadjov 060c8fd9bf
Add a helper simplifying writing a single value to a stream 2019-06-24 05:07:13 +03:00