aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/lib.c
diff options
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2017-05-28 23:44:48 +0200
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2017-09-14 18:12:42 +0200
commit2ee3305ea8d50558bdc678745da5f10cf38ab80c (patch)
treeec38529a794a758b981274b0e2ccbce5a3373264 /lib.c
parent5e1d94a00cd15e91468e8277497c34dca93fe5f4 (diff)
downloadsparse-dev-2ee3305ea8d50558bdc678745da5f10cf38ab80c.tar.gz
option: rename 'struct warning' to 'struct flag'
'struct warning' can be reused for flags other than warnings. To avoid future confusion, rename it to something more general: 'struct flag' (which in its context, handling of compiler flags, is clear enough). Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'lib.c')
-rw-r--r--lib.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib.c b/lib.c
index 351da6f4..04f9de5a 100644
--- a/lib.c
+++ b/lib.c
@@ -513,7 +513,7 @@ static char **handle_switch_o(char *arg, char **next)
return next;
}
-static const struct warning {
+static const struct flag {
const char *name;
int *flag;
} warnings[] = {
@@ -558,7 +558,7 @@ enum {
};
-static char **handle_onoff_switch(char *arg, char **next, const struct warning warnings[], int n)
+static char **handle_onoff_switch(char *arg, char **next, const struct flag warnings[], int n)
{
int flag = WARNING_ON;
char *p = arg + 1;
@@ -600,7 +600,7 @@ static char **handle_switch_W(char *arg, char **next)
return next;
}
-static struct warning debugs[] = {
+static struct flag debugs[] = {
{ "entry", &dbg_entry},
{ "dead", &dbg_dead},
};
@@ -619,7 +619,7 @@ static char **handle_switch_v(char *arg, char **next)
return next;
}
-static struct warning dumps[] = {
+static struct flag dumps[] = {
{ "D", &dump_macro_defs},
};
@@ -633,7 +633,7 @@ static char **handle_switch_d(char *arg, char **next)
}
-static void handle_onoff_switch_finalize(const struct warning warnings[], int n)
+static void handle_onoff_switch_finalize(const struct flag warnings[], int n)
{
unsigned i;