mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2026-01-01 01:41:18 +01:00
tests/pkg_jsmn: use kernel define ARRAY_SIZE macro
This commit is contained in:
parent
d244b0fe59
commit
9af59196da
@ -29,12 +29,9 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "kernel_defines.h" /* for ARRAY_SIZE macro */
|
||||
#include "jsmn.h"
|
||||
|
||||
#ifndef ARRAY_SIZE
|
||||
#define ARRAY_SIZE(a) (sizeof(a)/sizeof(*a))
|
||||
#endif
|
||||
|
||||
/*
|
||||
* A small example of jsmn parsing when JSON structure is known and number of
|
||||
* tokens is predictable.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user