Browse Source

cppparser: fix formatting of typecast operator

rdb 7 years ago
parent
commit
5da8b63a66
1 changed files with 4 additions and 0 deletions
  1. 4 0
      dtool/src/cppparser/cppFunctionType.cxx

+ 4 - 0
dtool/src/cppparser/cppFunctionType.cxx

@@ -292,6 +292,10 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
 
     out << str;
 
+  } else if (_flags & F_operator_typecast) {
+    out << "operator ";
+    _return_type->output_instance(out, indent_level, scope, complete, "", prename + str);
+
   } else {
     if (prename.empty()) {
       _return_type->output_instance(out, indent_level, scope, complete,