+
+/*
+  RECUR 1 SWIFT
+
+  Simply run with: 'swift-t recur-1.swift'
+*/
 
 app (void v) dummy(string parent, int stage, int id, void block)
 {

N = 4;

void A[string];

int stage = 1;
foreach id in [0:N-1]
{
  string this = int2string(id);
  v = dummy("", 2, id, propagate());
  foreach id_child in [0:N-1]
  {
    runstage(N, this, stage+1, id_child, v);
  }
}

(void v) runstage(int N, string parent, int stage, int id, void block)
{

    }
  }
}

int stage = 1;
foreach id in [0:N-1]
{
  runstage(N, "", stage, id, propagate());
}
