mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 19:47:45 +00:00
Merge branch 'main' into gitattributes
This commit is contained in:
commit
90b96095af
3 changed files with 13 additions and 10 deletions
4
.vscode/extensions.json
vendored
4
.vscode/extensions.json
vendored
|
@ -1,10 +1,8 @@
|
||||||
{
|
|
||||||
// spell-checker:ignore (misc) matklad
|
// spell-checker:ignore (misc) matklad
|
||||||
// see <http://go.microsoft.com/fwlink/?LinkId=827846> for the documentation about the extensions.json format
|
// see <http://go.microsoft.com/fwlink/?LinkId=827846> for the documentation about the extensions.json format
|
||||||
|
{
|
||||||
"recommendations": [
|
"recommendations": [
|
||||||
// Rust language support.
|
// Rust language support.
|
||||||
"rust-lang.rust",
|
|
||||||
// Provides support for rust-analyzer: novel LSP server for the Rust programming language.
|
|
||||||
"matklad.rust-analyzer",
|
"matklad.rust-analyzer",
|
||||||
// `cspell` spell-checker support
|
// `cspell` spell-checker support
|
||||||
"streetsidesoftware.code-spell-checker"
|
"streetsidesoftware.code-spell-checker"
|
||||||
|
|
|
@ -88,10 +88,7 @@ fn print_escaped(input: &str, mut output: impl Write) -> io::Result<bool> {
|
||||||
start = 0;
|
start = 0;
|
||||||
next
|
next
|
||||||
}),
|
}),
|
||||||
'0' => parse_code(&mut iter, 8, 3, 3).unwrap_or_else(|| {
|
'0' => parse_code(&mut iter, 8, 3, 3).unwrap_or('\0'),
|
||||||
start = 0;
|
|
||||||
next
|
|
||||||
}),
|
|
||||||
_ => {
|
_ => {
|
||||||
start = 0;
|
start = 0;
|
||||||
next
|
next
|
||||||
|
|
|
@ -138,11 +138,19 @@ fn test_escape_short_octal() {
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn test_escape_no_octal() {
|
fn test_escape_nul() {
|
||||||
new_ucmd!()
|
new_ucmd!()
|
||||||
.args(&["-e", "foo\\0 bar"])
|
.args(&["-e", "foo\\0 bar"])
|
||||||
.succeeds()
|
.succeeds()
|
||||||
.stdout_only("foo\\0 bar\n");
|
.stdout_only("foo\0 bar\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn test_escape_octal_invalid_digit() {
|
||||||
|
new_ucmd!()
|
||||||
|
.args(&["-e", "foo\\08 bar"])
|
||||||
|
.succeeds()
|
||||||
|
.stdout_only("foo\u{0}8 bar\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue