add simple warning to deprecated %name directive
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@6749 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
2e1f72c883
commit
831b585d55
1 changed files with 6 additions and 2 deletions
|
|
@ -1849,12 +1849,16 @@ module_directive: MODULE options idstring {
|
|||
------------------------------------------------------------ */
|
||||
|
||||
name_directive : NAME LPAREN idstring RPAREN {
|
||||
Swig_warning(WARN_DEPRECATED_EXCEPT,cparse_file,cparse_line,
|
||||
"%%name is deprecated. Use %%rename instead (see docs).\n");
|
||||
yyrename = NewString($3);
|
||||
$$ = 0;
|
||||
}
|
||||
| NAME LPAREN RPAREN {
|
||||
$$ = 0;
|
||||
Swig_error(cparse_file,cparse_line,"Missing argument to %%name directive.\n");
|
||||
Swig_warning(WARN_DEPRECATED_EXCEPT,cparse_file,cparse_line,
|
||||
"%%name is deprecated. Use %%rename instead (see docs).\n");
|
||||
$$ = 0;
|
||||
Swig_error(cparse_file,cparse_line,"Missing argument to %%name directive.\n");
|
||||
}
|
||||
;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue