diff --git a/src/test/ui/issues/auxiliary/issue-49544.rs b/src/test/ui/issues/auxiliary/issue-49544.rs new file mode 100644 index 00000000000..f8b3a3fba1e --- /dev/null +++ b/src/test/ui/issues/auxiliary/issue-49544.rs @@ -0,0 +1,7 @@ +#![crate_type = "lib"] + +pub fn foo() -> Vec { + std::env::args() + .skip(1) + .collect() +} diff --git a/src/test/ui/issues/issue-49544.rs b/src/test/ui/issues/issue-49544.rs new file mode 100644 index 00000000000..ed356275fc1 --- /dev/null +++ b/src/test/ui/issues/issue-49544.rs @@ -0,0 +1,9 @@ +// aux-build:issue-49544.rs +// check-pass + +extern crate issue_49544; +use issue_49544::foo; + +fn main() { + let _ = foo(); +}