                             pctEncoded = ""
 
                         } else {
-                            syntaxErrors += (URITemplateError.MalformedPctEncodedInLiteral, index)
+                            errors += (URITemplateError.MalformedPctEncodedInLiteral, index)
                             result += encodeLiteralString(pctEncoded)
                             result += encodeLiteralCharacter(c)
                             state = .ScanningLiteral

    case MalformedVarSpec
}

let URITemplateSyntaxErrorsKey = "SyntaxErrors"

public class URITemplate {
    enum State {
        case ScanningLiteral

                    // Process expression
                    let (operator, error) = findOperatorInExpression(expression)
                    if error {
                        errors += (URITemplateError.MalformedPctEncodedInLiteral, index)
                        result = result + "{" + expression + "}"

                    } else {
