cgen: fix error for interface and embedded struct build (#13530)
parent
67e33bf9bc
commit
09f08e1fee
|
@ -5633,6 +5633,9 @@ static inline __shared__$interface_name ${shared_fn_name}(__shared__$cctype* x)
|
||||||
methods_wrapper.write_string('.$esym.embed_name()')
|
methods_wrapper.write_string('.$esym.embed_name()')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if fargs.len > 1 {
|
||||||
|
methods_wrapper.write_string(', ')
|
||||||
|
}
|
||||||
methods_wrapper.writeln('${fargs[1..].join(', ')});')
|
methods_wrapper.writeln('${fargs[1..].join(', ')});')
|
||||||
} else {
|
} else {
|
||||||
if parameter_name.starts_with('__shared__') {
|
if parameter_name.starts_with('__shared__') {
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
pub struct Event {}
|
||||||
|
|
||||||
|
pub struct ViewBase {}
|
||||||
|
|
||||||
|
pub fn (vb ViewBase) point_inside(e Event) {}
|
||||||
|
|
||||||
|
pub struct ContainerBase {
|
||||||
|
ViewBase
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Focusable {
|
||||||
|
point_inside(Event)
|
||||||
|
}
|
||||||
|
|
||||||
|
fn test_interface_and_embedded_struct_build() {
|
||||||
|
assert true
|
||||||
|
}
|
Loading…
Reference in New Issue