OMNeT++/OMNEST Bug Tracker - OMNeT++
View Issue Details
0000088OMNeT++simulation kernelpublic2009-07-24 09:072010-01-05 12:50
ypsilon 
levy 
highmajoralways
resolvedfixed 
4.0 
4.1 
0000088: on second extend modules loose gates?
I have a module interface defining two gates, e.g.:
moduleinterface InterfaceA {
  gates:
    inout app[];
    inout net[];
}

This interface is implemented by a module, defining the two necessary gates (which belongs to an abstract class - so I can extend the class and the module for implementation purposes - but this just for motivation, it doesn't influence the problem):
simple AbstractModuleA like InterfaceA {
  gates:
    inout app[];
    inout net[];
}


If I extend from that module:
simple ModuleA extends AbstractModuleA {
}
I can start a simulation using ModuleA.

However, it I extend from that module again:
simple ModuleAWithASpecialPurpose extends ModuleA {
}
I get upon simulation start:
<!> Error: module type has no gate `app', required by interface `InterfaceA', at [...]/ModuleAWithASpecialPurpose.ned:21.
workaround is quiet simple by extending only once but this can be quiet a structural loss for the model.
No tags attached.
? NED_inheritance_gates_iface.test (883) 2009-08-21 09:43
https://dev.omnetpp.org/bugs/file_download.php?file_id=19&type=bug
Issue History
2009-07-24 09:07ypsilonNew Issue
2009-08-21 09:43ypsilonFile Added: NED_inheritance_gates_iface.test
2009-08-21 09:49ypsilonNote Added: 0000166
2009-10-21 16:24rhornigStatusnew => confirmed
2009-10-21 16:25rhornigPrioritynormal => high
2009-10-21 16:25rhornigSeverityminor => major
2010-01-05 12:49levyAssigned To => levy
2010-01-05 12:50levyStatusconfirmed => resolved
2010-01-05 12:50levyFixed in Version => 4.1
2010-01-05 12:50levyResolutionopen => fixed

Notes
(0000166)
ypsilon   
2009-08-21 09:49   
this one is more severe than I thought for me :-(
I added a test case to help find it.

It's interesting, that the gates actually exist if one removes the "like Iface". The bug seems to happen when the interface compliance is checked.