@@ -266,7 +266,7 @@ bool return_type_needs_typedef(String *s) {
266
266
* \brief Construct any necessary 'import' identifier.
267
267
*
268
268
* When the `imtype` is an actual `type(Foo)`, it's necessary to import the identifier Foo from the module definition scope. This function examines the
269
- * evaluated `imtype` (could be `imtype:in`, probably has $fclassname replaced)
269
+ * evaluated `imtype` (could be `imtype:in`, probably has $fortranclassname replaced)
270
270
*/
271
271
String *make_import_string (String *imtype) {
272
272
char *start = Strstr (imtype, " type(" );
@@ -1672,7 +1672,7 @@ Wrapper *FORTRAN::proxyfuncWrapper(Node *n) {
1672
1672
// Check whether the Fortran proxy routine returns a variable, and whether
1673
1673
// the actual C function does
1674
1674
1675
- // Replace any instance of $fclassname in return type
1675
+ // Replace any instance of $fortranclassname in return type
1676
1676
SwigType *return_cpptype = Getattr (n, " type" );
1677
1677
this ->replace_fclassname (return_cpptype, return_ftype);
1678
1678
this ->replace_fclassname (return_cpptype, return_imtype);
@@ -2948,7 +2948,7 @@ int FORTRAN::constantWrapper(Node *n) {
2948
2948
wname = Copy (symname);
2949
2949
}
2950
2950
2951
- // Replace fclassname if needed
2951
+ // Replace fortranclass if needed
2952
2952
this ->replace_fclassname (c_return_type, bindc_typestr);
2953
2953
2954
2954
// Add bound variable to interfaces
@@ -2975,26 +2975,26 @@ void FORTRAN::replace_fclassname(SwigType *intype, String *tm) {
2975
2975
SwigType *resolvedtype = SwigType_typedef_resolve_all (intype);
2976
2976
SwigType *strippedtype = SwigType_strip_qualifiers (resolvedtype);
2977
2977
2978
- if (Strstr (tm, " $fclassname " )) {
2978
+ if (Strstr (tm, " $fortranclassname " )) {
2979
2979
if (String *repl = this ->get_proxyname (strippedtype)) {
2980
- Replaceall (tm, " $fclassname " , repl);
2980
+ Replaceall (tm, " $fortranclassname " , repl);
2981
2981
}
2982
2982
}
2983
- if (Strstr (tm, " $*fclassname " )) {
2983
+ if (Strstr (tm, " $*fortranclassname " )) {
2984
2984
String *repltype = Copy (strippedtype);
2985
2985
Delete (SwigType_pop (repltype));
2986
2986
if (Len (repltype) > 0 ) {
2987
2987
if (String *repl = this ->get_proxyname (repltype)) {
2988
- Replaceall (tm, " $*fclassname " , repl);
2988
+ Replaceall (tm, " $*fortranclassname " , repl);
2989
2989
}
2990
2990
}
2991
2991
Delete (repltype);
2992
2992
}
2993
- if (Strstr (tm, " $&fclassname " )) {
2993
+ if (Strstr (tm, " $&fortranclassname " )) {
2994
2994
String *repltype = Copy (strippedtype);
2995
2995
SwigType_add_pointer (repltype);
2996
2996
if (String *repl = this ->get_proxyname (repltype)) {
2997
- Replaceall (tm, " $&fclassname " , repl);
2997
+ Replaceall (tm, " $&fortranclassname " , repl);
2998
2998
}
2999
2999
Delete (repltype);
3000
3000
}
@@ -3034,22 +3034,22 @@ String *FORTRAN::get_fsymname(Node *n, String *symname) {
3034
3034
3035
3035
/* ------------------------------------------------------------------------- */
3036
3036
3037
- String *FORTRAN::get_proxyname (SwigType *classnametype ) {
3037
+ String *FORTRAN::get_proxyname (SwigType *basetype ) {
3038
3038
Node *n = NULL ;
3039
3039
3040
- bool is_enum = SwigType_isenum (classnametype );
3040
+ bool is_enum = SwigType_isenum (basetype );
3041
3041
if (is_enum) {
3042
- n = this ->enumLookup (classnametype );
3042
+ n = this ->enumLookup (basetype );
3043
3043
} else {
3044
- n = this ->classLookup (classnametype );
3044
+ n = this ->classLookup (basetype );
3045
3045
}
3046
3046
3047
3047
if (n && (!is_enum || is_wrapped_enum (n))) {
3048
3048
// Class node or enum with already-generated wrapper
3049
3049
return this ->get_fsymname (n);
3050
3050
}
3051
3051
3052
- String *replacementname = create_mangled_fname (classnametype );
3052
+ String *replacementname = create_mangled_fname (basetype );
3053
3053
if (Getattr (d_emitted_mangled, replacementname)) {
3054
3054
// Mangled type has already been emitted
3055
3055
return replacementname;
@@ -3059,7 +3059,7 @@ String *FORTRAN::get_proxyname(SwigType *classnametype) {
3059
3059
// Create a node so we can insert into the fortran symbol table
3060
3060
n = NewHash ();
3061
3061
set_nodeType (n, (is_enum ? " enumforward" : " classforward" ));
3062
- Setattr (n, " name" , classnametype );
3062
+ Setattr (n, " name" , basetype );
3063
3063
if (this ->add_fsymbol (replacementname, n) == SWIG_NOWRAP) {
3064
3064
ASSERT_OR_PRINT_NODE (false , n);
3065
3065
return NULL ;
@@ -3083,12 +3083,12 @@ String *FORTRAN::get_proxyname(SwigType *classnametype) {
3083
3083
3084
3084
/* ------------------------------------------------------------------------- */
3085
3085
3086
- bool FORTRAN::is_wrapped_type (SwigType *classnametype ) {
3087
- if (SwigType_isenum (classnametype )) {
3088
- Node *n = this ->enumLookup (classnametype );
3086
+ bool FORTRAN::is_wrapped_type (SwigType *basetype ) {
3087
+ if (SwigType_isenum (basetype )) {
3088
+ Node *n = this ->enumLookup (basetype );
3089
3089
return n && is_wrapped_enum (n);
3090
3090
} else {
3091
- return this ->classLookup (classnametype ) != NULL ;
3091
+ return this ->classLookup (basetype ) != NULL ;
3092
3092
}
3093
3093
}
3094
3094
@@ -3118,12 +3118,12 @@ bool FORTRAN::is_wrapped_class(Node *n) {
3118
3118
if (!tm) {
3119
3119
// Somehow there's no ftype; allow it to be wrapped so the error is handled later
3120
3120
result = true ;
3121
- } else if (Strstr (tm, " $fclassname " )) {
3121
+ } else if (Strstr (tm, " $fortranclassname " )) {
3122
3122
result = this ->is_wrapped_type (strippedtype);
3123
- } else if (Strstr (tm, " $*fclassname " )) {
3123
+ } else if (Strstr (tm, " $*fortranclassname " )) {
3124
3124
SwigType_pop (strippedtype);
3125
3125
result = this ->is_wrapped_type (strippedtype);
3126
- } else if (Strstr (tm, " $&fclassname " )) {
3126
+ } else if (Strstr (tm, " $&fortranclassname " )) {
3127
3127
SwigType_add_pointer (strippedtype);
3128
3128
result = this ->is_wrapped_type (strippedtype);
3129
3129
} else {
0 commit comments