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

Add @_transparency attribute to reportIssue(_:_:) default implementation #140

Merged
merged 2 commits into from
Nov 12, 2024

Conversation

Killectro
Copy link
Contributor

@Killectro Killectro commented Nov 12, 2024

When integrating the latest versions into our app I noticed #139. The fix here is the copy the default protocol extension implementation of reportIssue(_:_:) (the one that takes an error as a parameter) inside _RuntimeWarningReporter and add the @_transparent attribute.

Verified in my work project that this works as expected! Photos are below (ignore the attributes parameter, that comes from our wrapper code around this library but doesn't affect the result)

Before After
image image

@Killectro Killectro changed the title Override reportIssue(_:_:) to add @_transparency attribute Override reportIssue(_:_:) to add @_transparency attribute for runtime warnings Nov 12, 2024
Comment on lines 93 to 94
@_transparent
public func reportIssue(
Copy link
Member

Choose a reason for hiding this comment

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

Instead of a new reportIssue can we just mark the existing one as @_transparent? That should also fix the problem.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That makes a lot more sense. Done!

@Killectro Killectro changed the title Override reportIssue(_:_:) to add @_transparency attribute for runtime warnings Add @_transparency attribute to reportIssue(_:_:) default conformance Nov 12, 2024
@Killectro Killectro changed the title Add @_transparency attribute to reportIssue(_:_:) default conformance Add @_transparency attribute to reportIssue(_:_:) default implementation Nov 12, 2024
@mbrandonw mbrandonw merged commit a3f634d into pointfreeco:main Nov 12, 2024
15 checks passed
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.

3 participants