The parser has no problems recognizing the Regex compact notation in a playground that I created to reproduce the problem. I declare the Regex on a separate line to make sure.
let transaction = "DEBIT 03/05/2022 Doug's Dugout Dogs $33.27"
let r = /\s{2,}|\t/
let fragments = transaction.split(separator: r)
The build error is related to line 3. String seems to be missing a variant of split(separator:) that accepts a Regex. Missing in the doc pages as well.