Skip to content

Commit

Permalink
Port c-link-to-rust-va-list-fn to Rust
Browse files Browse the repository at this point in the history
  • Loading branch information
Oneirical committed May 11, 2024
1 parent 3349155 commit a2e7e79
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 8 deletions.
1 change: 0 additions & 1 deletion src/tools/tidy/src/allowed_run_make_makefiles.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ run-make/c-dynamic-dylib/Makefile
run-make/c-dynamic-rlib/Makefile
run-make/c-link-to-rust-dylib/Makefile
run-make/c-link-to-rust-staticlib/Makefile
run-make/c-link-to-rust-va-list-fn/Makefile
run-make/c-static-dylib/Makefile
run-make/c-static-rlib/Makefile
run-make/c-unwind-abi-catch-lib-panic/Makefile
Expand Down
7 changes: 0 additions & 7 deletions tests/run-make/c-link-to-rust-va-list-fn/Makefile

This file was deleted.

21 changes: 21 additions & 0 deletions tests/run-make/c-link-to-rust-va-list-fn/rmake.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// test.c and its static library checkrust.rs make use of variadic functions (VaList).
// This test checks that the use of this feature does not

Check failure on line 2 in tests/run-make/c-link-to-rust-va-list-fn/rmake.rs

View workflow job for this annotation

GitHub Actions / PR - mingw-check-tidy

trailing whitespace
// prevent the creation of a functional binary.
// See https://github.com/rust-lang/rust/pull/49878

//@ ignore-cross-compile

use run_make_support::{cc, extra_c_flags, run, rustc, static_lib};

fn main() {
rustc()
.input("checkrust.rs")
.run();
cc()
.input("test.c")
.input(static_lib("checkrust"))
.out_exe("test")
.args(&extra_c_flags())
.run();
run("test");
}

0 comments on commit a2e7e79

Please sign in to comment.