Merge remote-tracking branch 'upstream/master'
This commit is contained in:
commit
bc4bc846ac
|
@ -12,6 +12,7 @@ com.ibm.wala.cast.java.polyglot/lib/
|
|||
com.ibm.wala.cast.java.test.data/src/JLex/
|
||||
com.ibm.wala.cast.java.test/testdata/
|
||||
com.ibm.wala.cast.js.html.nu_validator/lib/
|
||||
com.ibm.wala.cast.js.nodejs/lib/
|
||||
com.ibm.wala.cast.js.rhino.test/*.dump
|
||||
com.ibm.wala.cast.js.rhino.test/*.html*
|
||||
com.ibm.wala.cast.js.rhino.test/2009_swine_flu_outbreak
|
||||
|
@ -40,4 +41,5 @@ target/
|
|||
com.ibm.wala.dalvik.test/data/sample.cup
|
||||
com.ibm.wala.dalvik.test/parser.java
|
||||
com.ibm.wala.dalvik.test/report
|
||||
com.ibm.wala.dalvik.test/sym.java
|
||||
com.ibm.wala.dalvik.test/sym.java
|
||||
results
|
11
.travis.yml
11
.travis.yml
|
@ -1,17 +1,11 @@
|
|||
language: android
|
||||
jdk: oraclejdk8
|
||||
before_install:
|
||||
- "export DISPLAY=:99.0"
|
||||
- "sh -e /etc/init.d/xvfb start"
|
||||
- "pushd /tmp"
|
||||
- "git clone --depth=1 https://github.com/secure-software-engineering/DroidBench.git"
|
||||
- "popd"
|
||||
- "mkdir -p $TRAVIS_BUILD_DIR/com.ibm.wala.dalvik.test/lib"
|
||||
- "find /usr/local -name dx.jar -exec cp '{}' $TRAVIS_BUILD_DIR/com.ibm.wala.dalvik.test/lib/dx.jar ';'"
|
||||
- "git clone --depth=1 https://github.com/secure-software-engineering/DroidBench.git /tmp/DroidBench"
|
||||
install:
|
||||
- mvn clean verify -DskipTests=true -B -q
|
||||
script:
|
||||
- mvn clean verify -B -q
|
||||
- xvfb-run mvn clean verify -B -q
|
||||
- jdk_switcher use oraclejdk7
|
||||
- ./build-maven-jars.py "install -Dgpg.skip"
|
||||
sudo: false
|
||||
|
@ -19,4 +13,3 @@ cache:
|
|||
directories:
|
||||
- $HOME/.m2
|
||||
- $TRAVIS_BUILD_DIR/com.ibm.wala.core.testdata/ocaml/ocamljava-2.0-alpha1/lib
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
os: Visual Studio 2015
|
||||
|
||||
install:
|
||||
- ps: |
|
||||
Add-Type -AssemblyName System.IO.Compression.FileSystem
|
||||
if (!(Test-Path -Path "C:\maven" )) {
|
||||
(new-object System.Net.WebClient).DownloadFile(
|
||||
'http://www.us.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.zip',
|
||||
'C:\maven-bin.zip'
|
||||
)
|
||||
[System.IO.Compression.ZipFile]::ExtractToDirectory("C:\maven-bin.zip", "C:\maven")
|
||||
}
|
||||
- cmd: SET PATH=C:\maven\apache-maven-3.3.9\bin;%JAVA_HOME%\bin;%PATH%
|
||||
- cmd: SET MAVEN_OPTS=-XX:MaxPermSize=2g -Xmx4g
|
||||
- cmd: SET JAVA_OPTS=-XX:MaxPermSize=2g -Xmx4g
|
||||
|
||||
build_script:
|
||||
- mvn clean verify -DskipTests=true -B -q
|
||||
|
||||
test_script:
|
||||
- mvn clean verify -B -q
|
||||
|
||||
cache:
|
||||
- C:\maven\
|
||||
- C:\Users\appveyor\.m2
|
|
@ -22,7 +22,9 @@ projects = [
|
|||
"cast.java",
|
||||
"cast.java.ecj",
|
||||
"cast.js",
|
||||
"cast.js.rhino"
|
||||
"cast.js.rhino",
|
||||
"dalvik",
|
||||
"scandroid"
|
||||
]
|
||||
|
||||
for proj in projects:
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<feature
|
||||
id="com.ibm.wala-feature"
|
||||
label="%featureName"
|
||||
version="1.3.10.qualifier"
|
||||
version="1.4.3.qualifier"
|
||||
provider-name="%providerName">
|
||||
|
||||
<plugin
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<artifactId>WALA</artifactId>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala-feature</artifactId>
|
||||
<packaging>eclipse-feature</packaging>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>WALA</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala-repository</artifactId>
|
||||
<packaging>eclipse-repository</packaging>
|
||||
|
|
|
@ -5,4 +5,11 @@ org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
|||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=no_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
|
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -2,7 +2,7 @@ Manifest-Version: 1.0
|
|||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: WALA CAst Java ECJ frontend
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.java.ecj
|
||||
Bundle-Version: 1.3.10.qualifier
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Bundle-Vendor: IBM
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
Require-Bundle: com.ibm.wala.cast.java,
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast.java.ecj</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
<packaging>jar</packaging>
|
||||
<name>WALA CAst Java ECJ</name>
|
||||
<description>WALA Common AST Java ECJ front-end</description>
|
||||
|
@ -45,22 +45,22 @@
|
|||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast.java</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.core</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.shrike</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.eclipse.core</groupId>
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<artifactId>WALA</artifactId>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.java.ecj</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
|
|
|
@ -15,7 +15,7 @@ import com.ibm.wala.classLoader.ClassLoaderFactory;
|
|||
import com.ibm.wala.ipa.callgraph.propagation.InstanceKey;
|
||||
import com.ibm.wala.util.config.SetOfClasses;
|
||||
|
||||
public class ECJJavaSourceAnalysisEngine extends JavaSourceAnalysisEngine<InstanceKey> {
|
||||
public class ECJJavaSourceAnalysisEngine<I extends InstanceKey> extends JavaSourceAnalysisEngine<I> {
|
||||
|
||||
@Override
|
||||
protected ClassLoaderFactory getClassLoaderFactory(SetOfClasses exclusions) {
|
||||
|
|
|
@ -70,7 +70,7 @@ public class SourceDirCallGraph {
|
|||
// options.setReflectionOptions(ReflectionOptions.NONE);
|
||||
AnalysisCache cache = new AnalysisCacheImpl(AstIRFactory.makeDefaultFactory());
|
||||
//CallGraphBuilder builder = new ZeroCFABuilderFactory().make(options, cache, cha, scope, false);
|
||||
CallGraphBuilder builder = new ZeroOneContainerCFABuilderFactory().make(options, cache, cha, scope, false);
|
||||
CallGraphBuilder<?> builder = new ZeroOneContainerCFABuilderFactory().make(options, cache, cha, scope, false);
|
||||
System.out.println("building call graph...");
|
||||
CallGraph cg = builder.makeCallGraph(options, null);
|
||||
long end = System.currentTimeMillis();
|
||||
|
|
|
@ -447,12 +447,14 @@ public class FakeExceptionTypeBinding implements ITypeBinding {
|
|||
}
|
||||
|
||||
// do not put @Override here, to avoid breaking compilation on Juno
|
||||
@Override
|
||||
public IMethodBinding getFunctionalInterfaceMethod() {
|
||||
Assertions.UNREACHABLE("FakeExceptionTypeBinding ");
|
||||
return null;
|
||||
}
|
||||
|
||||
// do not put @Override here, to avoid breaking compilation on Juno
|
||||
@Override
|
||||
public IAnnotationBinding[] getTypeAnnotations() {
|
||||
Assertions.UNREACHABLE("FakeExceptionTypeBinding ");
|
||||
return null;
|
||||
|
|
|
@ -61,7 +61,7 @@ import com.ibm.wala.util.debug.Assertions;
|
|||
|
||||
public class JDT2CAstUtils {
|
||||
public static Collection<CAstQualifier> mapModifiersToQualifiers(int modifiers, boolean isInterface, boolean isAnnotation) {
|
||||
Set<CAstQualifier> quals = new LinkedHashSet<CAstQualifier>();
|
||||
Set<CAstQualifier> quals = new LinkedHashSet<>();
|
||||
|
||||
if (isInterface)
|
||||
quals.add(CAstQualifier.INTERFACE);
|
||||
|
@ -299,7 +299,7 @@ public class JDT2CAstUtils {
|
|||
}
|
||||
|
||||
public static Collection<IMethodBinding> getOverriddenMethod(IMethodBinding met) {
|
||||
HashMap<ITypeBinding, IMethodBinding> overridden = new HashMap<ITypeBinding, IMethodBinding>();
|
||||
HashMap<ITypeBinding, IMethodBinding> overridden = new HashMap<>();
|
||||
if (met == null)
|
||||
return null;
|
||||
getMethodInClassOrSuperclass(met, met.getDeclaringClass(), true, overridden);
|
||||
|
|
|
@ -88,7 +88,7 @@ public class JDTIdentityMapper {
|
|||
* This method canonicalizes the TypeReferences
|
||||
*/
|
||||
public TypeReference getTypeRef(ITypeBinding type) {
|
||||
type = JDT2CAstUtils.getErasedType((ITypeBinding) type, fAst); // GENERICS: erasure...
|
||||
type = JDT2CAstUtils.getErasedType(type, fAst); // GENERICS: erasure...
|
||||
|
||||
if (!fTypeMap.containsKey(type.getKey())) {
|
||||
TypeName typeName = TypeName.string2TypeName(typeToTypeID(type));
|
||||
|
|
|
@ -253,7 +253,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
public CAstEntity translateToCAst() {
|
||||
|
||||
List<CAstEntity> declEntities = new ArrayList<CAstEntity>();
|
||||
List<CAstEntity> declEntities = new ArrayList<>();
|
||||
|
||||
for (Iterator<CAstEntity> iter = cu.types().iterator(); iter.hasNext();) {
|
||||
AbstractTypeDeclaration decl = (AbstractTypeDeclaration) iter.next();
|
||||
|
@ -287,16 +287,13 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
private final T fSourcePosition;
|
||||
|
||||
private final Set<CAstAnnotation> annotations;
|
||||
|
||||
public ClassEntity(ITypeBinding jdtType, String name, Collection<CAstQualifier> quals, Collection<CAstEntity> entities,
|
||||
T pos, Set<CAstAnnotation> annotations) {
|
||||
T pos) {
|
||||
fName = name;
|
||||
fQuals = quals;
|
||||
fEntities = entities;
|
||||
fJdtType = jdtType;
|
||||
fSourcePosition = pos;
|
||||
this.annotations = annotations;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -348,7 +345,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Iterator getScopedEntities(CAstNode construct) {
|
||||
public Iterator<CAstEntity> getScopedEntities(CAstNode construct) {
|
||||
Assertions.UNREACHABLE("Non-AST-bearing entity (ClassEntity) asked for scoped entities related to a given AST node");
|
||||
return null;
|
||||
}
|
||||
|
@ -387,7 +384,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Collection getQualifiers() {
|
||||
public Collection<CAstQualifier> getQualifiers() {
|
||||
return fQuals;
|
||||
}
|
||||
|
||||
|
@ -419,16 +416,16 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* @param context
|
||||
* @return
|
||||
*/
|
||||
private CAstEntity createClassDeclaration(ASTNode n, List/* <BodyDeclaration> */bodyDecls,
|
||||
List/* EnumConstantDeclaration */enumConstants, ITypeBinding typeBinding, String name, int modifiers,
|
||||
private CAstEntity createClassDeclaration(ASTNode n, List<BodyDeclaration> bodyDecls,
|
||||
List<EnumConstantDeclaration> enumConstants, ITypeBinding typeBinding, String name, int modifiers,
|
||||
boolean isInterface, boolean isAnnotation, WalkContext context) {
|
||||
final List<CAstEntity> memberEntities = new ArrayList<CAstEntity>();
|
||||
final List<CAstEntity> memberEntities = new ArrayList<>();
|
||||
|
||||
// find and collect all initializers (type Initializer) and field initializers (type VariableDeclarationFragment).
|
||||
// instance initializer code will be inserted into each constructors.
|
||||
// all static initializer code will be grouped together in its own entity.
|
||||
ArrayList<ASTNode> inits = new ArrayList<ASTNode>();
|
||||
ArrayList<ASTNode> staticInits = new ArrayList<ASTNode>();
|
||||
ArrayList<ASTNode> inits = new ArrayList<>();
|
||||
ArrayList<ASTNode> staticInits = new ArrayList<>();
|
||||
|
||||
if (enumConstants != null) {
|
||||
for (Object decl : enumConstants) {
|
||||
|
@ -534,9 +531,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
Collection<CAstQualifier> quals = JDT2CAstUtils.mapModifiersToQualifiers(modifiers, isInterface, isAnnotation);
|
||||
|
||||
Set<CAstAnnotation> annotations = handleAnnotations(typeBinding);
|
||||
|
||||
return new ClassEntity(typeBinding, name, quals, memberEntities, makePosition(n), annotations);
|
||||
return new ClassEntity(typeBinding, name, quals, memberEntities, makePosition(n));
|
||||
}
|
||||
|
||||
private CAstEntity visit(AnonymousClassDeclaration n, WalkContext context) {
|
||||
|
@ -548,7 +543,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
// TODO 1.6: enums of course...
|
||||
AbstractTypeDeclaration decl = n.getDeclaration();
|
||||
assert decl instanceof TypeDeclaration : "Local enum declaration not yet supported";
|
||||
CAstEntity classEntity = visitTypeDecl((TypeDeclaration) decl, context);
|
||||
CAstEntity classEntity = visitTypeDecl(decl, context);
|
||||
|
||||
// these statements doin't actually do anything, just define a type
|
||||
final CAstNode lcdNode = makeNode(context, fFactory, n, CAstNode.EMPTY);
|
||||
|
@ -582,7 +577,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
assert superCtor != null : "couldn't find constructor for anonymous class";
|
||||
|
||||
// PART II: make ctor with simply "super(a,b,c...)"
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities);
|
||||
MethodDeclaration fakeCtor = ast.newMethodDeclaration();
|
||||
fakeCtor.setConstructor(true);
|
||||
|
@ -592,7 +587,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
// PART IIa: make a fake JDT constructor method with the proper number of args
|
||||
// Make fake args that will be passed
|
||||
String[] fakeArguments = new String[superCtor.getParameterTypes().length + 1];
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<CAstType>(superCtor.getParameterTypes().length);
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<>(superCtor.getParameterTypes().length);
|
||||
for (int i = 0; i < fakeArguments.length; i++)
|
||||
fakeArguments[i] = (i == 0) ? "this" : ("argument" + i); // TODO: change to invalid name and don't use
|
||||
// singlevariabledeclaration below
|
||||
|
@ -744,7 +739,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
//
|
||||
// add a method exactly like overridden that calls overriding
|
||||
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities);
|
||||
|
||||
CAstNode calltarget;
|
||||
|
@ -755,7 +750,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
ITypeBinding paramTypes[] = overridden.getParameterTypes();
|
||||
|
||||
ArrayList<CAstNode> arguments = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> arguments = new ArrayList<>();
|
||||
int i = 0;
|
||||
for (Object o : overriding.parameters()) {
|
||||
SingleVariableDeclaration svd = (SingleVariableDeclaration) o;
|
||||
|
@ -775,7 +770,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
// make parameters to new synthetic method
|
||||
// use RETURN TYPE of overridden, everything else from overriding (including parameter names)
|
||||
ArrayList<CAstType> paramCAstTypes = new ArrayList<CAstType>(overridden.getParameterTypes().length);
|
||||
ArrayList<CAstType> paramCAstTypes = new ArrayList<>(overridden.getParameterTypes().length);
|
||||
for (ITypeBinding paramType : overridden.getParameterTypes())
|
||||
paramCAstTypes.add(fTypeDict.getCAstTypeFor(paramType));
|
||||
return new ProcedureEntity(mdast, overriding, overridingBinding.getDeclaringClass(), memberEntities, context, paramCAstTypes,
|
||||
|
@ -789,7 +784,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
private CAstEntity visit(MethodDeclaration n, ITypeBinding classBinding, WalkContext oldContext, ArrayList<ASTNode> inits) {
|
||||
|
||||
// pass in memberEntities to the context, later visit(New) etc. may add classes
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities); // LEFTOUT: in polyglot there is a
|
||||
// class context in between method and
|
||||
// root
|
||||
|
@ -863,7 +858,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Iterator getScopedEntities(CAstNode construct) {
|
||||
public Iterator<CAstEntity> getScopedEntities(CAstNode construct) {
|
||||
if (fEntities.containsKey(construct)) {
|
||||
return (fEntities.get(construct)).iterator();
|
||||
} else {
|
||||
|
@ -929,9 +924,8 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
this.annotations = annotations;
|
||||
|
||||
// from CodeBodyEntity
|
||||
fEntities = new LinkedHashMap<CAstNode, Collection<CAstEntity>>();
|
||||
for (Iterator keys = entities.keySet().iterator(); keys.hasNext();) {
|
||||
CAstNode key = (CAstNode) keys.next();
|
||||
fEntities = new LinkedHashMap<>();
|
||||
for (CAstNode key : entities.keySet()) {
|
||||
fEntities.put(key, Collections.singleton(entities.get(key)));
|
||||
}
|
||||
|
||||
|
@ -947,7 +941,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
if (parameterTypes == null) {
|
||||
fParameterTypes = new ArrayList<CAstType>(fDecl.parameters().size());
|
||||
fParameterTypes = new ArrayList<>(fDecl.parameters().size());
|
||||
for (Object p : fDecl.parameters()) {
|
||||
fParameterNames[i++] = ((SingleVariableDeclaration) p).getName().getIdentifier();
|
||||
fParameterTypes.add(fTypeDict.getCAstTypeFor(((SingleVariableDeclaration) p).resolveBinding().getType()));
|
||||
|
@ -962,7 +956,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
} else {
|
||||
fParameterNames = new String[0];
|
||||
fParameterTypes = new ArrayList<CAstType>(0); // static initializer
|
||||
fParameterTypes = new ArrayList<>(0); // static initializer
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1038,7 +1032,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Collection getQualifiers() {
|
||||
public Collection<CAstQualifier> getQualifiers() {
|
||||
if (fDecl == null)
|
||||
return JDT2CAstUtils.mapModifiersToQualifiers(Modifier.STATIC, false, false); // static init
|
||||
else
|
||||
|
@ -1093,7 +1087,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
@Override
|
||||
public Collection<CAstType>/* <CAstType> */getExceptionTypes() {
|
||||
if (fExceptionTypes == null) {
|
||||
fExceptionTypes = new LinkedHashSet<CAstType>();
|
||||
fExceptionTypes = new LinkedHashSet<>();
|
||||
if (fDecl != null)
|
||||
for (Object exception : fDecl.thrownExceptionTypes())
|
||||
|
||||
|
@ -1208,7 +1202,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Iterator getScopedEntities(CAstNode construct) {
|
||||
public Iterator<CAstEntity> getScopedEntities(CAstNode construct) {
|
||||
return EmptyIterator.instance();
|
||||
}
|
||||
|
||||
|
@ -1251,7 +1245,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Collection getQualifiers() {
|
||||
public Collection<CAstQualifier> getQualifiers() {
|
||||
return quals;
|
||||
}
|
||||
|
||||
|
@ -1270,7 +1264,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* (VariableDeclarationStatements) may expand to more than one CAstNode.
|
||||
*/
|
||||
private ArrayList<CAstNode> createBlock(Block n, WalkContext context) {
|
||||
ArrayList<CAstNode> stmtNodes = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> stmtNodes = new ArrayList<>();
|
||||
for (Object s : n.statements())
|
||||
visitNodeOrNodes((ASTNode) s, context, stmtNodes);
|
||||
return stmtNodes;
|
||||
|
@ -1316,7 +1310,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* One VariableDeclarationStatement represents more than one CAstNode statement.
|
||||
*/
|
||||
private ArrayList<CAstNode> visit(VariableDeclarationStatement n, WalkContext context) {
|
||||
ArrayList<CAstNode> result = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> result = new ArrayList<>();
|
||||
|
||||
for (Object o : n.fragments())
|
||||
result.add(visit((VariableDeclarationFragment) o, context));
|
||||
|
@ -1332,7 +1326,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
eltNodes[idx++] = makeNode(context, fFactory, n, CAstNode.NEW, fFactory.makeConstant(newTypeRef), fFactory.makeConstant(n
|
||||
.expressions().size()));
|
||||
for (Iterator iter = n.expressions().iterator(); iter.hasNext(); idx++) {
|
||||
for (Iterator<CAstEntity> iter = n.expressions().iterator(); iter.hasNext(); idx++) {
|
||||
Expression element = (Expression) iter.next();
|
||||
eltNodes[idx] = visitNode(element, context);
|
||||
if (eltNodes[idx] == null)
|
||||
|
@ -1347,7 +1341,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
.getAnonymousClassDeclaration(), context);
|
||||
}
|
||||
|
||||
private CAstNode createClassInstanceCreation(ASTNode nn, List/* Expression or CAstNode */arguments, IMethodBinding ctorBinding,
|
||||
private CAstNode createClassInstanceCreation(ASTNode nn, List<?> arguments, IMethodBinding ctorBinding,
|
||||
Expression qual, AnonymousClassDeclaration anonDecl, WalkContext context) {
|
||||
// a new instruction is actually two things: a NEW object and a CALL to a constructor
|
||||
CAstNode newNode;
|
||||
|
@ -1419,7 +1413,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
argNodes[idx++] = fFactory.makeConstant(callSiteRef);
|
||||
|
||||
// rest of args
|
||||
for (Iterator iter = arguments.iterator(); iter.hasNext();) {
|
||||
for (Iterator<?> iter = arguments.iterator(); iter.hasNext();) {
|
||||
Object arg = iter.next();
|
||||
argNodes[idx++] = (arg instanceof CAstNode) ? ((CAstNode) arg) : visitNode((Expression) arg, context);
|
||||
}
|
||||
|
@ -1533,7 +1527,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
private CAstNode createMethodInvocation(ASTNode pos, IMethodBinding methodBinding, CAstNode target,
|
||||
List/* Expression or CAstNode */arguments, WalkContext context) {
|
||||
List<?> arguments, WalkContext context) {
|
||||
// MethodMethodInstance methodInstance = n.methodInstance();
|
||||
boolean isStatic = (methodBinding.getModifiers() & Modifier.STATIC) != 0;
|
||||
ITypeBinding methodOwner = methodBinding.getDeclaringClass();
|
||||
|
@ -1592,7 +1586,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* @param arguments
|
||||
* @param context
|
||||
*/
|
||||
private void populateArguments(CAstNode[] children, IMethodBinding methodBinding, List/* CAstNode or Expression */arguments,
|
||||
private void populateArguments(CAstNode[] children, IMethodBinding methodBinding, List<?/* CAstNode or Expression */> arguments,
|
||||
WalkContext context) {
|
||||
int nFormals = methodBinding.getParameterTypes().length;
|
||||
assert children.length == nFormals + 2;
|
||||
|
@ -1682,9 +1676,6 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* where field 'y' is parameterized to type string. then += is not defined for type 'object'. This function is a hack that expands
|
||||
* the code into an assignment and binary operation.
|
||||
*
|
||||
* @param leftCast this is the left cast in the original expression. We throw most of it away, although we use the "Cast from" and
|
||||
* "cast to"
|
||||
* @param left
|
||||
* @param context
|
||||
* @return
|
||||
*/
|
||||
|
@ -1838,7 +1829,6 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* owningTypeRef or the subtype that the field is accessed thru, for expanding "f = 5" into "TheClass.this.f = 5".
|
||||
*
|
||||
* @param typeOfThis
|
||||
* @param owningTypeRef
|
||||
* @param isPrivate
|
||||
* @return
|
||||
*/
|
||||
|
@ -1900,10 +1890,9 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
* exception. maybe handle this in here as a special case? i don't know... or check if targetNode is THIS, that should even work
|
||||
* for this.x = 5 and (this).x = 5
|
||||
*
|
||||
* @param target Used to evaluate the field access. In the case of static field accesses, this is included in the first part of a
|
||||
* @param targetNode Used to evaluate the field access. In the case of static field accesses, this is included in the first part of a
|
||||
* block -- thus it is evaluated for any side effects but thrown away.
|
||||
* @param fieldName Name of the field.
|
||||
* @param fieldBinding This is used to determine the field's class.
|
||||
* @param positioningNode Used only for making a JdtPosition.
|
||||
* @param context
|
||||
* @return
|
||||
|
@ -1950,12 +1939,11 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
if (targetNode.getKind() != CAstNode.THIS) { // this.x will never throw a null pointer exception, because this
|
||||
// can never be null
|
||||
Collection excTargets = context.getCatchTargets(fNullPointerExcType);
|
||||
Collection<Pair<ITypeBinding, Object>> excTargets = context.getCatchTargets(fNullPointerExcType);
|
||||
if (!excTargets.isEmpty()) {
|
||||
// connect NPE exception edge to relevant catch targets
|
||||
// (presumably only one)
|
||||
for (Iterator iterator = excTargets.iterator(); iterator.hasNext();) {
|
||||
Pair catchPair = (Pair) iterator.next();
|
||||
for (Pair<ITypeBinding, Object> catchPair : excTargets) {
|
||||
context.cfg().add(refNode, catchPair.snd, fNullPointerExcType);
|
||||
}
|
||||
} else {
|
||||
|
@ -2087,10 +2075,9 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
if (JDT2CAstUtils.isLongOrLess(leftType)
|
||||
&& JDT2CAstUtils.isLongOrLess(rightType)
|
||||
&& (JDT2CAstUtils.mapBinaryOpcode(op) == CAstOperator.OP_DIV || JDT2CAstUtils.mapBinaryOpcode(op) == CAstOperator.OP_MOD)) {
|
||||
Collection excTargets = context.getCatchTargets(fDivByZeroExcType);
|
||||
Collection<Pair<ITypeBinding, Object>> excTargets = context.getCatchTargets(fDivByZeroExcType);
|
||||
if (!excTargets.isEmpty()) {
|
||||
for (Iterator iterator = excTargets.iterator(); iterator.hasNext();) {
|
||||
Pair catchPair = (Pair) iterator.next();
|
||||
for (Pair<ITypeBinding, Object> catchPair : excTargets) {
|
||||
context.cfg().add(op, catchPair.snd, fDivByZeroExcType);
|
||||
}
|
||||
} else {
|
||||
|
@ -2133,7 +2120,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
/**
|
||||
* callerNode: used for positioning and also in CFG (handleThrowsFrom Call)
|
||||
*/
|
||||
private CAstNode createConstructorInvocation(IMethodBinding ctorBinding, List/* <Expression> */arguments, ASTNode callerNode,
|
||||
private CAstNode createConstructorInvocation(IMethodBinding ctorBinding, List<Expression> arguments, ASTNode callerNode,
|
||||
WalkContext context, boolean isSuper) {
|
||||
ITypeBinding ctorType = ctorBinding.getDeclaringClass();
|
||||
assert ctorType.isClass();
|
||||
|
@ -2189,12 +2176,11 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
CAstNode ast = makeNode(context, fFactory, pos, CAstNode.CAST, fFactory.makeConstant(fTypeDict.getCAstTypeFor(castedTo)),
|
||||
argNode, fFactory.makeConstant(fTypeDict.getCAstTypeFor(castedFrom)));
|
||||
|
||||
Collection excTargets = context.getCatchTargets(fClassCastExcType);
|
||||
Collection<Pair<ITypeBinding, Object>> excTargets = context.getCatchTargets(fClassCastExcType);
|
||||
if (!excTargets.isEmpty()) {
|
||||
// connect ClassCastException exception edge to relevant catch targets
|
||||
// (presumably only one)
|
||||
for (Iterator iterator = excTargets.iterator(); iterator.hasNext();) {
|
||||
Pair catchPair = (Pair) iterator.next();
|
||||
for (Pair<ITypeBinding, Object> catchPair : excTargets) {
|
||||
context.cfg().add(cfgMapDummy, catchPair.snd, fClassCastExcType);
|
||||
}
|
||||
} else {
|
||||
|
@ -2327,7 +2313,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
ASTNode continueTarget = makeBreakOrContinueTarget(n, "continueLabel" + n.getStartPosition());
|
||||
CAstNode continueNode = visitNode(continueTarget, context);
|
||||
|
||||
String loopLabel = (String) context.getLabelMap().get(n);
|
||||
String loopLabel = context.getLabelMap().get(n);
|
||||
LoopContext lc = new LoopContext(context, loopLabel, breakTarget, continueTarget);
|
||||
|
||||
/*
|
||||
|
@ -2377,11 +2363,11 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
private CAstNode visit(SwitchStatement n, WalkContext context) {
|
||||
ASTNode breakTarget = makeBreakOrContinueTarget(n, "breakLabel" + n.getStartPosition());
|
||||
CAstNode breakAst = visitNode(breakTarget, context);
|
||||
String loopLabel = (String) context.getLabelMap().get(n); // set by labeled statement (if there is one before this
|
||||
String loopLabel = context.getLabelMap().get(n); // set by labeled statement (if there is one before this
|
||||
// switch statement)
|
||||
WalkContext childContext = new BreakContext(context, loopLabel, breakTarget);
|
||||
Expression cond = n.getExpression();
|
||||
List/* <Statement> */cases = n.statements();
|
||||
List<Statement> cases = n.statements();
|
||||
|
||||
// First compute the control flow edges for the various case labels
|
||||
for (int i = 0; i < cases.size(); i++) {
|
||||
|
@ -2398,11 +2384,11 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
}
|
||||
|
||||
ArrayList<CAstNode> caseNodes = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> caseNodes = new ArrayList<>();
|
||||
|
||||
// polyglot bundles all statements in between two statements into a block.
|
||||
// this is temporary place to hold current bundle of nodes.
|
||||
ArrayList<CAstNode> currentBlock = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> currentBlock = new ArrayList<>();
|
||||
|
||||
// Now produce the CAst representation for each case
|
||||
for (Object o : cases) {
|
||||
|
@ -2627,7 +2613,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
ASTNode breakTarget = makeBreakOrContinueTarget(n, "breakLabel" + n.getStartPosition());
|
||||
ASTNode continueTarget = makeBreakOrContinueTarget(n, "continueLabel" + n.getStartPosition());
|
||||
String loopLabel = (String) context.getLabelMap().get(n);
|
||||
String loopLabel = context.getLabelMap().get(n);
|
||||
WalkContext loopContext = new LoopContext(context, loopLabel, breakTarget, continueTarget);
|
||||
|
||||
return makeNode(context, fFactory, n, CAstNode.LOCAL_SCOPE,
|
||||
|
@ -2643,10 +2629,10 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
private CAstNode visit(ForStatement n, WalkContext context) {
|
||||
ASTNode breakTarget = makeBreakOrContinueTarget(n, "breakLabel" + n.getStartPosition());
|
||||
ASTNode continueTarget = makeBreakOrContinueTarget(n, "continueLabel" + n.getStartPosition());
|
||||
String loopLabel = (String) context.getLabelMap().get(n);
|
||||
String loopLabel = context.getLabelMap().get(n);
|
||||
WalkContext loopContext = new LoopContext(context, loopLabel, breakTarget, continueTarget);
|
||||
|
||||
ArrayList<CAstNode> inits = new ArrayList<CAstNode>();
|
||||
ArrayList<CAstNode> inits = new ArrayList<>();
|
||||
for (int i = 0; i < n.initializers().size(); i++) {
|
||||
ASTNode init = (ASTNode) n.initializers().get(i);
|
||||
if (init instanceof VariableDeclarationExpression) {
|
||||
|
@ -2672,7 +2658,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
private CAstNode visit(TryStatement n, WalkContext context) {
|
||||
List/* <CatchClause> */catchBlocks = n.catchClauses();
|
||||
List<CatchClause> catchBlocks = n.catchClauses();
|
||||
Block finallyBlock = n.getFinally();
|
||||
Block tryBlock = n.getBody();
|
||||
|
||||
|
@ -2685,8 +2671,8 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
TryCatchContext tc = new TryCatchContext(context, n);
|
||||
|
||||
CAstNode tryNode = visitNode(tryBlock, tc);
|
||||
for (Iterator iter = catchBlocks.iterator(); iter.hasNext();) {
|
||||
tryNode = makeNode(context, fFactory, n, CAstNode.TRY, tryNode, visitNode((CatchClause) iter.next(), context));
|
||||
for (CatchClause catchClause : catchBlocks) {
|
||||
tryNode = makeNode(context, fFactory, n, CAstNode.TRY, tryNode, visitNode(catchClause, context));
|
||||
}
|
||||
|
||||
// try/catch
|
||||
|
@ -2720,11 +2706,9 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
context.cfg().map(n, result);
|
||||
|
||||
Collection/* <Pair<Type,Node>> */catchNodes = context.getCatchTargets(label);
|
||||
|
||||
for (Iterator iter = catchNodes.iterator(); iter.hasNext();) {
|
||||
Pair/* <Type,Node> */catchNode = (Pair/* <Type,Node> */) iter.next();
|
||||
Collection<Pair<ITypeBinding, Object>> catchNodes = context.getCatchTargets(label);
|
||||
|
||||
for (Pair<ITypeBinding, Object> catchNode : catchNodes) {
|
||||
context.cfg().add(n, catchNode.snd, catchNode.fst);
|
||||
}
|
||||
|
||||
|
@ -2732,12 +2716,11 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
private void hookUpNPETargets(ASTNode n, WalkContext wc) {
|
||||
Collection excTargets = wc.getCatchTargets(fNullPointerExcType);
|
||||
Collection<Pair<ITypeBinding, Object>> excTargets = wc.getCatchTargets(fNullPointerExcType);
|
||||
if (!excTargets.isEmpty()) {
|
||||
// connect NPE exception edge to relevant catch targets
|
||||
// (presumably only one)
|
||||
for (Iterator iterator = excTargets.iterator(); iterator.hasNext();) {
|
||||
Pair catchPair = (Pair) iterator.next();
|
||||
for (Pair<ITypeBinding, Object> catchPair : excTargets) {
|
||||
wc.cfg().add(n, catchPair.snd, fNullPointerExcType);
|
||||
}
|
||||
} else {
|
||||
|
@ -2774,13 +2757,12 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
} else {
|
||||
TypeReference arrayTypeRef = fIdentityMapper.getTypeRef(newType);
|
||||
|
||||
List/* <Expression> */dims = n.dimensions();
|
||||
List<Expression> dims = n.dimensions();
|
||||
CAstNode[] args = new CAstNode[dims.size() + 1];
|
||||
|
||||
int idx = 0;
|
||||
args[idx++] = fFactory.makeConstant(arrayTypeRef);
|
||||
for (Iterator iter = dims.iterator(); iter.hasNext();) {
|
||||
Expression dimExpr = (Expression) iter.next();
|
||||
for (Expression dimExpr : dims) {
|
||||
args[idx++] = visitNode(dimExpr, context);
|
||||
}
|
||||
return makeNode(context, fFactory, n, CAstNode.NEW, args);
|
||||
|
@ -2840,7 +2822,6 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
/**
|
||||
* Giant switch statement, part deux
|
||||
*
|
||||
* @param body
|
||||
* @param context
|
||||
* @return
|
||||
*/
|
||||
|
@ -3016,7 +2997,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Iterator getScopedEntities(CAstNode construct) {
|
||||
public Iterator<CAstEntity> getScopedEntities(CAstNode construct) {
|
||||
Assertions.UNREACHABLE("CompilationUnitEntity asked for AST-related entities, but it has no AST.");
|
||||
return null;
|
||||
}
|
||||
|
@ -3050,8 +3031,8 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Collection getQualifiers() {
|
||||
return Collections.EMPTY_LIST;
|
||||
public Collection<CAstQualifier> getQualifiers() {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -3141,13 +3122,13 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
}
|
||||
|
||||
private static class TryCatchContext extends DelegatingContext {
|
||||
Collection<Pair<ITypeBinding, Object>> fCatchNodes = new ArrayList<Pair<ITypeBinding, Object>>();
|
||||
Collection<Pair<ITypeBinding, Object>> fCatchNodes = new ArrayList<>();
|
||||
|
||||
TryCatchContext(WalkContext parent, TryStatement tryNode) {
|
||||
super(parent);
|
||||
|
||||
for (Iterator catchIter = tryNode.catchClauses().iterator(); catchIter.hasNext();) {
|
||||
CatchClause c = (CatchClause) catchIter.next();
|
||||
for (Iterator<CatchClause> catchIter = tryNode.catchClauses().iterator(); catchIter.hasNext();) {
|
||||
CatchClause c = catchIter.next();
|
||||
Pair<ITypeBinding, Object> p = Pair.make(c.getException().resolveBinding().getType(), (Object) c);
|
||||
|
||||
fCatchNodes.add(p);
|
||||
|
@ -3159,11 +3140,10 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
// Look for all matching targets for this thrown type:
|
||||
// if supertpe match, then return only matches at this catch
|
||||
// if subtype match, then matches here and parent matches
|
||||
Collection<Pair<ITypeBinding, Object>> catchNodes = new ArrayList<Pair<ITypeBinding, Object>>();
|
||||
Collection<Pair<ITypeBinding, Object>> catchNodes = new ArrayList<>();
|
||||
|
||||
for (Iterator<Pair<ITypeBinding, Object>> iter = fCatchNodes.iterator(); iter.hasNext();) {
|
||||
Pair<ITypeBinding, Object> p = (Pair<ITypeBinding, Object>) iter.next();
|
||||
ITypeBinding catchType = (ITypeBinding) p.fst;
|
||||
for (Pair<ITypeBinding, Object> p : fCatchNodes) {
|
||||
ITypeBinding catchType = p.fst;
|
||||
|
||||
// catchType here should NEVER be FakeExceptionTypeBinary, because these can only be thrown (not caught) by
|
||||
// "1/0", implicit null pointer exceptions, etc.
|
||||
|
@ -3341,7 +3321,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
// // ENUM TRANSFORMATION //////////////////////////////////////////
|
||||
// /////////////////////////////////////////////////////////////////
|
||||
|
||||
private static final ArrayList<CAstQualifier> enumQuals = new ArrayList<CAstQualifier>(3);
|
||||
private static final ArrayList<CAstQualifier> enumQuals = new ArrayList<>(3);
|
||||
static {
|
||||
enumQuals.add(CAstQualifier.PUBLIC);
|
||||
enumQuals.add(CAstQualifier.STATIC);
|
||||
|
@ -3372,7 +3352,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
fFactory.makeConstant(fieldRef));
|
||||
|
||||
// CONSTRUCT ARGUMENTS & "new MyEnum(...)" statement
|
||||
ArrayList<Object> arguments = new ArrayList<Object>();
|
||||
ArrayList<Object> arguments = new ArrayList<>();
|
||||
arguments.add(fFactory.makeConstant(node.getName().getIdentifier())); // name of constant
|
||||
arguments.add(fFactory.makeConstant(node.resolveVariable().getVariableId())); // id
|
||||
arguments.addAll(node.arguments());
|
||||
|
@ -3405,7 +3385,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
superMet = m;
|
||||
assert met != null && superMet != null : "Couldn't find enum values() function in JDT bindings!";
|
||||
|
||||
Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities);
|
||||
|
||||
MethodDeclaration fakeMet = ast.newMethodDeclaration();
|
||||
|
@ -3423,7 +3403,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
CAstNode typeLit = makeNode(context, fFactory, fakeMet, CAstNode.TYPE_LITERAL_EXPR, fFactory.makeConstant(fIdentityMapper
|
||||
.typeToTypeID(enumType)));
|
||||
CAstNode stringSvar = makeNode(context, fFactory, fakeMet, CAstNode.VAR, fFactory.makeConstant("s"), fFactory.makeConstant(fTypeDict.getCAstTypeFor(ast.resolveWellKnownType("java.lang.String"))));
|
||||
ArrayList<Object> args = new ArrayList<Object>();
|
||||
ArrayList<Object> args = new ArrayList<>();
|
||||
args.add(typeLit);
|
||||
args.add(stringSvar);
|
||||
CAstNode call = createMethodInvocation(fakeMet, superMet, makeNode(context, fFactory, fakeMet, CAstNode.VOID), args, context);
|
||||
|
@ -3431,7 +3411,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
CAstNode bodyNode = makeNode(context, fFactory, fakeMet, CAstNode.LOCAL_SCOPE, makeNode(context, fFactory, fakeMet,
|
||||
CAstNode.BLOCK_STMT, makeNode(context, fFactory, fakeMet, CAstNode.RETURN, cast)));
|
||||
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<CAstType>(1);
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<>(1);
|
||||
paramTypes.add(fTypeDict.getCAstTypeFor(ast.resolveWellKnownType("java.lang.String")));
|
||||
|
||||
return new ProcedureEntity(bodyNode, fakeMet, enumType, memberEntities, context, paramTypes, enumType, met.getModifiers(), handleAnnotations(met));
|
||||
|
@ -3444,7 +3424,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
met = m;
|
||||
assert met != null : "Couldn't find enum values() function in JDT bindings!";
|
||||
|
||||
Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities);
|
||||
|
||||
MethodDeclaration fakeMet = ast.newMethodDeclaration();
|
||||
|
@ -3465,7 +3445,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
CAstNode.BLOCK_STMT, makeNode(context, fFactory, fakeMet, CAstNode.RETURN, makeNode(context, fFactory, fakeMet,
|
||||
CAstNode.ARRAY_LITERAL, eltNodes))));
|
||||
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<CAstType>(0);
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<>(0);
|
||||
return new ProcedureEntity(bodyNode, fakeMet, enumType, memberEntities, context, paramTypes, enumType.createArrayType(1), met
|
||||
.getModifiers(), handleAnnotations(enumType));
|
||||
}
|
||||
|
@ -3491,7 +3471,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
// fakeValuesDecl.setProperty("com.ibm.wala.cast.java.translator.jdt.fakeValuesDeclConstants", constants);
|
||||
// staticInits.add(fakeValuesDecl);
|
||||
|
||||
ArrayList<IVariableBinding> constants = new ArrayList<IVariableBinding>();
|
||||
ArrayList<IVariableBinding> constants = new ArrayList<>();
|
||||
for (IVariableBinding var : typeBinding.getDeclaredFields())
|
||||
if (var.isEnumConstant())
|
||||
constants.add(var);
|
||||
|
@ -3540,7 +3520,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
|
||||
// PART II: make ctor with simply "super(a,b,c...)"
|
||||
// TODO: extra CAstNodes
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<CAstNode, CAstEntity>();
|
||||
final Map<CAstNode, CAstEntity> memberEntities = new LinkedHashMap<>();
|
||||
final MethodContext context = new MethodContext(oldContext, memberEntities);
|
||||
MethodDeclaration fakeCtor = ast.newMethodDeclaration();
|
||||
fakeCtor.setConstructor(true);
|
||||
|
@ -3560,7 +3540,7 @@ public abstract class JDTJava2CAstTranslator<T extends Position> {
|
|||
fakeArguments[i] = ((SingleVariableDeclaration) nonDefaultCtor.parameters().get(i - 3)).getName().getIdentifier();
|
||||
}
|
||||
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<CAstType>(superCtor.getParameterTypes().length);
|
||||
ArrayList<CAstType> paramTypes = new ArrayList<>(superCtor.getParameterTypes().length);
|
||||
fakeArguments[0] = "this";
|
||||
fakeArguments[1] = "__wala_jdtcast_argument1"; // TODO FIXME: change to invalid name in the case that nonDefaultCtor != null
|
||||
fakeArguments[2] = "__wala_jdtcast_argument2"; // otherwise there will be conflicts if we name our variable
|
||||
|
|
|
@ -62,7 +62,6 @@ public class JDTTypeDictionary extends CAstTypeDictionaryImpl {
|
|||
/**
|
||||
*
|
||||
* @param ast Needed to get root type "java.lang.Object"
|
||||
* @param translator
|
||||
*/
|
||||
public JDTTypeDictionary(AST ast, JDTIdentityMapper identityMapper) {
|
||||
fAst = ast;
|
||||
|
@ -121,7 +120,6 @@ public class JDTTypeDictionary extends CAstTypeDictionaryImpl {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public Collection<CAstType> getSupertypes() {
|
||||
if (fEltJdtType.isPrimitive())
|
||||
return Collections.singleton(getCAstTypeFor(fAst.resolveWellKnownType("java.lang.Object")));
|
||||
|
@ -129,7 +127,7 @@ public class JDTTypeDictionary extends CAstTypeDictionaryImpl {
|
|||
// just ignore it
|
||||
// TEST DOUBLE ARRAYS! and maybe ask someone?
|
||||
assert fEltJdtType.isArray() || fEltJdtType.isClass() : "Non-primitive, non-reference array element type!";
|
||||
Collection<CAstType> supers = new ArrayList<CAstType>();
|
||||
Collection<CAstType> supers = new ArrayList<>();
|
||||
for (ITypeBinding type : fEltJdtType.getInterfaces()) {
|
||||
supers.add(getCAstTypeFor(type));
|
||||
}
|
||||
|
@ -160,8 +158,7 @@ public class JDTTypeDictionary extends CAstTypeDictionaryImpl {
|
|||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public Collection getSupertypes() {
|
||||
public Collection<CAstType> getSupertypes() {
|
||||
if (fSuperTypes == null) {
|
||||
buildSuperTypes();
|
||||
}
|
||||
|
@ -175,7 +172,7 @@ public class JDTTypeDictionary extends CAstTypeDictionaryImpl {
|
|||
.getSuperclass();
|
||||
int N = fType.getInterfaces().length + 1;
|
||||
|
||||
fSuperTypes = new ArrayList<CAstType>(N);
|
||||
fSuperTypes = new ArrayList<>(N);
|
||||
// Following assumes that noone can call getSupertypes() before we have
|
||||
// created CAstType's for every type in the program being analyzed.
|
||||
fSuperTypes.add(getCAstTypeFor(superType));
|
||||
|
|
|
@ -90,7 +90,7 @@ public class ECJSourceModuleTranslator implements SourceModuleTranslator {
|
|||
|
||||
@Override
|
||||
public void acceptAST(String source, CompilationUnit ast) {
|
||||
JDTJava2CAstTranslator jdt2cast = makeCAstTranslator(ast, source);
|
||||
JDTJava2CAstTranslator<Position> jdt2cast = makeCAstTranslator(ast, source);
|
||||
final Java2IRTranslator java2ir = makeIRTranslator();
|
||||
java2ir.translate(sourceMap.get(source), jdt2cast.translateToCAst());
|
||||
|
||||
|
@ -129,8 +129,8 @@ public class ECJSourceModuleTranslator implements SourceModuleTranslator {
|
|||
}
|
||||
|
||||
private Pair<String[],String[]> computeClassPath(AnalysisScope scope) {
|
||||
List<String> sources = new LinkedList<String>();
|
||||
List<String> libs = new LinkedList<String>();
|
||||
List<String> sources = new LinkedList<>();
|
||||
List<String> libs = new LinkedList<>();
|
||||
for (ClassLoaderReference cl : scope.getLoaders()) {
|
||||
|
||||
while (cl != null) {
|
||||
|
@ -171,10 +171,9 @@ public class ECJSourceModuleTranslator implements SourceModuleTranslator {
|
|||
* Project -> AST code from org.eclipse.jdt.core.tests.performance
|
||||
*/
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public void loadAllSources(Set<ModuleEntry> modules) {
|
||||
List<String> sources = new LinkedList<String>();
|
||||
List<String> sources = new LinkedList<>();
|
||||
Map<String, ModuleEntry> sourceMap = HashMapFactory.make();
|
||||
for(ModuleEntry m : modules) {
|
||||
if (m.isSourceFile()) {
|
||||
|
@ -188,7 +187,7 @@ public class ECJSourceModuleTranslator implements SourceModuleTranslator {
|
|||
final ASTParser parser = ASTParser.newParser(AST.JLS8);
|
||||
parser.setResolveBindings(true);
|
||||
parser.setEnvironment(libs, this.sources, null, false);
|
||||
Hashtable options = JavaCore.getOptions();
|
||||
Hashtable<String, String> options = JavaCore.getOptions();
|
||||
options.put(JavaCore.COMPILER_SOURCE, "1.8");
|
||||
parser.setCompilerOptions(options);
|
||||
parser.createASTs(sourceFiles, null, new String[0], new ECJAstToIR(sourceMap), new NullProgressMonitor());
|
||||
|
@ -198,7 +197,7 @@ public class ECJSourceModuleTranslator implements SourceModuleTranslator {
|
|||
return new Java2IRTranslator(sourceLoader);
|
||||
}
|
||||
|
||||
protected JDTJava2CAstTranslator makeCAstTranslator(CompilationUnit cu, String fullPath) {
|
||||
protected JDTJava2CAstTranslator<Position> makeCAstTranslator(CompilationUnit cu, String fullPath) {
|
||||
return new JDTJava2CAstTranslator<Position>(sourceLoader, cu, fullPath, false, dump) {
|
||||
@Override
|
||||
public Position makePosition(int start, int end) {
|
||||
|
|
|
@ -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.8"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -7,9 +7,9 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul
|
|||
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.8
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -84,7 +84,7 @@ org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
|||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
|
||||
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=warning
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
|
||||
|
@ -95,6 +95,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedImport=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
|
||||
|
@ -103,10 +104,10 @@ org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
|
|||
org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.8
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
|
|
|
@ -2,6 +2,6 @@ Manifest-Version: 1.0
|
|||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Data Plug-in
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.java.test.data
|
||||
Bundle-Version: 1.3.10.qualifier
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Bundle-Vendor: IBM
|
||||
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>WALA</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.java.test.data</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
* IBM Corporation - initial API and implementation
|
||||
*****************************************************************************/
|
||||
public class CastFromNull {
|
||||
@SuppressWarnings({ "cast", "unused" })
|
||||
public static void main(String args[]) {
|
||||
new CastFromNull();
|
||||
Object x = (Object) null;
|
||||
|
|
|
@ -49,6 +49,7 @@ final class IntWrapper extends PrimitiveWrapper {
|
|||
* @see com.ibm.miniatur.tests.sequential.PrimitiveWrapper#intValue()
|
||||
*/
|
||||
|
||||
@SuppressWarnings("javadoc")
|
||||
public int intValue() {
|
||||
return val;
|
||||
}
|
||||
|
@ -58,6 +59,7 @@ final class IntWrapper extends PrimitiveWrapper {
|
|||
* @see com.ibm.miniatur.tests.sequential.PrimitiveWrapper#setIntValue(int)
|
||||
*/
|
||||
|
||||
@SuppressWarnings("javadoc")
|
||||
public void setIntValue(int i) {
|
||||
this.val = i;
|
||||
}
|
||||
|
@ -67,6 +69,7 @@ final class IntWrapper extends PrimitiveWrapper {
|
|||
* @see com.ibm.miniatur.tests.sequential.PrimitiveWrapper#equals(java.lang.Object)
|
||||
*/
|
||||
|
||||
@SuppressWarnings("javadoc")
|
||||
public boolean equals(Object o) {
|
||||
return o instanceof IntWrapper && ((IntWrapper)o).val==val;
|
||||
}
|
||||
|
|
|
@ -15,10 +15,6 @@ public class Monitor2 {
|
|||
|
||||
public void incr() { synchronized(this) { i++; } }
|
||||
|
||||
private static boolean test(Object o) {
|
||||
return true;
|
||||
}
|
||||
|
||||
public static void main(String[] a) {
|
||||
new Monitor2().incr();
|
||||
}
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
package foo.bar.hello.world;
|
||||
|
||||
public class LoopsAndLabels {
|
||||
@SuppressWarnings({ "cast", "unused" })
|
||||
public static void main(String args[]) {
|
||||
|
||||
aaa: do {
|
||||
|
|
|
@ -39,6 +39,7 @@ package foo.bar.hello.world;
|
|||
|
||||
public class Misc {
|
||||
|
||||
@SuppressWarnings({ "cast", "unused" })
|
||||
public static void main(String args[]) {
|
||||
if ( "hello" instanceof Object ) {
|
||||
System.out.println("strings are objects in java");
|
||||
|
|
|
@ -85,7 +85,7 @@ public class AnonymousGenerics {
|
|||
globalEconomy = ops.nullary();
|
||||
System.out.println(globalEconomy);
|
||||
|
||||
Ops hack = ops;
|
||||
Ops<String> hack = ops;
|
||||
hack.unary("whatever");
|
||||
hack.nullary();
|
||||
hack = strQuadrupler;
|
||||
|
|
|
@ -43,7 +43,7 @@ import java.util.Iterator;
|
|||
public class BasicsGenerics {
|
||||
|
||||
static ArrayList<String> strs = new ArrayList<String>();
|
||||
static ArrayList ints = new ArrayList();
|
||||
static ArrayList<Integer> ints = new ArrayList<>();
|
||||
|
||||
public BasicsGenerics() {
|
||||
strs.add("Coucou, monde!");
|
||||
|
|
|
@ -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"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -2,9 +2,9 @@ eclipse.preferences.version=1
|
|||
instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.6
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
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,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
|
|||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
|
@ -73,7 +74,7 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=di
|
|||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.6
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
|
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -2,7 +2,7 @@ Manifest-Version: 1.0
|
|||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Java AST WALA Test Plug-in
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.java.test
|
||||
Bundle-Version: 1.3.10.qualifier
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Bundle-Activator: com.ibm.wala.cast.java.test.TestPlugin
|
||||
Bundle-Vendor: IBM
|
||||
Require-Bundle: com.ibm.wala.core.tests,
|
||||
|
|
|
@ -2,3 +2,4 @@ source.. = src/
|
|||
output.. = bin/
|
||||
bin.includes = META-INF/,\
|
||||
.
|
||||
javacProjectSettings = true
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>WALA</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.java.test</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
|
|
|
@ -126,7 +126,7 @@ public abstract class IRTests {
|
|||
protected static class EdgeAssertions implements IRAssertion {
|
||||
public final String srcDescriptor;
|
||||
|
||||
public final List/* <String> */<String> tgtDescriptors = new ArrayList<String>();
|
||||
public final List/* <String> */<String> tgtDescriptors = new ArrayList<>();
|
||||
|
||||
public EdgeAssertions(String srcDescriptor) {
|
||||
this.srcDescriptor = srcDescriptor;
|
||||
|
@ -346,7 +346,7 @@ public abstract class IRTests {
|
|||
return new String[] { "L" + pkgName + "/" + getTestName().substring(4) };
|
||||
}
|
||||
|
||||
protected abstract AbstractAnalysisEngine getAnalysisEngine(String[] mainClassDescriptors, Collection<String> sources, List<String> libs);
|
||||
protected abstract <I extends InstanceKey> AbstractAnalysisEngine<I> getAnalysisEngine(String[] mainClassDescriptors, Collection<String> sources, List<String> libs);
|
||||
|
||||
public <I extends InstanceKey> Pair<CallGraph, PointerAnalysis<I>> runTest(Collection<String> sources, List<String> libs,
|
||||
String[] mainClassDescriptors, List<? extends IRAssertion> ca, boolean assertReachable) throws IllegalArgumentException, CancelException, IOException {
|
||||
|
|
|
@ -615,7 +615,7 @@ public abstract class JavaIRTests extends IRTests {
|
|||
// test partial slice
|
||||
MethodReference sliceRootRef = getSliceRootReference("MiniaturSliceBug", "validNonDispatchedCall", "(LIntWrapper;)V");
|
||||
Set<CGNode> roots = cg.getNodes(sliceRootRef);
|
||||
Pair<Collection<Statement>, SDG> y = AstJavaSlicer.computeAssertionSlice(cg, pa, roots, false);
|
||||
Pair<Collection<Statement>,SDG<InstanceKey>> y = AstJavaSlicer.computeAssertionSlice(cg, pa, roots, false);
|
||||
Collection<Statement> slice = y.fst;
|
||||
SlicerTest.dumpSlice(slice);
|
||||
Assert.assertEquals(0, SlicerTest.countAllocations(slice));
|
||||
|
|
|
@ -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"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -2,9 +2,9 @@ eclipse.preferences.version=1
|
|||
instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.6
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
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,6 +38,7 @@ org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
|
|||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
|
@ -74,7 +75,7 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=di
|
|||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.6
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
|
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -2,7 +2,7 @@ Manifest-Version: 1.0
|
|||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Java Source WALA Front End
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.java
|
||||
Bundle-Version: 1.3.10.qualifier
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Bundle-Vendor: rfuhrer@watson.ibm.com
|
||||
Require-Bundle: com.ibm.wala.cast,
|
||||
com.ibm.wala.core,
|
||||
|
|
|
@ -2,3 +2,4 @@ source.. = src/
|
|||
output.. = bin/
|
||||
bin.includes = META-INF/,\
|
||||
.
|
||||
javacProjectSettings = true
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast.java</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
<packaging>jar</packaging>
|
||||
<name>WALA CAst</name>
|
||||
<description>WALA Common AST core Java front-end functionality</description>
|
||||
|
@ -45,17 +45,17 @@
|
|||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.cast</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.core</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>com.ibm.wala.shrike</artifactId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<artifactId>WALA</artifactId>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.java</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
|
|
|
@ -22,7 +22,6 @@ import com.ibm.wala.cast.java.ipa.callgraph.JavaSourceAnalysisScope;
|
|||
import com.ibm.wala.classLoader.ClassLoaderFactory;
|
||||
import com.ibm.wala.classLoader.Module;
|
||||
import com.ibm.wala.client.AbstractAnalysisEngine;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCache;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCacheImpl;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisOptions;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisScope;
|
||||
|
@ -111,8 +110,9 @@ public abstract class JavaSourceAnalysisEngine<I extends InstanceKey> extends Ab
|
|||
scope = makeSourceAnalysisScope();
|
||||
|
||||
if (getExclusionsFile() != null) {
|
||||
InputStream is = new File(getExclusionsFile()).exists()? new FileInputStream(getExclusionsFile()): FileProvider.class.getClassLoader().getResourceAsStream(getExclusionsFile());
|
||||
scope.setExclusions(new FileOfClasses(is));
|
||||
try (final InputStream is = new File(getExclusionsFile()).exists()? new FileInputStream(getExclusionsFile()): FileProvider.class.getClassLoader().getResourceAsStream(getExclusionsFile())) {
|
||||
scope.setExclusions(new FileOfClasses(is));
|
||||
}
|
||||
}
|
||||
|
||||
for (Module M : this.systemEntries) {
|
||||
|
@ -172,7 +172,7 @@ public abstract class JavaSourceAnalysisEngine<I extends InstanceKey> extends Ab
|
|||
}
|
||||
|
||||
@Override
|
||||
protected CallGraphBuilder getCallGraphBuilder(IClassHierarchy cha, AnalysisOptions options, IAnalysisCacheView cache) {
|
||||
protected CallGraphBuilder<I> getCallGraphBuilder(IClassHierarchy cha, AnalysisOptions options, IAnalysisCacheView cache) {
|
||||
return new ZeroCFABuilderFactory().make(options, cache, cha, scope, false);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
package com.ibm.wala.cast.java.client.impl;
|
||||
|
||||
import com.ibm.wala.cast.java.ipa.callgraph.AstJavaZeroXCFABuilder;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCache;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisOptions;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisScope;
|
||||
import com.ibm.wala.ipa.callgraph.CallGraphBuilder;
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
*****************************************************************************/
|
||||
package com.ibm.wala.cast.java.ipa.callgraph;
|
||||
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCache;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisOptions;
|
||||
import com.ibm.wala.ipa.callgraph.IAnalysisCacheView;
|
||||
import com.ibm.wala.ipa.callgraph.propagation.cfa.DefaultPointerKeyFactory;
|
||||
|
|
|
@ -22,7 +22,6 @@ import com.ibm.wala.cast.java.ssa.EnclosingObjectReference;
|
|||
import com.ibm.wala.classLoader.IClass;
|
||||
import com.ibm.wala.fixpoint.IntSetVariable;
|
||||
import com.ibm.wala.fixpoint.UnaryOperator;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisCache;
|
||||
import com.ibm.wala.ipa.callgraph.AnalysisOptions;
|
||||
import com.ibm.wala.ipa.callgraph.CGNode;
|
||||
import com.ibm.wala.ipa.callgraph.IAnalysisCacheView;
|
||||
|
|
|
@ -47,8 +47,8 @@ public class AstJavaModRef<T extends InstanceKey> extends AstModRef<T> {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected RefVisitor makeRefVisitor(CGNode n, Collection<PointerKey> result, PointerAnalysis<T> pa, ExtendedHeapModel h) {
|
||||
return new AstJavaRefVisitor(n, result, pa, h);
|
||||
protected RefVisitor<T, ? extends ExtendedHeapModel> makeRefVisitor(CGNode n, Collection<PointerKey> result, PointerAnalysis<T> pa, ExtendedHeapModel h) {
|
||||
return new AstJavaRefVisitor<>(n, result, pa, h);
|
||||
}
|
||||
|
||||
protected static class AstJavaModVisitor<T extends InstanceKey>
|
||||
|
@ -73,8 +73,8 @@ public class AstJavaModRef<T extends InstanceKey> extends AstModRef<T> {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected ModVisitor makeModVisitor(CGNode n, Collection<PointerKey> result, PointerAnalysis<T> pa, ExtendedHeapModel h, boolean ignoreAllocHeapDefs) {
|
||||
return new AstJavaModVisitor<T>(n, result, h, pa);
|
||||
protected ModVisitor<T, ? extends ExtendedHeapModel> makeModVisitor(CGNode n, Collection<PointerKey> result, PointerAnalysis<T> pa, ExtendedHeapModel h, boolean ignoreAllocHeapDefs) {
|
||||
return new AstJavaModVisitor<>(n, result, h, pa);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -39,7 +39,6 @@ import com.ibm.wala.util.Predicate;
|
|||
import com.ibm.wala.util.collections.Pair;
|
||||
import com.ibm.wala.util.graph.traverse.DFS;
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public class AstJavaSlicer extends Slicer {
|
||||
|
||||
/*
|
||||
|
@ -59,7 +58,7 @@ public class AstJavaSlicer extends Slicer {
|
|||
}
|
||||
|
||||
public static Set<Statement> gatherStatements(CallGraph CG, Collection<CGNode> partialRoots, Predicate<SSAInstruction> filter) {
|
||||
Set<Statement> result = new HashSet<Statement>();
|
||||
Set<Statement> result = new HashSet<>();
|
||||
for (Iterator<CGNode> ns = DFS.getReachableNodes(CG, partialRoots).iterator(); ns.hasNext();) {
|
||||
CGNode n = ns.next();
|
||||
IR nir = n.getIR();
|
||||
|
@ -108,10 +107,10 @@ public class AstJavaSlicer extends Slicer {
|
|||
});
|
||||
}
|
||||
|
||||
public static Pair<Collection<Statement>, SDG> computeAssertionSlice(CallGraph CG, PointerAnalysis<InstanceKey> pa,
|
||||
public static Pair<Collection<Statement>, SDG<InstanceKey>> computeAssertionSlice(CallGraph CG, PointerAnalysis<InstanceKey> pa,
|
||||
Collection<CGNode> partialRoots, boolean multiThreadedCode) throws IllegalArgumentException, CancelException {
|
||||
CallGraph pcg = PartialCallGraph.make(CG, new LinkedHashSet<CGNode>(partialRoots));
|
||||
SDG sdg = new SDG(pcg, pa, new AstJavaModRef(), DataDependenceOptions.FULL, ControlDependenceOptions.FULL);
|
||||
CallGraph pcg = PartialCallGraph.make(CG, new LinkedHashSet<>(partialRoots));
|
||||
SDG<InstanceKey> sdg = new SDG<>(pcg, pa, new AstJavaModRef<>(), DataDependenceOptions.FULL, ControlDependenceOptions.FULL);
|
||||
//System.err.println(("SDG:\n" + sdg));
|
||||
Set<Statement> stmts = gatherAssertions(CG, partialRoots);
|
||||
if (multiThreadedCode) {
|
||||
|
|
|
@ -155,7 +155,7 @@ public abstract class JavaSourceLoaderImpl extends ClassLoaderImpl {
|
|||
|
||||
@Override
|
||||
public Collection<IClass> getDirectInterfaces() {
|
||||
List<IClass> result = new ArrayList<IClass>();
|
||||
List<IClass> result = new ArrayList<>();
|
||||
for (Iterator iter = superTypeNames.iterator(); iter.hasNext();) {
|
||||
TypeName name = (TypeName) iter.next();
|
||||
IClass domoType = lookupClass(name);
|
||||
|
@ -288,15 +288,15 @@ public abstract class JavaSourceLoaderImpl extends ClassLoaderImpl {
|
|||
if (isStatic()) {
|
||||
types = new TypeReference[argCount];
|
||||
for (int i = 0; i < argCount; i++) {
|
||||
types[i] = TypeReference.findOrCreate(JavaSourceLoaderImpl.this.getReference(), ((CAstType) type.getArgumentTypes()
|
||||
.get(i)).getName());
|
||||
types[i] = TypeReference.findOrCreate(JavaSourceLoaderImpl.this.getReference(), type.getArgumentTypes()
|
||||
.get(i).getName());
|
||||
}
|
||||
} else {
|
||||
types = new TypeReference[argCount + 1];
|
||||
types[0] = cls.getReference();
|
||||
for (int i = 0; i < argCount; i++) {
|
||||
types[i + 1] = TypeReference.findOrCreate(JavaSourceLoaderImpl.this.getReference(), ((CAstType) type.getArgumentTypes()
|
||||
.get(i)).getName());
|
||||
types[i + 1] = TypeReference.findOrCreate(JavaSourceLoaderImpl.this.getReference(), type.getArgumentTypes()
|
||||
.get(i).getName());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -540,7 +540,7 @@ public abstract class JavaSourceLoaderImpl extends ClassLoaderImpl {
|
|||
}
|
||||
|
||||
public IClass defineType(CAstEntity type, String typeName, CAstEntity owner) {
|
||||
Collection<TypeName> superTypeNames = new ArrayList<TypeName>();
|
||||
Collection<TypeName> superTypeNames = new ArrayList<>();
|
||||
for (Iterator superTypes = type.getType().getSupertypes().iterator(); superTypes.hasNext();) {
|
||||
superTypeNames.add(toWALATypeName(((CAstType) superTypes.next())));
|
||||
}
|
||||
|
|
|
@ -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"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
|
|
@ -2,9 +2,9 @@ eclipse.preferences.version=1
|
|||
instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.6
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
|
@ -73,7 +73,7 @@ org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=di
|
|||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.6
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
|
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -2,7 +2,7 @@ Manifest-Version: 1.0
|
|||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Nu_validator
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.js.html.nu_validator
|
||||
Bundle-Version: 1.3.10.qualifier
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Export-Package: com.ibm.wala.cast.js.html.nu_validator
|
||||
Require-Bundle: com.ibm.wala.cast.js;bundle-version="1.0.0",
|
||||
com.ibm.wala.cast.js.rhino.test;bundle-version="1.0.0",
|
||||
|
|
|
@ -4,4 +4,5 @@ bin.includes = META-INF/,\
|
|||
.,\
|
||||
lib/htmlparser-1.4.jar
|
||||
jars.extra.classpath = lib/htmlparser-1.4.jar
|
||||
javacProjectSettings = true
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
<parent>
|
||||
<artifactId>WALA</artifactId>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<version>1.3.10-SNAPSHOT</version>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.js.html.nu_validator</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
|
|
|
@ -55,7 +55,7 @@ public class NuValidatorHtmlParser implements IHtmlParser {
|
|||
parser.setXmlPolicy(XmlViolationPolicy.ALLOW);
|
||||
parser.setContentHandler(new ContentHandler() {
|
||||
private Locator locator;
|
||||
private Stack<ITag> tags = new Stack<ITag>();;
|
||||
private Stack<ITag> tags = new Stack<>();;
|
||||
|
||||
private int countLines(char[] ch, int start, int length) {
|
||||
LineNumberReader r = new LineNumberReader(new StringReader (new String(ch, start, length)));
|
||||
|
@ -99,7 +99,7 @@ public class NuValidatorHtmlParser implements IHtmlParser {
|
|||
@Override
|
||||
public Set<java.util.Map.Entry<String, Pair<String,Position>>> entrySet() {
|
||||
if (es == null) {
|
||||
es = new HashSet<Map.Entry<String,Pair<String,Position>>>();
|
||||
es = new HashSet<>();
|
||||
for(int i = 0; i < atts.getLength(); i++) {
|
||||
final int index = i;
|
||||
es.add(new Map.Entry<String,Pair<String,Position>>() {
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/4"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.cast.js.nodejs"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.cast.js"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.core"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.util"/>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
||||
<classpathentry kind="src" path="testdata"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>com.ibm.wala.cast.js.nodejs.test</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.ManifestBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.SchemaBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.pde.PluginNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -0,0 +1,348 @@
|
|||
eclipse.preferences.version=1
|
||||
instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
||||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
org.eclipse.jdt.core.compiler.doc.comment.support=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.deprecation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
|
||||
org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
|
||||
org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
|
||||
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
|
||||
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=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingSerialVersion=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
|
||||
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedImport=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
|
||||
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
|
||||
org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_after_package=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_field=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_method=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_package=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
|
||||
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
|
||||
org.eclipse.jdt.core.formatter.comment.format_block_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_header=false
|
||||
org.eclipse.jdt.core.formatter.comment.format_html=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_line_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_source_code=true
|
||||
org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
|
||||
org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
|
||||
org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
|
||||
org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.comment.line_length=80
|
||||
org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
|
||||
org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
|
||||
org.eclipse.jdt.core.formatter.compact_else_if=true
|
||||
org.eclipse.jdt.core.formatter.continuation_indentation=2
|
||||
org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
|
||||
org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
|
||||
org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
|
||||
org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
|
||||
org.eclipse.jdt.core.formatter.indent_empty_lines=false
|
||||
org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
|
||||
org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
|
||||
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
|
||||
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
|
||||
org.eclipse.jdt.core.formatter.indentation.size=2
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.join_lines_in_comments=true
|
||||
org.eclipse.jdt.core.formatter.join_wrapped_lines=true
|
||||
org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
|
||||
org.eclipse.jdt.core.formatter.lineSplit=132
|
||||
org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
|
||||
org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
|
||||
org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
|
||||
org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
|
||||
org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
|
||||
org.eclipse.jdt.core.formatter.tabulation.char=space
|
||||
org.eclipse.jdt.core.formatter.tabulation.size=2
|
||||
org.eclipse.jdt.core.formatter.use_on_off_tags=false
|
||||
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
|
||||
org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
|
||||
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -0,0 +1,20 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Test
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.js.nodejs.test
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Export-Package: NodejsRequireJsonTest,
|
||||
NodejsRequireTargetSelectorResolve,
|
||||
NodejsRequireTargetSelectorResolve.requireDynamic,
|
||||
NodejsRequireTargetSelectorResolve.requireNodeModules,
|
||||
NodejsRequireTargetSelectorResolve.requireNodeModules.node_modules.lib,
|
||||
NodejsRequireTargetSelectorResolve.requireNodeModules.node_modules.lib.node_modules.sublib,
|
||||
NodejsRequireTargetSelectorResolve.requireNodeModules.node_modules.lib2,
|
||||
NodejsRequireTargetSelectorResolve.requireSimple,
|
||||
NodejsRequireTargetSelectorResolve.requireStaticCircular,
|
||||
com.ibm.wala.cast.js.nodejs.test
|
||||
Require-Bundle: com.ibm.wala.cast.js.nodejs;bundle-version="1.3.10",
|
||||
com.ibm.wala.cast.js;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
|
|
@ -0,0 +1,5 @@
|
|||
source.. = src/,\
|
||||
testdata/
|
||||
bin.includes = META-INF/,\
|
||||
.
|
||||
javacProjectSettings = true
|
|
@ -0,0 +1,42 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.ibm.wala</groupId>
|
||||
<artifactId>WALA</artifactId>
|
||||
<version>1.4.3-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>com.ibm.wala.cast.js.nodejs.test</artifactId>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>test</id>
|
||||
<phase>test</phase>
|
||||
<configuration>
|
||||
<testClassesDirectory>${project.build.outputDirectory}</testClassesDirectory>
|
||||
<argLine>-Xmx800M -ea</argLine>
|
||||
<redirectTestOutputToFile>true</redirectTestOutputToFile>
|
||||
</configuration>
|
||||
<goals>
|
||||
<goal>test</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>4.11</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
|
@ -0,0 +1,43 @@
|
|||
/******************************************************************************
|
||||
* Copyright (c) 2002 - 2016 IBM Corporation.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Brian Pfretzschner - initial implementation
|
||||
*****************************************************************************/
|
||||
package com.ibm.wala.cast.js.nodejs.test;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
import com.ibm.wala.cast.js.nodejs.NodejsCallGraphBuilderUtil;
|
||||
import com.ibm.wala.ipa.callgraph.CallGraph;
|
||||
import com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder;
|
||||
|
||||
/**
|
||||
* @author Brian Pfretzschner <brian.pfretzschner@gmail.com>
|
||||
*/
|
||||
public class NodejsRequireJsonTest {
|
||||
|
||||
@Test
|
||||
public void test() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireJsonTest/index.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Lempty/jsonModule>"));
|
||||
assertTrue(cgString.contains("Lnested/jsonModule>"));
|
||||
assertTrue(cgString.contains("Lpackage/jsonModule>"));
|
||||
assertTrue(!cgString.contains("?"));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,98 @@
|
|||
/******************************************************************************
|
||||
* Copyright (c) 2002 - 2016 IBM Corporation.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Brian Pfretzschner - initial implementation
|
||||
*****************************************************************************/
|
||||
package com.ibm.wala.cast.js.nodejs.test;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URL;
|
||||
|
||||
import org.junit.Test;
|
||||
|
||||
import com.ibm.wala.cast.js.nodejs.NodejsCallGraphBuilderUtil;
|
||||
import com.ibm.wala.ipa.callgraph.CallGraph;
|
||||
import com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder;
|
||||
|
||||
/**
|
||||
* @author Brian Pfretzschner <brian.pfretzschner@gmail.com>
|
||||
*/
|
||||
public class NodejsRequireTargetSelectorResolveTest {
|
||||
|
||||
@Test
|
||||
public void testRequireSimple() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireTargetSelectorResolve/requireSimple/index.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Lmod/nodejsModule/moduleSource/exec>"));
|
||||
assertTrue(cgString.contains("Lmod/nodejsModule/moduleSource/SomeClass/hello>"));
|
||||
assertTrue(!cgString.contains("?"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRequireStaticCircular() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireTargetSelectorResolve/requireStaticCircular/index.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Llib1/nodejsModule/moduleSource/lib1>"));
|
||||
assertTrue(cgString.contains("Llib2/nodejsModule/moduleSource/lib2>"));
|
||||
assertTrue(!cgString.contains("?"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRequireDynamic() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireTargetSelectorResolve/requireDynamic/index.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Llib1/nodejsModule/moduleSource/lib1>"));
|
||||
assertTrue(cgString.contains("Llib2/nodejsModule/moduleSource/lib2>"));
|
||||
assertTrue(!cgString.contains("?"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRequireNodeModules() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireTargetSelectorResolve/requireNodeModules/index.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Lnode_modules_lib_node_modules_sublib_sublib/nodejsModule/moduleSource"));
|
||||
assertTrue(!cgString.contains("?"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testRequireCoreModules() throws Exception {
|
||||
URL fileUrl = getClass().getClassLoader().getResource("NodejsRequireTargetSelectorResolve/requireCoreModules.js");
|
||||
File file = new File(fileUrl.toURI());
|
||||
|
||||
PropagationCallGraphBuilder builder = NodejsCallGraphBuilderUtil.makeCGBuilder(file);
|
||||
CallGraph CG = builder.makeCallGraph(builder.getOptions());
|
||||
String cgString = CG.toString();
|
||||
|
||||
assertTrue(cgString.contains("Lutil/nodejsModule/moduleSource/util"));
|
||||
assertTrue(cgString.contains("Lhttps/nodejsModule/moduleSource/https"));
|
||||
assertTrue(cgString.contains("Lhttp/nodejsModule/moduleSource/http"));
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
{}
|
|
@ -0,0 +1,3 @@
|
|||
var empty = require('./empty.json');
|
||||
var empty = require('./nested.json');
|
||||
var empty = require('./package.json');
|
|
@ -0,0 +1 @@
|
|||
{ num: 7, obj: { val1: "hello", num: 77 } }
|
15
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireJsonTest/package.json
vendored
Normal file
15
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireJsonTest/package.json
vendored
Normal file
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
"name": "test2",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"poc-lettersonly-gm": "^1.0.1",
|
||||
"validator": "^5.5.0"
|
||||
}
|
||||
}
|
|
@ -0,0 +1,2 @@
|
|||
var util = require('util');
|
||||
var util = require('https');
|
|
@ -0,0 +1,9 @@
|
|||
var lib1 = myRequire('lib1', true);
|
||||
lib1();
|
||||
|
||||
function myRequire(name, local) {
|
||||
var prefix = '';
|
||||
if (local) prefix = './';
|
||||
|
||||
return require(prefix+name);
|
||||
}
|
|
@ -0,0 +1,5 @@
|
|||
var lib2 = require('./lib2');
|
||||
|
||||
module.exports = function lib1() {
|
||||
lib2();
|
||||
};
|
|
@ -0,0 +1,5 @@
|
|||
var lib1 = require('./lib1');
|
||||
|
||||
module.exports = function lib2() {
|
||||
lib1();
|
||||
};
|
|
@ -0,0 +1 @@
|
|||
require('lib');
|
0
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib/helper.js
generated
vendored
Normal file
0
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib/helper.js
generated
vendored
Normal file
2
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib/index.js
generated
vendored
Normal file
2
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib/index.js
generated
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
require('./helper');
|
||||
require('sublib');
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"main": "sublib.js"
|
||||
}
|
|
@ -0,0 +1 @@
|
|||
require('lib2');
|
2
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib2/index.js
generated
vendored
Normal file
2
com.ibm.wala.cast.js.nodejs.test/testdata/NodejsRequireTargetSelectorResolve/requireNodeModules/node_modules/lib2/index.js
generated
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
module.exports = function lib2() {
|
||||
};
|
|
@ -0,0 +1,2 @@
|
|||
var mod = require('./mod');
|
||||
mod.exec();
|
|
@ -0,0 +1,8 @@
|
|||
function SomeClass() {
|
||||
this.hello = function hello() {}
|
||||
}
|
||||
|
||||
exports.exec = function exec() {
|
||||
var c = new SomeClass();
|
||||
c.hello();
|
||||
};
|
|
@ -0,0 +1,2 @@
|
|||
var lib1 = require('./lib1');
|
||||
lib1();
|
|
@ -0,0 +1,5 @@
|
|||
var lib2 = require('./lib2');
|
||||
|
||||
module.exports = function lib1() {
|
||||
lib2();
|
||||
};
|
|
@ -0,0 +1,5 @@
|
|||
var lib1 = require('./lib1');
|
||||
|
||||
module.exports = function lib2() {
|
||||
lib1();
|
||||
};
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="src">
|
||||
<attributes>
|
||||
<attribute name="optional" value="true"/>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry excluding="**" kind="src" output="target/classes" 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">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.cast"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.cast.js"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.cast.js.rhino"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.core"/>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.util"/>
|
||||
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
|
||||
<attributes>
|
||||
<attribute name="maven.pomderived" value="true"/>
|
||||
</attributes>
|
||||
</classpathentry>
|
||||
<classpathentry combineaccessrules="false" kind="src" path="/com.ibm.wala.shrike"/>
|
||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||
<classpathentry kind="output" path="target/classes"/>
|
||||
</classpath>
|
|
@ -0,0 +1,34 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>com.ibm.wala.cast.js.nodejs</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.ManifestBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.pde.SchemaBuilder</name>
|
||||
<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>
|
||||
</projectDescription>
|
|
@ -0,0 +1,2 @@
|
|||
eclipse.preferences.version=1
|
||||
encoding/<project>=UTF-8
|
|
@ -0,0 +1,390 @@
|
|||
eclipse.preferences.version=1
|
||||
instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
|
||||
org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
|
||||
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnull.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
|
||||
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary=
|
||||
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
|
||||
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.unusedLocal=preserve
|
||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
||||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
|
||||
org.eclipse.jdt.core.compiler.debug.localVariable=generate
|
||||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
org.eclipse.jdt.core.compiler.doc.comment.support=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deadCode=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning
|
||||
org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
|
||||
org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
|
||||
org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
|
||||
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
|
||||
org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled
|
||||
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=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=no_tag
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.missingSerialVersion=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullReference=warning
|
||||
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
|
||||
org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
|
||||
org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
|
||||
org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning
|
||||
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning
|
||||
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.rawTypeReference=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
|
||||
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
|
||||
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedImport=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
|
||||
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
|
||||
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
|
||||
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
|
||||
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
|
||||
org.eclipse.jdt.core.compiler.source=1.7
|
||||
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
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_assignment=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
|
||||
org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
|
||||
org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
|
||||
org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
|
||||
org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_after_package=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_field=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_method=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_package=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
|
||||
org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
|
||||
org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
|
||||
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
|
||||
org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
|
||||
org.eclipse.jdt.core.formatter.comment.format_block_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_header=false
|
||||
org.eclipse.jdt.core.formatter.comment.format_html=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_line_comments=true
|
||||
org.eclipse.jdt.core.formatter.comment.format_source_code=true
|
||||
org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
|
||||
org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
|
||||
org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
|
||||
org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.comment.line_length=80
|
||||
org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
|
||||
org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
|
||||
org.eclipse.jdt.core.formatter.compact_else_if=true
|
||||
org.eclipse.jdt.core.formatter.continuation_indentation=2
|
||||
org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
|
||||
org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
|
||||
org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
|
||||
org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
|
||||
org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
|
||||
org.eclipse.jdt.core.formatter.indent_empty_lines=false
|
||||
org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
|
||||
org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
|
||||
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
|
||||
org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
|
||||
org.eclipse.jdt.core.formatter.indentation.size=2
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
|
||||
org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
|
||||
org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
|
||||
org.eclipse.jdt.core.formatter.join_lines_in_comments=true
|
||||
org.eclipse.jdt.core.formatter.join_wrapped_lines=true
|
||||
org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
|
||||
org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
|
||||
org.eclipse.jdt.core.formatter.lineSplit=132
|
||||
org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
|
||||
org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
|
||||
org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
|
||||
org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
|
||||
org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
|
||||
org.eclipse.jdt.core.formatter.tabulation.char=space
|
||||
org.eclipse.jdt.core.formatter.tabulation.size=2
|
||||
org.eclipse.jdt.core.formatter.use_on_off_tags=false
|
||||
org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
|
||||
org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
|
||||
org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
|
|
@ -0,0 +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.p.missing-version-export-package=2
|
||||
compilers.p.missing-version-import-package=1
|
||||
compilers.p.missing-version-require-bundle=1
|
||||
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.unresolved-ex-points=0
|
||||
compilers.p.unresolved-import=0
|
||||
compilers.s.create-docs=false
|
||||
compilers.s.doc-folder=doc
|
||||
compilers.s.open-tags=1
|
||||
eclipse.preferences.version=1
|
|
@ -0,0 +1,10 @@
|
|||
Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: Nodejs
|
||||
Bundle-SymbolicName: com.ibm.wala.cast.js.nodejs
|
||||
Bundle-Version: 1.4.3.qualifier
|
||||
Export-Package: com.ibm.wala.cast.js.nodejs
|
||||
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,
|
||||
.
|
|
@ -0,0 +1,6 @@
|
|||
source.. = src/,\
|
||||
dat/
|
||||
bin.includes = META-INF/,\
|
||||
.,\
|
||||
lib/json-20160212.jar
|
||||
javacProjectSettings = true
|
|
@ -0,0 +1,39 @@
|
|||
<project name="com.ibm.wala.cast.js.nodejs" default="download-core-libs" basedir=".">
|
||||
<description>
|
||||
WALA Nodejs Front-end
|
||||
</description>
|
||||
<property name="nodejs-release" location="nodejs.zip" />
|
||||
<property name="core-modules" location="dat/core-modules" />
|
||||
|
||||
<target name="download-core-libs">
|
||||
<!-- 0a604e92e258c5ee2752d763e50721e35053f135 is v0.12.4-release -->
|
||||
<get src="https://api.github.com/repos/nodejs/node/zipball/0a604e92e258c5ee2752d763e50721e35053f135"
|
||||
dest="${nodejs-release}" />
|
||||
|
||||
<tempfile property="unzip-dest" />
|
||||
|
||||
<unzip src="${nodejs-release}"
|
||||
dest="${unzip-dest}">
|
||||
|
||||
<patternset>
|
||||
<include name="*/lib/**" />
|
||||
</patternset>
|
||||
</unzip>
|
||||
|
||||
<mkdir dir="${core-modules}" />
|
||||
|
||||
<move todir="${core-modules}"
|
||||
flatten="true">
|
||||
|
||||
<fileset dir="${unzip-dest}">
|
||||
<include name="*/lib/*.js" />
|
||||
</fileset>
|
||||
</move>
|
||||
|
||||
<!-- Cleanup -->
|
||||
<delete includeemptydirs="true">
|
||||
<fileset dir="${unzip-dest}" includes="**" />
|
||||
<fileset file="${nodejs-release}" />
|
||||
</delete>
|
||||
</target>
|
||||
</project>
|
|
@ -0,0 +1,4 @@
|
|||
rules:
|
||||
# Custom rules in tools/eslint-rules
|
||||
require-buffer: 2
|
||||
buffer-constructor: 2
|
|
@ -0,0 +1 @@
|
|||
*.js
|
|
@ -0,0 +1,13 @@
|
|||
var timerId = 0;
|
||||
|
||||
function setTimeout(cb, t) {
|
||||
cb();
|
||||
return timerId++;
|
||||
}
|
||||
|
||||
function setInterval(cb, t) {
|
||||
return setTimeout(function () {
|
||||
cb();
|
||||
setInterval(cb, t);
|
||||
}, t);
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue