XSB cannot handle negative integers

Issue #678 resolved
Joachim Jansen created an issue

Negative integers, e.g., -1 cannot be handled yet. They were previously only parsed as -(1) (application of unary - function).

Attached file performing error.

Comments (3)

  1. Joachim Jansen reporter

    Adjusted print to be able to work with negative integer domain elements.

    Added a whitespace before and after each operator, since arguments may be of the form -1. XSB only accepts this if they are written as (X = -1), and not if written as (X=-1). In the latter case, XSB will throw an error when parsing the file.

    This fixes bug #678

    Important: always add a whitespace before and after each operator, arguments may be of the form -1 which will only be accepted by XSB if they are written as (X = -1), and not if written as (X=-1)

    → <<cset c1b33cf9b3e7>>

  2. Broes De Cat

    Adjusted print to be able to work with negative integer domain elements.

    Added a whitespace before and after each operator, since arguments may be of the form -1. XSB only accepts this if they are written as (X = -1), and not if written as (X=-1). In the latter case, XSB will throw an error when parsing the file.

    This fixes bug #678

    Important: always add a whitespace before and after each operator, arguments may be of the form -1 which will only be accepted by XSB if they are written as (X = -1), and not if written as (X=-1)

    → <<cset f781f57d3986>>

  3. Log in to comment