Skip to content
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

feat(go): runtime type check type unions #3712

Merged
merged 23 commits into from
Aug 24, 2022
Merged

Conversation

RomainMuller
Copy link
Contributor

@RomainMuller RomainMuller commented Aug 18, 2022

Runtime type-checking can be disabled by adding
--tag=no_runtime_type_checking to go compiler invocations. This can
be used to avoid paying the performance toll of runtime type checking
(which should be modest in most cases), or to work around a bug in the
type checking code.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Runtime type-checking can be disabled by adding
`--tag=no_runtime_type_checks` to go compiler invocations. This can be
used to avoid paying the performance toll of runtime type checking
(which should be modest in most cases), or to work around a bug in the
type checking code.
@mergify mergify bot added the contribution/core This is a PR that came from AWS. label Aug 18, 2022
@RomainMuller RomainMuller requested a review from a team August 19, 2022 10:09
@RomainMuller RomainMuller self-assigned this Aug 19, 2022
@RomainMuller RomainMuller added the language/go Regarding GoLang bindings label Aug 19, 2022
Copy link
Contributor

@comcalvi comcalvi left a comment

Choose a reason for hiding this comment

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

just a few small comments! Looks great.

Copy link
Contributor

@comcalvi comcalvi left a comment

Choose a reason for hiding this comment

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

This is a massive change to the generated code, so I think it would be worthwhile to add a test to confirm that the runtime checks being disabled produces no changes - what do you think?

Copy link
Contributor

@comcalvi comcalvi left a comment

Choose a reason for hiding this comment

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

one tiny cosmetic comment

# Conflicts:
#	packages/jsii-pacmak/test/generated-code/__snapshots__/target-dotnet.test.js.snap
#	packages/jsii-pacmak/test/generated-code/__snapshots__/target-go.test.js.snap
#	packages/jsii-pacmak/test/generated-code/__snapshots__/target-python.test.js.snap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution/core This is a PR that came from AWS. language/go Regarding GoLang bindings
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants