From 297788c4592eef0393847079a873b5466102ce08 Mon Sep 17 00:00:00 2001 From: Virgile Prevosto <virgile.prevosto@m4x.org> Date: Wed, 25 Mar 2020 19:19:42 +0100 Subject: [PATCH] [tests] add pretty-printing test for treatment of new builtins --- tests/syntax/oracle/signal.res.oracle | 12 ++++++++++++ tests/syntax/signal.c | 7 +++++++ 2 files changed, 19 insertions(+) create mode 100644 tests/syntax/oracle/signal.res.oracle create mode 100644 tests/syntax/signal.c diff --git a/tests/syntax/oracle/signal.res.oracle b/tests/syntax/oracle/signal.res.oracle new file mode 100644 index 00000000000..7f9d11fa241 --- /dev/null +++ b/tests/syntax/oracle/signal.res.oracle @@ -0,0 +1,12 @@ +[kernel] Parsing tests/syntax/signal.c (with preprocessing) +/* Generated by Frama-C */ +#include "signal.h" +void f(void) +{ + signal(10,SIG_IGN); + signal(12,SIG_ERR); + signal(31,SIG_DFL); + return; +} + + diff --git a/tests/syntax/signal.c b/tests/syntax/signal.c new file mode 100644 index 00000000000..31221db005b --- /dev/null +++ b/tests/syntax/signal.c @@ -0,0 +1,7 @@ +#include <signal.h> + +void f() { + signal (SIGUSR1, SIG_IGN); + signal (SIGUSR2, SIG_ERR); + signal (SIGUNUSED, SIG_DFL); +} -- GitLab