| Index: third_party/WebKit/Source/bindings/core/v8/ScriptSourceCode.cpp
|
| diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptSourceCode.cpp b/third_party/WebKit/Source/bindings/core/v8/ScriptSourceCode.cpp
|
| index 306d636b949661b5bec92ae512876d50336d40cd..d037c78f605f20a1dbeeeb4efc843bde2f30df28 100644
|
| --- a/third_party/WebKit/Source/bindings/core/v8/ScriptSourceCode.cpp
|
| +++ b/third_party/WebKit/Source/bindings/core/v8/ScriptSourceCode.cpp
|
| @@ -14,6 +14,11 @@ ScriptSourceCode::ScriptSourceCode()
|
| }
|
|
|
| ScriptSourceCode::ScriptSourceCode(const String& source, const KURL& url, const TextPosition& startPosition)
|
| + : ScriptSourceCode(CompressableString(source.impl()), url, startPosition)
|
| +{
|
| +}
|
| +
|
| +ScriptSourceCode::ScriptSourceCode(const CompressableString& source, const KURL& url, const TextPosition& startPosition)
|
| : m_source(source)
|
| , m_resource(0)
|
| , m_url(url)
|
| @@ -76,14 +81,14 @@ String ScriptSourceCode::sourceMapUrl() const
|
| void ScriptSourceCode::treatNullSourceAsEmpty()
|
| {
|
| // ScriptSourceCode allows for the representation of the null/not-there-really ScriptSourceCode value.
|
| - // Encoded by way of a m_source.isNull() being true, with the nullary constructor to be used to
|
| + // Encoded by way of a m_source->isNull() being true, with the nullary constructor to be used to
|
| // construct such a value.
|
| //
|
| // Should the other constructors be passed a null string, that is interpreted as representing
|
| // the empty script. Consequently, we need to disambiguate between such null string occurrences.
|
| // Do that by converting the latter case's null strings into empty ones.
|
| if (m_source.isNull())
|
| - m_source = "";
|
| + m_source = CompressableString(StringImpl::empty());
|
| }
|
|
|
| } // namespace blink
|
|
|