aboutsummaryrefslogtreecommitdiff
path: root/Source/Modules/java.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Modules/java.cxx')
-rw-r--r--Source/Modules/java.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx
index 259f23f8e..fcc83819d 100644
--- a/Source/Modules/java.cxx
+++ b/Source/Modules/java.cxx
@@ -1633,7 +1633,7 @@ public:
if (classname_substituted_flag) {
if (SwigType_isenum(t)) {
// This handles wrapping of inline initialised const enum static member variables (not when wrapping enum items - ignored later on)
- Printf(constants_code, "%s.swigToEnum(%s.%s());\n", return_type, full_imclass_name, Swig_name_get(getNSpace(), symname));
+ Printf(constants_code, "%s.swigToEnum(%s.%s());\n", return_type, full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname));
} else {
// This handles function pointers using the %constant directive
Printf(constants_code, "new %s(%s.%s(), false);\n", return_type, full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname));