forked from niklasf/python-chess
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create new function for parsing engine output
The function next_token() extracts the next word from a string and removes the leading and trailing whitespace around that word. It also returns the remainder of the string unchanged. Using this function instead of split() gets rid of extraneous whitespace when searching for keywords and preserves whitespace in strings generated by users and their engines.
- Loading branch information
Showing
1 changed file
with
110 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters