ENHANCED: Character type checks for get_char/[1,2].

This addresses #906.
This commit is contained in:
Markus Triska
2021-11-28 10:49:40 +01:00
parent a87f0481b8
commit 5e55732cb0

View File

@@ -1311,10 +1311,12 @@ char_code(Char, Code) :-
). ).
get_char(C) :- get_char(C) :-
error:can_be(character, C),
current_input(S), current_input(S),
'$get_char'(S, C). '$get_char'(S, C).
get_char(S, C) :- get_char(S, C) :-
error:can_be(character, C),
'$get_char'(S, C). '$get_char'(S, C).
can_be_number(N, PI) :- can_be_number(N, PI) :-