Currently, the @simplemodel macro uses staged evaluation; it generates some code, but the code it generates also uses eval. I think that we can avoid this use of eval by instead declaring @generated methods for the implementations of checkvalidity, typarg and ap. This potentially could speed up load time of Gatlab, because the bodies of the @generated methods wouldn't be evaluated until they are actually run.
Currently, the
@simplemodel
macro uses staged evaluation; it generates some code, but the code it generates also useseval
. I think that we can avoid this use ofeval
by instead declaring@generated
methods for the implementations ofcheckvalidity
,typarg
andap
. This potentially could speed up load time of Gatlab, because the bodies of the@generated
methods wouldn't be evaluated until they are actually run.