comparison of distinct pointer types lacks a cast