A sequence builtin that is lacking is a str equivalent.
Currently, working with str and pyochain is a bit awkard, as a lot of methods return "raw" list and Iterator, breaking method chains. we could also add methods from rust that are missing in python when applicable.
However, great care must be taken in the implementation: since we often work with Iterable of str, it means that overhead is even less acceptable than with Vec or Seq.
As such, the best way would surely be to directly inerhit from str, rather than going with the usual composition pattern.
However, it means that this "break" the usual way of implementing wrappers, and we can't benefit from an "easy" heritance of PyoSequence.
The latter point especially imply some work, as we must integrate the whole chain of PyoSequence in a py_abc trait.
A sequence builtin that is lacking is a
strequivalent.Currently, working with
strand pyochain is a bit awkard, as a lot of methods return "raw"listandIterator, breaking method chains. we could also add methods from rust that are missing in python when applicable.However, great care must be taken in the implementation: since we often work with
Iterableofstr, it means that overhead is even less acceptable than withVecorSeq.As such, the best way would surely be to directly inerhit from
str, rather than going with the usual composition pattern.However, it means that this "break" the usual way of implementing wrappers, and we can't benefit from an "easy" heritance of
PyoSequence.The latter point especially imply some work, as we must integrate the whole chain of
PyoSequencein apy_abctrait.