Fixes and test for lowering array comparison