Debian Codegraph @

t/ffi_platypus_lang_asm.t

raw
1 use Test2::V0 -no_srand => 1;
2 use FFI::CheckLib;
3 use FFI::Platypus;
4
5 my $libtest = find_lib lib => 'test', symbol => 'f0', libpath => 't/ffi';
6
7 subtest ASM => sub {
8 my $ffi = FFI::Platypus->new(lang => 'ASM');
9 $ffi->lib($libtest);
10
11 eval { $ffi->type('int') };
12 isnt $@, '', 'int is not an okay type';
13 note $@;
14 eval { $ffi->type('foo_t') };
15 isnt $@, '', 'foo_t is not an okay type';
16 note $@;
17 eval { $ffi->type('sint16') };
18 is $@, '', 'sint16 is an okay type';
19
20 is $ffi->find_symbol('UnMangled::Name(int i)'), undef, 'unable to find unmangled name';
21
22 };
23
24 done_testing;