Using a mixin:

string f(string x) { return "_" ~ x; }

int main() {
  mixin("int "~f("x")~" = 3;");
  return _x;
}

Reply via email to