core: improve is_array() and get_array_base()
If you have an array full of function pointers then Smatch is supposed to
record that, but it wasn't working because is_array() almost always
returned false.
I've improved is_array(). But now it returns true for EXPR_BINOP as well
as EXPR_PREOP so a bunch of the callers had to be updated. They assumed
that only EXPR_PREOP was an array and we should use expr->unop->left to
get the array and expr->unop->right to get the offset. This is quite
bogus.
We have a function to give the array and the array offset. I've renamed
the "get array" function from get_array_name() to get_array_base(). That
name sort of sucks as well... I can rename it later with sed so that's
ok.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>