Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Commit

Permalink
minfo.d is no longer throwing Errors
Browse files Browse the repository at this point in the history
  • Loading branch information
WalterBright authored and Dennis committed Mar 1, 2022
1 parent 51fd8a1 commit 57beed7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/rt/minfo.d
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ struct ModuleGroup
// release mode.
if (distance[target] != curdist)
{
throw new Error("internal error printing module cycle");
assert(0, "internal error printing module cycle");
}

// determine the path. This is tricky, because we have to
Expand Down Expand Up @@ -196,7 +196,7 @@ struct ModuleGroup
break;
default:
// invalid cycle handling option.
throw new Error("DRT invalid cycle handling option: " ~ cycleHandling);
assert(0, "DRT invalid cycle handling option: " ~ cycleHandling);
}

debug (printModuleDependencies)
Expand Down Expand Up @@ -368,7 +368,8 @@ struct ModuleGroup

string errmsg = "";
buildCycleMessage(idx, midx, (string x) {errmsg ~= x;});
throw new Error(errmsg, __FILE__, __LINE__);
assert(0, errmsg);

case ignore:
break;
case print:
Expand Down

0 comments on commit 57beed7

Please sign in to comment.