use of constraints like allowed-values

2009-05-05
2012-11-23
  • Jack  Widman
    Jack Widman
    2009-05-05

    I think there is something fundamental I am missing.

    (defclass A (slot i (type INTEGER)))

    I am assuming that I cannot do

    (make-instance a of A (i "hello"))

    But CLIPS lets me. Is this the desired behavior?

    Also with allowed-values.

    Is there some flag I need to use or are these constraints meant to be a suggestion or for documentation purposes?

    Thanks.

     
    • Jack  Widman
      Jack Widman
      2009-05-06

      Never mind. I just learned about (set-dynamic-constraint-checking TRUE)