@@ -2764,44 +2764,6 @@ void CodegenNeuronCppVisitor::print_net_event_call(const ast::FunctionCall& /* n
27642764 printer->fmt_text (" net_event({}, t)" , point_process);
27652765}
27662766
2767- void CodegenNeuronCppVisitor::print_nrn_state_disc (const ast::FunctionCall& node) {
2768- printer->push_block (" if (nrn_netrec_state_adjust && !cvode_active_)" );
2769- printer->add_text (" double state = " );
2770- const auto & args = node.get_arguments ();
2771- const auto & first = args[0 ];
2772- const auto & second = args[1 ];
2773- first->accept (*this );
2774- printer->add_text (" ;" );
2775- printer->add_newline ();
2776- printer->add_text (" double primary_delta = (" );
2777- second->accept (*this );
2778- printer->add_text (" ) - state;" );
2779- printer->add_newline ();
2780- printer->add_line (" double dtsav = nt->_dt;" );
2781- printer->fmt_push_block (" for(auto i = 0; i < {}(0); ++i)" ,
2782- method_name (naming::CVODE_COUNT_NAME ));
2783- printer->add_line (" // TODO: add setting stuff to zero" );
2784- printer->pop_block ();
2785- printer->add_line (" // TODO: add setting first element" );
2786- printer->add_line (" nt->_dt *= 0.5;" );
2787- printer->add_line (" // TODO: add v" );
2788- printer->fmt_line (" {}({});" ,
2789- method_name (naming::CVODE_UPDATE_STIFF_NAME ),
2790- get_arg_str (cvode_update_parameters ()));
2791- printer->add_line (" nt->_dt = dtsav;" );
2792- printer->fmt_push_block (" for(auto i = 0; i < {}(0); ++i)" ,
2793- method_name (naming::CVODE_COUNT_NAME ));
2794- printer->add_line (" // TODO: add updating of data" );
2795- printer->pop_block ();
2796- printer->pop_block ();
2797- printer->push_block (" else" );
2798- print_vector_elements (args, " = " );
2799- printer->add_text (" ;" );
2800- printer->add_newline ();
2801- printer->pop_block ();
2802- }
2803-
2804-
28052767void CodegenNeuronCppVisitor::print_function_table_call (const FunctionCall& node) {
28062768 auto name = node.get_node_name ();
28072769 const auto & arguments = node.get_arguments ();
0 commit comments