aboutsummaryrefslogtreecommitdiffstats
path: root/util/src/main/java/org
Commit message (Collapse)AuthorAgeFilesLines
* Add Java 16 test suite for AspectJ 1.9.7 + test refactoringsAlexander Kriegisch2021-03-211-0/+4
| | | | | | | | | | | | | | | - Test all features which were preview in 14+15 and are now final in 16, compiling them with language level 16. - For Java 15 we only have sanity tests (and of course the Java <14 tests), compiling Java 16 features to target 15 does not seem to work. - Test remaining Java 16 preview feature (sealed classes). - Instead of overriding runTest(String) in several base classes like XMLBasedAjcTestCaseForJava*Only or XMLBasedAjcTestCaseForJava*OrLater, we now override setUp() from JUnit's TestCase base class. This will run before runTest(String) and make the tests fail much faster, if a user tries to run them on the wrong VM. Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Add Java 15 / AspectJ 1.9.7 test suiteAlexander Kriegisch2021-03-171-0/+4
| | | | | | Also fix some minor details in Java 14 suite Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Fix 'ajdoc' tests for Java 15 buildAlexander Kriegisch2021-03-141-6/+10
| | | | Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Fix resource leak in FileUtilAlexander Kriegisch2021-03-111-24/+15
| | | | | | | | | | | | | | This made ModuleTests.testBuildModuleAndApplyAspectsFromAspectPath fail because a file delete job for a module JAR failed after a previous compile job had called FileUtil.isZipFile(File) in which the opened zip file was never closed. A try with resources fixes that. Maybe the corresponding test worked on Linux before, I did not try. I just know that Linux is more forgiving about deleting open files while on Windows they are being locked, which makes Windows the better system to search for open file leaks. Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Fix javadoc references to nonexistent fields, classes, or packagesJerry James2020-09-141-1/+1
|
* Fix misplaced or incorrect javadoc tagsJerry James2020-09-142-11/+11
|
* Remove unnecessary interface modifiersLars Grefer2020-08-171-16/+16
| | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Merge branch 'master' into feature/collection-performanceAndy Clement2020-08-152-2/+0
|\
| * Cleanup unused importsLars Grefer2020-08-162-2/+0
| | | | | | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* | Weaken Collection declarationsLars Grefer2020-08-153-5/+5
| | | | | | | | | | | | Reports on declarations of Collection variables made by using the collection class as the type, rather than an appropriate interface. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* | Redundant Collection.addAll() callLars Grefer2020-08-151-2/+1
| | | | | | | | | | | | Reports Collection.addAll() and Map.putAll() calls after instantiation of a collection using a constructor call without arguments. Such constructs can be replaced with a single call to a parametrized constructor which simplifies code. Also for some collections the replacement might be more performant. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* | Collection.toArray() call styleLars Grefer2020-08-151-1/+1
|/ | | | | | | There are two styles to convert a collection to an array: either using a pre-sized array (like c.toArray(new String[c.size()])) or using an empty array (like c.toArray(new String[0]). In older Java versions using pre-sized array was recommended, as the reflection call which is necessary to create an array of proper size was quite slow. However since late updates of OpenJDK 6 this call was intrinsified, making the performance of the empty array version the same and sometimes even better, compared to the pre-sized version. Also passing pre-sized array is dangerous for a concurrent or synchronized collection as a data race is possible between the size and toArray call which may result in extra nulls at the end of the array, if the collection was concurrently shrunk during the operation. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Remove checks for old Java VersionsLars Grefer2020-08-131-0/+5
| | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Use the diamond operator where possibleLars Grefer2020-08-137-35/+35
| | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Unnecessary unboxingLars Grefer2020-08-081-1/+1
| | | | | | Reports "unboxing", e.g. explicit unwrapping of wrapped primitive values. Unboxing is unnecessary under Java 5 and newer, and can be safely removed. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* 'String.indexOf()' expression is replaceable with 'contains()'Lars Grefer2020-08-082-3/+3
| | | | | | Reports any String.indexOf() expressions which can be replaced with a call to the String.contains() method available in Java 5 and newer. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* 'for' loop replaceable with enhanced 'for' loopLars Grefer2020-08-086-150/+144
| | | | | | Reports for loops which iterate over collections or arrays, and can be replaced with an enhanced for loop (i.e. the foreach iteration syntax). Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Include JDTCore for Java14Andy Clement2020-04-201-7/+10
|
* polishAndy Clement2019-11-292-3/+7
|
* Java 13 supportAndy Clement2019-11-251-55/+60
|
* Fix Bug 550290 - Lack of TypeSafeEnum#hashCode may lead to non-deterministic ↵Andy Clement2019-09-091-9/+21
| | | | bytecode
* Updated with Java12 supportAndy Clement2019-04-031-0/+4
|
* extra util for finding suitable files with mustBeJar optionAndy Clement2019-02-191-0/+35
|
* mavenized util moduleAndy Clement2019-01-2311-0/+4643