Line numbers start at 1
Bumps the line number for the singleton warning. When the singleton
occurs on the same line at the term starts, the line number is correct:
foo(X).
However it stills mis-reports this line number as 1 instead of 5:
foo(1) :-
true,
true,
true,
Y.
See issue #1356.
This commit is contained in:
@@ -210,7 +210,8 @@ load_loop(Stream, Evacuable) :-
|
||||
'$conclude_load'(Evacuable)
|
||||
; var(Term) ->
|
||||
instantiation_error(load/1)
|
||||
; warn_about_singletons(Singletons, LinesRead),
|
||||
; LineNum is LinesRead + 1,
|
||||
warn_about_singletons(Singletons, LineNum),
|
||||
compile_term(Term, Evacuable),
|
||||
load_loop(Stream, Evacuable)
|
||||
).
|
||||
|
||||
Reference in New Issue
Block a user