File tree Expand file tree Collapse file tree 3 files changed +8
-0
lines changed
tests/rust_guests/witguest Expand file tree Collapse file tree 3 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -155,6 +155,9 @@ impl test::wit::Roundtrip for Host {
155155 ) -> test:: wit:: roundtrip:: Testenum {
156156 x
157157 }
158+ fn roundtrip_fix_list ( & mut self , x : Vec < u8 > ) -> Vec < u8 > {
159+ x
160+ }
158161
159162 fn roundtrip_no_result ( & mut self , _x : u32 ) { }
160163}
@@ -331,6 +334,7 @@ mod wit_test {
331334 make_test ! { roundtrip_flags_large, in arb_largeflags( ) }
332335 make_test ! { roundtrip_variant, in arb_testvariant( ) }
333336 make_test ! { roundtrip_enum, in arb_testenum( ) }
337+ make_test ! { roundtrip_fix_list, : Vec <u8 > }
334338
335339 #[ test]
336340 fn test_simple_func ( ) {
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ interface roundtrip {
2626 roundtrip-option : func (x : option <string >) -> option <string >;
2727 roundtrip-result : func (x : result <char , string >) -> result <char , string >;
2828 roundtrip-no-result : func (x : u32 );
29+ roundtrip-fix-list : func (x : list <u8 , 4 >) -> list <u8 , 4 >;
2930
3031 record testrecord {
3132 contents : string ,
Original file line number Diff line number Diff line change @@ -113,6 +113,9 @@ impl test::wit::Roundtrip for Guest {
113113 ) -> test:: wit:: roundtrip:: Testenum {
114114 ( Host { } ) . roundtrip_enum ( x)
115115 }
116+ fn roundtrip_fix_list ( & mut self , x : Vec < u8 > ) -> Vec < u8 > {
117+ ( Host { } ) . roundtrip_fix_list ( x)
118+ }
116119 fn roundtrip_no_result ( & mut self , x : u32 ) {
117120 ( Host { } ) . roundtrip_no_result ( x)
118121 }
You can’t perform that action at this time.
0 commit comments