A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/pmd/pmd/issues/831 below:

[java] StackOverflow in JavaTypeDefinitionSimple.toString · Issue #831 · pmd/pmd · GitHub

Affects PMD Version:
6.0.0

Rule:
Don't know if this is related to any particular rule, can check further.

Description:
With 5.8.1 pmd everything works fine, with 6.0.0 I'm getting StackOverflowException from toString method when called from MethodTypeResolution(358):
LOG.log(Level.FINE, "Method {0} couldn't be resolved", String.valueOf(methodType));

Cause: java.lang.StackOverflowError
	at net.sourceforge.pmd.lang.java.typeresolution.typedefinition.JavaTypeDefinitionSimple.toString(JavaTypeDefinitionSimple.java:246)
	at net.sourceforge.pmd.lang.java.typeresolution.typedefinition.JavaTypeDefinitionSimple.toString(JavaTypeDefinitionSimple.java:246)
...

Code Sample demonstrating the issue:

public abstract class MessageBuilder<T extends MessageBuilder, U extends PartBuilder<U>> implements IMessageBuilder {
	public T addComponent(U builder) {
		components.add(builder);
		return (T) this;
	}
}

Running PMD through: Gradle


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4