Bug 91408 - IndexedDB: Add intVersion to chromium/public/WebIDBMetadata.h
Summary: IndexedDB: Add intVersion to chromium/public/WebIDBMetadata.h
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: David Grogan
URL:
Keywords:
Depends on:
Blocks: 91414
  Show dependency treegraph
 
Reported: 2012-07-16 11:15 PDT by David Grogan
Modified: 2012-07-18 18:31 PDT (History)
9 users (show)

See Also:


Attachments
Patch (1.36 KB, patch)
2012-07-16 11:19 PDT, David Grogan
no flags Details | Formatted Diff | Diff
Patch (1.54 KB, patch)
2012-07-16 11:36 PDT, David Grogan
no flags Details | Formatted Diff | Diff
Patch (1.79 KB, patch)
2012-07-16 14:17 PDT, David Grogan
no flags Details | Formatted Diff | Diff
Patch for landing (2.00 KB, patch)
2012-07-17 15:18 PDT, David Grogan
no flags Details | Formatted Diff | Diff
Patch (3.39 KB, patch)
2012-07-18 15:48 PDT, David Grogan
no flags Details | Formatted Diff | Diff
Patch (1.96 KB, patch)
2012-07-18 17:41 PDT, David Grogan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Grogan 2012-07-16 11:15:51 PDT
IndexedDB: Add intVersion to chromium/public/WebIDBMetadata.h
Comment 1 David Grogan 2012-07-16 11:19:36 PDT
Created attachment 152570 [details]
Patch
Comment 2 David Grogan 2012-07-16 11:20:28 PDT
Josh or Alec, could you look at this?
Comment 3 WebKit Review Bot 2012-07-16 11:24:05 PDT
Please wait for approval from abarth@webkit.org, dglazkov@chromium.org, fishd@chromium.org, jamesr@chromium.org or tkent@chromium.org before submitting, as this patch contains changes to the Chromium public API. See also https://trac.webkit.org/wiki/ChromiumWebKitAPI.
Comment 4 Joshua Bell 2012-07-16 11:25:57 PDT
Comment on attachment 152570 [details]
Patch

LGTM
Comment 5 David Grogan 2012-07-16 11:36:52 PDT
Created attachment 152573 [details]
Patch
Comment 6 Darin Fisher (:fishd, Google) 2012-07-16 13:36:54 PDT
Comment on attachment 152573 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=152573&action=review

> Source/WebKit/chromium/public/WebIDBMetadata.h:48
>      WebIDBMetadata() { }

perhaps you should initialize intVersion?  it is good practice for
default constructors to initialize integer fields, etc.
Comment 7 David Grogan 2012-07-16 14:17:40 PDT
Created attachment 152609 [details]
Patch
Comment 8 David Grogan 2012-07-16 14:19:25 PDT
Comment on attachment 152573 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=152573&action=review

>> Source/WebKit/chromium/public/WebIDBMetadata.h:48
>>      WebIDBMetadata() { }
> 
> perhaps you should initialize intVersion?  it is good practice for
> default constructors to initialize integer fields, etc.

Sounds good.  Done.
Comment 9 David Grogan 2012-07-17 14:32:43 PDT
Comment on attachment 152609 [details]
Patch

ping fishd / other WebKit API reviewers
Comment 10 Adam Barth 2012-07-17 15:06:18 PDT
Comment on attachment 152609 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=152609&action=review

> Source/WebKit/chromium/public/WebIDBMetadata.h:49
>      WebString version;
> +    int64_t intVersion;

Is the plan to delete version and rename intVersion to version at some point?  I wonder if it make sense to add a macro for selecting between the two?  Maybe add a FIXME explaining your future plans?
Comment 11 David Grogan 2012-07-17 15:15:47 PDT
Comment on attachment 152609 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=152609&action=review

>> Source/WebKit/chromium/public/WebIDBMetadata.h:49
>> +    int64_t intVersion;
> 
> Is the plan to delete version and rename intVersion to version at some point?  I wonder if it make sense to add a macro for selecting between the two?  Maybe add a FIXME explaining your future plans?

The plan is to delete version, but not necessarily to rename intVersion.  A macro seems like overkill, but a FIXME would be prudent.  Coming up.
Comment 12 David Grogan 2012-07-17 15:18:22 PDT
Created attachment 152844 [details]
Patch for landing
Comment 13 WebKit Review Bot 2012-07-17 16:04:58 PDT
Comment on attachment 152844 [details]
Patch for landing

Clearing flags on attachment: 152844

Committed r122884: <http://trac.webkit.org/changeset/122884>
Comment 14 WebKit Review Bot 2012-07-17 16:05:04 PDT
All reviewed patches have been landed.  Closing bug.
Comment 15 Tony Chang 2012-07-17 16:45:11 PDT
This appears to be causing compile failures on Windows:
7>  WebIDBMetadata.cpp
7>C:\b\build\slave\webkit-win-latest-rel\build\src\third_party\WebKit\Source\WebKit\chromium\public\WebIDBMetadata.h(52): error C2146: syntax error : missing ';' before identifier 'intVersion'
7>C:\b\build\slave\webkit-win-latest-rel\build\src\third_party\WebKit\Source\WebKit\chromium\public\WebIDBMetadata.h(52): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
7>C:\b\build\slave\webkit-win-latest-rel\build\src\third_party\WebKit\Source\WebKit\chromium\public\WebIDBMetadata.h(52): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
7>C:\b\build\slave\webkit-win-latest-rel\build\src\third_party\WebKit\Source\WebKit\chromium\public\WebIDBMetadata.h(54): error C2614: 'WebKit::WebIDBMetadata' : illegal member initialization: 'intVersion' is not a base or member
7>c:\b\build\slave\webkit-win-latest-rel\build\src\third_party\webkit\source\webkit\chromium\public\WebIDBMetadata.h(52): error C2146: syntax error : missing ';' before identifier 'intVersion'
7>c:\b\build\slave\webkit-win-latest-rel\build\src\third_party\webkit\source\webkit\chromium\public\WebIDBMetadata.h(52): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
7>c:\b\build\slave\webkit-win-latest-rel\build\src\third_party\webkit\source\webkit\chromium\public\WebIDBMetadata.h(52): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
7>c:\b\build\slave\webkit-win-latest-rel\build\src\third_party\webkit\source\webkit\chromium\public\WebIDBMetadata.h(54): error C2614: 'WebKit::WebIDBMetadata' : illegal member initialization: 'intVersion' is not a base or member
7
Comment 16 Tony Chang 2012-07-17 17:03:41 PDT
Reverted r122884 for reason:

Broke the chromium-win build.

Committed r122898: <http://trac.webkit.org/changeset/122898>
Comment 17 David Grogan 2012-07-18 15:48:43 PDT
Created attachment 153115 [details]
Patch
Comment 18 David Grogan 2012-07-18 15:52:04 PDT
Comment on attachment 153115 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=153115&action=review

> Source/Platform/chromium/public/WebCommon.h:77
> +typedef __int64 int64_t;

The windows try server suggests this will fix the problem:

original patch fails compile: http://build.chromium.org/p/tryserver.chromium/builders/win_layout_rel/builds/519
patch with typedef compiles fine: http://build.chromium.org/p/tryserver.chromium/builders/win_layout_rel/builds/520
Comment 19 WebKit Review Bot 2012-07-18 15:52:18 PDT
Attachment 153115 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/Platform/ChangeLog', u'Source/Platf..." exit_code: 1
Source/Platform/chromium/public/WebCommon.h:77:  int64_t is incorrectly named. Don't use underscores in your identifier names.  [readability/naming] [4]
Total errors found: 1 in 4 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 20 David Grogan 2012-07-18 16:22:14 PDT
(In reply to comment #19)
> Attachment 153115 [details] did not pass style-queue:
> 
> Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/Platform/ChangeLog', u'Source/Platf..." exit_code: 1
> Source/Platform/chromium/public/WebCommon.h:77:  int64_t is incorrectly named. Don't use underscores in your identifier names.  [readability/naming] [4]
> Total errors found: 1 in 4 files
> 
> 
> If any of these errors are false positives, please file a bug against check-webkit-style.

Done: https://bugs.webkit.org/show_bug.cgi?id=91691
Comment 21 David Grogan 2012-07-18 16:24:19 PDT
Comment on attachment 153115 [details]
Patch

Adam, could you review this patch (again)?  Thanks.
Comment 22 Adam Barth 2012-07-18 16:29:07 PDT
Comment on attachment 153115 [details]
Patch

We must use 64-bit numbers in the WebKit API.  I'm surprised that we'd need this typedef.
Comment 23 Adam Barth 2012-07-18 16:29:54 PDT
Looks like we use "long long" for 64 bit ints.
Comment 24 Adam Barth 2012-07-18 16:30:19 PDT
e.g., WebFrame::identifier()
Comment 25 David Grogan 2012-07-18 17:41:49 PDT
Created attachment 153147 [details]
Patch
Comment 26 David Grogan 2012-07-18 17:44:51 PDT
(In reply to comment #23)
> Looks like we use "long long" for 64 bit ints.

Switched to long long.  Another look?
Comment 27 WebKit Review Bot 2012-07-18 18:31:53 PDT
Comment on attachment 153147 [details]
Patch

Clearing flags on attachment: 153147

Committed r123059: <http://trac.webkit.org/changeset/123059>
Comment 28 WebKit Review Bot 2012-07-18 18:31:59 PDT
All reviewed patches have been landed.  Closing bug.