Files
swift-mirror/test/StringProcessing/Parse/regex.swift
Richard Wei cf8e0fea12 [Regex] Switch regex match to Swift tuples.
Typed captures no longer use ad-hoc nominal tuples. We use Swift native tuples instead. See apple/swift-experimental-string-processing#127.

Update checkout tag to dev/6.
2022-02-09 16:21:57 -08:00

12 lines
351 B
Swift

// RUN: %target-typecheck-verify-swift -enable-experimental-string-processing
// REQUIRES: swift_in_compiler
_ = '/abc/'
_ = ('/[*/', '/+]/', '/.]/')
// expected-error@-1 {{cannot parse regular expression: quantifier '+' must appear after expression}}
// expected-error@-2 {{cannot parse regular expression: expected ']'}}
_ = '/\w+/'
_ = '/\'\\/'