Skip to content

Commit

Permalink
Rename HOC/Py wrapper function name.
Browse files Browse the repository at this point in the history
  • Loading branch information
1uc committed Oct 18, 2024
1 parent a7dce33 commit e87c7c3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
9 changes: 4 additions & 5 deletions src/codegen/codegen_neuron_cpp_visitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -389,9 +389,8 @@ void CodegenNeuronCppVisitor::print_hoc_py_wrapper_setup(
}
}

void CodegenNeuronCppVisitor::print_hoc_py_wrapper_function_body(
const ast::Block* function_or_procedure_block,
InterpreterWrapper wrapper_type) {
void CodegenNeuronCppVisitor::print_hoc_py_wrapper(const ast::Block* function_or_procedure_block,
InterpreterWrapper wrapper_type) {
if (info.point_process && wrapper_type == InterpreterWrapper::Python) {
return;
}
Expand All @@ -414,8 +413,8 @@ void CodegenNeuronCppVisitor::print_hoc_py_wrapper_function_body(
void CodegenNeuronCppVisitor::print_hoc_py_wrapper_function_definitions() {
auto print_wrappers = [this](const auto& callables) {
for (const auto& callable: callables) {
print_hoc_py_wrapper_function_body(callable, InterpreterWrapper::HOC);
print_hoc_py_wrapper_function_body(callable, InterpreterWrapper::Python);
print_hoc_py_wrapper(callable, InterpreterWrapper::HOC);
print_hoc_py_wrapper(callable, InterpreterWrapper::Python);
}
};

Expand Down
4 changes: 2 additions & 2 deletions src/codegen/codegen_neuron_cpp_visitor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,8 @@ class CodegenNeuronCppVisitor: public CodegenCppVisitor {
* * Print setup code `inst`, etc.
* * Print code to call the function and return.
*/
void print_hoc_py_wrapper_function_body(const ast::Block* function_or_procedure_block,
InterpreterWrapper wrapper_type);
void print_hoc_py_wrapper(const ast::Block* function_or_procedure_block,
InterpreterWrapper wrapper_type);

/** Print the setup code for HOC/Py wrapper.
*/
Expand Down

0 comments on commit e87c7c3

Please sign in to comment.