def parse_type_comment(type_comment):
try:<EOL><INDENT>result = ast3.parse(type_comment, '<STR_LIT>', '<STR_LIT>')<EOL><DEDENT>except SyntaxError:<EOL><INDENT>raise ValueError(f"<STR_LIT>") from None<EOL><DEDENT>assert isinstance(result, ast3.Expression)<EOL>return result.body<EOL>
Parse a type comment string into AST nodes.