protobuf-ts icon indicating copy to clipboard operation
protobuf-ts copied to clipboard

Enhancement: Generate specialized `mergePartial()` method when `optimize_for = SPEED`

Open jcready opened this issue 1 year ago • 0 comments

Currently specialized methods are generated for: create(), internalBinaryRead(), and internalBinaryWrite() when optimize_for = SPEED https://github.com/timostamm/protobuf-ts/blob/3a7ce47d43113d1a80cacd0ae70630b3727eda3e/packages/plugin/src/code-gen/message-type-generator.ts#L116-L123

The same could be done for mergePartial() to avoid relying on runtime reflection and iteration.

jcready avatar Sep 14 '23 14:09 jcready