Mikhail Glukhikh
b27152f903
Replace some FIR syntax errors with more proper diagnostics
2020-03-27 16:46:59 +03:00
FenstonSingel
b7d8e879a6
[FIR] Support 4 diagnostics for pairs of modifiers
...
In particular, this commit includes:
* Attempt to abstract access to FirSourceElement via FirModifier
* Add more visit functions to DeclarationCheckersDiagnosticComponent
* Add messages+factories for 4 modifier-related errors and warnings
* Introduce FirModifierChecker
2020-03-27 12:34:29 +03:00
Mikhail Glukhikh
8884cbe415
Introduce FIR_IDENTICAL for FIR vs old frontend tests #KT-36879 Fixed
2020-03-05 09:39:40 +03:00
Ilya Chernikov
6356807997
Reapply "Only create descriptors for candidates with lambda args"
...
#KT-36247 fixed
A lot of testdata changed because significanly less (error) descriptors
are created for unresolved types, so diagnostics became different.
2020-02-14 11:41:30 +01:00
Dmitriy Novozhilov
2536fa0cd5
[FIR-TEST] Add new testdata generated after changes in previous commit
2019-12-12 16:11:46 +03:00
victor.petukhov
46bd5ba107
Add alphabetical sorting diagnostics with same ranges
2019-02-14 12:31:42 +03:00
Kirill Rakhman
8bc020f31b
Fix modifier order in generated overriden functions
...
Fixes #KT-21600
2018-01-16 15:42:02 +01:00
Dmitry Savvinov
816d89e393
[NI] Improved testdata after changes in applicabilities
...
This commits introduces testdata changes, where NI behaviour strictly
improved, after several previous fixes.
For some tests, just WITH_NEW_INFERENCE directive was added. It
indicates, that some of previous commits first introduced error in that
test, and then some other commit fixed it (netting no overall testdata
change). It is preferrably to keep those annotations until we will
migrate to NI completely, to prevent unexpected regressions.
2017-12-07 12:49:56 +03:00
Mikhail Zarechenskiy
8757298994
Add diagnostics to test data from NI
2017-11-29 02:54:26 +03:00
Mikhail Zarechenskiy
a71238bf94
Place !WITH_NEW_INFERENCE directive to diagnostics test data
2017-11-29 02:53:49 +03:00
Dmitry Petrov
4c2cfd3ea9
Synthesized 'copy' in data classes cannot override anything since 1.3
...
Synthesized 'copy' introduces default values for parameters, which is
prohibited for regular overrides.
Report warning in language version 1.2-, error in 1.3+.
2017-09-14 10:13:22 +03:00
Mikhail Zarechenskiy
f5cd8c7e4d
Relax name shadowing warning on parameter names
...
#KT-17611 Fixed
2017-07-07 14:19:57 +03:00
Mikhail Zarechenskiy
32f609ceee
Check lambda parameter for name shadowing
...
#KT-5160 Fixed
2017-04-17 17:12:44 +03:00
Pavel V. Talanov
d94da5af40
Frontend: create component functions for properties with error types
...
Fixes an inconsistency in light classes where we could have different
class structure depending on whether the type was resolved
2017-03-15 20:55:00 +03:00
Mikhail Glukhikh
7a41d13b41
Do not add special names to scopes #KT-14319 Fixed
2016-10-13 17:17:05 +03:00
Alexander Udalov
090d157f86
Update test data for data classes
2016-09-15 16:45:48 +03:00
Alexander Udalov
fea116f14e
Allow data classes to implement equals/hashCode/toString from base classes
...
#KT-11306 Fixed
2016-09-15 16:45:48 +03:00
Denis Zharkov
7a9af072b4
Fix ClassCastException when data object is being analyzed
...
#KT-12687 Fixed
2016-07-10 15:04:32 +03:00
Alexander Udalov
e68de436bb
Allow data classes to inherit from other classes
...
#KT-10330 Fixed
2016-06-22 21:35:57 +03:00
Denis Zharkov
d0acb3674a
Fix rendered testData
...
New members in enum member scope
2016-05-16 15:38:13 +03:00
Alexander Udalov
1b8f934b54
Delete deprecated enum 'values' property
2016-02-19 22:28:44 +03:00
Denis Zharkov
816c66063b
Report special diagnostic when fake-call receiver is nullable
...
#KT-3602 Fixed
2016-02-02 08:17:49 +03:00
Mikhail Glukhikh
22c0ddaa48
Destructuring declaration initializer now cannot use extension componentX() on nullable #KT-7794 Fixed
2016-01-26 19:03:28 +03:00
Mikhail Glukhikh
c8b50eec1e
Enum.values: deprecation (warning) --> deprecation (error)
2015-12-11 11:11:42 +03:00
Mikhail Glukhikh
dc60c62781
Enum.values is now deprecated but Enum.values() is no more deprecated
2015-11-23 17:29:36 +03:00
Mikhail Glukhikh
cd1b58f2eb
Final in interfaces: deprecation ---> error + relevant test fixes
2015-11-20 15:43:19 +03:00
Mikhail Glukhikh
dd43674426
Data class must have at least one argument is reported on constructor parameter list now, if any #KT-9999 Fixed
2015-11-16 10:45:54 +03:00
Alexey Tsvetkov
dc27363452
Remove @annotation from test data
2015-10-19 20:45:01 +03:00
Alexey Tsvetkov
1973573a89
Remove @data from test data
2015-10-19 20:45:00 +03:00
Denis Zharkov
1c02231cda
Regenerate rendered descriptors after transforming Enum.values to property
2015-10-17 17:46:16 +03:00
Mikhail Glukhikh
f8a356747e
Stdlib rename: 'name' and 'ordinal' are now properties in Enum, same name functions are deprecated
2015-10-14 20:40:13 +03:00
Mikhail Glukhikh
fff434d377
data + open / inner / abstract / sealed are now forbidden
2015-10-07 15:13:14 +03:00
Mikhail Glukhikh
930402d910
Incorrect 'inner' usage is diagnosed by parent, not by target
2015-09-30 17:54:47 +03:00
Mikhail Glukhikh
7cf2840fe5
'final' is deprecated in interfaces
2015-09-29 13:05:08 +03:00
Yan Zhulanow
6db9344659
Fix compiler tests
2015-09-25 19:20:20 +03:00
Mikhail Glukhikh
f06a79d534
KNPE fixed in data class checker together with some ID warnings #KT-9296 Fixed #EA-73584 Fixed
2015-09-25 17:46:33 +03:00
Mikhail Glukhikh
789f351f6f
data modifier is now inapplicable to enum classes, annotations, objects and interfaces #KT-8302 Fixed
2015-09-23 16:33:11 +03:00
Mikhail Glukhikh
315a304c8e
New modifier checking strategy: only one error but any number of warnings, a warning can never shadow an error
2015-09-23 16:33:08 +03:00
Mikhail Glukhikh
55c7df8b8d
Deprecations: data class should now have at least one primary constructor parameter, parameters should be val / var and not vararg.
2015-09-23 16:33:05 +03:00
Mikhail Glukhikh
3d6253c27f
abstract + data and sealed + data are also deprecated
2015-09-23 16:33:02 +03:00
Mikhail Glukhikh
038d955c23
Data classes cannot have class supertypes, a new test, relevant test fixes
2015-09-23 16:33:00 +03:00
Mikhail Glukhikh
58110cd0d1
open + data and inner + data are deprecated, a new test, relevant test fixes
2015-09-23 16:32:57 +03:00
Denis Zharkov
4850fd10f0
Regenerate test data containing rendered descriptors
...
Introduced '@' after each annotation
2015-09-18 10:14:39 +03:00
Michael Nedzelsky
bc5c9065d2
fix tests in org.jetbrains.kotlin.checkers
2015-09-08 02:04:32 +03:00
Denis Zharkov
349d5f02ea
Drop wrong assertion about duplicating properties in data class
...
#EA-64269 Fixed
2015-06-02 14:07:49 +03:00
Dmitry Jemerov
4bdf598bfe
compiler testdata: s/trait/interface
2015-05-12 19:43:17 +02:00
Dmitry Jemerov
9975bb8935
replace 'trait' keyword with 'interface' in user-visible messages and code generation tools
2015-05-12 11:49:37 +02:00
Dmitry Jemerov
f374eec8f1
deprecating types after colon
2015-04-29 16:33:24 +02:00
Andrey Breslav
d466533ef2
Missing test added
2015-03-06 21:59:03 +03:00
Andrey Breslav
9c469a7dff
Don't make generated methods of local data classes LOCAL
2015-01-29 16:07:30 +03:00