idea: get rid of some pointless (int) casts