Skip to content

Commit

Permalink
You’re never too experienced to make dumb mistakes :P (#577)
Browse files Browse the repository at this point in the history
  • Loading branch information
robin-aws authored Sep 11, 2024
1 parent 97e702a commit 7b2982a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -145,10 +145,8 @@ public static void main(String[] args) {
cliArguments.patchFilesDir.ifPresent(engineBuilder::withPatchFilesDir);
final CodegenEngine engine = engineBuilder.build();
switch (cliArguments.command) {
case GENERATE:
engine.run();
case PATCH_AFTER_TRANSPILE:
engine.patchAfterTranspiling();
case GENERATE -> engine.run();
case PATCH_AFTER_TRANSPILE -> engine.patchAfterTranspiling();
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -885,10 +885,6 @@ private void patchRustAfterTranspiling() {
final List<String> lines = Files.readAllLines(
implementationFromDafnyPath
);
// TODO fix root cause of duplicate extra declarations
if (lines.contains("// (extra-declarations)")) {
return;
}
final int firstModDeclIndex = IntStream
.range(0, lines.size())
.filter(i -> lines.get(i).trim().startsWith("pub mod"))
Expand Down

0 comments on commit 7b2982a

Please sign in to comment.