Patch #3260265 fixing overloading of non-primitive types and integers in Perl 5.12 and later
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@12691 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
527c3e0552
commit
ea00ff974f
4 changed files with 26 additions and 3 deletions
|
|
@ -2,7 +2,7 @@
|
|||
use overload_simple;
|
||||
use vars qw/$DOWARN/;
|
||||
use strict;
|
||||
use Test::More tests => 71;
|
||||
use Test::More tests => 75;
|
||||
|
||||
pass("loaded");
|
||||
|
||||
|
|
@ -189,3 +189,10 @@ is(overload_simple::fid("3", 3), "fid:intint", "fid:fid(int,int)");
|
|||
isnt(overload_simple::fbool(0), overload_simple::fbool(1), "fbool(bool)");
|
||||
|
||||
is(2, overload_simple::fbool(2), "fbool(int)");
|
||||
|
||||
# int and object overload
|
||||
|
||||
is(overload_simple::int_object(1), 1, "int_object(1)");
|
||||
is(overload_simple::int_object(0), 0, "int_object(0)");
|
||||
is(overload_simple::int_object(undef), 999, "int_object(Spam*)");
|
||||
is(overload_simple::int_object($s), 999, "int_object(Spam*)");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue