-
Notifications
You must be signed in to change notification settings - Fork 61
Fixed ConcurrentModificationException on a map and tweeked some options. #443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: mmazas <[email protected]>
Signed-off-by: mmazas <[email protected]>
Do you have a stack trace of the ConcurrentModificationException? |
I had one, but did not record it, pointing on the second call to it.next(),
denoting the map change due to the put() on it; the proposed and tested fix
is to use an additional map ca2.
Le sam. 12 juil. 2025 à 11:17, Olivier Lamy ***@***.***> a
écrit :
… *olamy* left a comment (codehaus-plexus/plexus-compiler#443)
<#443 (comment)>
Do you have a stack trace of the ConcurrentModificationException?
—
Reply to this email directly, view it on GitHub
<#443 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFQZRCZPKINQOZYDFJBRWVT3IDHBLAVCNFSM6AAAAACBDR3KUSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTANRUHE4DANBTGE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Signed-off-by: mmazas <[email protected]>
I added a commit to fix erroneous excludes management. |
if (excludes != null && !excludes.isEmpty()) { | ||
String[] exclStrs = excludes.toArray(new String[excludes.size()]); | ||
scanner.setIncludes(exclStrs); | ||
scanner.setExcludes(exclStrs); |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do too but did not find a way to create a second pull request while the first one was still opened...
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
You should get one easily with:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a ConcurrentModificationException that occurred when modifying a map while iterating over it, and includes several improvements to compiler argument handling and option tweaks for the C# compiler.
- Fixed ConcurrentModificationException by using a temporary HashMap to collect modifications during iteration
- Enhanced debug option handling to support different debug modes (full, pdbonly, etc.)
- Corrected various compiler argument processing logic and fixed a bug where excludes were incorrectly set as includes
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
} else { | ||
args.add("/debug-"); | ||
} | ||
// plugin parameter is no the same as the compiler option! so replaced |
Copilot
AI
Oct 5, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corrected spelling of 'no' to 'not'.
// plugin parameter is no the same as the compiler option! so replaced | |
// plugin parameter is not the same as the compiler option! so replaced |
Copilot uses AI. Check for mistakes.
// plugin parameter is no the same as the compiler option! so replaced | ||
// if (config.isDebug()) { | ||
// args.add("/debug+"); | ||
// } else { | ||
// args.add("/debug-"); | ||
// } |
Copilot
AI
Oct 5, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider removing commented-out code rather than leaving it in the codebase. If this code might be needed for reference, document why it was removed in a comment.
// plugin parameter is no the same as the compiler option! so replaced | |
// if (config.isDebug()) { | |
// args.add("/debug+"); | |
// } else { | |
// args.add("/debug-"); | |
// } | |
// plugin parameter is not the same as the compiler option, so debug handling was removed. |
Copilot uses AI. Check for mistakes.
String k = arr[0]; | ||
v = arr[1]; | ||
compilerArguments.put(k, v); | ||
// compilerArguments.put(k, v); |
Copilot
AI
Oct 5, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider removing commented-out code rather than leaving it in the codebase.
// compilerArguments.put(k, v); |
Copilot uses AI. Check for mistakes.
No description provided.