This functionality MUST be accessible with a function or a method. (?)
As already mentioned, building up a pattern string and then using that on the LHS cannot work:
>>> pattern = "{a:d} {b:d}"
>>> pattern += " {c:s}"
>>> pattern = "12 34 ef"
This is the way Parse works; you call parse() and it returns a Result:
>>> r = parse("The {} who say {}", "The knights who say Ni!")
>>> print(r)
<Result ('knights', 'Ni!') {}>
>>> print(r.fixed)
('knights', 'Ni!')
```rst
Result and Match Objects
------------------------
The result of a ``parse()`` and ``search()`` operation is either ``None`` (no match), a
``Result`` instance or a ``Match`` instance if ``evaluate_result`` is False.
The ``Result`` instance has three attributes:
``fixed``
A tuple of the fixed-position, anonymous fields extracted from the input.
``named``
A dictionary of the named fields extracted from the input.
``spans``
A dictionary mapping the names and fixed position indices matched to a
2-tuple slice range of where the match occurred in the input.
The span does not include any stripped padding (alignment or width).
The ``Match`` instance has one method:
``evaluate_result()``
Generates and returns a ``Result`` instance for this ``Match`` object.
```
Similar functionality in the standard library could return e.g. Union[tuple, namedtuple] and expect users to call namedtuple.asdict() when there are template field names specified; but the parse.Result object does support .spans ("A dictionary mapping the names and fixed position indices matched to a 2-tuple slice range of where the match occurred in the input.").