Anonymous | Login | 2022-06-26 14:19 UTC | ![]() |
My View | View Issues | Change Log | Roadmap |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0000098 | OMNeT++ | simulation kernel | public | 2009-08-27 14:19 | 2010-05-26 19:59 | ||||
Reporter | rhornig | ||||||||
Assigned To | andras | ||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||
Status | resolved | Resolution | fixed | ||||||
Platform | OS | OS Version | |||||||
Product Version | 4.0 | ||||||||
Target Version | Fixed in Version | 4.1rc1 | |||||||
Summary | 0000098: Assignment of a compound module parameter in a submodule does not assign the unit | ||||||||
Description | I ran into some problems using the @unit property for integer parameters of compound modules and was hoping for some feedback to clear up my confusion or confirmation that there's something wrong. Here are the important parts of the simple module definition: simple SimpleApp { volatile int msgLength @unit(b) = default(1024b); } and of the compound module: module StumpNode { parameters: volatile int pktLength @unit(b); submodules: app: SimpleApp{ parameters: msgLength = pktLength; } } In omnetpp.ini I have: **.pktLength = 2048b Running the simulation yields the following error: Error evaluating parameter `msgLength': Cannot convert unit none to 'b' (bit) After some debugging, I found that if I change the following code: cdynamicexpression.cc line 95: case cPar::LONG: *this = par.doubleValue(); break; to case cPar::LONG: *this = par.doubleValue(); dblunit = par.getUnit(); break; Then, it works as expected. Also, changing the compound module parameter type to double fixes the problem. | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
![]() |
|||
Date Modified | Username | Field | Change |
2009-08-27 14:19 | rhornig | New Issue | |
2010-05-26 19:59 | andras | Note Added: 0000307 | |
2010-05-26 19:59 | andras | Status | new => resolved |
2010-05-26 19:59 | andras | Fixed in Version | => 4.1rc1 |
2010-05-26 19:59 | andras | Resolution | open => fixed |
2010-05-26 19:59 | andras | Assigned To | => andras |
Copyright © 2000 - 2022 MantisBT Team |