d模板插件中运行

mixin template foo()
{
  int _ignoreme()
  {
    if (readln.strip == "abort") throw new AbortException;
    return 1;
  }
  int _alsoIgnoreMe = _ignoreme();
}
void main()
{
  mixin foo;
}
posted @ 2021-09-16 11:13  zjh6  阅读(13)  评论(0)    收藏  举报  来源