Typing references