zephyr/scripts/coccinelle/macros.h
Rubin Gerritsen fc377363e4 cocinelle: Parse ztest test functions
We want to able to use cocinelle on ztest functions as
well when transforming APIs.

Provide a simple macro so that test functions are recognized.

Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
2024-06-14 19:25:42 +02:00

23 lines
611 B
C

/*
* Copyright (c) 2020 Nordic Semiconductor ASA
*
* SPDX-License-Identifier: Apache-2.0
*/
/* File to be specified by -macro-file in invocations of coccinelle
* to avoid parse errors that prevent application of rules.
*
* This is not exhaustive: only defines that have been proven to
* inhibit context recognition are listed. The structure of the file
* is expected to follow that of the Coccinelle standard.h macro file.
*/
/* Zephyr macros */
#define ZTEST(suite, fn) static void _##suite##_##fn##_wrapper(void)
/* Attributes */
/* Confirmed problematic */
#define __noinit
#define __syscall