Short redirection syntax (#8503)

This one's pretty clear from the diff! It's more of a language design
discussion.
This commit is contained in:
Dan Davison 2023-03-17 19:57:37 +00:00 committed by GitHub
parent 14bf0b000e
commit 77e9f8d7df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -247,21 +247,21 @@ pub fn lex_item(
}
match &input[(span.start - span_offset)..(span.end - span_offset)] {
b"out>" => (
b"out>" | b"o>" => (
Token {
contents: TokenContents::OutGreaterThan,
span,
},
None,
),
b"err>" => (
b"err>" | b"e>" => (
Token {
contents: TokenContents::ErrGreaterThan,
span,
},
None,
),
b"out+err>" | b"err+out>" => (
b"out+err>" | b"err+out>" | b"o+e>" | b"e+o>" => (
Token {
contents: TokenContents::OutErrGreaterThan,
span,