From: cee1 <fy...@gm...> - 2009-12-13 13:18:05
|
Hi all, I'm reading the code of adam.cpp, and get totally lost. In the function sheet_t::implementation_t::get: (adam.cpp 1387) "if (initialize_mode_m) { ..." I've found initialize_mode_m is false when instantiates sheet_t::implementation_t, and will be true when calls add_constant, add_input or add_interface. So the following assert should always fail: (adam.cpp 1428) assert(cell.interface_input_m && ...), Because when this line is reached, the initialize_mode_m is false, then we should not have called add_constant, add_input or add_interface, so the cell is not an interface cell, assert failed. Also, I find some code that makes no sense to me, like: (adam.cpp 1267) sheet_t::implementation_t::initialize_one accumulate_contributing_m.reset(); ... cell.init_contributing_m |= accumulate_contributing_m; or (adam.cpp 1173) in function sheet_t::implementation_t::update if (cell.specifier_m == access_interface_output) get_stack_m.push_back(std::make_pair(cell.name_m, false)); ... if (cell.specifier_m == access_interface_output) get_stack_m.pop_back(); Sorry for this mass mail, but I feel lost in adam.cpp. Could someone show me the global picture of how these functions in sheet_t::implementation work? Regards, - cee1 |