Bug 140891 - Use std::forward() instead of WTF::move() in CSSPrimitiveValue::create(T&& value)
Summary: Use std::forward() instead of WTF::move() in CSSPrimitiveValue::create(T&& va...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords:
Depends on:
Blocks: 140577 140777
  Show dependency treegraph
 
Reported: 2015-01-26 11:13 PST by Chris Dumez
Modified: 2015-01-26 12:04 PST (History)
4 users (show)

See Also:


Attachments
Patch (3.47 KB, patch)
2015-01-26 11:15 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2015-01-26 11:13:08 PST
Use std::forward() instead of WTF::move() in CSSPrimitiveValue::create(T&& value) to make sure the argument is not unexpectedly moved when it shouldn't (like I experienced yesterday in Bug 140577).
Comment 1 Chris Dumez 2015-01-26 11:15:11 PST
Created attachment 245357 [details]
Patch
Comment 2 Chris Dumez 2015-01-26 11:20:07 PST
Darin, I verified that with this patch, the moving issue from yesterday is gone if I drop the const from "CSSFontFamily* fontFamily" member. Good thing I asked Anders about it today :)
Comment 3 WebKit Commit Bot 2015-01-26 12:04:40 PST
Comment on attachment 245357 [details]
Patch

Clearing flags on attachment: 245357

Committed r179131: <http://trac.webkit.org/changeset/179131>
Comment 4 WebKit Commit Bot 2015-01-26 12:04:46 PST
All reviewed patches have been landed.  Closing bug.