Commit Graph
100 Commits
Author SHA1 Message Date
Leonardo 359f282784 Added .clang-format and formatted source code 2019-12-03 16:09:31 -03:00
Leonardo 26fa80f7e0 Removed cmc_string.h as it is no longer needed 2019-12-03 02:00:15 -03:00
Leonardo 74177f891d Fixing cmc_alloc_node_default error 2019-11-23 01:46:12 -03:00
Leonardo 3ee070b4dd Update TODO and added to_string visual test 2019-11-23 00:38:31 -03:00
Leonardo 49bed825c2 All collections now support custom allocation functions
Also some development was made towards callback functions
Now all files are independent and include all necessary definitions within it
2019-11-23 00:28:11 -03:00
Leonardo 26cc284618 Update TODO 2019-11-22 14:49:28 -03:00
Leonardo f550b0dfa3 Custom allocation node to hashmap, hashset and heap 2019-11-22 00:51:23 -03:00
Leonardo 3b8182d751 Fixing more bidimap stuff and update deque 2019-11-21 23:58:05 -03:00
Leonardo 9996eefc69 Fixing bidimap and adding more tests 2019-11-21 01:52:54 -03:00
Leonardo ad2ae84c13 Finishing up some functions of bidimap that were left off
Also gearing up bidimap for next update containing callbacks and custom allocation functions
2019-11-13 23:23:54 -03:00
Leonardo 0d57698d2f Main header file now only uses a single concatenation macro 2019-11-13 21:24:38 -03:00
Leonardo e3a8745a0b v1.7.3 2019-10-30 00:05:34 -03:00
Leonardo 415720c6a6 Update benchmarks and examples 2019-10-29 12:00:46 -03:00
Leonardo 33c33e8947 Completely removed typedefs 2019-10-29 02:19:34 -03:00
Leonardo db61269d42 Added compile time benchmark and bidimap tests 2019-10-26 15:03:44 -03:00
Leonardo 8f06e8abce Replaced calls to malloc and memset with just calloc 2019-10-26 00:39:46 -03:00
Leonardo 122d012ffd Fast forward codecov 2019-10-23 01:14:10 -03:00
Leonardo 616327f054 Moved all collections from ext to cmc
ext no longer exists
2019-10-22 23:51:39 -03:00
Leonardo de744f5822 v1.7.2 2019-10-18 11:15:52 -03:00
Leonardo 5583ca38b3 Changed default_type functions to compound literals 2019-10-17 01:37:55 -03:00
Leonardo 2d3b441d74 Added resize to multimap, multiset and sortedlist 2019-10-16 21:34:30 -03:00
Leonardo 99cd01ba1e Added intervalheap resize 2019-10-15 23:52:09 -03:00
Leonardo 1f11b6d2da Added preview of bidimap 2019-10-14 22:37:39 -03:00
Leonardo e41fe14502 Refactoring multiset code to be at most 100 characters per line 2019-10-12 00:27:38 -03:00
Leonardo 63d0453341 Finally releasing sortedlist 2019-10-11 02:14:33 -03:00
Leonardo 5e1a26b72e Added queue and stack resize 2019-10-10 15:10:37 -03:00
Leonardo e06e795ed8 hashmap quickfix 2019-10-09 00:53:40 -03:00
Leonardo b9b507bf07 Added heap and list resize function and refactored some tests and added some more 2019-10-08 13:57:58 -03:00
Leonardo 9f8671f75f Added resize function to hashmap and hashset 2019-10-07 19:57:20 -03:00
Leonardo f0b7b125b9 Added deque.h resize and added more deque and hashmap tests 2019-10-05 00:31:29 -03:00
Leonardo 8483eda701 Added two working examples, hanoi and printer 2019-10-04 01:19:18 -03:00
Leonardo b870649627 Refactoring tests 2019-10-03 11:29:35 -03:00
Leonardo 93ac623ffe Update README and benchmark 2019-10-02 00:11:08 -03:00
Leonardo 5997302a8c Fixed deque and queue bug and added more tests 2019-10-01 00:48:09 -03:00
Leonardo f52a9ff702 Refactoring tests and added sortedlist test 2019-09-30 18:27:19 -03:00
Leonardo 376c0ad4e7 Minor optimization to list.h and added finished more TODOs from sortedlist.h 2019-09-30 18:26:31 -03:00
Leonardo 34e649d82a Removed all conditional IO 2019-09-29 15:49:10 -03:00
Leonardo bfb8426183 Fixing travis 2019-09-28 15:01:02 -03:00
Leonardo 4f755f0915 Redone tests
./codecov is a stalled version for code coverage. It will be merged with main when the library is done with breaking changes
2019-09-28 14:58:10 -03:00
Leonardo dea77b5ca2 A minor fix to intervalheap.h 2019-09-27 00:06:26 -03:00
Leonardo b300c889f3 Added cmc prefix to timer 2019-09-27 00:05:22 -03:00
Leonardo 2126da3f25 Removed unnecessary typedefs for log.h and test.h and fixed the latter 2019-09-26 01:17:18 -03:00
Leonardo fb7854ef5d Update assert.h and removed
Added 3 new assertion macros:

cmc_assert_array_equals_any
cmc_assert_array_within_any
cmc_assert_array_outside_any
cmc_assert_array_sorted_any (renamed)
2019-09-25 16:41:40 -03:00
Leonardo 1ff3142769 Update assert.h
Renamed the parameters to and from to to_index and from_index
2019-09-24 23:35:00 -03:00
Leonardo 331fb32b73 Small additions and fixes to sortedlist 2019-09-23 22:34:23 -03:00
Leonardo Vencovsky fa03379580 Merge pull request #5 from LeoVen/dev
v1.7.1 fast forward master
2019-09-22 01:20:01 -03:00
Leonardo 43f4ae9f16 v1.7.1 2019-09-21 19:19:36 -03:00
Leonardo d9171a11cf Fixed some include guards for cmc_hashtable_primes and cmc_entry_state
Also removed unnecessary typedef for enum cmc_entry_state
Now cmc_entry state is in another guard, separated from the cmc_hashtable_primes guard
2019-09-21 18:25:01 -03:00
Leonardo 344e9f77fe Renamed list and linkedlist functions
push - push_at
pop - pop_at

The list prepend, append and insert - seq_push_front, seq_push_back, seq_push_at
2019-09-21 00:37:56 -03:00
Leonardo 2c84c35264 Adding sortedlist skeleton
Some functions are already working but there is still too much to be optimized
2019-09-18 02:29:11 -03:00
Leonardo c27edd53f6 Added cmc_assert_sorted 2019-09-18 02:28:20 -03:00
Leonardo a0db76b50d Update README.md
Trying to fix the shield's icon
2019-09-17 12:00:40 -03:00
Leonardo bb3efd75ff Update README and TODO 2019-09-17 00:37:12 -03:00
Leonardo 3d7e218195 Move the string format to each collection files and quick fix on deque
Now the format to print them is only declared if you actually include the header
2019-09-16 23:50:06 -03:00
Leonardo 191c47fc7c v1.7.0 2019-09-16 14:47:54 -03:00
Leonardo f2f806612f Moving documentation to the docs folder 2019-09-16 14:47:42 -03:00
Leonardo 5e2e001265 Merge branch 'master' of https://github.com/LeoVen/C-Macro-Containers 2019-09-16 14:45:45 -03:00
Leonardo 2ca2210a77 Added CMC prefix to all macros and removed FMOD 2019-09-16 14:45:24 -03:00
Leonardo Vencovsky 747aa8cb4e Merge pull request #4 from LeoVen/dev
Merge pull request #2 from LeoVen/master
2019-09-16 14:35:55 -03:00
Leonardo 4fe4e96811 v1.6.3 2019-09-14 00:38:45 -03:00
Leonardo 0df0ebbdeb Update TODO, quick fixes in a makefile and in assert.h 2019-09-14 00:38:13 -03:00
Leonardo e834aaee81 Added iter_advance, iter_rewind and iter_go_to to all collections
Also reworked many iterator functions that could cause strange behavior
2019-09-13 18:46:00 -03:00
Leonardo 1928fdd6d5 Reworked assert.h and test.h and added the cmc prefix to the logging utility
Integrated the assert utility with the test utility. Now any assertion that fails inside the unit test will trigger failure and is no longer needed to manually pass or fail a test.
Also reworked makefiles.
2019-09-06 12:17:11 -03:00
Leonardo abdbfa2018 v1.6.2 2019-09-05 01:48:51 -03:00
Leonardo a1a940399a Unified _set and _update functions
Also _remove now accepts an optional parameter if to retrieve or not the removed value. _update also has the same optional parameter that retrieves the old value.
The multimap will allocate an array based on the amount of keys and add all the values to that array.
2019-09-05 01:33:54 -03:00
Leonardo 855e085996 Fixed benchmark 2019-09-05 01:09:06 -03:00
Leonardo e95379bdd7 Updated tests 2019-09-03 17:07:34 -03:00
Leonardo 762b95db26 Some fixes and improvements to hashmap, hashset and multimap 2019-09-03 17:07:15 -03:00
Leonardo 396066f289 Update README.md 2019-09-03 16:54:21 -03:00
Leonardo f070d274f4 Added _equals function to all collections and fixed some issues with multimap 2019-08-29 23:25:32 -03:00
Leonardo 1f50add1bb Added _copy_of functions to all collections 2019-08-28 16:34:15 -03:00
Leonardo e68b8a8e0e Fixing main unit test 2019-08-27 01:38:34 -03:00
Leonardo 5ee7bfa23a v1.6.1 2019-08-27 01:36:06 -03:00
Leonardo 8ec768d30e removed linkedqueue and now _free and _clear have a deallocator parameter 2019-08-27 01:33:58 -03:00
Leonardo Vencovsky 35d27ffb39 Merge pull request #2 from LeoVen/master
Fast forward dev
2019-08-08 15:43:04 -03:00
Leonardo 613392ae76 Changed how _update works and added _set
_update: retrieves old value
_set: ignores old value
2019-08-05 23:28:12 -03:00
Leonardo f74ce7519a Added update function for hashmap, treemap and multimap and added update_all for multimap 2019-08-03 01:55:36 -03:00
Leonardo 01d0b42e1a v1.6.0 2019-08-02 01:03:28 -03:00
Leonardo e470021d13 Added to_string to intervalheap and multimap 2019-08-02 00:53:35 -03:00
Leonardo 7de3ce5c0c Updating examples readme and added multiset to benchmark 2019-08-02 00:36:54 -03:00
Leonardo 976965bcfa Fixed integer overflow with hashtables when calculating their capacity 2019-08-02 00:18:22 -03:00
Leonardo 1254e657c5 Complete remake of multiset 2019-08-01 23:52:50 -03:00
Leonardo 90ee6a424d heap hotfix 2019-07-31 23:08:51 -03:00
Leonardo bf79616e7e Adding Code Review shields 2019-07-18 22:58:41 -03:00
Leonardo 09ebb1eae8 Thank you Code Review for your awesome community! 2019-07-17 13:57:13 -03:00
Leonardo ba6d8edde1 Update .travis.yml 2019-07-17 00:05:54 -03:00
Leonardo 2f76ad4b6f Update README.md 2019-07-16 23:59:38 -03:00
Leonardo 407141661a Fixing test 2019-07-16 23:58:02 -03:00
Leonardo 38620ba457 Added to_string methods to cmc, ./utl/cmc_string.h, fixed some variable names and fixed includes 2019-07-16 23:55:30 -03:00
Leonardo f8f704f432 Added intervalheap and multimap to benchmark 2019-07-14 22:33:30 -03:00
Leonardo 8ae83acd1a Update stack unit test 2019-07-13 00:17:31 -03:00
Leonardo af26f6c081 More fixes to ./cmc/stack.h 2019-07-13 00:17:01 -03:00
Leonardo d82be005da Fixing stack iter_init 2019-07-12 23:34:16 -03:00
Leonardo e37b54fc62 Added bool type assert 2019-07-12 23:33:35 -03:00
Leonardo 9eb8d5f682 Fixing tests and added linkedqueue tests 2019-07-10 17:26:31 -03:00
Leonardo 7ecb2e90fd Update TODO 2019-07-10 16:57:54 -03:00
Leonardo 354cd538f8 Added cmc prefixes to enums used by heap and hashtables and fixed return type on treeset and hashset 2019-07-10 16:57:46 -03:00
Leonardo 0c883b0a74 Multimap tests 2019-07-09 23:51:01 -03:00
Leonardo 9c23c3ca77 Update multimap to new standards 2019-07-08 19:55:48 -03:00
Leonardo d0244a0513 Update TODO 2019-07-06 01:24:07 -03:00