def get_type_name(type_name, sub_type=None):
if type_name in ("<STR_LIT:string>", "<STR_LIT>"):<EOL><INDENT>return "<STR_LIT:string>"<EOL><DEDENT>if type_name == "<STR_LIT:float>":<EOL><INDENT>return "<STR_LIT>"<EOL><DEDENT>if type_name == "<STR_LIT>":<EOL><INDENT>return "<STR_LIT:bool>"<EOL><DEDENT>if type_name == "<STR_LIT:list>":<EOL><INDENT>st = get_type_name(type_name=sub_type, sub_type=None) if sub_type else "<STR_LIT>"<EOL>return "<STR_LIT>" % st<EOL><DEDENT>if type_name == "<STR_LIT>":<EOL><INDENT>return "<STR_LIT:int>"<EOL><DEDENT>if type_name == "<STR_LIT:time>":<EOL><INDENT>return "<STR_LIT>"<EOL><DEDENT>return "<STR_LIT>"<EOL>
Returns a go type according to a spec type