-
Notifications
You must be signed in to change notification settings - Fork 1.1k
inline delegate not working with opaque type #6802
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
Comments
The |
We decided that inline and opaque cannot be mixed. The example now produces this as first error:
|
This is a pity as it's likely people, (ie me), will want to combine opaque types and macros, for compile-time checked literal values. I hit the same issue today, and FWIW this illustrates a reasonable workaround I came to: |
Just hit this also. It is a shame these features don't compose. Is there documentation of which features don't compose? Like a matrix which shows which are prohibited? |
@odersky @nicolasstucki How long should we expect the limitation that opaque types and inline can't be combined, to last? Is it something that will be addressed in after 3.0? 3.1? I'm finding that I never use opaque types because of this limitation. |
@japgolly did you test the difference to see how much slower things are? I wonder if In banana-rdf we have built a framework allowing us to write code independently of the various implementations of RDF, so that we can switch between them with one line of code. Opaque types should help for there to be no leakage of the underlying implementations. But ideally we'd like to also use the relevant function calls from the underlying libraries directly. The lib covers Java, JS and should also come handy with native libs too. There are WASM RDF libs in the works. |
Note:opaque and inline can now work together. |
Ah latest beta? I'll switch. |
It was merged on June 17, so it should be in 3.02 RC-1. 3.02 final should
be released later this week.
#12815
…On Mon, Aug 30, 2021 at 10:36 AM Henry Story ***@***.***> wrote:
Ah latest beta? I'll switch.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6802 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGCKVRQVOKABTYIMMCQV33T7M7JFANCNFSM4H5OWG5A>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
--
Martin Odersky
Professor, Programming Methods Group (LAMP)
Faculty IC, EPFL
Station 14, Lausanne, Switzerland
|
Uh oh!
There was an error while loading. Please reload this page.
minimized code
error message
expectation
x1
should work because the implicit is in the companion objectx2
should work because we've explicitly imported delegatesThe text was updated successfully, but these errors were encountered: