fixed handling of integer references