[riot-notifications] [RIOT-OS/RIOT] core/clist: add clist_count() (#11251)

Hauke Petersen notifications at github.com
Sat Mar 23 23:50:45 CET 2019


### Contribution description
Using `clistls`, I was missing the possibility to easily count the number of elements in a given list. This PR adds that functionality.

As this is an inline function, it should not have any effect on any existing code...

### Testing procedure
run the provided unittests (`unittests/tests-core`), these should prove the functions correctness.

### Issues/PRs references
none
You can view, comment on, or merge this pull request online at:

  https://github.com/RIOT-OS/RIOT/pull/11251

-- Commit Summary --

  * core/clist: add clist_count()
  * unittests/core: added tests for clist_count

-- File Changes --

    M core/include/clist.h (22)
    M tests/unittests/tests-core/tests-core-clist.c (18)

-- Patch Links --

https://github.com/RIOT-OS/RIOT/pull/11251.patch
https://github.com/RIOT-OS/RIOT/pull/11251.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/11251
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190323/a9380f57/attachment.html>


More information about the notifications mailing list