Commit Graph

29 Commits

Author SHA1 Message Date
Ben Liblit d35e8d0fa2 Disable Eclipse warnings about missing version constraints
Specifically, we're turning off Eclipse warnings about missing version
constraints on required bundles ("Require-Bundle"), exported
packages ("Export-Package"), and imported packages ("Import-Package").
We're not turning these off absolutely everywhere, though: only in
packages where one or more such warnings were actually being reported.
So if a given package was already providing all version constraints
for, say, package imports, then we've kept that warning on in that
package.

Honestly I don't entirely understand the practical implications of
these warnings.  However, there were 355 of them across many WALA
subprojects.  I take this as evidence that the WALA developers do not
consider these version constraints to be important.  Therefore, we may
as well stop warning about something we have no intention of fixing.

That being said, if we *do* want to fix some or all of these, I
welcome any advice on what those fixes should look like.  I am rather
ignorant about all things OSGi.
2017-03-28 20:37:41 -05:00
Ben Liblit 1bb3d827c4 Turn off Eclipse warnings about unused caught-exception parameters
Manu requested that we use this approach instead of adding
`@SuppressWarnings("unused")` at each affected catch block.  That
seems reasonable to me, given the large number of such warnings and
the lack of likely harm from ignoring such caught exceptions.
2017-03-23 16:39:58 -05:00
Manu Sridharan 064fa9a503 Merge pull request #140 from liblit/remove-execute-bits-from-non-scripts
Remove execute bits from many non-executable (i.e., non-script) files
2017-03-12 10:27:08 -07:00
Ben Liblit 5a5cccc062 Strip execute bits from many non-executable (i.e., non-script) files 2017-02-23 06:10:08 -06:00
Ben Liblit 522c382a19 Use consistent Java versions, usually 1.7
Previously, the various Eclipse projects' Java configurations used
mixtures of 1.6, 1.7, and 1.8.  Many were internally inconsistent,
such as requiring 1.7 in "MANIFEST.MF" but 1.6 in the Eclipse JDT
build preferences.  The Travis-CI configuration tests against both 1.7
and 1.8, but does not test against 1.6.

Across all projects, the most common version was 1.7.  So I'm going to
assume that 1.7 is the intended build target.  This commit makes 1.7
the selected version nearly everywhere.

"com.ibm.wala.core.testdata" is the one exception.  This specific
project uses a few features only found in 1.8, such as lambda
expressions.  Previously, "com.ibm.wala.core.testdata" used 1.7 in
some aspects of its configuration but 1.8 in others.  Now it
consistently targets 1.8.  I wish this one project didn't need to be
inconsistent with the rest of WALA, but at least now it's consistent
with itself.

(Personally, I'd be happy to target 1.8 only.  But my impression
across all of these configuration files is that the WALA developers
still want to be compatible with 1.7.  If that is no longer a
requirement, let me know and I will adjust these changes accordingly
to target 1.8 only.)

This change eliminates 11 "There is no 'jre.compilation.profile' build
entry and the project has Java compliance preferences set" warnings
and 13 "The JRE container on the classpath is not a perfect match to
the 'JavaSE-1.7' execution environment" warnings.  However, it also
adds 450 "Redundant specification of type arguments <...>" warnings
and 17 "Resource '...' should be managed by try-with-resource"
warnings.  So this seems like a net step backward in my wish to reduce
WALA warnings.  However, those new warnings concern Java 1.7 language
features that we were not previously using to good effect in projects
that targeted 1.6.  If we all agree that we can now target 1.7
instead, then we can use these helpful features as the newly-added
warnings suggest.  So I call that a step in the right direction.
2016-11-29 21:29:30 -06:00
Ben Liblit 18b79bf0f9 Merge branch 'master' into warning-fixes-xml-validation 2016-11-29 10:08:00 -06:00
Ben Liblit 3b1547f0a7 Exclude Maven-generated (?) files from XML validation
I think the "target/p2artifacts.xml" and "target/p2content.xml" files
are generated by Maven.  They are well-formed XML but Eclipse's XML
validator legitimately warns that they lack grammar constraints.
Since we're not maintaining the tool that creates these files, we are
not in a position to do anything about that.  Therefore, we may as
well exclude these from validation entirely.  That way we can
more-clearly recognize warnings that we *can* do something about.
2016-11-28 14:55:25 -06:00
Ben Liblit 94f6933ff1 Exclude JUnit test result files from XML validation
As created by Tycho Surefire, these files are XML documents without
DTD or XML Schema declarations.  The XML validator warns about this
omission.  However, Surefire is not a WALA component.  We are not in a
suitable position to change it to include XML schema or DTD
declarations in the XML files it generates.  Better, then, to ignore
this benign problem so we can focus on warnings that we can act on
directly.
2016-11-28 12:42:30 -06:00
Ben Liblit 2a5503b9aa Exclude Maven-generated HTML pages from validation
Eclipse validation warns about invalid HTML content in all
Maven-generated "target/site/dependency-convergence.html" files.  The
warnings are legitimate: these HTML files are indeed invalid.
However, we don't maintain the tool that generates these files, so we
are not in a position to fix them.  Better, therefore, to suppress
these warnings so that we can notice and fix other problems over which
we do have control.
2016-11-27 21:24:03 -06:00
Ben Liblit dace7b709f Ignore missing non-null-by-default annotations in Eclipse
In general, the WALA code base is not really ready for nullness
checking.  It would be nice if we got there some day, but I'm not
planning to take that on now or any time soon.  Until then, it's not
useful to warn about missing @NonNullByDefault declarations on WALA
packages.

See also older commit 7b6811b.
2016-11-26 18:47:35 -06:00
Ben Liblit 7b6811b2dd Ignore potential null accesses in Eclipse
Eclipse Mars Service Release 2 finds 45 potential null pointer accesses
across WALA's various Eclipse projects. Eclipse ignores these by
default, but any individual user may have changed their personal Eclipse
configuration to treat them as warnings or errors. Thus, some people
will find that the code builds while others find that it fails. Better
to explicitly use a known-good configuration.

In the long run someone should inspect these cases one-by-one and fix
them where appropriate. But that is probably better managed as part of a
larger effort to tidy up nulls in WALA. I'm not planning to take that on
now or any time soon, though, so this is a better setup for now.
2016-06-27 13:11:42 -05:00
Julian Dolby 36709b9d1a java 7 support, with much pain for stack maps :) 2014-10-06 15:34:16 -04:00
Manu Sridharan 898e1c3810 add modeling of window.onload invocation 2013-09-16 09:37:18 -07:00
Manu Sridharan 00eb1d2bd2 Set all projects to build against Java 6; no semantic change. Fixes #20 2013-04-10 16:01:27 -07:00
Manu Sridharan 56f3d847a5 more conversion to Unix line endings 2012-09-04 15:59:50 -07:00
msridhar1 e149af8a13 Some more tests.
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@4381 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2012-01-06 21:41:57 +00:00
sjfink 3a49f17ebc update code formatting for Eclipse 3.6
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@4048 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2011-02-03 15:14:47 +00:00
msridhar1 8b41d7fc88 update to JUnit 4
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3747 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2009-07-27 23:21:22 +00:00
dolby-oss 637f06b2c0 further work on lexical scoping
more bug fixes for Anders


git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@3136 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-12-16 14:54:09 +00:00
sjfink dfad24c3ee tweak code format
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2946 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-07-04 01:56:49 +00:00
sjfink 4142366236 tweak code format
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2903 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-06-25 14:08:57 +00:00
sjfink c17b88a69f tweak code format
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2371 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-11 16:51:21 +00:00
sjfink a9ec8071f7 tweak code formatting for enums
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2333 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-10 16:26:01 +00:00
sjfink 639d5d3aa4 tweak code formatting template
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2268 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2008-01-03 16:31:34 +00:00
sjfink fbca81de76 revert code compliance level to 5.0
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@2205 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-12-17 18:47:50 +00:00
sjfink e6effa6909 bump up source level to 6.0
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1845 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-10-11 14:25:30 +00:00
sjfink 603bf56043 share errors/warnings settings
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1084 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-05-07 13:28:45 +00:00
sjfink 1f52a37eb6 shared code formatter settings
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1067 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-05-07 13:21:01 +00:00
sjfink 8b1a9b1750 enable project-specific compiler settings
git-svn-id: https://wala.svn.sourceforge.net/svnroot/wala/trunk@1026 f5eafffb-2e1d-0410-98e4-8ec43c5233c4
2007-04-30 13:46:57 +00:00