From 8e64a3a9df916fdcb7a4de81991772048d9a08bc Mon Sep 17 00:00:00 2001 From: Alex Deem Date: Sun, 8 Jan 2023 22:55:06 +1100 Subject: [PATCH] Allow single-quote as literal Refer RFC errata 6937 https://www.rfc-editor.org/errata/eid6937 --- Sources/ScreamURITemplate/Internal/CharacterSets.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/ScreamURITemplate/Internal/CharacterSets.swift b/Sources/ScreamURITemplate/Internal/CharacterSets.swift index 235f47e..ec56760 100644 --- a/Sources/ScreamURITemplate/Internal/CharacterSets.swift +++ b/Sources/ScreamURITemplate/Internal/CharacterSets.swift @@ -19,7 +19,7 @@ private let genDelimsCharacterSet = CharacterSet(charactersIn: ":/?#[]@") private let subDelimsCharacterSet = CharacterSet(charactersIn: "!$&'()*+,;=") internal let reservedCharacterSet = genDelimsCharacterSet.union(subDelimsCharacterSet) internal let reservedAndUnreservedCharacterSet = reservedCharacterSet.union(unreservedCharacterSet) -internal let invertedLiteralCharacterSet = CharacterSet.illegalCharacters.union(CharacterSet.controlCharacters).union(CharacterSet(charactersIn: " \"'%<>\\^`{|}")) +internal let invertedLiteralCharacterSet = CharacterSet.illegalCharacters.union(CharacterSet.controlCharacters).union(CharacterSet(charactersIn: " \"%<>\\^`{|}")) internal let literalCharacterSet = invertedLiteralCharacterSet.inverted internal let hexCharacterSet = CharacterSet(charactersIn: "0123456789abcdefABCDEF") internal let varnameCharacterSet = CharacterSet.alphanumerics.union(CharacterSet(charactersIn: "_%."))