mernst commented on code in PR #138:
URL: https://github.com/apache/commons-bcel/pull/138#discussion_r945153126
##########
src/test/java/org/apache/bcel/AbstractTestCase.java:
##########
@@ -63,9 +64,12 @@ public AnnotationEntryGen createFruitAnnotationEntry(final
ConstantPoolGen cp,
public SyntheticRepository createRepos(final String cpentry)
{
- final ClassPath cp = new ClassPath("target" + File.separator +
"testdata"
- + File.separator + cpentry + File.separator);
- return SyntheticRepository.getInstance(cp);
+ try (ClassPath cp = new ClassPath("target" + File.separator +
"testdata"
+ + File.separator + cpentry + File.separator)) {
+ return SyntheticRepository.getInstance(cp);
+ } catch (IOException e) {
+ throw new Error(e);
Review Comment:
Good idea. I have done that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]