SE-0354: Regex Literals

Was this change upstreamed in the proposal, or is there an edited version somewhere? It still deprecates prefix / in the proposal.

I have a PR up to amend the proposal: [SE-0354] Update regex literal proposal by hamishknight · Pull Request #1651 · apple/swift-evolution · GitHub

2 Likes

Can I check if this question is addressing the proposal, or @Paul_Cantrell's thoughts?

The proposal is that with multi-line literals, whitespace is not semantic. So leading and trailing newlines are ignored, not just by analogy with string literals but because all whitespace is ignored.

I was asking about the proposal; this makes sense.

I think I misunderstood @Paul_Cantrell's example, where it's the internal space between "hello" and "world" that becomes ignored in the case of a multiline literal, causing it not to match "hello world". That's...unfortunate but a different issue.

1 Like

Review Update

The core team has decided to return the proposal for revision and a second review is now running.

I have moved some of the recent discussion to that review thread.

3 Likes