Stricter type hint parsing

This fixes #59.