I started by wanting to eliminate Arc<str>. Then I noticed that vello_editor was allocating temporary Vecs for the PlainEditorOps. Finally, it occurred to me that we could probably do something altogether more efficient than PlainEditorOp. I think my refactored version, with separate functions in PlainEditorTxn, will be nicer to maintain as well.
I started by wanting to eliminate
Arc<str>
. Then I noticed thatvello_editor
was allocating temporaryVec
s for thePlainEditorOp
s. Finally, it occurred to me that we could probably do something altogether more efficient thanPlainEditorOp
. I think my refactored version, with separate functions inPlainEditorTxn
, will be nicer to maintain as well.