When executing PMD on the command line, multiple errors are logged, e.g.
Could not find class net.sourceforge.pmd.util.viewer.model.ViewerModel, due to: java.lang.IncompatibleClassChangeError: net/sourceforge/pmd/lang/java/typeresolution/visitors/PMDASMVisitor
Jun 04, 2016 7:41:03 PM net.sourceforge.pmd.lang.java.typeresolution.ClassTypeResolver visit
WARNUNG: Could not find class net.sourceforge.pmd.util.viewer.model.ViewerModel, due to: java.lang.IncompatibleClassChangeError: net/sourceforge/pmd/lang/java/typeresolution/visitors/PMDASMVisitor
Could not find class net.sourceforge.pmd.util.viewer.model.ViewerModelEvent, due to: java.lang.IncompatibleClassChangeError: net/sourceforge/pmd/lang/java/typeresolution/visitors/PMDASMVisitor
Jun 04, 2016 7:41:03 PM net.sourceforge.pmd.lang.java.typeresolution.ClassTypeResolver visit
WARNUNG: Could not find class net.sourceforge.pmd.util.viewer.model.ViewerModelEvent, due to: java.lang.IncompatibleClassChangeError: net/sourceforge/pmd/lang/java/typeresolution/visitors/PMDASMVisitor
Could not find class net.sourceforge.pmd.util.viewer.model.ViewerModelListener, due to: java.lang.IncompatibleClassChangeError: net/sourceforge/pmd/lang/java/typeresolution/visitors/PMDASMVisitor
Jun 04, 2016 7:41:03 PM net.sourceforge.pmd.lang.java.typeresolution.ClassTypeResolver visit
This is because of classpath madness - pmd-apex brings apex-jorje-ide jar, which is an uberjar, which conatins ASM in an old version, but PMD itself relies on version 5 (in oder to support java8 etc...). In the older version, org.objectweb.asm.ClassVisitor is a interface, but in the recent version 5.0.4 it is an abstract class - so this change is incompatible :)
This will be fixed with PMD 5.5.0.
Commt: https://github.com/pmd/pmd/commit/af21dd5297a28d4bfe2cfdcbf52bc9a63452683f