Skip to content

bugfix: UnmarshalWithConf parameter o is not effective when UnmarshalConf.DecoderConfig is passed in #360

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

tsln1998
Copy link

Close #359

@tsln1998 tsln1998 changed the title bugfix: UnmarshalWithConf parameter o is not effective when UnmarshalConf is passed in bugfix: UnmarshalWithConf parameter o is not effective when UnmarshalConf.DecoderConfig is passed in May 25, 2025
WeaklyTypedInput: true,
}
}

if c.DecoderConfig.Result == nil {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's better to always set c.DecoderConfig.Result = o without the if condition as o is an explicit function arg which should always have the results. If Result is set in DecoderConfig externally, it's better for that to be ignored and o to always have the result.

@knadh knadh closed this in c985517 Jun 9, 2025
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.

When UnmarshalConf.DecoderConfig is passed in, parameter o is not effective.
2 participants