Hi! First of all, thanks for your reply!
Use of
evalin the macro is bad.
This is not necessarily true, as many developers in Julia say.
This will do the same thing as what you seem to be trying to do above but without
eval.
What about the case where your variables depend on other variables? Or defining a function. Or a vector in specific indexes?
For instance, you may not need
@varon each line. You can allow the user to define multiple variables in abegin .. endblock.
Yes, I have already coded it as @vars but it just changes the begin...end block for @var macro calls. Then, I just want to focus on @var.
The first thing is to figure out what you are trying to do though.
Okay, that is fair. But it seems that if I explain the whole problem it will take a while. Shortly, I want to define scalar variables, vectors, matrices, functions, etc, to build expressions that describe the drift and diffusion of stochastic processes to simulate with DifferentialEquations.jl. But I will explain expand more on that later.
Maybe someone arrives with a good idea with all the provided information.
Thank you!