1

I'm trying to run a chess.pl engine in SICStus prolog but I'm getting this error: Which command should I execute to run that page code ? I've tried several options none of which works.

(Perhaps compile chess.pl in the last but one line in the snippet should be replaced by some other command)

enter image description here

EDIT However startGame. does something a bit useful:

enter image description here

But now, F2,F3. gives

Instantiation error in argument ` of call/1
goal: call(user:_195)
?-
false
  • 10,264
  • 13
  • 101
  • 209

1 Answers1

3

This code contains non-standard escape sequences like \u265B. Replace these sequences by a standard escape sequence as they are supported by SICStus, like \x265B\ which denotes a "black chess queen". Note that two backslashes are needed for each such character one at the beginning and one at the end.

As for read_string/3, this indicates that the code you have uses a non-standard data type. A relatively fitting replacement in SICStus would be to use atoms in stead. So there will be some more changes here.

false
  • 10,264
  • 13
  • 101
  • 209