-
Notifications
You must be signed in to change notification settings - Fork 152
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
In 7ba37fb (8 years ago), we disabled cell collection syntax productions when parsing rules because of OOMs in the compiler. We haven't needed to use this syntax since then, but @PetarMax recently identified a lemma that required being able to do so. --------- Co-authored-by: Petar Maksimović <PetarMax@users.noreply.github.com>
- Loading branch information
Showing
10 changed files
with
111 additions
and
7 deletions.
There are no files selected for viewing
1 change: 1 addition & 0 deletions
1
k-distribution/tests/regression-new/star-multiplicity-concat/1.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#putCells |
22 changes: 22 additions & 0 deletions
22
k-distribution/tests/regression-new/star-multiplicity-concat/1.test.out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<generatedTop> | ||
<k> | ||
<cell> | ||
<num> | ||
0 | ||
</num> | ||
<data> | ||
0 | ||
</data> | ||
</cell> <cell> | ||
<num> | ||
1 | ||
</num> | ||
<data> | ||
1 | ||
</data> | ||
</cell> ~> .K | ||
</k> | ||
<cells> | ||
.CellCellMap | ||
</cells> | ||
</generatedTop> |
7 changes: 7 additions & 0 deletions
7
k-distribution/tests/regression-new/star-multiplicity-concat/Makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
DEF=test | ||
EXT=test | ||
TESTDIR=. | ||
KOMPILE_BACKEND=llvm | ||
KOMPILE_FLAGS=--syntax-module TEST | ||
|
||
include ../../../include/kframework/ktest.mak |
24 changes: 24 additions & 0 deletions
24
k-distribution/tests/regression-new/star-multiplicity-concat/test.k
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// Copyright (c) Runtime Verification, Inc. All Rights Reserved. | ||
module TEST | ||
imports INT | ||
|
||
configuration | ||
<k> $PGM:K </k> | ||
<cells> | ||
<cell multiplicity="*" type="Map"> | ||
<num> 0 </num> | ||
<data> 0 </data> | ||
</cell> | ||
</cells> | ||
|
||
syntax CellCellMap ::= #makeCell( Int, Int ) [function] | ||
// ---------------------------- | ||
rule #makeCell( X, Y ) => CellCellMapItem( | ||
<num> X </num>, | ||
<cell> <num> X </num> <data> Y </data> </cell> | ||
) | ||
|
||
syntax KItem ::= "#putCells" | ||
// ---------------------------- | ||
rule <k> #putCells => #makeCell(0,0) (#makeCell(1,1) .CellCellMap) </k> | ||
endmodule |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#putCells |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<generatedTop> | ||
<k> | ||
<cell> | ||
<num> | ||
0 | ||
</num> | ||
<data> | ||
0 | ||
</data> | ||
</cell> <cell> | ||
<num> | ||
1 | ||
</num> | ||
<data> | ||
1 | ||
</data> | ||
</cell> ~> .K | ||
</k> | ||
<cells> | ||
.CellCellMap | ||
</cells> | ||
<generatedCounter> | ||
0 | ||
</generatedCounter> | ||
</generatedTop> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
DEF=test | ||
EXT=test | ||
TESTDIR=. | ||
KOMPILE_BACKEND=llvm | ||
KOMPILE_FLAGS=--syntax-module TEST | ||
|
||
include ../include/ktest.mak |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// Copyright (c) Runtime Verification, Inc. All Rights Reserved. | ||
module TEST | ||
imports INT | ||
|
||
configuration | ||
<k> $PGM:K </k> | ||
<cells> | ||
<cell multiplicity="*" type="Map"> | ||
<num> 0 </num> | ||
<data> 0 </data> | ||
</cell> | ||
</cells> | ||
|
||
syntax CellCellMap ::= #makeCell( Int, Int ) [function] | ||
// ---------------------------- | ||
rule #makeCell( X, Y ) => CellCellMapItem( | ||
<num> X </num>, | ||
<cell> <num> X </num> <data> Y </data> </cell> | ||
) | ||
|
||
syntax KItem ::= "#putCells" | ||
// ---------------------------- | ||
rule <k> #putCells => #makeCell(0,0) (#makeCell(1,1) .CellCellMap) </k> | ||
endmodule |