Fixed bus error. Removed inline functions. Minor cleanup.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5500 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
bf47d2da55
commit
9f9b71ed6c
6 changed files with 12 additions and 20 deletions
32
SWIG/Source/Modules/utils.cxx
Normal file
32
SWIG/Source/Modules/utils.cxx
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
|
||||
#include <swigmod.h>
|
||||
|
||||
int is_public(Node* n)
|
||||
{
|
||||
String* access = Getattr(n, "access");
|
||||
return !access || !Cmp(access, "public");
|
||||
}
|
||||
|
||||
int is_private(Node* n)
|
||||
{
|
||||
String* access = Getattr(n, "access");
|
||||
return access && !Cmp(access, "private");
|
||||
}
|
||||
|
||||
int is_protected(Node* n)
|
||||
{
|
||||
String* access = Getattr(n, "access");
|
||||
return access && !Cmp(access, "protected");
|
||||
}
|
||||
|
||||
int is_member_director(Node* parentnode, Node* member)
|
||||
{
|
||||
int parent_director = parentnode && checkAttribute(parentnode,"feature:director","1");
|
||||
int cdecl_nodirector = checkAttribute(member,"feature:nodirector","1");
|
||||
return parent_director && !cdecl_nodirector;
|
||||
}
|
||||
|
||||
int is_member_director(Node* member)
|
||||
{
|
||||
return is_member_director(Getattr(member, "parentNode"), member);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue