Consistent warning 470 across all languages

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7123 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2005-03-30 22:24:44 +00:00
commit 1b00d2e007
5 changed files with 8 additions and 5 deletions

View file

@ -80,7 +80,7 @@
if (res == SWIG_NEWOBJ) delete ptr;
}
%typemap(directorout,fragment=pyfrag,warning="470:Possible thread/reentrant unsafe wrapping, consider using a plain '"#Type"' return type instead.") const Type& {
%typemap(directorout,fragment=pyfrag,warning=SWIG_WARN_TYPEMAP_THREAD_UNSAFE) const Type& {
Type *ptr = 0;
int res = $input ? asptr_meth($input, &ptr) : 0;
if (!res || !ptr)

View file

@ -78,7 +78,7 @@
if (!$input || PyErr_Occurred())
Swig::DirectorTypeMismatchException::raise("Error converting Python object when using as_meth.");
}
%typemap(directorout,fragment=pyfrag,warning="470:Using thread/reentrant unsafe wrapping, consider using a plain '"#Type"' return type instead.") const Type& {
%typemap(directorout,fragment=pyfrag,warning=SWIG_WARN_TYPEMAP_THREAD_UNSAFE) const Type& {
if ($input) {
static $basetype temp = SWIG_static_cast(SWIG_arg(as_meth($input)),$basetype);
$result = &temp;