杨锴
2025-03-11 90dc3329d1973fda691e357cf4523d5c7c67fa1d
Pods/SwifterSwift/Sources/SwifterSwift/Foundation/NSAttributedStringExtensions.swift
@@ -127,8 +127,8 @@
    ///   - attributes: Dictionary of attributes.
    ///   - target: a subsequence string for the attributes to be applied to.
    /// - Returns: An NSAttributedString with attributes applied on the target string.
    func applying<T: StringProtocol>(attributes: [Key: Any],
                                     toOccurrencesOf target: T) -> NSAttributedString {
    func applying(attributes: [Key: Any],
                  toOccurrencesOf target: some StringProtocol) -> NSAttributedString {
        let pattern = "\\Q\(target)\\E"
        return applying(attributes: attributes, toRangesMatching: pattern)