Files
swift-mirror/test/StringProcessing/Parse/regex_parse_end_of_buffer.swift
Richard Wei e5175d595e [Regex] Infer 'Match' type of regex literals.
Applies swift-experimental-string-processing#68 in regex literal type inference. Regex literals with captures will have type `Regex<Tuple{n}<Substring, {Captures...}>>`. This is a temporary thing that allows us to define generic constraints on captures. We will switch back to native tuples once we have variadic generics.
2022-01-06 10:54:10 -08:00

6 lines
241 B
Swift

// RUN: %target-typecheck-verify-swift -enable-experimental-string-processing
// REQUIRES: swift_in_compiler
// Note there is purposefully no trailing newline here.
// expected-error@+1 {{unterminated regex literal}}
var unterminated = '/xy