-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Drop StringView constructors taking in raw pointers
https://bugs.webkit.org/show_bug.cgi?id=271512 Reviewed by Darin Adler and Sihui Liu. Drop StringView constructors taking in raw pointers, in favor of the ones taking in a std::span. * Source/JavaScriptCore/runtime/ArrayPrototype.cpp: (JSC::JSC_DEFINE_HOST_FUNCTION): * Source/JavaScriptCore/runtime/ExceptionHelpers.cpp: (JSC::notAFunctionSourceAppender): * Source/JavaScriptCore/runtime/ISO8601.cpp: (JSC::ISO8601::parseDuration): * Source/JavaScriptCore/runtime/IntlCollator.cpp: (JSC::IntlCollator::checkICULocaleInvariants): * Source/JavaScriptCore/runtime/IntlDateTimeFormat.cpp: (JSC::canonicalizeTimeZoneName): (JSC::IntlDateTimeFormat::initializeDateTimeFormat): (JSC::IntlDateTimeFormat::formatToParts const): (JSC::IntlDateTimeFormat::formatRangeToParts): * Source/JavaScriptCore/runtime/IntlDurationFormat.cpp: (JSC::IntlDurationFormat::formatToParts const): * Source/JavaScriptCore/runtime/IntlListFormat.cpp: (JSC::IntlListFormat::formatToParts const): * Source/JavaScriptCore/runtime/IntlLocale.cpp: (JSC::IntlLocale::hourCycles): * Source/JavaScriptCore/runtime/IntlNumberFormat.cpp: (JSC::IntlNumberFormat::formatRangeToPartsInternal): * Source/JavaScriptCore/runtime/JSString.h: (JSC::JSRopeString::unsafeView const): (JSC::JSRopeString::viewWithUnderlyingString const): * Source/JavaScriptCore/runtime/LiteralParser.cpp: (JSC::LiteralParser<CharType>::Lexer::lex): (JSC::LiteralParser<CharType>::Lexer::lexStringSlow): (JSC::LiteralParser<CharType>::parsePrimitiveValue): * Source/JavaScriptCore/wasm/WasmIndexOrName.cpp: (JSC::Wasm::makeString): * Source/WTF/wtf/HexNumber.cpp: (WTF::printInternal): * Source/WTF/wtf/HexNumber.h: (WTF::HexNumberBuffer::span const): * Source/WTF/wtf/URL.cpp: (WTF::URL::setHost): (WTF::URL::setHostAndPort): * Source/WTF/wtf/URLParser.cpp: (WTF::URLParser::encodeNonUTF8Query): (WTF::URLParser::copyURLPartsUntil): (WTF::URLParser::parsedDataView): (WTF::URLParser::domainToASCII): (WTF::URLParser::parseHostAndPort): * Source/WTF/wtf/cf/CFURLExtras.cpp: (WTF::isSameOrigin): * Source/WTF/wtf/text/StringBuilder.h: (WTF::StringBuilder::operator StringView const): (WTF::equal): * Source/WTF/wtf/text/StringCommon.h: * Source/WTF/wtf/text/StringParsingBuffer.h: * Source/WTF/wtf/text/StringView.cpp: (WTF::StringView::GraphemeClusters::Iterator::Impl::operator* const): (WTF::convertASCIILowercaseAtom): * Source/WTF/wtf/text/StringView.h: (WTF::StringView::initialize): (WTF::StringView::StringView): (WTF::StringView::substring const): (WTF::StringView::trim const): * Source/WTF/wtf/text/TextBreakIterator.cpp: (WTF::setTextForIterator): * Source/WTF/wtf/text/TextBreakIterator.h: (WTF::TextBreakIterator::setText): (WTF::TextBreakIteratorCache::take): (WTF::CachedTextBreakIterator::CachedTextBreakIterator): (WTF::CachedLineBreakIteratorFactory::get): * Source/WTF/wtf/text/cf/TextBreakIteratorCF.h: (WTF::TextBreakIteratorCF::setText): * Source/WTF/wtf/text/cocoa/TextBreakIteratorInternalICUCocoa.cpp: (WTF::TextBreakIterator::mapModeToBackingIterator): (WTF::TextBreakIterator::TextBreakIterator): * Source/WTF/wtf/text/icu/TextBreakIteratorICU.h: (WTF::TextBreakIteratorICU::TextBreakIteratorICU): (WTF::TextBreakIteratorICU::setText): * Source/WTF/wtf/text/icu/UTextProvider.h: (WTF::initializeContextAwareUTextProvider): * Source/WTF/wtf/text/icu/UTextProviderLatin1.cpp: (WTF::openLatin1UTextProvider): (WTF::openLatin1ContextAwareUTextProvider): * Source/WTF/wtf/text/icu/UTextProviderLatin1.h: * Source/WTF/wtf/text/icu/UTextProviderUTF16.cpp: (WTF::openUTF16ContextAwareUTextProvider): * Source/WTF/wtf/text/icu/UTextProviderUTF16.h: * Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCCertificateGenerator.cpp: (WebCore::LibWebRTCCertificateGenerator::RTCCertificateGeneratorCallbackWrapper::process): * Source/WebCore/Modules/websockets/WebSocketHandshake.cpp: (WebCore::trimInputSample): (WebCore::WebSocketHandshake::readStatusLine): (WebCore::WebSocketHandshake::readHTTPHeaders): * Source/WebCore/bindings/js/ScriptBufferSourceProvider.h: * Source/WebCore/css/parser/CSSCustomPropertySyntax.cpp: (WebCore::CSSCustomPropertySyntax::parseComponent): * Source/WebCore/css/parser/CSSParserToken.cpp: (WebCore::mergeIfAdjacent): * Source/WebCore/editing/TextIterator.cpp: (WebCore::WordAwareIterator::text const): (WebCore::SearchBuffer::isWordEndMatch const): (WebCore::SearchBuffer::isWordStartMatch const): (WebCore::SearchBuffer::search): * Source/WebCore/editing/TextIterator.h: (WebCore::TextIteratorCopyableText::text const): * Source/WebCore/editing/VisibleUnits.cpp: (WebCore::wordBreakIteratorForMinOffsetBoundary): (WebCore::wordBreakIteratorForMaxOffsetBoundary): (WebCore::backwardSearchForBoundaryWithTextIterator): (WebCore::forwardSearchForBoundaryWithTextIterator): * Source/WebCore/html/FTPDirectoryDocument.cpp: (WebCore::FTPDirectoryDocumentParser::append): * Source/WebCore/html/MediaFragmentURIParser.cpp: (WebCore::collectFraction): * Source/WebCore/html/parser/CSSPreloadScanner.cpp: (WebCore::CSSPreloadScanner::emitRule): * Source/WebCore/html/parser/HTMLConstructionSite.cpp: (WebCore::findBreakIndexSlow): * Source/WebCore/html/parser/HTMLMetaCharsetParser.cpp: (WebCore::HTMLMetaCharsetParser::processMeta): * Source/WebCore/html/parser/HTMLParserIdioms.cpp: (WebCore::parseHTTPRefreshInternal): * Source/WebCore/html/parser/HTMLPreloadScanner.cpp: (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes): * Source/WebCore/html/parser/HTMLSrcsetParser.cpp: (WebCore::appendDescriptorAndReset): (WebCore::parseImageCandidatesFromSrcsetAttribute): * Source/WebCore/html/track/VTTScanner.cpp: (WebCore::VTTScanner::scanDigits): * Source/WebCore/loader/LinkHeader.cpp: (WebCore::parseParameterName): * Source/WebCore/loader/ResourceCryptographicDigest.cpp: (WebCore::parseCryptographicDigestImpl): * Source/WebCore/page/EventSource.cpp: (WebCore::EventSource::parseEventStreamLine): * Source/WebCore/page/csp/ContentSecurityPolicySourceList.cpp: (WebCore::ContentSecurityPolicySourceList::parseScheme): (WebCore::ContentSecurityPolicySourceList::parseHost): (WebCore::ContentSecurityPolicySourceList::parsePath): (WebCore::ContentSecurityPolicySourceList::parsePort): * Source/WebCore/platform/Length.cpp: (WebCore::parseLength): * Source/WebCore/platform/graphics/ComplexTextController.cpp: (WebCore::ComplexTextController::offsetForPosition): (WebCore::ComplexTextController::collectComplexTextRuns): * Source/WebCore/platform/graphics/ComplexTextController.h: (WebCore::ComplexTextController::ComplexTextRun::span const): * Source/WebCore/platform/graphics/ComposedCharacterClusterTextIterator.h: (WebCore::ComposedCharacterClusterTextIterator::ComposedCharacterClusterTextIterator): * Source/WebCore/platform/graphics/StringTruncator.cpp: (WebCore::stringWidth): * Source/WebCore/platform/graphics/TextRun.h: (WebCore::TextRun::span8): (WebCore::TextRun::span16): (WebCore::TextRun::setText): * Source/WebCore/platform/graphics/WidthIterator.cpp: (WebCore::WidthIterator::advance): * Source/WebCore/platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: (WebCore::InbandTextTrackPrivateAVF::processNativeSamples): * Source/WebCore/platform/network/HTTPParsers.cpp: (WebCore::trimInputSample): (WebCore::parseHTTPHeader): * Source/WebCore/platform/network/RFC8941.cpp: (RFC8941::parseKey): * Source/WebCore/rendering/RenderBlock.cpp: (WebCore::RenderBlock::constructTextRun): * Source/WebCore/rendering/RenderText.cpp: (WebCore::capitalize): (WebCore::RenderText::previousOffset const): (WebCore::RenderText::previousOffsetForBackwardDeletion const): (WebCore::RenderText::nextOffset const): (WebCore::RenderText::stringView const): * Source/WebCore/rendering/TextPainter.cpp: (WebCore::TextPainter::paintTextAndEmphasisMarksIfNeeded): * Source/WebCore/svg/SVGLengthList.cpp: (WebCore::SVGLengthList::parse): * Source/WebCore/testing/MockCDMFactory.cpp: (WebCore::MockCDMInstance::setServerCertificate): * Source/WebKit/NetworkProcess/storage/CacheStorageManager.cpp: (WebKit::readSizeFile): * Source/WebKitLegacy/mac/Misc/WebKitNSStringExtras.mm: (-[NSString _web_drawAtPoint:font:textColor:]): (-[NSString _web_widthWithFont:]): * Tools/TestWebKitAPI/Tests/WTF/StringView.cpp: (TestWebKitAPI::TEST): * Tools/TestWebKitAPI/Tests/WTF/TextBreakIterator.cpp: (TestWebKitAPI::TEST): * Tools/TestWebKitAPI/Tests/WebCore/ComplexTextController.cpp: (TestWebKitAPI::TEST_F): * Tools/TestWebKitAPI/Tests/WebCore/MonospaceFontTests.cpp: (TestWebKitAPI::TEST): * Tools/TestWebKitAPI/Tests/WebCore/SharedBuffer.cpp: (TestWebKitAPI::TEST_F): * Tools/TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm: (respondToRangeRequests): Canonical link: https://commits.webkit.org/276616@main
- Loading branch information
Showing
82 changed files
with
282 additions
and
279 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.