peek_code/2

"peek_code(+ S, - C" ) is iso

If C is unbound, or is the code for a character, and the stream S is a text stream, read the next character from the current stream and unify its code with C, while leaving the current stream position unaltered.