Skip to content

Pass the emit_context by (non-const) reference#7

Merged
BurningEnlightenment merged 1 commit intomasterfrom
dev/mutable-emit-context
Feb 3, 2023
Merged

Pass the emit_context by (non-const) reference#7
BurningEnlightenment merged 1 commit intomasterfrom
dev/mutable-emit-context

Conversation

@BurningEnlightenment
Copy link
Copy Markdown
Contributor

Purpose

In order to allow storing state in the emit_context in a future API extension it needs to be mutable. Note that since it stores the output_buffer by reference, there are no concerns w.r.t. codecs replacing the current output_buffer.

Additional explanatory comments

This was an early design mishap in #4 which I forgot to rectify before merging.

In order to allow storing state in the emit_context in a future API
extension it needs to be mutable. Note that since it stores the
output_buffer by reference, there are no concerns w.r.t. codecs
replacing the current output_buffer.

BREAKING CHANGE: The `(de|en)code()` APIs won't accept an
		 `emit_context const &` argument anymore
@BurningEnlightenment BurningEnlightenment merged commit f4ddb1a into master Feb 3, 2023
@BurningEnlightenment BurningEnlightenment deleted the dev/mutable-emit-context branch February 3, 2023 09:47
@BurningEnlightenment BurningEnlightenment linked an issue Feb 15, 2023 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make emit_context codec parameter non-const

1 participant