2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-27 07:02:15 +00:00

- fixed default arguments in virtual methods

[SVN r17823]
This commit is contained in:
Bruno da Silva de Oliveira
2003-03-12 01:32:00 +00:00
parent 415991f6fc
commit ca9920874f
2 changed files with 209 additions and 167 deletions

View File

@@ -25,7 +25,11 @@ class FunctionExporter(Exporter):
def CheckPolicy(self, func):
'Warns the user if this function needs a policy'
def IsString(type):
return type.const and type.name == 'char' and isinstance(type, PointerType)
needs_policy = isinstance(func.result, (ReferenceType, PointerType))
if IsString(func.result):
needs_policy = False
if needs_policy and self.info.policy is None:
print '---> Error: Function "%s" needs a policy.' % func.FullName()
print