suppress unreachable warnings
This commit is contained in:
parent
76f8916dca
commit
e8a50410a5
|
@ -1,5 +1,9 @@
|
||||||
#include "picrin/var.h"
|
#include "picrin/var.h"
|
||||||
|
|
||||||
|
#include <assert.h>
|
||||||
|
|
||||||
|
#define UNREACHABLE (assert(false))
|
||||||
|
|
||||||
struct pic_var *
|
struct pic_var *
|
||||||
pic_var_new(pic_state *pic, pic_value init, struct pic_proc *conv)
|
pic_var_new(pic_state *pic, pic_value init, struct pic_proc *conv)
|
||||||
{
|
{
|
||||||
|
@ -59,6 +63,7 @@ var_call(pic_state *pic)
|
||||||
else {
|
else {
|
||||||
pic_abort(pic, "logic flaw");
|
pic_abort(pic, "logic flaw");
|
||||||
}
|
}
|
||||||
|
UNREACHABLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static pic_value
|
static pic_value
|
||||||
|
@ -98,6 +103,7 @@ get_var_from_proc(pic_state *pic, struct pic_proc *proc)
|
||||||
|
|
||||||
typeerror:
|
typeerror:
|
||||||
pic_error(pic, "expected parameter");
|
pic_error(pic, "expected parameter");
|
||||||
|
UNREACHABLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static pic_value
|
static pic_value
|
||||||
|
|
Loading…
Reference in New Issue