Closed
Bug 1017951
Opened 10 years ago
Closed 10 years ago
Prevent using [Pref] on names that are exposed to workers
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
RESOLVED
FIXED
mozilla34
People
(Reporter: ehsan.akhgari, Unassigned)
References
Details
Boris mentioned that these currently generate code which access the pref service from the worker. We should explicitly generate a WebIDL compiler error for now before someone starts to need it without realizing the implications.
![]() |
||
Comment 1•10 years ago
|
||
The problem is the codegen doesn't know what's exposed to workers....
Yeah, this is simply not possible today :( We do need to move the information about which interfaces are visible in workers into codegen eventually to generate RegisterBindings.cpp. Perhaps we should do that now.
Reporter | ||
Comment 3•10 years ago
|
||
(In reply to comment #1) > The problem is the codegen doesn't know what's exposed to workers.... Hmm, can't it check [ExposedTo] from the AST?
(In reply to :Ehsan Akhgari (lagging on bugmail, needinfo? me!) from comment #3) > (In reply to comment #1) > > The problem is the codegen doesn't know what's exposed to workers.... > > Hmm, can't it check [ExposedTo] from the AST? What is [ExposedTo]?
![]() |
||
Comment 5•10 years ago
|
||
> What is [ExposedTo]? Ehsan mean [Exposed], from <http://heycam.github.io/webidl/#Exposed>: A pretty new addition to the spec. But yes, we should implement [Exposed]. We can also use it to do things like skip codegen for some things on workers. That said, I think the current spec for [Exposed] is wrong in an obvious way. See https://www.w3.org/Bugs/Public/show_bug.cgi?id=25495
Reporter | ||
Comment 6•10 years ago
|
||
(In reply to Boris Zbarsky [:bz] from comment #5) > > What is [ExposedTo]? > > Ehsan mean [Exposed], from <http://heycam.github.io/webidl/#Exposed>: A > pretty new addition to the spec. > > But yes, we should implement [Exposed]. We can also use it to do things > like skip codegen for some things on workers. Ah, yeah, sorry I didn't realize that we haven't implemented that yet. And I got the name wrong too!! > That said, I think the current spec for [Exposed] is wrong in an obvious > way. See https://www.w3.org/Bugs/Public/show_bug.cgi?id=25495 Can we somehow help improve the situation there? I think supporting [Exposed] would be beneficial to the readability of our WebIDL files as well.
![]() |
||
Comment 7•10 years ago
|
||
I filed bug 1017988 on implementing [Exposed]. > Can we somehow help improve the situation there? https://github.com/heycam/webidl/pull/12
Reporter | ||
Comment 8•10 years ago
|
||
(In reply to comment #7) > I filed bug 1017988 on implementing [Exposed]. > > > Can we somehow help improve the situation there? > > https://github.com/heycam/webidl/pull/12 Thanks!
Reporter | ||
Comment 9•10 years ago
|
||
Is this possible to fix now?
![]() |
||
Comment 10•10 years ago
|
||
Bug 1017988 part 10 fixes it.
![]() |
||
Updated•10 years ago
|
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla34
Assignee | ||
Updated•5 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•