Allow casting to a restricted type if !restricted_value

If the operand of a cast to a restricted type is an unrestricted value,
 the cast should not produce a warning, since an equivalent implied cast
 (e.g. in an initialiser) would not do so.

Also adds a test case (bitwise-cast.c) testing implicit and explicit
 conversions of zero and nonzero integers to bitwise type.

Signed-off-by: Edward Cree <ecree@solarflare.com>
Acked-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Tested-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Christopher Li <sparse@chrisli.org>
2 files changed