]> git.ipfire.org Git - thirdparty/bird.git/commit
Filter: Ensure that all expressions declared return type
authorOndrej Zajicek (work) <santiago@crfreenet.org>
Thu, 3 Mar 2022 19:34:44 +0000 (20:34 +0100)
committerOndrej Zajicek (work) <santiago@crfreenet.org>
Thu, 3 Mar 2022 19:48:08 +0000 (20:48 +0100)
commitcecc10f7733fbfb894280fbd7ff29899a478d808
tree2dbe3b0700a722ef356667ac600438cc89b0b30c
parentfc77b798c557602f57a2b8cfc97cfa206281f065
Filter: Ensure that all expressions declared return type

All instructions with a return value (i.e. expressions, ones with
non-zero outval, third argument in INST()) should declare their return
type. Check that automatically by M4 macros.

Set outval of FI_RETURN to 0. The instruction adds one value to stack,
but syntactically it is a statement, not an expression.

Add fake return type declaration to FI_CALL, otherwise the automatic
check would fail builds.
filter/decl.m4
filter/f-inst.c