Sorry message for multi-dimension foreach loop indices.

This commit is contained in:
Stephen Williams 2014-08-21 20:34:55 -07:00
parent 8b969202c0
commit 5de83906f7
1 changed files with 5 additions and 1 deletions

View File

@ -731,7 +731,11 @@ PForeach* pform_make_foreach(const struct vlltype&loc,
perm_string use_index = loop_vars->front();
loop_vars->pop_front();
ivl_assert(loc, loop_vars->empty());
if (! loop_vars->empty()) {
cerr << loc.get_fileline() << ": sorry: "
<< "Multi-dimension foreach indices not supported." << endl;
error_count += 1;
}
delete loop_vars;
PForeach*fe = new PForeach(use_name, use_index, stmt);