WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
185621
Fix -Wreturn-std-move warnings in WebKit found by new clang compiler
https://bugs.webkit.org/show_bug.cgi?id=185621
Summary
Fix -Wreturn-std-move warnings in WebKit found by new clang compiler
David Kilzer (:ddkilzer)
Reported
2018-05-14 12:39:49 PDT
Building WebKit with a newer clang compiler enables a -Wreturn-std-move warning that catches cases where a parameter is passed by rvalue reference (T&& t), but then gets copied when returning that reference by value from the function (return t). For example, this method: String PeerConnectionBackend::filterSDP(String&& sdp) const generates a warning like this: In file included from DerivedSources/WebCore/unified-sources/UnifiedSource139.cpp:5: ./Modules/mediastream/PeerConnectionBackend.cpp:412:16: error: local variable 'sdp' will be copied despite being returned by name [-Werror,-Wreturn-std-move] return sdp; ^~~ ./Modules/mediastream/PeerConnectionBackend.cpp:412:16: note: call 'std::move' explicitly to avoid copying return sdp; ^~~ std::move(sdp) 1 error generated.
Attachments
Patch v1
(5.74 KB, patch)
2018-05-14 12:42 PDT
,
David Kilzer (:ddkilzer)
no flags
Details
Formatted Diff
Diff
Archive of layout-test-results from ews206 for win-future
(12.78 MB, application/zip)
2018-05-14 16:47 PDT
,
EWS Watchlist
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
David Kilzer (:ddkilzer)
Comment 1
2018-05-14 12:42:58 PDT
Created
attachment 340343
[details]
Patch v1
Radar WebKit Bug Importer
Comment 2
2018-05-14 14:07:44 PDT
<
rdar://problem/40232133
>
EWS Watchlist
Comment 3
2018-05-14 16:47:22 PDT
Comment on
attachment 340343
[details]
Patch v1
Attachment 340343
[details]
did not pass win-ews (win): Output:
http://webkit-queues.webkit.org/results/7682747
New failing tests: http/tests/security/canvas-remote-read-remote-video-blocked-no-crossorigin.html
EWS Watchlist
Comment 4
2018-05-14 16:47:33 PDT
Created
attachment 340377
[details]
Archive of layout-test-results from ews206 for win-future The attached test failures were seen while running run-webkit-tests on the win-ews. Bot: ews206 Port: win-future Platform: CYGWIN_NT-6.1-2.9.0-0.318-5-3-x86_64-64bit
WebKit Commit Bot
Comment 5
2018-05-15 03:24:29 PDT
Comment on
attachment 340343
[details]
Patch v1 Clearing flags on attachment: 340343 Committed
r231796
: <
https://trac.webkit.org/changeset/231796
>
WebKit Commit Bot
Comment 6
2018-05-15 03:24:31 PDT
All reviewed patches have been landed. Closing bug.
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