If I have:
namespace X {
struct Y {
...
};
}
All 'copyToR' methods get parsed like this:
setMethod('copyToR', '_p_X::Y', CopyToR_X__Y)
In matchSignature(signature, fdef, where) :
in the method signature for function "copyToR" no definition for class: “_p_X::Y”
It should be parsed to:
setMethod('copyToR', '_p_X__Y', CopyToR_X__Y)
r-base version 2.10.1-2
swig version 2.0.2
Assigning to Joseph.
in r.cxx, changing the line
Printf(sfile, "setMethod('copyToR', '_p_%s', CopyToR%s);\n", rclassName,
mangledName);
to
Printf(sfile, "setMethod('copyToR', '_p%s', CopyToR%s);\n", mangledName,
mangledName);
fixes it
Any update on this? This causes warnings every time the SWIG module is loaded in R.
Still not fixed:
The suggested fix seems very plausible to me. Will test locally and open a PR.
Added a runtime testcase which fails before the change and applied in 781379351167f11873bf15feb78ed500795aecda. Fix will be in SWIG 4.1.0.