-
Notifications
You must be signed in to change notification settings - Fork 1.1k
handle export forwarders in Scala.js #12611
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
Conversation
47ffc63
to
61c5b5e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can an export
definition be annotated itself? If yes, we should also forbid JS annotations on export
s.
compiler/src/dotty/tools/dotc/transform/sjs/PrepJSInterop.scala
Outdated
Show resolved
Hide resolved
compiler/src/dotty/tools/dotc/transform/sjs/PrepJSInterop.scala
Outdated
Show resolved
Hide resolved
compiler/src/dotty/tools/dotc/transform/sjs/PrepJSInterop.scala
Outdated
Show resolved
Hide resolved
- prevent export forwarders in JS Native types - remove annotations js.native, js.annotation.* from export forwarders in PrepJSInterop
@sjrd I have added a 'hack' for detecting if we are in a non-native JS trait |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. The logic looks good now. I have mostly a suggestion to turn your "hack" into properly fitting in the design.
compiler/src/dotty/tools/dotc/transform/sjs/PrepJSInterop.scala
Outdated
Show resolved
Hide resolved
compiler/src/dotty/tools/dotc/transform/sjs/PrepJSInterop.scala
Outdated
Show resolved
Hide resolved
4cdd310
to
3a91c59
Compare
js.native
,js.annotation.*
from export forwardersin
PrepJSInterop
fixes #12111