Chromium Code Reviews
DescriptionUse std::string instead of WebString in WebRuntimeFeatures
The reason why I want to make this change comes from following facts:
- WebString's internal implementation is String, and String uses
PartitionAlloc to acquire memory.
- PartitonAlloc must be initialized before any memory allocation.
blink::initalize() does the job.
- On the other hand, runtime features needs to be enabled/disabled before
blink::initalize() because Blink's initialization logic depends on the
configuration. WebRuntimeFeature provides APIs to enable/disable
features and it depends on WebString. Conflict happens.
By using std::string instead of WebString, we can avoid this problem
because std::string doesn't depend on PartitionAlloc.
We could take other options to fix this problem. For example, we can
separate initialization into 2 phases. I didn't take this approach
because it makes Blink API use be complicated.
BUG=501171
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=199972
Patch Set 1 : #
Messages
Total messages: 11 (3 generated)
|
||||||||||||||||||||||||||||||||||||||||||||||