fixed bugs in function annotations