(Context ctx)
| 1242 | // / Demonstrates how to initialize the parser symbol table. |
| 1243 | |
| 1244 | public void parserExample2(Context ctx) throws TestFailedException |
| 1245 | { |
| 1246 | System.out.println("ParserExample2"); |
| 1247 | Log.append("ParserExample2"); |
| 1248 | |
| 1249 | Symbol[] declNames = { ctx.mkSymbol("a"), ctx.mkSymbol("b") }; |
| 1250 | FuncDecl<IntSort> a = ctx.mkConstDecl(declNames[0], ctx.mkIntSort()); |
| 1251 | FuncDecl<IntSort> b = ctx.mkConstDecl(declNames[1], ctx.mkIntSort()); |
| 1252 | FuncDecl[] decls = new FuncDecl[] { a, b }; |
| 1253 | |
| 1254 | BoolExpr f = ctx.parseSMTLIB2String("(assert (> a b))", null, null, declNames, decls)[0]; |
| 1255 | System.out.printf("formula: %s%n", f); |
| 1256 | check(ctx, f, Status.SATISFIABLE); |
| 1257 | } |
| 1258 | |
| 1259 | // / Demonstrates how to initialize the parser symbol table. |
| 1260 |
no test coverage detected