lib: fix "reduce strcmp in CLI" fallout (10bac801)

In "lib/cli: reduce strcmp in CLI hot paths", I failed to notice that
CMD_VARIABLE as a boolean test covers a superset of the other types of
variables.  Thus, the patch broke processing of IP/IPv6/Integer range
parameters in the CLI.

Fix by some reordering and introducing TERMINAL_RECORD macro (which
marks whether a given terminal type is a parameter) to be used in places
where the check is really for all kinds of variables.

Reported-by: Timo Teräs <timo.teras@iki.fi>
Tested-by: Martin Winter <mwinter@netdef.org>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
diff --git a/lib/command.h b/lib/command.h
index 3a95df9..a36a524 100644
--- a/lib/command.h
+++ b/lib/command.h
@@ -165,6 +165,9 @@
   TERMINAL_IPV6_PREFIX,
 };
 
+/* argument to be recorded on argv[] if it's not a literal */
+#define TERMINAL_RECORD(t) ((t) >= TERMINAL_OPTION)
+
 /* Command description structure. */
 struct cmd_token
 {