Manu Sridharan
2b1d82d1bb
Expand missing super test
2018-07-19 18:17:59 +02:00
Manu Sridharan
a78af3f67e
Add API to add an InputStream for a jar to an AnalysisScope ( #330 )
...
This is useful, e.g., if you have the bytes of a jar file in memory and want to load it into an `AnalysisScope`.
2018-07-19 17:01:51 +02:00
Manu Sridharan
aeb17dfca4
Allow for classes with missing superclasses in class hierarchy ( #329 )
...
Fixes #322
We add an option `createPhantomSuperclasses` to `ClassHierarchy`. When set, if a superclass is missing, we create a new `PhantomClass` in its place and allow the subclass to be added.
To use, you can create the `ClassHierarchy` with the new `ClassHierarchyFactory.makeWithPhantom` methods.
2018-07-19 16:10:35 +02:00
Manu Sridharan
76faa4df2d
Fix bug with method lookup ( #276 )
...
The previous lookup logic would erroneously look in superclasses for a constructor with parameters.
Bug reported on [the mailing list](https://groups.google.com/forum/#!msg/wala-sourceforge-net/6m_VmDF-lZ0/erZIYQ68BwAJ;context-place=topic/wala-sourceforge-net/TjRzdDyljjY )
2017-12-23 16:38:26 -08:00
Ben Liblit
e316471d88
Fix nearly all Eclipse warnings about using raw types
...
Along the way, I also converted many "for (;;)" loops into modern
"for (:)" loops. I didn't systematically look for all opportunities
to do this, though. I merely made this change where I was already
converting raw Iterator uses into modern Iterator<...> uses.
Better use of generics also allowed many casts to become statically
redundant. I have removed all such redundant casts.
Only three raw-types warnings remain after this batch of fixes. All
three involve raw uses of CallGraphBuilder. I've tried to fix these
too, but it quickly snowballs into a cascade of changes that may or
may not eventually reach a statically-type-save fixed point. I may
give these last few problem areas another go in the future. For now,
though, the hundreds of other fixes seem worth keeping even if there
are a few stragglers.
This commit may change some public APIs, but only by making weaker
type signatures stronger by replacing raw types with generic types.
For example, we may change something like "Set" into "Set<String>",
but we're not adding new arguments, changing any
underlying (post-generics-erasure) types, etc.
2017-07-12 10:39:06 -07:00
Ben Liblit
aaf66705e1
Fix 65 Eclipse warnings about unused exception parameters
...
In the cases addressed here, the caught exception was being "handled"
by throwing some new exception. Instead of discarding the old
exception, pass it to the new exception's constructor to indicate the
original cause of the newly-created exception. This practice, called
"exception chaining", can often be useful in debugging.
2017-03-20 00:44:39 -05:00
Ben Liblit
7cbbeb1d81
Fix 92 deprecation warnings
...
All of these fixes involve replacing junit.framework.Assert with
org.junit.Assert for JUnit 4.x and later.
2017-03-17 21:18:26 -05:00
Julian Dolby
d24519e974
cross-cutting changes to make more of WALA runnable with TeaVM. The biggest change is refactoring to AnalysisCache and friends; since TeaVM does not support SoftReference, I needed to add a layer of interfaces so that I can use a more simpleminded caching implementation for TeaVM. There are other changes to Module and friends to break connections with File and URL, which also cause TeaVM grief. I also organized imports in many places to remove unused types that caused trouble.
2017-02-02 20:33:27 -05:00
Julian Dolby
c9b1006305
changes for allowing seq. and conc. CHAs
2017-01-12 16:34:54 -05:00
Julian Dolby
26b126203d
fix imports; restructure annotations tests
2015-09-16 13:25:21 -04:00
Julian Dolby
31f9f1b0b5
more exclusions
...
allow 1.8 libs
2015-06-04 15:51:46 -04:00
Julian Dolby
58b7c7324c
test for reading java 8
2015-06-04 13:53:25 -04:00
Julian Dolby
0ccaae3b2c
pull exclusions file support into util project and then share it with
...
the shrike-based dynamic call graph builder so that static and dynamic
graphs can be built consistently more easily.
2013-11-14 13:02:56 -05:00
Julian Dolby
080325b5f6
merge
2013-06-25 11:57:37 -04:00
Manu Sridharan
9bc5bcbb3c
Disable certain tests when analyzed classes are in a jar file.
...
These tests create FileModules for certain class / source files,
and hence assume those files are sitting in the filesystem. We
should come up with a better fix here.
2013-05-26 14:45:50 -07:00
Manu Sridharan
ba228963bf
better handling of missing bytecodes
...
In some cases, class files will have non-abstract methods with no
bytecodes (e.g., stubs for compilation purposes). While such a class
file is invalid, we want to enable clients to handle such an error.
With these changes, Shrike will throw an InvalidClassFileException for
such cases, and WALA's IR construction code will throw a
WalaRuntimeException.
2013-01-21 15:27:13 -08:00
Manu Sridharan
256cd06460
Convert all Java source files to use Unix line endings; no semantic change
2012-09-04 15:56:05 -07:00
Manu Sridharan
3317c1ccf6
basic compatibility with Java 7 (i.e., don't crash immediately)
2012-08-03 15:41:09 -07:00
Manu Sridharan
2edb070437
changed FileProvider to have instance methods
2012-04-16 14:57:14 -04:00
msridhar1
d81d8569eb
fix test
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@4554 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2012-04-03 22:43:34 +00:00
msridhar1
1d28b2dc26
fix for bug reported by Juergen Graf: handle multiple fields with the same name in a JVM class
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@4552 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2012-04-03 22:26:12 +00:00
msridhar1
2ed3b05257
bug fix
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3986 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2010-11-03 17:49:06 +00:00
dolby-oss
3c8c5e2059
clean up @author
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3819 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2010-04-28 19:35:34 +00:00
msridhar1
ab47cddadf
more speedups
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3749 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-07-28 01:47:06 +00:00
msridhar1
93a4571961
undo WalaTestCase extending TestCase; dependent projects will have to be switched to JUnit 4. Also, more optimizations.
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3742 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-07-27 22:43:06 +00:00
msridhar1
02e7bf2894
switch to jUnit 4
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3739 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-07-27 20:38:48 +00:00
sjfink
f229e9c2ac
mostly comments. A few new type parameters. No semantic changes.
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3620 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-05-29 15:26:35 +00:00
sjfink
f39b9cf43a
revert previous checkin (a major API change to IClass.getSourceFile())
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3584 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-05-07 14:38:07 +00:00
omertripp
2113f3e601
REFACTOR: - code changes to accommodate .NET into WALA. A .NET class maps onto multiple source files, and thus these changes.
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3583 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-05-07 14:14:28 +00:00
sjfink
957cb2b8ca
deprecate Trace
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3432 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-04-09 20:31:14 +00:00
sjfink
7fdacaef22
more IllegalArgument checks
...
propagate IOExceptions when reading AnalysisScopes from files
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3396 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-03-31 20:16:52 +00:00
dolby-oss
7118bd6573
adapt to core changes
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3232 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-02-19 16:01:24 +00:00
sjfink
3aefc3e1ea
support for reading InnerClass attributes
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2992 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-08-15 14:49:53 +00:00
msridhar1
cbcee6624f
change getPossibleTargets() to handle <init> methods specially
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2745 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-04-04 17:54:00 +00:00
msridhar1
4bb4e509ff
add logic that arrays implement Cloneable and Serializable
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2740 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-04-01 21:50:45 +00:00
sjfink
feac4a9dd7
delete IClass.isStatic()
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2647 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-03-03 01:47:13 +00:00
msridhar1
1f7b573bf6
added static inner class test (commented out assert for now)
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2645 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-03-02 17:45:45 +00:00
sjfink
444d3a92b0
more cleanup of util packages
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2463 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-24 22:54:05 +00:00
sjfink
0d7f69e274
misc bug fixes
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2439 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-24 01:58:34 +00:00
sjfink
bfbe4fdd2f
clean up and refactor some APIs surrounding file I/O and exclusions files. Needed in order to allow clients to use some APIs with application-specific exclusions.
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2248 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-02 22:27:45 +00:00
dolby-oss
1d62ddf160
remove EMF
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2162 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-12-12 20:47:35 +00:00
sjfink
23b0e9a91c
bug fix and related API changes for interface type tests
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2105 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-12-05 19:49:39 +00:00
sjfink
beb56a76e7
more EMF obliteration
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2034 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-11-16 19:20:50 +00:00
sjfink
7826d12a77
more aggressive exclusions in order to run quickly against Java 6.0 libraries
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1859 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-10-11 16:05:17 +00:00
sjfink
a6e4894120
use Hash factories everywhere
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1442 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-07-11 21:08:35 +00:00
sjfink
10492c7298
massive overhaul of Warnings management
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1379 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-07-06 22:07:24 +00:00
sjfink
448741b9d3
misc. cleanups and refactorings
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1151 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-05-18 17:30:49 +00:00
sjfink
9790e8a14f
test for bug report 1714480, OOM for ClassHierarchy.getPossibleTargets
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1087 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-05-07 20:29:37 +00:00
sjfink
2dbd132c3a
annotations and minor cleanups
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1006 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-04-26 13:52:53 +00:00
sjfink
7938061118
make ClassHierarchy implement Iterable<IClass>
...
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@784 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-02-23 17:20:59 +00:00