Mark wrapped abstract classes
This allows restoring reflection checks in testcase director_abstract.
This commit is contained in:
parent
40906ae856
commit
50f92dca08
2 changed files with 13 additions and 0 deletions
|
|
@ -49,4 +49,13 @@ check::equal($me2->Color(1, 2, 3), 2, "Example2_get_color failed");
|
|||
$me3 = new MyExample3();
|
||||
check::equal($me3->Color(1, 2, 3), 3, "Example3_get_color failed");
|
||||
|
||||
$class = new ReflectionClass('Example1');
|
||||
check::equal($class->isAbstract(), true, "Example1 abstractness failed");
|
||||
|
||||
$class = new ReflectionClass('Example2');
|
||||
check::equal($class->isAbstract(), true, "Example2 abstractness failed");
|
||||
|
||||
$class = new ReflectionClass('Example3_i');
|
||||
check::equal($class->isAbstract(), true, "Example3_i abstractness failed");
|
||||
|
||||
check::done();
|
||||
|
|
|
|||
|
|
@ -1783,6 +1783,10 @@ public:
|
|||
Printf(s_oinit, " SWIGTYPE_%s_ce = zend_register_internal_class(&SWIGTYPE_%s_internal_ce);\n", class_name, class_name);
|
||||
}
|
||||
|
||||
if (Getattr(n, "abstracts") && !GetFlag(n, "feature:notabstract")) {
|
||||
Printf(s_oinit, " SWIGTYPE_%s_ce->ce_flags |= ZEND_ACC_EXPLICIT_ABSTRACT_CLASS;\n", class_name);
|
||||
}
|
||||
|
||||
{
|
||||
Node *node = NewHash();
|
||||
Setattr(node, "type", Getattr(n, "name"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue