Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(863)

Issue 676563002: Service Worker: Annotate IDLs with [TypeChecking] to turn it on (Closed)

Created:
6 years, 2 months ago by jsbell
Modified:
6 years, 2 months ago
Reviewers:
haraken
CC:
blink-reviews, michaeln, jsbell+serviceworker_chromium.org, kenjibaheux+watch_chromium.org, tzik, serviceworker-reviews, nhiroki, falken, kinuko+serviceworker, horo+watch_chromium.org, asanka, jkarlin, gavinp, kenjibaheux
Project:
blink
Visibility:
Public.

Description

Service Worker: Annotate IDLs with [TypeChecking] to turn it on We should be doing type checking everywhere, but for back-compat reasons Blink currently doesn't do "interface" or "unrestricted" enforcement. Turn it on for all the new SW interfaces (since there's no compat issue) and to fix a cache where Cache.put()'s second argument went unchecked. R=haraken@chromium.org BUG=426153 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=184295

Patch Set 1 #

Patch Set 2 : Remove dedicated test, enable test cases in cache-put #

Patch Set 3 : Remove TypeChecking=Unrestricted #

Unified diffs Side-by-side diffs Delta from patch set Stats (+31 lines, -22 lines) Patch
M LayoutTests/http/tests/serviceworker/cache-put-expected.txt View 1 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/http/tests/serviceworker/resources/cache-put-worker.js View 1 2 chunks +12 lines, -20 lines 0 comments Download
M Source/modules/serviceworkers/Body.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/Cache.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/CacheStorage.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ExtendableEvent.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/FetchEvent.idl View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M Source/modules/serviceworkers/Headers.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/InstallEvent.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/Request.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/Response.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorker.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerClient.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerClients.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerContainer.idl View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerGlobalScope.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/serviceworkers/ServiceWorkerRegistration.idl View 1 2 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 9 (1 generated)
jsbell
haraken@ - PTAL? The test case exercises the failure caught by asanka's tests in https://codereview.chromium.org/425413002/ ...
6 years, 2 months ago (2014-10-22 23:52:59 UTC) #1
haraken
I understand you need "TypeChecking=Interface", but why do you need "TypeChecking=Unrestricted"? LGTM to avoid overnight ...
6 years, 2 months ago (2014-10-23 00:43:51 UTC) #2
jsbell
On 2014/10/23 00:43:51, haraken wrote: > I understand you need "TypeChecking=Interface", but why do you ...
6 years, 2 months ago (2014-10-23 16:11:38 UTC) #3
haraken
On 2014/10/23 16:11:38, jsbell wrote: > On 2014/10/23 00:43:51, haraken wrote: > > I understand ...
6 years, 2 months ago (2014-10-23 16:15:19 UTC) #4
jsbell
On 2014/10/23 16:15:19, haraken wrote: > Is restricted double a legacy behavior? The opposite. Without ...
6 years, 2 months ago (2014-10-23 16:55:46 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/676563002/40001
6 years, 2 months ago (2014-10-23 16:58:51 UTC) #7
commit-bot: I haz the power
Committed patchset #3 (id:40001) as 184295
6 years, 2 months ago (2014-10-23 18:47:42 UTC) #8
haraken
6 years, 2 months ago (2014-10-23 23:33:14 UTC) #9
Message was sent while issue was closed.
On 2014/10/23 16:55:46, jsbell wrote:
> On 2014/10/23 16:15:19, haraken wrote:
> > Is restricted double a legacy behavior?
> 
> The opposite. Without [TypeChecking=Unrestricted] blink does not throw if
> Infinity or NaN is passed to foo(double d);. With [TypeChecking=Unrestricted],
> blink throws. If you want to not throw, an IDL should specify foo(unrestricted
> double d);
> 
> Since there's uncertainty - and since we probably won't add methods taking
> numbers here in the near future - I'll remove the 'Unrestricted'.

Makes sense, thanks for the clarification!

Powered by Google App Engine
This is Rietveld 408576698