You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This isn't quite right. The setEvent example which you changed should actually still work as shown in the current tutorial - we're only talking about disallowing returning a pony tuple from an FFI call.
So it's the getEvent example (that you didn't change) which will no longer work - it would need to be returning an EGLEvent* rather than an EGLEvent in order to work.
I recommend that we just remove the getEvent example, leave the setEvent example as is, and note that FFI calls which return structs by value are not portable enough and consistent enough across compilers to be supported. Perhaps we should also change the title of "pass C structs" to "pass C structs by value" to emphasize that there is another (non-tuple) mechanism for passing and returning structs by reference.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change reflects the changes about to be made in order to resolve ponylang/ponyc#1240