From 75805fac0dd49705ac26e8130a2e57a88b8918bf Mon Sep 17 00:00:00 2001 From: vms Date: Mon, 10 May 2021 14:34:49 +0300 Subject: [PATCH] fix tests --- .../export_functions/inner_vec_refs.rs | 4 +++ .../export_functions/inner_vec_refs.stderr | 28 ++++++------------- 2 files changed, 12 insertions(+), 20 deletions(-) diff --git a/fluence/tests/compilation_tests/export_functions/inner_vec_refs.rs b/fluence/tests/compilation_tests/export_functions/inner_vec_refs.rs index 448ac1d..ea133cc 100644 --- a/fluence/tests/compilation_tests/export_functions/inner_vec_refs.rs +++ b/fluence/tests/compilation_tests/export_functions/inner_vec_refs.rs @@ -1,5 +1,9 @@ #![allow(improper_ctypes)] +use fluence::marine; + +pub fn main() {} + #[marine] pub fn inner_arrays_2(_arg: &Vec>>>) -> &Vec>>> { unimplemented!() diff --git a/fluence/tests/compilation_tests/export_functions/inner_vec_refs.stderr b/fluence/tests/compilation_tests/export_functions/inner_vec_refs.stderr index 85ac160..b5f773c 100644 --- a/fluence/tests/compilation_tests/export_functions/inner_vec_refs.stderr +++ b/fluence/tests/compilation_tests/export_functions/inner_vec_refs.stderr @@ -1,23 +1,11 @@ -error: cannot find attribute `marine` in this scope - --> $DIR/inner_vec_refs.rs:8:3 +error: a vector type in output types of export functions shouldn't contain references + --> $DIR/inner_vec_refs.rs:8:54 | -8 | #[marine] - | ^^^ +8 | pub fn inner_arrays_2(_arg: &Vec>>>) -> &Vec>>> { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error: cannot find attribute `marine` in this scope - --> $DIR/inner_vec_refs.rs:3:3 - | -3 | #[marine] - | ^^^ - -error[E0601]: `main` function not found in crate `$CRATE` - --> $DIR/inner_vec_refs.rs:1:1 +error: a vector type in output types of export functions shouldn't contain references + --> $DIR/inner_vec_refs.rs:13:54 | -1 | / #![allow(improper_ctypes)] -2 | | -3 | | #[marine] -4 | | pub fn inner_arrays_2(_arg: &Vec>>>) -> &Vec>>> { -... | -10 | | unimplemented!() -11 | | } - | |_^ consider adding a `main` function to `$DIR/tests/compilation_tests/export_functions/inner_vec_refs.rs` +13 | pub fn inner_arrays_3(_arg: &Vec>>>) -> &Vec<&Vec<&Vec<&Vec<&u8>>>> { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^