errorEof function

JSONASTException errorEof(
  1. String input,
  2. List tokenList,
  3. Settings settings
)

Implementation

JSONASTException errorEof(
    String input, List<dynamic> tokenList, Settings settings) {
  final Loc loc = tokenList.length > 0
      ? tokenList[tokenList.length - 1].loc.end
      : new Loc(line: 1, column: 1);

  final src = settings.source ?? "";
  return new JSONASTException(
      unexpectedEnd(), input, src, loc.line, loc.column);
}