Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove old workaround #4485

Merged
merged 8 commits into from
Jun 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#putCells
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>
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
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
Original file line number Diff line number Diff line change
Expand Up @@ -547,9 +547,6 @@ public static Tuple3<Module, Module, Module> getCombinedGrammarImpl(
Stream.concat(prods.stream(), stream(mod.sentences()))
.flatMap(
s -> {
if (s instanceof Production && s.att().contains(Att.CELL_COLLECTION())) {
return Stream.empty();
}
if (s instanceof Production p && (s.att().contains(Att.CELL()))) {
// assuming that productions tagged with 'cell' start and end with terminals,
// and only have non-terminals in the middle
Expand Down
4 changes: 0 additions & 4 deletions pyk/regression-new/include/ktest.mak
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,6 @@ SOURCE_EXT?=$(or $(and $(wildcard $(DEF).k), k), $(or $(and $(wildcard $(DEF).md

VERBOSITY?=

ifeq ($(UNAME), Darwin)
KOMPILE_FLAGS+=--no-haskell-binary
endif

KOMPILE_FLAGS+=--no-exc-wrap --type-inference-mode checked $(VERBOSITY)
KRUN_FLAGS+=$(VERBOSITY)
KPROVE_FLAGS+=--type-inference-mode checked --failure-info $(VERBOSITY)
Expand Down
1 change: 1 addition & 0 deletions pyk/regression-new/star-multiplicity-concat/1.test
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
#putCells
25 changes: 25 additions & 0 deletions pyk/regression-new/star-multiplicity-concat/1.test.out
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>
7 changes: 7 additions & 0 deletions pyk/regression-new/star-multiplicity-concat/Makefile
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
24 changes: 24 additions & 0 deletions pyk/regression-new/star-multiplicity-concat/test.k
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
Loading