Vector and matrix variables with dimension of size 0

Yeah we do what Daniel mentioned a lot in the Stan programs for rstanarm. For example, it allows us to do something like

data {
  ...
  int<lower=0,upper=1> has_intercept;
}
parameters {
  ...
  real alpha[has_intercept];
}

so alpha will only have positive length if the user has specified a model with an intercept.

I guess I used an array and not a vector in that example, but it’s the same idea.