Commit Graph
137 Commits
Author SHA1 Message Date
Andreas Dangel 84ea5e04b4 Revert the changes - compare Nodes with == again 2021-02-26 20:59:35 +01:00
Andreas Dangel 7384a69d31 Merge branch 'master' into dogfood-6.30.0 2021-02-26 19:26:36 +01:00
Andreas Dangel f7909ae78a Merge branch 'master' into pr-2963-update 2021-01-21 11:43:01 +01:00
Andreas Dangel c37f208d3e Call jjtree/javacc with UTF-8 as default encoding
Fixes #2970
2020-12-17 18:31:13 +01:00
Andreas Dangel 62a052e97b (dogfood) Further CompareObjectsWithEquals fixes 2020-12-17 16:44:32 +01:00
Maikel Steneker af31b3a773 Add GenericToken.getKind() to interface 2020-12-10 12:10:47 +01:00
Jeff Bartolotta e1c42a10ec Move visitor to VfParser#parse
LanguageVersionHandler#getTypeResolutionFacade is deprecated. Moved the VfExpressionTypeVisitor creation and execution to VfParser#parse instead.

ParsingOptionsTest located in pmd-test wasn't running previously because it was in the src/main hierarchy. Moved this test into the src/test hierarchy and consolidated the methods from the
similarly named class from pmd-core.
2020-11-12 20:13:19 -08:00
Andreas Dangel 52a71f48aa [javascript] Add deprecations for EcmascriptParser/Handler
Refs #2837
2020-11-06 09:26:44 +01:00
Clément Fournier a43dea916d Fix JS tests
Rewrite assertions for better error messages
The difference is 32 tokens instead of 30;
this is because previously, AnyTokenizer
tokenized `window.alert` as a single token. Now
it tokenizes it a `window`, `.`, `alert`.
2020-09-03 11:40:03 +02:00
Andreas Dangel 89140d86ce Merge branch 'master' into pr-2656 2020-08-20 09:47:16 +02:00
Andreas Dangel 40f954f81a Merge branch 'pr-2675'
[core] Deprecate parser options #2675
2020-08-02 16:53:24 +02:00
Andreas Dangel eb683569af Merge branch 'pr-2617'
[core] Deprecate missing language attribute on rule definition #2617
2020-07-30 10:19:03 +02:00
Clément Fournier 25d59beb37 Revert changes to apex rules
Someone may be using those properties, this would
be a breaking change
2020-07-28 14:26:06 +02:00
Clément Fournier 151a56cfa0 Deprecate other custom XPath rules 2020-07-28 14:26:06 +02:00
Maikel Steneker 6fb5ac59b9 Ensure CPD uses tab width of 1 for tabs consistently
The columns that are reported by CPD were inconsistent across languages
before. A language like Java (using a JavaCC-based tokenizer) would use
a width of 8 for tabs, whereas a language like C# (using an Antlr-based
tokenizer) would use 1 instead.

This includes unit tests for most languages to ensure a tab character is
counted as 1. The configuration for JavaCC has been adjusted to respect
this as well.
2020-07-20 10:42:21 +02:00
Andreas Dangel 666621e958 Fix checkstyle 2020-07-17 15:16:29 +02:00
Andreas Dangel 7ae424a35b Add deprecation javadocs 2020-07-17 14:43:43 +02:00
Clément Fournier 8add323403 Fix other offenders 2020-07-06 14:02:21 +02:00
Clément Fournier 49635c2a66 Deprecate Rulechain visitors 2020-07-01 11:27:38 +02:00
Clément Fournier 659066ee02 Deprecate BaseLanguageModule constructor 2020-07-01 11:27:38 +02:00
Clément Fournier d7f96e08d9 Uniformize apply across languages 2020-07-01 11:27:38 +02:00
Clément Fournier 709996fddc Finish cpp module 2020-06-13 20:34:30 +02:00
Clément Fournier 551ab453fd Convert CPP tests 2020-06-13 20:14:08 +02:00
Clément Fournier 0a1e82efad Rename dir 2020-06-13 19:21:27 +02:00
Clément Fournier e48fc7cca2 Convert JS tests 2020-06-13 19:16:22 +02:00
Clément Fournier 4e21c1a947 Fix js tests 2020-06-13 19:02:35 +02:00
Andreas Dangel a3a292d591 Remove unnecessary source-type tags in rule tests
source-type is actually only needed if
* the language supports more than one version
* the parser behaves differently with different versions
  (this has to do with compatibility, e.g. assert/enum keywords
  in java)
* the test needs a newer version than the default version
  (e.g. to test new language features)
* the test needs an older version than the default version
  (e.g. the rule has a maximumLanguageVersion specified)
* the rule behaves differently for different versions
  (e.g. BigIntegerInstantiation)
2020-05-23 14:16:13 +02:00
Andreas Dangel 4c2c111492 [javascript] Cleanup rule test xml files
Avoid unnecessary CDATA for description
Use 4 space indentation instead of tabs
Remove trailing whitespace
End file with a newline
2020-05-16 18:56:05 +02:00
Andreas Dangel 01a3ae5a19 [javascript] Add a treedump test 2020-04-25 18:07:48 +02:00
Andreas Dangel bc49a8afff [javascript] Internalize AbstractInfixEcmascriptNode 2020-04-23 10:17:20 +02:00
Clément Fournier 75d5626c40 Merge branch 'master' into javascript-es6 2020-04-20 11:51:51 +02:00
Clément Fournier 6127add18e Fix forgotten ctor in js module 2020-04-20 11:27:16 +02:00
Clément Fournier aad67c501d Merge branch 'master' into js-deprecate-ast 2020-04-20 11:02:27 +02:00
Andreas Dangel c62041e827 Merge branch 'pr-2377'
[all] Update all XPath rules to XPath 2.0 #2377
2020-04-18 11:49:44 +02:00
Andreas Dangel 623ba4c92e [javascript] Internalize AST constructors 2020-04-17 20:44:54 +02:00
Clément Fournier fa7b286d31 Checkstyle 2020-04-16 18:17:33 +02:00
Clément Fournier c7172fe78f Add tests 2020-04-16 18:02:18 +02:00
Andreas Dangel 08d31c62a9 Merge branch 'master' into pr-2377 2020-04-16 17:52:03 +02:00
Clément Fournier 04b5372f23 Fix issue with Rhino localization 2020-04-16 17:19:04 +02:00
Andreas Dangel e2ee78dae3 [javascript] Add support for ES6 version and use that as default
Fixes #1235
Fixes #2379
2020-04-16 16:42:16 +02:00
Clément Fournier bcf90ceb8a Externalize creator for XPath rule 2020-04-08 21:35:34 +02:00
Clément Fournier 3d429019ee Fix rules 2020-03-20 18:47:40 +01:00
Clément Fournier 0d65c2e6e6 Add relevant property tag 2020-03-20 18:47:40 +01:00
Clément Fournier eaceefc39e Update XPath rules to 2.0 2020-03-20 18:47:40 +01:00
Clément Fournier 138c0e3e86 Deprecate tokManagers for more module 2020-03-17 15:08:58 +01:00
Clément Fournier d90d5d267c Remove trailing whitespace everywhere 2020-01-24 23:40:06 +01:00
Andreas Dangel 5feca7fd93 Exclude generated AST*.java files from internalization 2020-01-24 16:19:24 +01:00
Clément Fournier 60e97d0ec8 Deprecate javacc generated code 2020-01-22 17:19:29 +01:00
Andreas Dangel 4450d826f7 Merge branch 'pr-2225'
[core] CPD: report endLine / column informations for found duplications
2020-01-17 14:59:02 +01:00
Andreas Dangel 817c3d1127 CPD: Remove deprecations in Mark / TokenEntry
* Provide these values for more languages
2020-01-17 14:47:23 +01:00