Skip to content

Commit

Permalink
Updating Guice to 4.0 and deleting temporary injections
Browse files Browse the repository at this point in the history
  • Loading branch information
Robertorosmaninho committed Sep 14, 2023
1 parent a042195 commit ca809a2
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 31 deletions.
8 changes: 4 additions & 4 deletions kernel/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>4.0-beta5</version>
<version>4.0</version>
<classifier>no_aop</classifier>
</dependency>
<dependency>
<groupId>com.google.inject.extensions</groupId>
<artifactId>guice-multibindings</artifactId>
<version>4.0-beta5</version>
<version>4.0</version>
<exclusions>
<exclusion>
<groupId>com.google.inject</groupId>
Expand All @@ -49,7 +49,7 @@
<dependency>
<groupId>com.google.inject.extensions</groupId>
<artifactId>guice-grapher</artifactId>
<version>4.0-beta5</version>
<version>4.0</version>
<exclusions>
<exclusion>
<groupId>com.google.inject</groupId>
Expand All @@ -60,7 +60,7 @@
<dependency>
<groupId>com.google.inject.extensions</groupId>
<artifactId>guice-throwingproviders</artifactId>
<version>4.0-beta5</version>
<version>4.0</version>
<exclusions>
<exclusion>
<groupId>com.google.inject</groupId>
Expand Down
7 changes: 0 additions & 7 deletions kernel/src/main/java/org/kframework/main/GlobalOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,6 @@ public final class GlobalOptions {

public GlobalOptions() {}

//TODO(dwightguth): remove in Guice 4.0
/**
* Prevents instantiation by Guice when not explicitly configured in a Module.
*/
@Inject
public GlobalOptions(Void v) {}

public GlobalOptions(boolean debug, Warnings warnings, boolean verbose) {
this.debug = debug;
this.warnings = warnings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,6 @@ public PrintOptions(OutputModes output) {
this.output = output;
}

//TODO(dwightguth): remove in Guice 4.0
/**
* Prevents instantiation by Guice when not explicitly configured in a Module.
*/
@Inject
public PrintOptions(Void v) {
}

@Parameter(names = "--color", description = "Use colors in output. Default is on.", descriptionKey = "mode",
converter=ColorModeConverter.class)
private ColorSetting color;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ public class BackendOptions implements Serializable {

public BackendOptions() {}

//TODO(dwightguth): remove in Guice 4.0
@Inject
public BackendOptions(Void v) {}

@Parameter(names="--dry-run", description="Compile program into KORE format but do not run. Only used in Haskell and LLVM backend.")
public boolean dryRun = false;
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@ public class DefinitionLoadingOptions {

public DefinitionLoadingOptions() {}

//TODO(dwightguth): remove in Guice 4.0
@Inject
public DefinitionLoadingOptions(Void v) {}

@Parameter(names={"--directory", "-d"}, description="[DEPRECATED] Path to the directory in which the kompiled " +
"K definition resides. The default is the unique, only directory with the suffix '-kompiled' " +
"in the current directory.", descriptionKey = "path", hidden = true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ public class SMTOptions implements Serializable {

public SMTOptions() {}

//TODO(dwightguth): remove in Guice 4.0
@Inject
public SMTOptions(Void v) {}

@Parameter(names="--smt", converter=SMTSolverConverter.class, description="SMT solver to use for checking constraints. <executable> is one of [z3|none].", descriptionKey = "executable", hidden = true)
public SMTSolver smt = SMTSolver.Z3;

Expand Down

0 comments on commit ca809a2

Please sign in to comment.