Skip to content

Commit

Permalink
fixed #11
Browse files Browse the repository at this point in the history
  • Loading branch information
GassaFM committed Mar 21, 2020
1 parent bf03994 commit 739d14e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions source/parser.d
Original file line number Diff line number Diff line change
Expand Up @@ -557,6 +557,11 @@ final class StatementParser

FunctionBlock parseFunctionBlock (string prevIndent)
{
if (t.empty)
{
enforce (!t.empty, "program is empty");
}

auto line = t.front;
check (line.indent == prevIndent, line,
"indent does not match");
Expand Down

0 comments on commit 739d14e

Please sign in to comment.