Merged with remote-tracking branch 'upstream/master'.
This commit is contained in:
commit
9716d50146
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
|
|
|
@ -9,8 +9,8 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.autoboxing=error
|
||||
|
@ -105,4 +105,4 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -4,7 +4,7 @@ Bundle-Name: %Bundle-Name
|
|||
Bundle-SymbolicName: com.ibm.wala.cast.java.ecj
|
||||
Bundle-Version: 1.4.4.qualifier
|
||||
Bundle-Vendor: %Bundle-Vendor
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Require-Bundle: com.ibm.wala.cast.java,
|
||||
com.ibm.wala.core,
|
||||
org.eclipse.core.runtime,
|
||||
|
|
|
@ -3,3 +3,4 @@ output.. = bin/
|
|||
bin.includes = META-INF/,\
|
||||
.,\
|
||||
OSGI-INF/
|
||||
javacProjectSettings = true
|
||||
|
|
|
@ -42,6 +42,11 @@
|
|||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.util</artifactId>
|
||||
<version>1.4.4-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast</artifactId>
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -11,9 +11,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
|||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -48,7 +48,7 @@ org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
|
||||
|
@ -76,7 +76,7 @@ org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
|
||||
|
@ -100,7 +100,7 @@ org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=error
|
|||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=error
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=ignore
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -4,4 +4,4 @@ Bundle-Name: %Bundle-Name
|
|||
Bundle-SymbolicName: com.ibm.wala.cast.java.test.data
|
||||
Bundle-Version: 1.4.4.qualifier
|
||||
Bundle-Vendor: %Bundle-Vendor
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -9,7 +9,6 @@
|
|||
* IBM Corporation - initial API and implementation
|
||||
*****************************************************************************/
|
||||
public class CastFromNull {
|
||||
@SuppressWarnings({ "cast" })
|
||||
public static void main(String args[]) {
|
||||
new CastFromNull();
|
||||
Object x = (Object) null;
|
||||
|
|
|
@ -38,7 +38,6 @@ public class Switch1 {
|
|||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("incomplete-switch")
|
||||
public void testThree(String[] args) {
|
||||
char ch = '?';
|
||||
switch(Integer.parseInt(args[0])) {
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
package foo.bar.hello.world;
|
||||
|
||||
public class LoopsAndLabels {
|
||||
@SuppressWarnings({ "cast", "unused" })
|
||||
@SuppressWarnings("unused")
|
||||
public static void main(String args[]) {
|
||||
|
||||
aaa: do {
|
||||
|
|
|
@ -39,7 +39,6 @@ package foo.bar.hello.world;
|
|||
|
||||
public class Misc {
|
||||
|
||||
@SuppressWarnings({ "cast", "incomplete-switch" })
|
||||
public static void main(String args[]) {
|
||||
if ( "hello" instanceof Object ) {
|
||||
System.out.println("strings are objects in java");
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -14,4 +14,4 @@ Require-Bundle: com.ibm.wala.core.tests,
|
|||
org.junit;bundle-version="4.0.0"
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Export-Package: com.ibm.wala.cast.java.test
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -79,7 +79,7 @@ org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -20,4 +20,4 @@ Export-Package: com.ibm.wala.cast.java.analysis.typeInference,
|
|||
com.ibm.wala.cast.java.translator,
|
||||
com.ibm.wala.cast.java.types
|
||||
Bundle-ClassPath: .
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -42,6 +42,11 @@
|
|||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.util</artifactId>
|
||||
<version>1.4.4-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast</artifactId>
|
||||
|
|
|
@ -216,9 +216,7 @@ public class JavaCAst2IRTranslator extends AstTranslator {
|
|||
// code bodies, so we may see other things than TYPE_ENTITY here.
|
||||
IClass owner = loader.lookupClass(makeType(topEntity.getType()).getName());
|
||||
|
||||
if (owner == null) {
|
||||
assert owner != null : makeType(topEntity.getType()).getName() + " not found in " + loader;
|
||||
}
|
||||
assert owner != null : makeType(topEntity.getType()).getName() + " not found in " + loader;
|
||||
|
||||
((JavaSourceLoaderImpl) loader).defineField(n, owner);
|
||||
}
|
||||
|
@ -231,9 +229,7 @@ public class JavaCAst2IRTranslator extends AstTranslator {
|
|||
CAstType owningType = methodType.getDeclaringType();
|
||||
IClass owner = loader.lookupClass(makeType(owningType).getName());
|
||||
|
||||
if (owner == null) {
|
||||
assert owner != null : makeType(owningType).getName().toString() + " not found in " + loader;
|
||||
}
|
||||
assert owner != null : makeType(owningType).getName().toString() + " not found in " + loader;
|
||||
|
||||
((JavaSourceLoaderImpl) loader).defineAbstractFunction(N, owner);
|
||||
}
|
||||
|
@ -249,9 +245,7 @@ public class JavaCAst2IRTranslator extends AstTranslator {
|
|||
TypeName typeName = makeType(owningType).getName();
|
||||
IClass owner = loader.lookupClass(typeName);
|
||||
|
||||
if (owner == null) {
|
||||
assert owner != null : typeName.toString() + " not found in " + loader;
|
||||
}
|
||||
assert owner != null : typeName.toString() + " not found in " + loader;
|
||||
|
||||
symtab.getConstant(0);
|
||||
symtab.getNullConstant();
|
||||
|
|
|
@ -4,6 +4,6 @@
|
|||
<classpathentry kind="src" path="tests"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="lib" path="lib/htmlparser-1.4.jar"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -118,7 +118,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=0
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -13,6 +13,6 @@ Require-Bundle: com.ibm.wala.cast.js;bundle-version="1.0.0",
|
|||
com.ibm.wala.core.tests;bundle-version="1.1.3",
|
||||
com.ibm.wala.core;bundle-version="1.1.3",
|
||||
org.junit;bundle-version="4.8.1"
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-ClassPath: .,
|
||||
lib/htmlparser-1.4.jar
|
||||
|
|
|
@ -8,4 +8,4 @@ bin.includes = META-INF/,\
|
|||
jars.extra.classpath = lib/htmlparser-1.4.jar
|
||||
javacProjectSettings = true
|
||||
output.. = bin/
|
||||
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="src" path="testdata"/>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -118,7 +118,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -18,4 +18,4 @@ Require-Bundle: com.ibm.wala.cast.js.nodejs;bundle-version="1.3.10",
|
|||
com.ibm.wala.cast.js.rhino;bundle-version="1.3.10",
|
||||
com.ibm.wala.core;bundle-version="1.3.10",
|
||||
org.junit
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry kind="src" output="target/classes" path="dat">
|
||||
<classpathentry kind="src" path="dat">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry exported="true" kind="lib" path="lib/json-20160212.jar"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
|
|
|
@ -20,14 +20,8 @@
|
|||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.m2e.core.maven2Builder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.m2e.core.maven2Nature</nature>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.pde.PluginNature</nature>
|
||||
</natures>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -76,7 +76,7 @@ org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=0
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -9,4 +9,4 @@ Require-Bundle: com.ibm.wala.cast.js;bundle-version="1.3.10",
|
|||
com.ibm.wala.cast.js.rhino;bundle-version="1.3.10"
|
||||
Bundle-ClassPath: lib/json-20160212.jar,
|
||||
.
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -80,7 +80,7 @@ public class NodejsCallGraphBuilderUtil extends JSCallGraphUtil {
|
|||
CAstAnalysisScope scope = new CAstAnalysisScope(files, loaders, languages);
|
||||
|
||||
IClassHierarchy cha = ClassHierarchyFactory.make(scope, loaders, language, null);
|
||||
com.ibm.wala.cast.js.util.Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
|
||||
// Make Script Roots
|
||||
Iterable<Entrypoint> roots = new JavaScriptEntryPoints(cha, loaders.getTheLoader());
|
||||
|
|
|
@ -69,9 +69,8 @@ public class NodejsRequiredSourceModule extends SourceFileModule {
|
|||
|
||||
@Override
|
||||
public InputStream getInputStream() {
|
||||
InputStream inputStream = super.getInputStream();
|
||||
String moduleSource = null;
|
||||
try {
|
||||
try (final InputStream inputStream = super.getInputStream()) {
|
||||
moduleSource = IOUtils.toString(inputStream);
|
||||
} catch (IOException e) {
|
||||
Assertions.UNREACHABLE(e.getMessage());
|
||||
|
@ -117,8 +116,9 @@ public class NodejsRequiredSourceModule extends SourceFileModule {
|
|||
}
|
||||
|
||||
private static String loadWrapperSource(String filename) throws IOException {
|
||||
InputStream url = NodejsRequiredSourceModule.class.getClassLoader().getResourceAsStream(filename);
|
||||
return new String(Streams.inputStream2ByteArray(url));
|
||||
try (final InputStream url = NodejsRequiredSourceModule.class.getClassLoader().getResourceAsStream(filename)) {
|
||||
return new String(Streams.inputStream2ByteArray(url));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="harness-src"/>
|
||||
<classpathentry kind="lib" path="/com.ibm.wala.cast.js.test.data/examples-src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=0
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -14,7 +14,7 @@ Require-Bundle: com.ibm.wala.cast.js.rhino;bundle-version="1.0.0",
|
|||
com.ibm.wala.cast.js.test.data;bundle-version="1.3.4",
|
||||
com.ibm.wala.shrike;bundle-version="1.3.4",
|
||||
org.junit;bundle-version="4.0.0"
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Export-Package: com.ibm.wala.cast.js.examples.hybrid,
|
||||
com.ibm.wala.cast.js.rhino.callgraph.fieldbased.test,
|
||||
|
|
|
@ -28,7 +28,6 @@ import com.ibm.wala.cast.js.ipa.callgraph.JSCallGraphUtil;
|
|||
import com.ibm.wala.cast.js.loader.JavaScriptLoader;
|
||||
import com.ibm.wala.cast.js.loader.JavaScriptLoaderFactory;
|
||||
import com.ibm.wala.cast.js.translator.CAstRhinoTranslatorFactory;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.cast.loader.AstMethod;
|
||||
import com.ibm.wala.cast.types.AstMethodReference;
|
||||
import com.ibm.wala.classLoader.IClass;
|
||||
|
@ -101,7 +100,7 @@ public class PrintIRs {
|
|||
JavaScriptLoaderFactory loaders = new WebPageLoaderFactory(JSCallGraphUtil.getTranslatorFactory());
|
||||
CAstAnalysisScope scope = new CAstAnalysisScope(scripts, loaders, Collections.singleton(JavaScriptLoader.JS));
|
||||
IClassHierarchy cha = ClassHierarchyFactory.make(scope, loaders, JavaScriptLoader.JS);
|
||||
Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
printIRsForCHA(cha, new Predicate<String>() {
|
||||
|
||||
@Override
|
||||
|
|
|
@ -17,7 +17,6 @@ import org.junit.Test;
|
|||
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSCFABuilder;
|
||||
import com.ibm.wala.cast.js.translator.CAstRhinoTranslatorFactory;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder;
|
||||
import com.ibm.wala.util.CancelException;
|
||||
import com.ibm.wala.util.WalaException;
|
||||
|
@ -82,7 +81,7 @@ public class TestSimpleCallGraphShapeRhino extends TestSimpleCallGraphShape {
|
|||
public void testParseError() throws IllegalArgumentException, IOException, CancelException, WalaException {
|
||||
PropagationCallGraphBuilder B = JSCallGraphBuilderUtil.makeScriptCGBuilder("tests", "portal-example-simple.html");
|
||||
B.makeCallGraph(B.getOptions());
|
||||
Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -22,7 +22,6 @@ import com.ibm.wala.cast.js.html.JSSourceExtractor;
|
|||
import com.ibm.wala.cast.js.html.WebUtil;
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSCFABuilder;
|
||||
import com.ibm.wala.cast.js.translator.CAstRhinoTranslatorFactory;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.ipa.callgraph.CallGraph;
|
||||
import com.ibm.wala.util.CancelException;
|
||||
import com.ibm.wala.util.WalaException;
|
||||
|
@ -45,7 +44,7 @@ public abstract class TestSimplePageCallGraphShapeRhino extends TestSimplePageCa
|
|||
URL url = getClass().getClassLoader().getResource("pages/garbage2.html");
|
||||
JSCFABuilder B = JSCallGraphBuilderUtil.makeHTMLCGBuilder(url, DefaultSourceExtractor.factory);
|
||||
B.makeCallGraph(B.getOptions());
|
||||
Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
|
|
@ -18,7 +18,6 @@ import com.ibm.wala.cast.js.html.DefaultSourceExtractor;
|
|||
import com.ibm.wala.cast.js.html.IHtmlParser;
|
||||
import com.ibm.wala.cast.js.html.jericho.JerichoHtmlParser;
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSCFABuilder;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.ipa.callgraph.CallGraph;
|
||||
import com.ibm.wala.util.CancelException;
|
||||
import com.ibm.wala.util.WalaException;
|
||||
|
@ -36,7 +35,7 @@ public class TestSimplePageCallGraphShapeRhinoJericho extends TestSimplePageCall
|
|||
URL url = getClass().getClassLoader().getResource("pages/garbage.html");
|
||||
JSCFABuilder B = JSCallGraphBuilderUtil.makeHTMLCGBuilder(url, DefaultSourceExtractor.factory);
|
||||
B.makeCallGraph(B.getOptions());
|
||||
Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(B.getClassHierarchy());
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<classpath>
|
||||
<classpathentry kind="src" path="source"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="lib" path="lib/rhino-1.7.6.jar"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -47,7 +47,7 @@ org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=0
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -7,7 +7,7 @@ Bundle-Vendor: %Bundle-Vendor
|
|||
Require-Bundle: com.ibm.wala.cast;bundle-version="1.0.0",
|
||||
com.ibm.wala.cast.js;bundle-version="1.0.0",
|
||||
com.ibm.wala.core;bundle-version="1.1.3"
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Export-Package: com.ibm.wala.cast.js.translator,
|
||||
org.mozilla.classfile,
|
||||
|
|
|
@ -42,6 +42,11 @@
|
|||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.util</artifactId>
|
||||
<version>1.4.4-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.core</artifactId>
|
||||
|
|
|
@ -1185,8 +1185,9 @@ public class RhinoToAstTranslator implements TranslatorToCAst {
|
|||
case Token.DEBUGGER: {
|
||||
return Ast.makeConstant(null);
|
||||
}
|
||||
default:
|
||||
throw new RuntimeException("unexpected keyword literal " + node + " (" + node.getType() +")");
|
||||
}
|
||||
throw new RuntimeException("unexpected keyword literal " + node + " (" + node.getType() +")");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1 +1 @@
|
|||
org.eclipse.wst.jsdt.launching.JRE_CONTAINER
|
||||
org.eclipse.wst.jsdt.launching.JRE_CONTAINER
|
||||
|
|
|
@ -1 +1 @@
|
|||
Global
|
||||
Global
|
||||
|
|
|
@ -7,4 +7,4 @@ Bundle-Version: 1.4.4.qualifier
|
|||
Bundle-Vendor: %providerName
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Bundle-ClassPath: examples-src/
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -2,6 +2,6 @@
|
|||
<classpath>
|
||||
<classpathentry kind="src" path="harness-src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -47,7 +47,7 @@ org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
|
||||
|
@ -118,7 +118,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -13,4 +13,4 @@ Require-Bundle: com.ibm.wala.cast.js,
|
|||
com.ibm.wala.cast.js.test.data;bundle-version="1.3.4",
|
||||
org.junit;bundle-version="4.0.0"
|
||||
Export-Package: com.ibm.wala.cast.js.test
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -25,12 +25,12 @@ import com.ibm.wala.cast.js.callgraph.fieldbased.WorklistBasedOptimisticCallgrap
|
|||
import com.ibm.wala.cast.js.callgraph.fieldbased.flowgraph.vertices.ObjectVertex;
|
||||
import com.ibm.wala.cast.js.html.JSSourceExtractor;
|
||||
import com.ibm.wala.cast.js.html.WebPageLoaderFactory;
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSAnalysisOptions;
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSCallGraph;
|
||||
import com.ibm.wala.cast.js.ipa.callgraph.JSCallGraphUtil;
|
||||
import com.ibm.wala.cast.js.loader.JavaScriptLoader;
|
||||
import com.ibm.wala.cast.js.loader.JavaScriptLoaderFactory;
|
||||
import com.ibm.wala.cast.js.translator.JavaScriptTranslatorFactory;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.classLoader.Module;
|
||||
import com.ibm.wala.classLoader.SourceModule;
|
||||
import com.ibm.wala.classLoader.SourceURLModule;
|
||||
|
@ -54,7 +54,34 @@ import com.ibm.wala.util.functions.Function;
|
|||
*
|
||||
*/
|
||||
public class FieldBasedCGUtil {
|
||||
public static enum BuilderType { PESSIMISTIC, OPTIMISTIC, OPTIMISTIC_WORKLIST }
|
||||
public static enum BuilderType {
|
||||
PESSIMISTIC {
|
||||
@Override
|
||||
protected FieldBasedCallGraphBuilder fieldBasedCallGraphBuilderFactory(IClassHierarchy cha,
|
||||
final JSAnalysisOptions makeOptions, IAnalysisCacheView cache, boolean supportFullPointerAnalysis) {
|
||||
return new PessimisticCallGraphBuilder(cha, makeOptions, cache, supportFullPointerAnalysis);
|
||||
}
|
||||
},
|
||||
|
||||
OPTIMISTIC {
|
||||
@Override
|
||||
protected FieldBasedCallGraphBuilder fieldBasedCallGraphBuilderFactory(IClassHierarchy cha,
|
||||
JSAnalysisOptions makeOptions, IAnalysisCacheView cache, boolean supportFullPointerAnalysis) {
|
||||
return new OptimisticCallgraphBuilder(cha, makeOptions, cache, supportFullPointerAnalysis);
|
||||
}
|
||||
},
|
||||
|
||||
OPTIMISTIC_WORKLIST {
|
||||
@Override
|
||||
protected FieldBasedCallGraphBuilder fieldBasedCallGraphBuilderFactory(IClassHierarchy cha,
|
||||
JSAnalysisOptions makeOptions, IAnalysisCacheView cache, boolean supportFullPointerAnalysis) {
|
||||
return new WorklistBasedOptimisticCallgraphBuilder(cha, makeOptions, cache, supportFullPointerAnalysis);
|
||||
}
|
||||
};
|
||||
|
||||
protected abstract FieldBasedCallGraphBuilder fieldBasedCallGraphBuilderFactory(IClassHierarchy cha,
|
||||
JSAnalysisOptions makeOptions, IAnalysisCacheView cache, boolean supportFullPointerAnalysis);
|
||||
}
|
||||
|
||||
private final JavaScriptTranslatorFactory translatorFactory;
|
||||
|
||||
|
@ -98,23 +125,11 @@ public class FieldBasedCGUtil {
|
|||
public Pair<JSCallGraph, PointerAnalysis<ObjectVertex>> buildCG(JavaScriptLoaderFactory loaders, Module[] scripts, BuilderType builderType, IProgressMonitor monitor, boolean supportFullPointerAnalysis) throws WalaException, CancelException {
|
||||
CAstAnalysisScope scope = new CAstAnalysisScope(scripts, loaders, Collections.singleton(JavaScriptLoader.JS));
|
||||
IClassHierarchy cha = ClassHierarchyFactory.make(scope, loaders, JavaScriptLoader.JS);
|
||||
Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
Iterable<Entrypoint> roots = JSCallGraphUtil.makeScriptRoots(cha);
|
||||
FieldBasedCallGraphBuilder builder = null;
|
||||
|
||||
IAnalysisCacheView cache = new AnalysisCacheImpl(AstIRFactory.makeDefaultFactory());
|
||||
switch(builderType) {
|
||||
case PESSIMISTIC:
|
||||
builder = new PessimisticCallGraphBuilder(cha, JSCallGraphUtil.makeOptions(scope, cha, roots), cache, supportFullPointerAnalysis);
|
||||
break;
|
||||
case OPTIMISTIC:
|
||||
builder = new OptimisticCallgraphBuilder(cha, JSCallGraphUtil.makeOptions(scope, cha, roots), cache, supportFullPointerAnalysis);
|
||||
break;
|
||||
case OPTIMISTIC_WORKLIST:
|
||||
builder = new WorklistBasedOptimisticCallgraphBuilder(cha, JSCallGraphUtil.makeOptions(scope, cha, roots), cache, supportFullPointerAnalysis);
|
||||
break;
|
||||
}
|
||||
|
||||
final FieldBasedCallGraphBuilder builder = builderType.fieldBasedCallGraphBuilderFactory(cha,
|
||||
JSCallGraphUtil.makeOptions(scope, cha, roots), cache, supportFullPointerAnalysis);
|
||||
return builder.buildCallGraph(roots, monitor);
|
||||
}
|
||||
|
||||
|
|
|
@ -227,7 +227,7 @@ public class JSCallGraphBuilderUtil extends com.ibm.wala.cast.js.ipa.callgraph.J
|
|||
protected static JSCFABuilder makeCG(JavaScriptLoaderFactory loaders, AnalysisScope scope, CGBuilderType builderType, IRFactory<IMethod> irFactory) throws WalaException {
|
||||
try {
|
||||
IClassHierarchy cha = makeHierarchy(scope, loaders);
|
||||
com.ibm.wala.cast.js.util.Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
Iterable<Entrypoint> roots = makeScriptRoots(cha);
|
||||
JSAnalysisOptions options = makeOptions(scope, cha, roots);
|
||||
options.setHandleCallApply(builderType.handleCallApply());
|
||||
|
|
|
@ -46,7 +46,7 @@ public abstract class TestArgumentSensitivity extends TestJSCallGraphShape {
|
|||
AnalysisScope scope = JSCallGraphBuilderUtil.makeScriptScope("tests", "args.js", loaders);
|
||||
|
||||
IClassHierarchy cha = JSCallGraphUtil.makeHierarchy(scope, loaders);
|
||||
com.ibm.wala.cast.js.util.Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
Iterable<Entrypoint> roots = JSCallGraphUtil.makeScriptRoots(cha);
|
||||
JSAnalysisOptions options = JSCallGraphUtil.makeOptions(scope, cha, roots);
|
||||
|
||||
|
|
|
@ -4,6 +4,6 @@
|
|||
<classpathentry kind="src" path="dat"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/jericho-html-3.2.jar"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -47,7 +47,7 @@ org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled
|
|||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
|
||||
|
@ -79,7 +79,7 @@ org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
||||
|
@ -92,7 +92,7 @@ org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -34,4 +34,4 @@ Require-Bundle: com.ibm.wala.cast,
|
|||
com.ibm.wala.cast,
|
||||
com.ibm.wala.shrike;bundle-version="1.1.3"
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
|
|
@ -42,6 +42,11 @@
|
|||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.util</artifactId>
|
||||
<version>1.4.4-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.core</artifactId>
|
||||
|
|
|
@ -35,7 +35,6 @@ import com.ibm.wala.cast.js.ipa.callgraph.JSCallGraphUtil;
|
|||
import com.ibm.wala.cast.js.loader.JavaScriptLoader;
|
||||
import com.ibm.wala.cast.js.loader.JavaScriptLoaderFactory;
|
||||
import com.ibm.wala.cast.js.translator.JavaScriptTranslatorFactory;
|
||||
import com.ibm.wala.cast.js.util.Util;
|
||||
import com.ibm.wala.cast.loader.AstMethod;
|
||||
import com.ibm.wala.cast.loader.AstMethod.LexicalInformation;
|
||||
import com.ibm.wala.cast.tree.CAstSourcePositionMap.Position;
|
||||
|
@ -287,7 +286,7 @@ public class CorrelationFinder {
|
|||
CAstAnalysisScope scope = new CAstAnalysisScope(scripts_array, loaders, Collections.singleton(JavaScriptLoader.JS));
|
||||
IClassHierarchy cha = ClassHierarchyFactory.make(scope, loaders, JavaScriptLoader.JS);
|
||||
try {
|
||||
Util.checkForFrontEndErrors(cha);
|
||||
com.ibm.wala.cast.util.Util.checkForFrontEndErrors(cha);
|
||||
} catch (WalaException e) {
|
||||
return Collections.emptyMap();
|
||||
}
|
||||
|
|
|
@ -816,6 +816,8 @@ public class ClosureExtractor extends CAstRewriterExt {
|
|||
case CAstNode.CALL:
|
||||
case CAstNode.NEW:
|
||||
return false;
|
||||
default:
|
||||
// fall through to generic handlers below
|
||||
}
|
||||
for(int i=0;i<node.getChildCount();++i)
|
||||
if(!noJumpsAndNoCalls(node.getChild(i)))
|
||||
|
|
|
@ -539,8 +539,7 @@ public class JavaScriptConstructorFunctions {
|
|||
|
||||
assert fcls != null : "cannot find class for " + fileName;
|
||||
|
||||
if (fcls != null)
|
||||
return makeFunctionConstructor(cls, fcls);
|
||||
return makeFunctionConstructor(cls, fcls);
|
||||
|
||||
} catch (IOException e) {
|
||||
|
||||
|
|
|
@ -13,50 +13,17 @@ package com.ibm.wala.cast.js.util;
|
|||
import java.util.Iterator;
|
||||
|
||||
import com.ibm.wala.cast.js.ssa.PrototypeLookup;
|
||||
import com.ibm.wala.cast.loader.CAstAbstractLoader;
|
||||
import com.ibm.wala.classLoader.IClassLoader;
|
||||
import com.ibm.wala.classLoader.ModuleEntry;
|
||||
import com.ibm.wala.ipa.cha.IClassHierarchy;
|
||||
import com.ibm.wala.ssa.DefUse;
|
||||
import com.ibm.wala.ssa.IR;
|
||||
import com.ibm.wala.ssa.SSAInstruction;
|
||||
import com.ibm.wala.ssa.SSAPhiInstruction;
|
||||
import com.ibm.wala.util.WalaException;
|
||||
import com.ibm.wala.util.intset.IntSet;
|
||||
import com.ibm.wala.util.intset.IntSetAction;
|
||||
import com.ibm.wala.util.intset.IntSetUtil;
|
||||
import com.ibm.wala.util.intset.MutableIntSet;
|
||||
import com.ibm.wala.util.warnings.Warning;
|
||||
|
||||
public class Util {
|
||||
|
||||
public static void checkForFrontEndErrors(IClassHierarchy cha) throws WalaException {
|
||||
StringBuffer message = null;
|
||||
for(IClassLoader loader : cha.getLoaders()) {
|
||||
if (loader instanceof CAstAbstractLoader) {
|
||||
Iterator<ModuleEntry> errors = ((CAstAbstractLoader)loader).getModulesWithParseErrors();
|
||||
if (errors.hasNext()) {
|
||||
if (message == null) {
|
||||
message = new StringBuffer("front end errors:\n");
|
||||
}
|
||||
while (errors.hasNext()) {
|
||||
ModuleEntry errorModule = errors.next();
|
||||
for(Warning w : (((CAstAbstractLoader)loader).getMessages(errorModule))) {
|
||||
message.append("error in ").append(errorModule.getName()).append(":\n");
|
||||
message.append(w.toString()).append("\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
// clear out the errors to free some memory
|
||||
((CAstAbstractLoader)loader).clearMessages();
|
||||
}
|
||||
}
|
||||
if (message != null) {
|
||||
message.append("end of front end errors\n");
|
||||
throw new WalaException(String.valueOf(message));
|
||||
}
|
||||
}
|
||||
|
||||
public static IntSet getArgumentsArrayVns(IR ir, final DefUse du) {
|
||||
int originalArgsVn = getArgumentsArrayVn(ir);
|
||||
final MutableIntSet result = IntSetUtil.make();
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="harness-src/java"/>
|
||||
<classpathentry kind="src" path="harness-src/c"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -85,17 +85,17 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
|
||||
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
|
||||
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=error
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=error
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
|
@ -118,7 +118,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -12,5 +12,5 @@ Require-Bundle:
|
|||
com.ibm.wala.shrike,
|
||||
org.eclipse.core.runtime
|
||||
Export-Package: com.ibm.wala.cast.test
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ CAST_OBJS = $(wildcard $(C_GENERATED)/*.o)
|
|||
default: $(CAST_TEST_BIN)$(LIBPREFIX)xlator_test.$(DLLEXT)
|
||||
|
||||
$(TEST_JNI_BRIDGE_HEADER): $(CAST_TEST_BIN)com/ibm/wala/cast/test/TestNativeTranslator.class
|
||||
$(JAVA_SDK)bin/javah -classpath "$(CAST_TEST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.test.TestNativeTranslator
|
||||
$(JAVA_HOME)/bin/javah -classpath "$(CAST_TEST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.test.TestNativeTranslator
|
||||
|
||||
$(C_GENERATED)/smoke.o: $(TEST_JNI_BRIDGE_HEADER) smoke.cpp
|
||||
$(CC) $(ALL_FLAGS) -o $@ -c smoke.cpp
|
||||
|
|
|
@ -12,7 +12,6 @@ package com.ibm.wala.cast.test;
|
|||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.junit.Assert;
|
||||
|
@ -35,7 +34,6 @@ public class TestCAstPattern extends WalaTestCase {
|
|||
private final Map<String, Object> testNameMap = new HashMap<>();
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public CAstNode makeNode(int kind, CAstNode children[]) {
|
||||
if (kind == NAME_ASSERTION_SINGLE || kind == NAME_ASSERTION_MULTI) {
|
||||
assert children.length == 2;
|
||||
|
@ -47,11 +45,13 @@ public class TestCAstPattern extends WalaTestCase {
|
|||
if (kind == NAME_ASSERTION_SINGLE) {
|
||||
testNameMap.put(name, children[1]);
|
||||
} else {
|
||||
if (!testNameMap.containsKey(name)) {
|
||||
testNameMap.put(name, new ArrayList<>());
|
||||
@SuppressWarnings("unchecked")
|
||||
ArrayList<CAstNode> nodeList = (ArrayList<CAstNode>) testNameMap.get(name);
|
||||
if (nodeList == null) {
|
||||
nodeList = new ArrayList<>();
|
||||
testNameMap.put(name, nodeList);
|
||||
}
|
||||
|
||||
((List<CAstNode>) testNameMap.get(children[0].getValue())).add(children[1]);
|
||||
nodeList.add(children[1]);
|
||||
}
|
||||
return children[1];
|
||||
} else {
|
||||
|
|
|
@ -100,17 +100,17 @@ public abstract class TestCAstTranslator extends WalaTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
Pair<Object, Object>[] instanceMethods = (Pair[]) entry[4];
|
||||
Pair<?, ?>[] instanceMethods = (Pair[]) entry[4];
|
||||
if (instanceMethods != null) {
|
||||
for (int i = 0; i < instanceMethods.length; i++) {
|
||||
this.instanceMethods.put(Pair.make(clsName, instanceMethods[i].fst), instanceMethods[i].snd);
|
||||
this.instanceMethods.put(Pair.make(clsName, (Object) instanceMethods[i].fst), instanceMethods[i].snd);
|
||||
}
|
||||
}
|
||||
|
||||
Pair<Object, Object>[] staticMethods = (Pair[]) entry[5];
|
||||
Pair<?, ?>[] staticMethods = (Pair[]) entry[5];
|
||||
if (staticMethods != null) {
|
||||
for (int i = 0; i < staticMethods.length; i++) {
|
||||
this.staticMethods.put(Pair.make(clsName, staticMethods[i].fst), staticMethods[i].snd);
|
||||
this.staticMethods.put(Pair.make(clsName, (Object) staticMethods[i].fst), staticMethods[i].snd);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -177,7 +177,7 @@ public abstract class TestCAstTranslator extends WalaTestCase {
|
|||
Assert.assertTrue("found class " + cls.getName().toString(), classes.contains(cls.getName().toString()));
|
||||
|
||||
if (cls.getSuperclass() == null) {
|
||||
Assert.assertTrue(cls.getName() + " has no superclass", supers.get(cls.getName()) == null);
|
||||
Assert.assertTrue(cls.getName() + " has no superclass", supers.get(cls.getName().toString()) == null);
|
||||
} else {
|
||||
Assert.assertTrue("super of " + cls.getName() + " is " + cls.getSuperclass().getName(), supers
|
||||
.get(cls.getName().toString()).equals(cls.getSuperclass().getName().toString()));
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
<classpathentry kind="src" path="source/java"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/commons-io-2.4.jar"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -11,9 +11,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
|||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -93,11 +93,11 @@ org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=error
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=error
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
|
@ -120,7 +120,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -28,5 +28,5 @@ Export-Package: com.ibm.wala.cast.analysis.typeInference,
|
|||
com.ibm.wala.cast.util,
|
||||
org.apache.commons.io,
|
||||
org.apache.commons.io.input
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
|
||||
|
|
|
@ -42,6 +42,11 @@
|
|||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.util</artifactId>
|
||||
<version>1.4.4-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.core</artifactId>
|
||||
|
|
|
@ -13,10 +13,10 @@ bindir:
|
|||
mkdir -p $(C_GENERATED)
|
||||
|
||||
$(CAPA_JNI_BRIDGE_HEADER): $(DOMO_AST_BIN)com/ibm/wala/cast/ir/translator/NativeBridge.class bindir
|
||||
$(JAVA_SDK)bin/javah -classpath "$(DOMO_AST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.ir.translator.NativeBridge
|
||||
$(JAVA_HOME)/bin/javah -classpath "$(DOMO_AST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.ir.translator.NativeBridge
|
||||
|
||||
$(CAPA_JNI_XLATOR_HEADER): $(DOMO_AST_BIN)com/ibm/wala/cast/ir/translator/NativeTranslatorToCAst.class bindir
|
||||
$(JAVA_SDK)bin/javah -classpath "$(DOMO_AST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.ir.translator.NativeTranslatorToCAst
|
||||
$(JAVA_HOME)/bin/javah -classpath "$(DOMO_AST_BIN)$(JAVAH_CLASS_PATH)" -d "$(JAVAH_GENERATED)" com.ibm.wala.cast.ir.translator.NativeTranslatorToCAst
|
||||
|
||||
$(CAPA_OBJECTS): $(C_GENERATED)%.o: %.cpp $(CAPA_JNI_HEADERS) bindir
|
||||
echo $(CAPA_OBJECTS)
|
||||
|
|
|
@ -123,6 +123,7 @@ public class DelegatingAstPointerKeys implements AstPointerKeyFactory {
|
|||
return new NonNullSingletonIterator<>(ifk);
|
||||
}
|
||||
}
|
||||
return new NonNullSingletonIterator<PointerKey>(ReflectedFieldPointerKey.mapped(new ConcreteTypeKey(getFieldNameType(F)), I));
|
||||
PointerKey x = ReflectedFieldPointerKey.mapped(new ConcreteTypeKey(getFieldNameType(F)), I);
|
||||
return new NonNullSingletonIterator<>(x);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,13 +41,14 @@ public class CAstCloner extends CAstBasicRewriter {
|
|||
* what is the hack here? --MS
|
||||
*/
|
||||
protected CAstNode copyNodesHackForEclipse(CAstNode root, final CAstControlFlowMap cfg, NonCopyingContext c, Map<Pair<CAstNode,NoKey>, CAstNode> nodeMap) {
|
||||
final Pair<CAstNode, NoKey> pairKey = Pair.make(root, c.key());
|
||||
if (root instanceof CAstOperator) {
|
||||
nodeMap.put(Pair.make(root, c.key()), root);
|
||||
nodeMap.put(pairKey, root);
|
||||
return root;
|
||||
} else if (root.getValue() != null) {
|
||||
CAstNode copy = Ast.makeConstant(root.getValue());
|
||||
assert !nodeMap.containsKey(root);
|
||||
nodeMap.put(Pair.make(root, c.key()), copy);
|
||||
assert !nodeMap.containsKey(pairKey);
|
||||
nodeMap.put(pairKey, copy);
|
||||
return copy;
|
||||
} else {
|
||||
CAstNode newChildren[] = new CAstNode[root.getChildCount()];
|
||||
|
@ -57,8 +58,8 @@ public class CAstCloner extends CAstBasicRewriter {
|
|||
}
|
||||
|
||||
CAstNode copy = Ast.makeNode(root.getKind(), newChildren);
|
||||
assert !nodeMap.containsKey(root);
|
||||
nodeMap.put(Pair.make(root, c.key()), copy);
|
||||
assert !nodeMap.containsKey(pairKey);
|
||||
nodeMap.put(pairKey, copy);
|
||||
return copy;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
package com.ibm.wala.cast.util;
|
||||
|
||||
import java.util.Iterator;
|
||||
|
||||
import com.ibm.wala.cast.loader.CAstAbstractLoader;
|
||||
import com.ibm.wala.classLoader.IClassLoader;
|
||||
import com.ibm.wala.classLoader.ModuleEntry;
|
||||
import com.ibm.wala.ipa.cha.IClassHierarchy;
|
||||
import com.ibm.wala.util.WalaException;
|
||||
import com.ibm.wala.util.warnings.Warning;
|
||||
|
||||
public class Util {
|
||||
|
||||
public static void checkForFrontEndErrors(IClassHierarchy cha) throws WalaException {
|
||||
StringBuffer message = null;
|
||||
for(IClassLoader loader : cha.getLoaders()) {
|
||||
if (loader instanceof CAstAbstractLoader) {
|
||||
Iterator<ModuleEntry> errors = ((CAstAbstractLoader)loader).getModulesWithParseErrors();
|
||||
if (errors.hasNext()) {
|
||||
if (message == null) {
|
||||
message = new StringBuffer("front end errors:\n");
|
||||
}
|
||||
while (errors.hasNext()) {
|
||||
ModuleEntry errorModule = errors.next();
|
||||
for(Warning w : (((CAstAbstractLoader)loader).getMessages(errorModule))) {
|
||||
message.append("error in ").append(errorModule.getName()).append(":\n");
|
||||
message.append(w.toString()).append("\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
// clear out the errors to free some memory
|
||||
((CAstAbstractLoader)loader).clearMessages();
|
||||
}
|
||||
}
|
||||
if (message != null) {
|
||||
message.append("end of front end errors\n");
|
||||
throw new WalaException(String.valueOf(message));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
|
@ -93,7 +93,7 @@ org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
|
||||
|
|
|
@ -10,4 +10,4 @@ bin.includes = META-INF/,\
|
|||
com.ibm.wala.core.testdata_1.0.0a.jar,\
|
||||
OSGI-INF/l10n/bundle.properties,\
|
||||
OSGI-INF/
|
||||
|
||||
|
||||
|
|
|
@ -16,7 +16,6 @@ public class Reflect3 {
|
|||
|
||||
public static void main(String[] args) throws ClassNotFoundException, IllegalAccessException, InstantiationException {
|
||||
Class<?> c = Class.forName("java.util.Properties");
|
||||
@SuppressWarnings("unchecked")
|
||||
Hashtable<Object, Object> h = (Hashtable<Object, Object>) c.newInstance();
|
||||
System.out.println(h.toString());
|
||||
}
|
||||
|
|
|
@ -20,7 +20,6 @@ import java.lang.reflect.InvocationTargetException;
|
|||
*
|
||||
*/
|
||||
public class Reflect7 {
|
||||
@SuppressWarnings("unchecked")
|
||||
public static void main(String[] args) throws ClassNotFoundException, NoSuchMethodException,
|
||||
IllegalArgumentException, InstantiationException, IllegalAccessException, InvocationTargetException {
|
||||
Class<FilePermission> c = (Class<FilePermission>) Class.forName("java.io.FilePermission");
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="src" path="dat"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -10,9 +10,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
org.eclipse.jdt.core.compiler.annotation.nullable.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -38,7 +38,7 @@ org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
|
|||
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
|
||||
org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
|
||||
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
|
||||
|
@ -92,7 +92,7 @@ org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
|
||||
|
@ -119,7 +119,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
|||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
|
||||
|
|
|
@ -1,32 +1,32 @@
|
|||
compilers.f.unresolved-features=1
|
||||
compilers.f.unresolved-plugins=1
|
||||
compilers.incompatible-environment=1
|
||||
compilers.p.build=1
|
||||
compilers.p.build.bin.includes=1
|
||||
compilers.p.build.encodings=1
|
||||
compilers.p.build.java.compiler=1
|
||||
compilers.p.build.java.compliance=1
|
||||
compilers.p.build.missing.output=1
|
||||
compilers.p.build.output.library=1
|
||||
compilers.p.build.source.library=1
|
||||
compilers.p.build.src.includes=1
|
||||
compilers.p.deprecated=1
|
||||
compilers.p.discouraged-class=1
|
||||
compilers.p.internal=1
|
||||
compilers.p.missing-packages=1
|
||||
compilers.f.unresolved-features=0
|
||||
compilers.f.unresolved-plugins=0
|
||||
compilers.incompatible-environment=0
|
||||
compilers.p.build=0
|
||||
compilers.p.build.bin.includes=0
|
||||
compilers.p.build.encodings=0
|
||||
compilers.p.build.java.compiler=0
|
||||
compilers.p.build.java.compliance=0
|
||||
compilers.p.build.missing.output=0
|
||||
compilers.p.build.output.library=0
|
||||
compilers.p.build.source.library=0
|
||||
compilers.p.build.src.includes=0
|
||||
compilers.p.deprecated=0
|
||||
compilers.p.discouraged-class=0
|
||||
compilers.p.internal=0
|
||||
compilers.p.missing-packages=0
|
||||
compilers.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-import-package=0
|
||||
compilers.p.missing-version-require-bundle=2
|
||||
compilers.p.no-required-att=0
|
||||
compilers.p.not-externalized-att=1
|
||||
compilers.p.unknown-attribute=1
|
||||
compilers.p.unknown-class=1
|
||||
compilers.p.unknown-element=1
|
||||
compilers.p.unknown-identifier=1
|
||||
compilers.p.unknown-resource=1
|
||||
compilers.p.not-externalized-att=0
|
||||
compilers.p.unknown-attribute=0
|
||||
compilers.p.unknown-class=0
|
||||
compilers.p.unknown-element=0
|
||||
compilers.p.unknown-identifier=0
|
||||
compilers.p.unknown-resource=0
|
||||
compilers.p.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
compilers.s.open-tags=0
|
||||
eclipse.preferences.version=1
|
||||
|
|
|
@ -35,7 +35,7 @@ Export-Package: com.ibm.wala.core.tests.arraybounds,
|
|||
com.ibm.wala.examples.drivers,
|
||||
com.ibm.wala.examples.properties,
|
||||
com.ibm.wala.util.io
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
|
||||
Bundle-ActivationPolicy: lazy
|
||||
Bundle-Activator: com.ibm.wala.core.tests.plugin.CoreTestsPlugin
|
||||
Eclipse-RegisterBuddy: com.ibm.wala.core, com.ibm.wala.core.testdata
|
||||
|
|
|
@ -11,10 +11,13 @@
|
|||
package com.ibm.wala.core.tests.callGraph;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.Collection;
|
||||
|
||||
import org.junit.Assert;
|
||||
import org.junit.Test;
|
||||
|
||||
import com.ibm.wala.classLoader.IClass;
|
||||
import com.ibm.wala.classLoader.IMethod;
|
||||
import com.ibm.wala.core.tests.util.TestConstants;
|
||||
import com.ibm.wala.core.tests.util.WalaTestCase;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCacheImpl;
|
||||
|
@ -78,5 +81,13 @@ public class DefaultMethodsTest extends WalaTestCase {
|
|||
|
||||
// Check call from main to Test3.silly
|
||||
Assert.assertTrue("should have call site from main to Test3.silly", cg.getPossibleSites(mnode, ttnode).hasNext());
|
||||
|
||||
// Check that IClass.getAllMethods() returns default methods #219.
|
||||
TypeReference test1Type = TypeReference.findOrCreate(ClassLoaderReference.Application, "LdefaultMethods/DefaultMethods$Test1");
|
||||
IClass test1Class = cha.lookupClass(test1Type);
|
||||
|
||||
Collection<IMethod> allMethods = test1Class.getAllMethods();
|
||||
IMethod defaultMethod = test1Class.getMethod(t1m.getSelector());
|
||||
Assert.assertTrue("Expecting default methods to show up in IClass.allMethods()", allMethods.contains(defaultMethod));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -247,7 +247,6 @@ public class ReflectionTest extends WalaTestCase {
|
|||
Assert.assertTrue(succNodes.isEmpty());
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
public void testReflect7() throws Exception {
|
||||
AnalysisScope scope = findOrCreateAnalysisScope();
|
||||
|
|
|
@ -104,7 +104,6 @@ public class AnnotationTest extends WalaTestCase {
|
|||
}
|
||||
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
public void testClassAnnotations3() throws Exception {
|
||||
|
||||
|
@ -183,7 +182,7 @@ public class AnnotationTest extends WalaTestCase {
|
|||
IMethod methodUnderTest = cha.resolveMethod(methodRefUnderTest);
|
||||
harness.assertTrue(methodRefUnderTest.toString() + " not found", methodUnderTest != null);
|
||||
harness.assertTrue(methodUnderTest + " must be bytecode method", methodUnderTest instanceof IBytecodeMethod);
|
||||
IBytecodeMethod<IInstruction> IBytecodeMethodUnderTest = (IBytecodeMethod<IInstruction>) methodUnderTest;
|
||||
IBytecodeMethod<?> IBytecodeMethodUnderTest = (IBytecodeMethod<?>) methodUnderTest;
|
||||
|
||||
Collection<Annotation>[] parameterAnnotations = IBytecodeMethodUnderTest.getParameterAnnotations();
|
||||
harness.assertEquals(expected.length, parameterAnnotations.length);
|
||||
|
|
|
@ -104,7 +104,7 @@ public class ContextInsensitiveReachingDefs {
|
|||
}
|
||||
}
|
||||
}
|
||||
return new ObjectArrayMapping<Pair<CGNode, Integer>>(putInstrs.toArray(new Pair[putInstrs.size()]));
|
||||
return new ObjectArrayMapping<>(putInstrs.toArray(new Pair[putInstrs.size()]));
|
||||
}
|
||||
|
||||
private class TransferFunctions implements ITransferFunctionProvider<BasicBlockInContext<IExplodedBasicBlock>, BitVectorVariable> {
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue