diff options
author | Morgan Deters <mdeters@cs.nyu.edu> | 2013-04-23 23:03:37 -0400 |
---|---|---|
committer | Morgan Deters <mdeters@cs.nyu.edu> | 2013-04-23 23:16:58 -0400 |
commit | b25991f4c2779c34b51cd51b943290a4a3d2a9fd (patch) | |
tree | aaec41cf29cc3574288c6110ba246f361d84ec3a /src/expr/mkkind | |
parent | a006e7b92327668b76a1ab993007f42fe91052c3 (diff) |
Theory "alternates" support
* This is a feature that Dejan and I want for the upcoming tutorial.
It allows rapid prototyping of new decision procedure implementations
(which we may choose to demonstrate), and a new --use-theory command-line
option to select from different available implementations. It has no
affect on the current set of theories, as no "alternates" are defined.
* Also update the new-theory script, which was broken and incomplete.
Diffstat (limited to 'src/expr/mkkind')
-rwxr-xr-x | src/expr/mkkind | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/src/expr/mkkind b/src/expr/mkkind index f8432466d..02e0f50bf 100755 --- a/src/expr/mkkind +++ b/src/expr/mkkind @@ -77,10 +77,15 @@ theory_enum= theory_descriptions= function theory { - # theory T header + # theory ID T header lineno=${BASH_LINENO[0]} + if $seen_theory; then + echo "$kf:$lineno: error: multiple theories defined in one file !?" >&2 + exit 1 + fi + # this script doesn't care about the theory class information, but # makes does make sure it's there seen_theory=true @@ -106,6 +111,20 @@ function theory { " } +function alternate { + # alternate ID name T header + + lineno=${BASH_LINENO[0]} + + if $seen_theory; then + echo "$kf:$lineno: error: multiple theories defined in one file !?" >&2 + exit 1 + fi + + seen_theory=true + seen_endtheory=true +} + function properties { # rewriter class header lineno=${BASH_LINENO[0]} |