def parse_param(param, include_desc=False):
param_def, _colon, desc = param.partition('<STR_LIT::>')<EOL>if not include_desc:<EOL><INDENT>desc = None<EOL><DEDENT>else:<EOL><INDENT>desc = desc.lstrip()<EOL><DEDENT>if _colon == "<STR_LIT>":<EOL><INDENT>raise ValidationError("<STR_LIT>", declaration=param)<EOL><DEDENT>param_name, _space, param_type = param_def.partition('<STR_LIT:U+0020>')<EOL>if len(param_type) < <NUM_LIT:2> or param_type[<NUM_LIT:0>] != '<STR_LIT:(>' or param_type[-<NUM_LIT:1>] != '<STR_LIT:)>':<EOL><INDENT>raise ValidationError("<STR_LIT>", param_string=param_def, type_string=param_type)<EOL><DEDENT>param_type = param_type[<NUM_LIT:1>:-<NUM_LIT:1>]<EOL>return param_name, ParameterInfo(param_type, [], desc)<EOL>
Parse a single typed parameter statement.