ASTExternalVariable now covers several scenarios: fetch a variable from the postsynaptic partner, fetch a variable from the postsynaptic partner at a specific time in the spiking history buffer, and at a specific time in a continuous-time history buffer.
To keep these cases separated, it might be an option to introduce a variable type enum covering each of these cases as a class attribute.
This would help to clean up the following lines of code in the printer:
This is a design idea for a refactoring/cleanup.
ASTExternalVariable now covers several scenarios: fetch a variable from the postsynaptic partner, fetch a variable from the postsynaptic partner at a specific time in the spiking history buffer, and at a specific time in a continuous-time history buffer.
To keep these cases separated, it might be an option to introduce a variable type enum covering each of these cases as a class attribute.
This would help to clean up the following lines of code in the printer:
https://github.com/nest/nestml/blob/dea633c46ecbb328637a28aa443c4866f51fec4b/pynestml/codegeneration/printers/nest_variable_printer.py#L65