(self, args: list[str])
| 363 | # For "positional-only" function parsing, |
| 364 | # which generates a bunch of PyArg_ParseTuple calls. |
| 365 | def parse_argument(self, args: list[str]) -> None: |
| 366 | assert not (self.converter and self.encoding) |
| 367 | if self.format_unit == 'O&': |
| 368 | assert self.converter |
| 369 | args.append(self.converter) |
| 370 | |
| 371 | if self.encoding: |
| 372 | args.append(libclinic.c_str_repr(self.encoding)) |
| 373 | elif self.subclass_of: |
| 374 | args.append(self.subclass_of) |
| 375 | |
| 376 | s = ("&" if self.parse_by_reference else "") + self.parser_name |
| 377 | args.append(s) |
| 378 | |
| 379 | if self.length: |
| 380 | args.append(f"&{self.length_name}") |
| 381 | |
| 382 | # |
| 383 | # All the functions after here are intended as extension points. |
no test coverage detected