Merge branch 'nested' - nested structs/classes support
* nested: Deprecation of the 'nestedworkaround' feature Ensure -c++out is not used with -c++ Add missing header to new source file Nested C class setters restored in c++out mode for Octave Classprefix fixed after private nested classes some comments and spaces added Fix template partial specialization detection Minor tweaks in Swig_feature_set Swig_offset_string moved to misc.c nested private classes are discarded while parsing nested relate functions are moved to nested.cxx and renamed accordingly out-of-scope template definitions fixed nested_private test disabled again fixed out-of-scope nested class definitions, added a test enabled nested C structs assignment (still disabled for Octave), added Java runtime test fixed nested_private test case for Java & C# Testcase of private nested class usage causing segfault C nested struct passed by value example Add in Travis testing for nested branch Add C++ nested class example Minor code improvements Cosmetics/code beautification of nested class support Nested classes support
This commit is contained in:
commit
314fae460b
61 changed files with 2438 additions and 1127 deletions
|
|
@ -25,12 +25,15 @@ extern "C" {
|
|||
extern String *cparse_file;
|
||||
extern int cparse_line;
|
||||
extern int cparse_cplusplus;
|
||||
extern int cparse_cplusplusout;
|
||||
extern int cparse_start_line;
|
||||
|
||||
extern void Swig_cparse_cplusplus(int);
|
||||
extern void Swig_cparse_cplusplusout(int);
|
||||
extern void scanner_file(File *);
|
||||
extern void scanner_next_token(int);
|
||||
extern void skip_balanced(int startchar, int endchar);
|
||||
extern String *get_raw_text_balanced(int startchar, int endchar);
|
||||
extern void skip_decl(void);
|
||||
extern void scanner_check_typedef(void);
|
||||
extern void scanner_ignore_typedef(void);
|
||||
|
|
|
|||
|
|
@ -37,6 +37,9 @@ int cparse_start_line = 0;
|
|||
/* C++ mode */
|
||||
int cparse_cplusplus = 0;
|
||||
|
||||
/* Generate C++ compatible code when wrapping C code */
|
||||
int cparse_cplusplusout = 0;
|
||||
|
||||
/* Private vars */
|
||||
static int scan_init = 0;
|
||||
static int num_brace = 0;
|
||||
|
|
@ -52,6 +55,14 @@ void Swig_cparse_cplusplus(int v) {
|
|||
cparse_cplusplus = v;
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* Swig_cparse_cplusplusout()
|
||||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
void Swig_cparse_cplusplusout(int v) {
|
||||
cparse_cplusplusout = v;
|
||||
}
|
||||
|
||||
/* ----------------------------------------------------------------------------
|
||||
* scanner_init()
|
||||
*
|
||||
|
|
@ -118,6 +129,16 @@ void skip_balanced(int startchar, int endchar) {
|
|||
return;
|
||||
}
|
||||
|
||||
/* -----------------------------------------------------------------------------
|
||||
* get_raw_text_balanced()
|
||||
*
|
||||
* Returns raw text between 2 braces
|
||||
* ----------------------------------------------------------------------------- */
|
||||
|
||||
String *get_raw_text_balanced(int startchar, int endchar) {
|
||||
return Scanner_get_raw_text_balanced(scan, startchar, endchar);
|
||||
}
|
||||
|
||||
/* ----------------------------------------------------------------------------
|
||||
* void skip_decl(void)
|
||||
*
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue