mirror of
https://github.com/mappu/miqt.git
synced 2025-01-21 06:00:38 +00:00
genbindings: fix some cases of missing :: escaping
This commit is contained in:
parent
0884f371c1
commit
90de7178f2
@ -759,14 +759,14 @@ func emitParametersCabiConstructor(c *CppClass, ctor *CppMethod) string {
|
|||||||
plist := slice_copy(ctor.Parameters) // semi-shallow copy
|
plist := slice_copy(ctor.Parameters) // semi-shallow copy
|
||||||
|
|
||||||
plist = append(plist, CppParameter{
|
plist = append(plist, CppParameter{
|
||||||
ParameterName: cabiClassName("outptr_" + c.ClassName),
|
ParameterName: cabiClassName("outptr_" + cabiClassName(c.ClassName)),
|
||||||
ParameterType: c.ClassName,
|
ParameterType: c.ClassName,
|
||||||
Pointer: true,
|
Pointer: true,
|
||||||
PointerCount: 2,
|
PointerCount: 2,
|
||||||
})
|
})
|
||||||
for _, baseClass := range c.AllInherits() {
|
for _, baseClass := range c.AllInherits() {
|
||||||
plist = append(plist, CppParameter{
|
plist = append(plist, CppParameter{
|
||||||
ParameterName: cabiClassName("outptr_" + baseClass),
|
ParameterName: cabiClassName("outptr_" + cabiClassName(baseClass)),
|
||||||
ParameterType: baseClass,
|
ParameterType: baseClass,
|
||||||
Pointer: true,
|
Pointer: true,
|
||||||
PointerCount: 2,
|
PointerCount: 2,
|
||||||
@ -986,7 +986,7 @@ func emitBindingCpp(src *CppParsedHeader, filename string) (string, error) {
|
|||||||
"\t*outptr_" + cabiClassName(c.ClassName) + " = ret;\n", // Original class name
|
"\t*outptr_" + cabiClassName(c.ClassName) + " = ret;\n", // Original class name
|
||||||
)
|
)
|
||||||
for _, baseClass := range c.AllInherits() {
|
for _, baseClass := range c.AllInherits() {
|
||||||
ret.WriteString("\t*outptr_" + baseClass + " = static_cast<" + baseClass + "*>(ret);\n")
|
ret.WriteString("\t*outptr_" + cabiClassName(baseClass) + " = static_cast<" + baseClass + "*>(ret);\n")
|
||||||
}
|
}
|
||||||
|
|
||||||
ret.WriteString(
|
ret.WriteString(
|
||||||
|
@ -862,7 +862,7 @@ import "C"
|
|||||||
ret.WriteString(`var outptr_` + cabiClassName(c.ClassName) + ` *C.` + goClassName + " = nil\n")
|
ret.WriteString(`var outptr_` + cabiClassName(c.ClassName) + ` *C.` + goClassName + " = nil\n")
|
||||||
outptrs = append(outptrs, "outptr_"+cabiClassName(c.ClassName))
|
outptrs = append(outptrs, "outptr_"+cabiClassName(c.ClassName))
|
||||||
for _, baseClass := range c.AllInherits() {
|
for _, baseClass := range c.AllInherits() {
|
||||||
ret.WriteString(`var outptr_` + cabiClassName(baseClass) + ` *C.` + baseClass + " = nil\n")
|
ret.WriteString(`var outptr_` + cabiClassName(baseClass) + ` *C.` + cabiClassName(baseClass) + " = nil\n")
|
||||||
outptrs = append(outptrs, "outptr_"+cabiClassName(baseClass))
|
outptrs = append(outptrs, "outptr_"+cabiClassName(baseClass))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user