Skip to content

Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →

instance method

StringScanner#scan_byte

scan_byte → integer_byte or nil

Scans one byte and returns it as an integer. This method is not multibyte character sensitive. See also: getch.