WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
126644
Add WTF::StringView and use it for grammar checking
https://bugs.webkit.org/show_bug.cgi?id=126644
Summary
Add WTF::StringView and use it for grammar checking
Anders Carlsson
Reported
2014-01-08 09:10:21 PST
Add WTF::StringView and use it for grammar checking
Attachments
Patch
(28.29 KB, patch)
2014-01-08 09:23 PST
,
Anders Carlsson
no flags
Details
Formatted Diff
Diff
Patch
(28.62 KB, patch)
2014-01-08 09:29 PST
,
Anders Carlsson
no flags
Details
Formatted Diff
Diff
Patch
(28.65 KB, patch)
2014-01-08 11:26 PST
,
Anders Carlsson
koivisto
: review+
eflews.bot
: commit-queue-
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Anders Carlsson
Comment 1
2014-01-08 09:23:32 PST
Created
attachment 220638
[details]
Patch
WebKit Commit Bot
Comment 2
2014-01-08 09:24:24 PST
Attachment 220638
[details]
did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WTF/ChangeLog', u'Source/WTF/GNUmakefile.list.am', u'Source/WTF/WTF.vcxproj/WTF.vcxproj', u'Source/WTF/WTF.vcxproj/WTF.vcxproj.filters', u'Source/WTF/WTF.xcodeproj/project.pbxproj', u'Source/WTF/wtf/CMakeLists.txt', u'Source/WTF/wtf/Forward.h', u'Source/WTF/wtf/text/StringView.h', u'Source/WebCore/ChangeLog', u'Source/WebCore/editing/TextCheckingHelper.cpp', u'Source/WebCore/loader/EmptyClients.h', u'Source/WebCore/platform/text/TextCheckerClient.h', u'Source/WebKit/efl/ChangeLog', u'Source/WebKit/efl/WebCoreSupport/EditorClientEfl.h', u'Source/WebKit/mac/ChangeLog', u'Source/WebKit/mac/WebCoreSupport/WebEditorClient.h', u'Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm', u'Source/WebKit2/ChangeLog', u'Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp', u'Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.h', '--commit-queue']" exit_code: 1 ERROR: Source/WTF/wtf/text/StringView.h:27: StringView_h is incorrect. #defined constants should use all uppercase names with words separated by underscores. [readability/naming/define/constants] [4] Total errors found: 1 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
EFL EWS Bot
Comment 3
2014-01-08 09:29:09 PST
Comment on
attachment 220638
[details]
Patch
Attachment 220638
[details]
did not pass efl-ews (efl): Output:
http://webkit-queues.appspot.com/results/5268129038991360
Anders Carlsson
Comment 4
2014-01-08 09:29:22 PST
Created
attachment 220639
[details]
Patch
WebKit Commit Bot
Comment 5
2014-01-08 09:31:00 PST
Attachment 220639
[details]
did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WTF/ChangeLog', u'Source/WTF/GNUmakefile.list.am', u'Source/WTF/WTF.vcxproj/WTF.vcxproj', u'Source/WTF/WTF.vcxproj/WTF.vcxproj.filters', u'Source/WTF/WTF.xcodeproj/project.pbxproj', u'Source/WTF/wtf/CMakeLists.txt', u'Source/WTF/wtf/Forward.h', u'Source/WTF/wtf/text/StringView.h', u'Source/WebCore/ChangeLog', u'Source/WebCore/editing/TextCheckingHelper.cpp', u'Source/WebCore/loader/EmptyClients.h', u'Source/WebCore/platform/text/TextCheckerClient.h', u'Source/WebKit/efl/ChangeLog', u'Source/WebKit/efl/WebCoreSupport/EditorClientEfl.h', u'Source/WebKit/mac/ChangeLog', u'Source/WebKit/mac/WebCoreSupport/WebEditorClient.h', u'Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm', u'Source/WebKit2/ChangeLog', u'Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp', u'Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.h', '--commit-queue']" exit_code: 1 ERROR: Source/WTF/wtf/text/StringView.h:27: StringView_h is incorrect. #defined constants should use all uppercase names with words separated by underscores. [readability/naming/define/constants] [4] Total errors found: 1 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
Anders Carlsson
Comment 6
2014-01-08 09:34:34 PST
Comment on
attachment 220639
[details]
Patch Oops, this obviously won't work for 8-bit strings that can be 1-byte aligned.
Anders Carlsson
Comment 7
2014-01-08 11:26:09 PST
Created
attachment 220646
[details]
Patch
Antti Koivisto
Comment 8
2014-01-08 12:33:03 PST
Comment on
attachment 220646
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=220646&action=review
> Source/WTF/ChangeLog:11 > + Add a new StringView class which is an immutable reference to either an 8-bit or a 16-bit string. > + > + This makes it easier to pass substrings around without having to either copy string data > + or upconvert and use UChar pointers.
Might be good to mention std::string_view proposal since the name may be surprising.
> Source/WTF/wtf/text/StringView.h:36 > +// (This means that strings longer than 2 Gigabytes can not be represented. If that turns out to be > +// a problem we can investigate alternative solutions).
Those parentheses seem unnecessary.
EFL EWS Bot
Comment 9
2014-01-08 12:53:14 PST
Comment on
attachment 220646
[details]
Patch
Attachment 220646
[details]
did not pass efl-wk2-ews (efl-wk2): Output:
http://webkit-queues.appspot.com/results/5487205254430720
Anders Carlsson
Comment 10
2014-01-08 13:15:27 PST
Committed
r161518
: <
http://trac.webkit.org/changeset/161518
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug