rosenberg: fix crash parsing different functions with the same name