2

I am using the K semantics Framework and running tutorials this is my TEST1.k :

module TEST1-SYNTAX 
import DOMAINS


syntax Fun ::= "add(" Pgm "," Pgm ")"        [strict]
syntax Pgm ::= Int 
            | Fun

endmodule

module TEST1
import TEST1-SYNTAX

    rule add( I1:Int , I2:Int) => I1 +Int I2

    configuration <T  color="blue">
                <k color ="red"> $PGM:Pgm </k> 


    </T>
endmodule

but I get this error when run command Kompile Test1.k:

File "realdef.ml", line 2151, characters 331-338:
Error: This variant expression is expected to have type bool
   The constructor KApply1 does not belong to type bool
 [Error] Critical: ocamlopt returned nonzero exit code: 2
Examine output to see errors.
nishantjr
  • 1,788
  • 1
  • 15
  • 39
Mohsen Rahnamaei
  • 401
  • 1
  • 3
  • 15
  • i know that problem is in [strict]. because when i remove that everything is ok but I wanted – Mohsen Rahnamaei Jul 27 '19 at 12:54
  • 1
    it looks like a bug in the ocaml-backend (even if your input is wrong, this is not a sane way to report it), so please submit a bug report to the upstream: https://github.com/kframework/k/issues – ivg Jul 29 '19 at 13:42

0 Answers0