233 Commits
Author SHA1 Message Date
Patrick Pelissier 8a4d013354 Fix issues (normal contract where used for I/O whereas they could be used
with OA Dict)
2018-08-01 22:55:54 +02:00
Patrick Pelissier 318f1a2818 Update/Add comments. 2018-07-17 23:03:45 +02:00
Patrick Pelissier 96202aa78f Do not use reserved identifiers of the C standard (See 7.1.3 Reserved identifiers) 2018-07-14 14:35:14 +02:00
Patrick Pelissier 3164e2698d Improve comments. 2018-07-05 12:12:16 +02:00
Patrick Pelissier e23616169b Improve comments. 2018-07-04 17:38:48 +02:00
Patrick Pelissier 9d7fc942f7 Rename DICT_SET_DEF2 into DICT_SET_DEF 2018-07-03 15:50:14 +02:00
Patrick Pelissier 982d8cf19d DICT_*_DEF* doesn't require anymore oplists for defining the function:
it can get them from global oplists or default oplits.
2018-07-03 15:44:40 +02:00
Patrick Pelissier 4b0f7543ee Rename _set_at to _push method for SET dictionnary.
Add proper _splice method for SET dictionnary.
2018-07-03 10:40:26 +02:00
Patrick Pelissier 41362f12ea Add comment about _hash for dict. 2018-07-01 22:54:19 +02:00
Patrick Pelissier 3765c0b0fb Add _equal_p method for OA dictionary. 2018-07-01 22:44:56 +02:00
Patrick Pelissier aa195f9f6f Add methods _cget. 2018-07-01 17:16:25 +02:00
Patrick Pelissier 923e009fd3 Fix issue for new method _get_at for OA dict. 2018-06-29 22:32:10 +02:00
Patrick Pelissier bf2a04ff66 Add method _get_at:
_get or create an entry.
2018-06-29 19:41:34 +02:00
Patrick Pelissier 28f6a7d399 Add missing _empty_p methods for dictionnaries. 2018-06-27 07:10:18 +02:00
Patrick Pelissier 188b329eae Add method _parse_str for dict. 2018-05-03 17:43:40 +02:00
Patrick Pelissier 2eaeb26d4c Make Serialization input of array / dict more flexible
by supporting space characters within the input.
2018-04-30 11:02:42 +02:00
Patrick Pelissier 6bb94db22f Add function dict_splice 2018-04-15 21:02:14 +02:00
Patrick Pelissier 74a3d50c88 Minor optimization for _clean
No need to fill in the complete array with invalid param
as the array will be reduced.
2018-04-15 10:53:15 +02:00
Patrick Pelissier 1db2813aa3 Add dictionary with store computed hash, avoiding the need
of recomputation in some cases.
2018-02-28 21:06:58 +01:00
Patrick Pelissier 762d8a8e74 Update assertion 2018-02-27 22:43:17 +01:00
Patrick Pelissier b7966f6b61 Update assertions 2018-02-27 22:41:20 +01:00
Patrick Pelissier 210e05f7fc Update copyright to 2018 2018-01-29 20:28:30 +01:00
Patrick Pelissier 2089af8fd3 Fix broken code due to previous commits. 2018-01-24 22:26:46 +01:00
Patrick Pelissier 8914d336a0 dict_ref & dict_cref returns a pointer to struct pair_s instead of pair_t (which
is an array of struct pair_s).
This will break API compatibility. However:
it makes the user code cleaner as a level of indirection is removed.
it uniformizes with the OA dict version
2017-10-18 23:25:39 +02:00
Patrick Pelissier 4d328d97f1 FIXME --> TODO 2017-10-09 23:23:58 +02:00
Patrick Pelissier 8a1f24ca54 Fix issue detected by address sanitizer
(Read beyond and below the table allocation).
2017-09-27 22:57:08 +02:00
Patrick Pelissier f75bd05a02 Fix issue with dict equal_p 2017-09-17 11:29:00 +02:00
Patrick Pelissier 95f467f4be Fix potential bug in case of ill-formed serialized container. 2017-09-16 13:30:09 +02:00
Patrick Pelissier 44cdfa0c77 Remove use of feof and ferror as it is not needed as the return of fgetc
is sufficent.
2017-08-19 21:05:55 +02:00
Patrick Pelissier 5f737b3b65 Fix overflow issue. 2017-08-06 23:13:49 +02:00
Patrick Pelissier 8f213d20a5 Replace iteration + splice_back by calling spimply _splice. 2017-07-29 13:04:06 +02:00
Patrick Pelissier 80c273e6e2 Remove dict_ prefix for dictionnary.
See commit on shared-pointer.
2017-07-29 13:01:38 +02:00
Patrick Pelissier 34943e5b2a Remove array_ prefix from ARRAY_DEF
See commit on shared pointers.
2017-07-27 22:16:15 +02:00
Patrick Pelissier 4cb92a92b8 Remove list_ prefix from all lists.
See commit on shared-pointers.
Rename the iteration type to be prefix by name list_it_name_t ==> name_it_t
2017-07-27 21:40:35 +02:00
Patrick Pelissier e77e507b51 Add function reserve for OA dictionnary. 2017-07-15 23:30:00 +02:00
Patrick Pelissier 9078fb9cd0 Update comment after measurements. 2017-07-15 22:40:01 +02:00
Patrick Pelissier 28620c8cb5 Fix issue:
the function dict_oa_it_end was in fact dict_oa_it_last.
 add function dict_oa_it_end
2017-07-12 23:52:13 +02:00
Patrick Pelissier 13daf6b264 Fix issue. 2017-07-12 22:30:10 +02:00
Patrick Pelissier a1eb33344e Fix issue for OA addressing. 2017-07-12 22:23:07 +02:00
Patrick Pelissier 693c491f1e Fix issue with coverage build. 2017-07-11 23:52:48 +02:00
Patrick Pelissier 42989df5d9 Fix issue with coverage build. 2017-07-11 23:39:45 +02:00
Patrick Pelissier 2716ad425c Wrong parameter given for extra dict OA 2017-07-11 22:35:57 +02:00
Patrick Pelissier 08112a3a6d Fix issue detected by scan-build 2017-07-10 13:47:34 +02:00
Patrick Pelissier 2ef2dd1231 Add const to function definition. 2017-07-08 12:57:06 +02:00
Patrick Pelissier e8781e2860 Add new possible const due to const added to array functions. 2017-07-07 23:03:43 +02:00
Patrick Pelissier d3038cc758 Add _out_str, _in_str & _get_str to OA dict. 2017-07-06 23:14:26 +02:00
Patrick Pelissier 91affebce7 Fix wrong name in exported OPLIST for dict's out_str, get_str & in_str 2017-07-05 16:13:26 +02:00
Patrick Pelissier 76fc919ccb * Rename _slice into _splice.
* Rename _move_back into _splice_back
to uniform the interface.
2017-07-05 09:17:11 +02:00
Patrick Pelissier 61bebd3cff Fix bugs in iterator of OA dict for next/previous. 2017-06-08 23:51:09 +02:00
Patrick Pelissier 4b50020f12 Fix bugs with OA dict. 2017-06-08 23:36:12 +02:00