PerlFFI / FFI-Platypus-Lang-CPP

Documentation and tools for using Platypus with the C++ programming language
Other
4 stars 1 forks source link

A couple of questions #9

Open ghost opened 8 years ago

ghost commented 8 years ago
// C++
void Foo::set_bar(Bar& b) { bar = b; } // Bar is a class 
# Perl
$ffi->attach([ 'Foo::set_bar(Bar&)' => 'set_bar' ] => [ 'Foo', 'Bar' ] => 'void' );

But it's not able to find symbol for below case,

// C++
void Foo::set_bar(const Bar& b) { bar = b; }
# Perl
$ffi->attach([ 'Foo::set_bar(const Bar&)' => 'set_bar' ] => [ 'Foo', 'Bar' ] => 'void' );

Is this expected? As the "const" thing is commonly used in C++, I wonder it is possible to support this.

Thanks!

plicease commented 8 years ago

I should be able to add support for const. I think the signature parser needs a little tweaking.

I am not sure but a little doubtful of STL stuff.