Skip to content

Commit

Permalink
scilab: use language specific warnings for too long identifier names
Browse files Browse the repository at this point in the history
  • Loading branch information
Simon Marchetto committed Jul 21, 2014
1 parent dead560 commit cc8b859
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions Source/Include/swigwarn.h
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -232,6 +232,10 @@


/* please leave 700-719 free for D */ /* please leave 700-719 free for D */


#define WARN_SCILAB_TRUNCATED_NAME 720

/* please leave 720-739 free for Scilab */

#define WARN_RUBY_WRONG_NAME 801 #define WARN_RUBY_WRONG_NAME 801
#define WARN_RUBY_MULTIPLE_INHERITANCE 802 #define WARN_RUBY_MULTIPLE_INHERITANCE 802


Expand Down
2 changes: 1 addition & 1 deletion Source/Modules/scilab.cxx
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -740,7 +740,7 @@ class SCILAB:public Language {
void checkIdentifierName(String *name) { void checkIdentifierName(String *name) {
if (Len(name) > 24) { if (Len(name) > 24) {
// Warning on too long identifiers // Warning on too long identifiers
Swig_warning(WARN_LANG_IDENTIFIER, input_file, line_number, Swig_warning(WARN_SCILAB_TRUNCATED_NAME, input_file, line_number,
"Identifier name '%s' exceeds 24 characters, it is truncated to '%s'.\n", "Identifier name '%s' exceeds 24 characters, it is truncated to '%s'.\n",
name, DohNewStringWithSize(name, 24)); name, DohNewStringWithSize(name, 24));
} }
Expand Down

0 comments on commit cc8b859

Please sign in to comment.