add AppMode for best boundaries over stdlib
JaCoCo Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 61.98% (17344/27983)
* Branch Coverage: 53.07% (6720/12663)
* Lines of Code: 27983
* Cyclomatic Complexity: 11207
#### Quality Gates Summary
Output truncated.
Test / Build skipped: 11, passed: 581
Intrepid/Prometeu/Studio/pipeline/head This commit looks good
Intrepid/Prometeu/Studio/pipeline/pr-master This commit looks good
JaCoCo Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 61.98% (17344/27983)
* Branch Coverage: 53.07% (6720/12663)
* Lines of Code: 27983
* Cyclomatic Complexity: 11207
#### Quality Gates Summary
Output truncated.
Test / Build skipped: 11, passed: 581
Intrepid/Prometeu/Studio/pipeline/head This commit looks good
Intrepid/Prometeu/Studio/pipeline/pr-master This commit looks good
This commit is contained in:
+21
-10
@@ -1,5 +1,6 @@
|
||||
package p.studio.compiler.messages;
|
||||
|
||||
import p.studio.AppMode;
|
||||
import p.studio.compiler.models.BuildStack;
|
||||
import p.studio.compiler.models.SourceKind;
|
||||
import p.studio.compiler.source.identifiers.ProjectId;
|
||||
@@ -13,22 +14,16 @@ public class FrontendPhaseContext {
|
||||
public final BuildStack stack;
|
||||
private final NameTable nameTable;
|
||||
private final int stdlibVersion;
|
||||
private final AppMode target;
|
||||
private final HostAdmissionContext hostAdmissionContext;
|
||||
private final FESurfaceContext feSurfaceContext;
|
||||
|
||||
public FrontendPhaseContext(
|
||||
final ProjectTableReader projectTable,
|
||||
final FileTableReader fileTable,
|
||||
final BuildStack stack) {
|
||||
this(projectTable, fileTable, stack, 1, HostAdmissionContext.permissiveDefault(), FESurfaceContext.empty());
|
||||
}
|
||||
|
||||
public FrontendPhaseContext(
|
||||
final ProjectTableReader projectTable,
|
||||
final FileTableReader fileTable,
|
||||
final BuildStack stack,
|
||||
final int stdlibVersion) {
|
||||
this(projectTable, fileTable, stack, stdlibVersion, HostAdmissionContext.permissiveDefault(), FESurfaceContext.empty());
|
||||
final AppMode target) {
|
||||
this(projectTable, fileTable, stack, 1, target, HostAdmissionContext.permissiveDefault(), FESurfaceContext.empty());
|
||||
}
|
||||
|
||||
public FrontendPhaseContext(
|
||||
@@ -36,8 +31,18 @@ public class FrontendPhaseContext {
|
||||
final FileTableReader fileTable,
|
||||
final BuildStack stack,
|
||||
final int stdlibVersion,
|
||||
final AppMode target) {
|
||||
this(projectTable, fileTable, stack, stdlibVersion, target, HostAdmissionContext.permissiveDefault(), FESurfaceContext.empty());
|
||||
}
|
||||
|
||||
public FrontendPhaseContext(
|
||||
final ProjectTableReader projectTable,
|
||||
final FileTableReader fileTable,
|
||||
final BuildStack stack,
|
||||
final int stdlibVersion,
|
||||
final AppMode target,
|
||||
final HostAdmissionContext hostAdmissionContext) {
|
||||
this(projectTable, fileTable, stack, stdlibVersion, hostAdmissionContext, FESurfaceContext.empty());
|
||||
this(projectTable, fileTable, stack, stdlibVersion, target, hostAdmissionContext, FESurfaceContext.empty());
|
||||
}
|
||||
|
||||
public FrontendPhaseContext(
|
||||
@@ -45,6 +50,7 @@ public class FrontendPhaseContext {
|
||||
final FileTableReader fileTable,
|
||||
final BuildStack stack,
|
||||
final int stdlibVersion,
|
||||
final AppMode target,
|
||||
final HostAdmissionContext hostAdmissionContext,
|
||||
final FESurfaceContext feSurfaceContext) {
|
||||
this.projectTable = projectTable;
|
||||
@@ -52,6 +58,7 @@ public class FrontendPhaseContext {
|
||||
this.stack = stack;
|
||||
this.nameTable = new NameTable();
|
||||
this.stdlibVersion = stdlibVersion;
|
||||
this.target = target;
|
||||
this.hostAdmissionContext = hostAdmissionContext == null
|
||||
? HostAdmissionContext.permissiveDefault()
|
||||
: hostAdmissionContext;
|
||||
@@ -68,6 +75,10 @@ public class FrontendPhaseContext {
|
||||
return stdlibVersion;
|
||||
}
|
||||
|
||||
public AppMode target() {
|
||||
return target;
|
||||
}
|
||||
|
||||
public HostAdmissionContext hostAdmissionContext() {
|
||||
return hostAdmissionContext;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user