source: webkit/trunk/Source/WebCore/css/CSSVariableReferenceValue.cpp

Last change on this file was 293563, checked in by Chris Dumez, 3 years ago

Prepare more of the code base for making the AtomString(const String&) constructor explicit
https://bugs.webkit.org/show_bug.cgi?id=239711

Reviewed by Darin Adler.

Prepare more of the code base for making the AtomString(const String&) constructor explicit.
This helps us find cases where we atomize unnecessarily or not early enough, thus causing
unnecessary String allocations.

  • Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::didReceiveResponse):

  • Source/WebKit/NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.cpp:

(WebKit::ServiceWorkerFetchTask::processResponse):

  • Source/WebKit/WebProcess/WebPage/WebPage.cpp:

(WebKit::dumpHistoryItem):

  • Source/WTF/wtf/text/StringImpl.h:
  • Source/WebCore/Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::create):

  • Source/WebCore/Modules/highlight/HighlightRegister.cpp:

(WebCore::HighlightRegister::setFromMapLike):
(WebCore::HighlightRegister::remove):

  • Source/WebCore/Modules/highlight/HighlightRegister.h:

(WebCore::HighlightRegister::map const):

  • Source/WebCore/Modules/highlight/HighlightRegister.idl:
  • Source/WebCore/Modules/indexeddb/IDBVersionChangeEvent.idl:
  • Source/WebCore/Modules/mediastream/RTCDTMFToneChangeEvent.idl:
  • Source/WebCore/Modules/mediastream/RTCDataChannel.idl:
  • Source/WebCore/Modules/mediastream/RTCDataChannelEvent.idl:
  • Source/WebCore/Modules/pictureinpicture/PictureInPictureEvent.idl:
  • Source/WebCore/Modules/push-api/PushEvent.idl:
  • Source/WebCore/Modules/push-api/PushSubscriptionChangeEvent.idl:
  • Source/WebCore/Modules/speech/SpeechSynthesisErrorEvent.idl:
  • Source/WebCore/Modules/webaudio/AudioProcessingEvent.idl:
  • Source/WebCore/Modules/webaudio/OfflineAudioCompletionEvent.idl:
  • Source/WebCore/Modules/websockets/WebSocketHandshake.cpp:

(WebCore::WebSocketHandshake::readServerHandshake):
(WebCore::WebSocketHandshake::readStatusLine):

  • Source/WebCore/Modules/websockets/WebSocketHandshake.h:
  • Source/WebCore/animation/AnimationPlaybackEvent.idl:
  • Source/WebCore/css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::customPropertyValue):
(WebCore::ComputedStyleExtractor::customPropertyText):

  • Source/WebCore/css/CSSComputedStyleDeclaration.h:
  • Source/WebCore/css/CSSVariableReferenceValue.cpp:

(WebCore::resolveVariableReference):

  • Source/WebCore/css/ContainerQueryParser.cpp:

(WebCore::ContainerQueryParser::consumeFilteredContainerQuery):
(WebCore::consumeFeatureName):

  • Source/WebCore/css/parser/CSSParserImpl.cpp:

(WebCore::CSSParserImpl::consumeFontPaletteValuesRule):
(WebCore::CSSParserImpl::consumeKeyframesRule):

  • Source/WebCore/css/parser/CSSParserSelector.cpp:

(WebCore::CSSParserSelector::parsePseudoElementSelector):
(WebCore::CSSParserSelector::parsePseudoClassSelector):

  • Source/WebCore/css/typedom/CSSStyleValue.cpp:

(WebCore::CSSStyleValue::parse):
(WebCore::CSSStyleValue::parseAll):

  • Source/WebCore/css/typedom/CSSStyleValue.h:
  • Source/WebCore/css/typedom/CSSStyleValue.idl:
  • Source/WebCore/css/typedom/CSSStyleValueFactory.cpp:

(WebCore::CSSStyleValueFactory::extractCustomCSSValues):
(WebCore::CSSStyleValueFactory::parseStyleValue):

  • Source/WebCore/css/typedom/CSSStyleValueFactory.h:
  • Source/WebCore/css/typedom/ComputedStylePropertyMapReadOnly.cpp:

(WebCore::ComputedStylePropertyMapReadOnly::get const):
(WebCore::ComputedStylePropertyMapReadOnly::getAll const):
(WebCore::ComputedStylePropertyMapReadOnly::has const):

  • Source/WebCore/css/typedom/ComputedStylePropertyMapReadOnly.h:
  • Source/WebCore/css/typedom/StylePropertyMapReadOnly.h:
  • Source/WebCore/css/typedom/StylePropertyMapReadOnly.idl:
  • Source/WebCore/dom/AnimationEvent.idl:
  • Source/WebCore/dom/Document.cpp:

(WebCore::Document::setContentLanguage):
(WebCore::Document::processMetaHttpEquiv):

  • Source/WebCore/dom/Document.h:

(WebCore::Document::contentLanguage const):
(WebCore::Document::baseTarget const):

  • Source/WebCore/dom/Element.h:

(WebCore::Element::target const):

  • Source/WebCore/dom/KeyboardEvent.cpp:

(WebCore::KeyboardEvent::KeyboardEvent):
(WebCore::KeyboardEvent::initKeyboardEvent):

  • Source/WebCore/dom/KeyboardEvent.h:
  • Source/WebCore/dom/KeyboardEvent.idl:
  • Source/WebCore/dom/PointerEvent.cpp:

(WebCore::PointerEvent::create):

  • Source/WebCore/dom/PointerEvent.h:
  • Source/WebCore/dom/PopStateEvent.idl:
  • Source/WebCore/dom/ScriptElement.cpp:

(WebCore::ScriptElement::requestModuleScript):

  • Source/WebCore/dom/StyledElement.cpp:
  • Source/WebCore/history/HistoryItem.cpp:

(WebCore::HistoryItem::reset):
(WebCore::HistoryItem::target const):
(WebCore::HistoryItem::setTarget):
(WebCore::HistoryItem::childItemWithTarget):

  • Source/WebCore/history/HistoryItem.h:
  • Source/WebCore/html/Autofill.cpp:

(WebCore::AutofillData::createFromHTMLFormControlElement):

  • Source/WebCore/html/BaseButtonInputType.cpp:

(WebCore::BaseButtonInputType::setValue):

  • Source/WebCore/html/BaseCheckableInputType.cpp:

(WebCore::BaseCheckableInputType::setValue):

  • Source/WebCore/html/BaseDateAndTimeInputType.cpp:

(WebCore::BaseDateAndTimeInputType::setupDateTimeChooserParameters):

  • Source/WebCore/html/CustomPaintImage.cpp:

(WebCore::extractComputedProperty):
(WebCore::CustomPaintImage::doCustomPaint):

  • Source/WebCore/html/CustomPaintImage.h:
  • Source/WebCore/html/HTMLAnchorElement.cpp:

(WebCore::HTMLAnchorElement::target const):
(WebCore::HTMLAnchorElement::effectiveTarget const):

  • Source/WebCore/html/HTMLAnchorElement.h:
  • Source/WebCore/html/HTMLAreaElement.cpp:

(WebCore::HTMLAreaElement::target const):

  • Source/WebCore/html/HTMLAreaElement.h:
  • Source/WebCore/html/HTMLBaseElement.cpp:

(WebCore::HTMLBaseElement::target const):

  • Source/WebCore/html/HTMLBaseElement.h:
  • Source/WebCore/html/HTMLFormElement.cpp:

(WebCore::HTMLFormElement::target const):
(WebCore::HTMLFormElement::effectiveTarget const):

  • Source/WebCore/html/HTMLFormElement.h:
  • Source/WebCore/html/HTMLHtmlElement.idl:
  • Source/WebCore/html/HTMLIFrameElement.idl:
  • Source/WebCore/html/HTMLImageElement.idl:
  • Source/WebCore/html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::target const):

  • Source/WebCore/html/HTMLLinkElement.h:
  • Source/WebCore/html/track/AudioTrack.idl:
  • Source/WebCore/inspector/agents/InspectorNetworkAgent.cpp:
  • Source/WebCore/loader/CrossOriginPreflightChecker.cpp:

(WebCore::CrossOriginPreflightChecker::startPreflight):

  • Source/WebCore/loader/DocumentThreadableLoader.cpp:

(WebCore::DocumentThreadableLoader::loadRequest):

  • Source/WebCore/loader/FormSubmission.cpp:

(WebCore::FormSubmission::FormSubmission):

  • Source/WebCore/loader/FormSubmission.h:

(WebCore::FormSubmission::Attributes::target const):
(WebCore::FormSubmission::Attributes::setTarget):
(WebCore::FormSubmission::target const):

  • Source/WebCore/loader/FrameLoadRequest.cpp:

(WebCore::FrameLoadRequest::FrameLoadRequest):

  • Source/WebCore/loader/FrameLoadRequest.h:

(WebCore::FrameLoadRequest::FrameLoadRequest):
(WebCore::FrameLoadRequest::frameName const):
(WebCore::FrameLoadRequest::setFrameName):

  • Source/WebCore/loader/FrameLoader.cpp:

(WebCore::FrameLoader::changeLocation):
(WebCore::extractContentLanguageFromHeader):
(WebCore::FrameLoader::didBeginDocument):
(WebCore::FrameLoader::loadURL):
(WebCore::FrameLoader::loadPostRequest):
(WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):

  • Source/WebCore/loader/FrameLoader.h:
  • Source/WebCore/loader/HistoryController.cpp:

(WebCore::FrameLoader::HistoryController::recursiveGoToItem):

  • Source/WebCore/loader/LinkLoader.cpp:

(WebCore::LinkLoader::preloadIfNeeded):

  • Source/WebCore/loader/appcache/ApplicationCacheStorage.cpp:

(WebCore::ApplicationCacheStorage::shouldStoreResourceAsFlatFile):

  • Source/WebCore/page/DOMWindow.cpp:

(WebCore::DOMWindow::name const):
(WebCore::DOMWindow::setName):

  • Source/WebCore/page/DOMWindow.h:
  • Source/WebCore/page/DOMWindow.idl:
  • Source/WebCore/page/DragController.cpp:

(WebCore::documentFragmentFromDragData):

  • Source/WebCore/page/ModalContainerObserver.h:

(WebCore::ModalContainerObserver::overrideSearchTermForTesting):

  • Source/WebCore/page/Navigator.cpp:

(WebCore::Navigator::initializePluginAndMimeTypeArrays):

  • Source/WebCore/page/PageSerializer.cpp:

(WebCore::PageSerializer::SerializerMarkupAccumulator::appendCustomAttributes):

  • Source/WebCore/page/Quirks.cpp:

(WebCore::Quirks::triggerOptionalStorageAccessQuirk const):

  • Source/WebCore/platform/graphics/FontCache.cpp:

(WebCore::FontCache::cachedFontPlatformData):

  • Source/WebCore/platform/graphics/FontDescription.cpp:

(WebCore::computeSpecializedChineseLocale):

  • Source/WebCore/platform/graphics/MediaPlayer.cpp:

(WebCore::MediaPlayer::load):
(WebCore::MediaPlayer::supportsType):

  • Source/WebCore/platform/graphics/cocoa/FontDescriptionCocoa.cpp:

(WebCore::FontDescription::platformResolveGenericFamily):

  • Source/WebCore/platform/graphics/filters/FilterOperation.cpp:

(WebCore::ReferenceFilterOperation::ReferenceFilterOperation):

  • Source/WebCore/platform/graphics/filters/FilterOperation.h:

(WebCore::ReferenceFilterOperation::create):
(WebCore::ReferenceFilterOperation::fragment const):

  • Source/WebCore/platform/mediastream/cocoa/DisplayCaptureSourceCocoa.cpp:

(WebCore::DisplayCaptureSourceCocoa::settings):

  • Source/WebCore/platform/mediastream/mac/CoreAudioCaptureSource.cpp:

(WebCore::CoreAudioCaptureSource::capabilities):
(WebCore::CoreAudioCaptureSource::settings):

  • Source/WebCore/platform/mock/MockRealtimeAudioSource.cpp:

(WebCore::MockRealtimeAudioSource::settings):
(WebCore::MockRealtimeAudioSource::capabilities):

  • Source/WebCore/platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::capabilities):
(WebCore::MockRealtimeVideoSource::settings):

  • Source/WebCore/platform/mock/mediasource/MockSourceBufferPrivate.cpp:
  • Source/WebCore/platform/network/ResourceHandle.cpp:

(WebCore::ResourceHandle::create):
(WebCore::ResourceHandle::loadResourceSynchronously):

  • Source/WebCore/platform/network/ResourceResponseBase.cpp:

(WebCore::ResourceResponseBase::crossThreadData const):
(WebCore::ResourceResponseBase::fromCrossThreadData):
(WebCore::ResourceResponseBase::mimeType const):
(WebCore::ResourceResponseBase::setMimeType):
(WebCore::ResourceResponseBase::textEncodingName const):
(WebCore::ResourceResponseBase::setTextEncodingName):
(WebCore::ResourceResponseBase::httpVersion const):
(WebCore::ResourceResponseBase::setHTTPVersion):

  • Source/WebCore/platform/network/ResourceResponseBase.h:
  • Source/WebCore/plugins/DOMMimeType.cpp:

(WebCore::DOMMimeType::type const):

  • Source/WebCore/plugins/DOMMimeType.h:
  • Source/WebCore/plugins/DOMPlugin.cpp:

(WebCore::DOMPlugin::supportedPropertyNames const):

  • Source/WebCore/plugins/DOMPluginArray.cpp:

(WebCore::DOMPluginArray::supportedPropertyNames const):

  • Source/WebCore/plugins/PluginData.h:
  • Source/WebCore/rendering/MarkedText.h:
  • Source/WebCore/rendering/PathOperation.cpp:

(WebCore::ReferencePathOperation::create):
(WebCore::ReferencePathOperation::ReferencePathOperation):

  • Source/WebCore/rendering/PathOperation.h:
  • Source/WebCore/rendering/style/RenderStyle.cpp:

(WebCore::RenderStyle::addCustomPaintWatchProperty):

  • Source/WebCore/rendering/style/RenderStyle.h:
  • Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp:

(WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):

  • Source/WebCore/rendering/style/StyleRareNonInheritedData.h:
  • Source/WebCore/style/RuleSetBuilder.cpp:

(WebCore::Style::RuleSetBuilder::pushCascadeLayer):

  • Source/WebCore/style/StyleBuilder.cpp:

(WebCore::Style::Builder::applyCustomProperty):

  • Source/WebCore/style/StyleBuilder.h:
  • Source/WebCore/style/StyleBuilderConverter.h:

(WebCore::Style::BuilderConverter::convertPathOperation):

  • Source/WebCore/style/StyleBuilderCustom.h:

(WebCore::Style::BuilderCustom::applyValueListStyleType):
(WebCore::Style::BuilderCustom::applyValueWebkitLocale):
(WebCore::Style::BuilderCustom::applyValueFontFamily):
(WebCore::Style::BuilderCustom::applyValueTextEmphasisStyle):
(WebCore::Style::BuilderCustom::applyValueCounter):
(WebCore::Style::BuilderCustom::applyValueAlt):

  • Source/WebCore/style/StyleBuilderState.cpp:

(WebCore::Style::BuilderState::createFilterOperations):

  • Source/WebCore/svg/SVGAElement.cpp:

(WebCore::SVGAElement::defaultEventHandler):

  • Source/WebCore/svg/SVGAElement.h:
  • Source/WebCore/svg/SVGElement.cpp:

(WebCore::SVGElement::synchronizeAttribute):
(WebCore::SVGElement::synchronizeAllAttributes):
(WebCore::SVGElement::commitPropertyChange):
(WebCore::SVGElement::insertedIntoAncestor):
(WebCore::SVGElement::buildPendingResourcesIfNeeded):

  • Source/WebCore/svg/SVGElement.h:

(WebCore::SVGElement::className const):

  • Source/WebCore/svg/SVGURIReference.cpp:

(WebCore::SVGURIReference::fragmentIdentifierFromIRIString):
(WebCore::SVGURIReference::targetElementFromIRIString):

  • Source/WebCore/svg/SVGURIReference.h:
  • Source/WebCore/svg/SVGUseElement.cpp:

(WebCore::SVGUseElement::updateUserAgentShadowTree):
(WebCore::SVGUseElement::findTarget const):

  • Source/WebCore/svg/SVGUseElement.h:
  • Source/WebCore/svg/animation/SVGSMILElement.cpp:

(WebCore::SVGSMILElement::Condition::Condition):
(WebCore::SVGSMILElement::buildPendingResource):
(WebCore::SVGSMILElement::parseCondition):

  • Source/WebCore/svg/animation/SVGSMILElement.h:
  • Source/WebCore/svg/graphics/filters/SVGFilterBuilder.cpp:

(WebCore::SVGFilterBuilder::calculateFilterOutsets):

  • Source/WebCore/testing/Internals.cpp:

(WebCore::Internals::overrideModalContainerSearchTermForTesting):

  • Source/WebCore/testing/Internals.h:
  • Source/WebCore/testing/Internals.idl:
  • Source/WebCore/worklets/PaintWorkletGlobalScope.cpp:

(WebCore::PaintWorkletGlobalScope::PaintDefinition::PaintDefinition):
(WebCore::PaintWorkletGlobalScope::registerPaint):

  • Source/WebCore/worklets/PaintWorkletGlobalScope.h:
  • Source/WebCore/worklets/PaintWorkletGlobalScope.idl:
  • Source/WebCore/xml/CustomXPathNSResolver.cpp:

(WebCore::CustomXPathNSResolver::lookupNamespaceURI):

  • Source/WebCore/xml/XPathGrammar.cpp:
  • Source/WebCore/xml/XPathParser.cpp:

(WebCore::XPath::Parser::expandQualifiedName):

  • Source/WebCore/xml/XPathParser.h:

Canonical link: https://commits.webkit.org/250077@main

File size: 5.7 KB
Line 
1// Copyright 2015 The Chromium Authors. All rights reserved.
2// Copyright (C) 2016-2021 Apple Inc. All rights reserved.
3//
4// Redistribution and use in source and binary forms, with or without
5// modification, are permitted provided that the following conditions are
6// met:
7//
8// * Redistributions of source code must retain the above copyright
9// notice, this list of conditions and the following disclaimer.
10// * Redistributions in binary form must reproduce the above
11// copyright notice, this list of conditions and the following disclaimer
12// in the documentation and/or other materials provided with the
13// distribution.
14// * Neither the name of Google Inc. nor the names of its
15// contributors may be used to endorse or promote products derived from
16// this software without specific prior written permission.
17//
18// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
21// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29
30#include "config.h"
31#include "CSSVariableReferenceValue.h"
32
33#include "CSSVariableData.h"
34#include "ConstantPropertyMap.h"
35#include "RenderStyle.h"
36#include "StyleBuilder.h"
37#include "StyleResolver.h"
38
39namespace WebCore {
40
41static bool resolveTokenRange(CSSParserTokenRange, Vector<CSSParserToken>&, Style::BuilderState&);
42
43CSSVariableReferenceValue::CSSVariableReferenceValue(Ref<CSSVariableData>&& data, const CSSParserContext& context)
44 : CSSValue(VariableReferenceClass)
45 , m_data(WTFMove(data))
46 , m_context(context)
47{
48}
49
50Ref<CSSVariableReferenceValue> CSSVariableReferenceValue::create(const CSSParserTokenRange& range, const CSSParserContext& context)
51{
52 return adoptRef(*new CSSVariableReferenceValue(CSSVariableData::create(range), context));
53}
54
55Ref<CSSVariableReferenceValue> CSSVariableReferenceValue::create(Ref<CSSVariableData>&& data, const CSSParserContext& context)
56{
57 return adoptRef(*new CSSVariableReferenceValue(WTFMove(data), context));
58}
59
60bool CSSVariableReferenceValue::equals(const CSSVariableReferenceValue& other) const
61{
62 return m_data.get() == other.m_data.get();
63}
64
65String CSSVariableReferenceValue::customCSSText() const
66{
67 if (m_stringValue.isNull())
68 m_stringValue = m_data->tokenRange().serialize();
69 return m_stringValue;
70}
71
72static bool resolveVariableFallback(CSSParserTokenRange range, Vector<CSSParserToken>& result, Style::BuilderState& builderState)
73{
74 if (range.atEnd())
75 return false;
76 ASSERT(range.peek().type() == CommaToken);
77 range.consumeIncludingWhitespace();
78 return resolveTokenRange(range, result, builderState);
79}
80
81static bool resolveVariableReference(CSSParserTokenRange range, CSSValueID functionId, Vector<CSSParserToken>& result, Style::BuilderState& builderState)
82{
83 ASSERT(functionId == CSSValueVar || functionId == CSSValueEnv);
84
85 auto& registeredProperties = builderState.document().getCSSRegisteredCustomPropertySet();
86 auto& style = builderState.style();
87
88 range.consumeWhitespace();
89 ASSERT(range.peek().type() == IdentToken);
90 auto variableName = range.consumeIncludingWhitespace().value().toAtomString();
91 ASSERT(range.atEnd() || (range.peek().type() == CommaToken));
92
93 // Apply this variable first, in case it is still unresolved
94 builderState.builder().applyCustomProperty(variableName);
95
96 // Apply fallback to detect cycles
97 Vector<CSSParserToken> fallbackResult;
98 bool fallbackReturn = resolveVariableFallback(CSSParserTokenRange(range), fallbackResult, builderState);
99
100
101 auto* property = functionId == CSSValueVar
102 ? style.getCustomProperty(variableName)
103 : builderState.document().constantProperties().values().get(variableName);
104 if (!property || property->isUnset()) {
105 auto* registered = registeredProperties.get(variableName);
106 if (registered && registered->initialValue())
107 property = registered->initialValue();
108 }
109
110 if (!property || property->isInvalid()) {
111 if (fallbackResult.size() > CSSVariableReferenceValue::maxSubstitutionTokens)
112 return false;
113
114 if (fallbackReturn)
115 result.appendVector(fallbackResult);
116 return fallbackReturn;
117 }
118
119 ASSERT(property->isResolved());
120 if (property->tokens().size() > CSSVariableReferenceValue::maxSubstitutionTokens)
121 return false;
122
123 result.appendVector(property->tokens());
124 return true;
125}
126
127static bool resolveTokenRange(CSSParserTokenRange range, Vector<CSSParserToken>& result, Style::BuilderState& builderState)
128{
129 bool success = true;
130 while (!range.atEnd()) {
131 auto functionId = range.peek().functionId();
132 if (functionId == CSSValueVar || functionId == CSSValueEnv)
133 success &= resolveVariableReference(range.consumeBlock(), functionId, result, builderState);
134 else
135 result.append(range.consume());
136 }
137 return success;
138}
139
140RefPtr<CSSVariableData> CSSVariableReferenceValue::resolveVariableReferences(Style::BuilderState& builderState) const
141{
142 Vector<CSSParserToken> resolvedTokens;
143 if (!resolveTokenRange(m_data->tokenRange(), resolvedTokens, builderState))
144 return nullptr;
145
146 return CSSVariableData::create(resolvedTokens);
147}
148
149} // namespace WebCore
Note: See TracBrowser for help on using the repository browser.