Commit Graph

99 Commits

Author SHA1 Message Date
Toshiaki Kameyama 343af60cb4 Add intention to expand boolean expression
#KT-38597 Fixed
2020-06-02 23:52:06 +03:00
Ilya Kirillov 0fe5694cb7 Do not render redundant Nullable annotations when generating declarations
#KT-36321 fixed
2020-02-11 13:48:58 +03:00
Toshiaki Kameyama 4d9b19da82 Remove comments from function/property implementation template
#KT-18539 Fixed
2019-11-13 08:37:25 +09:00
Toshiaki Kameyama 44edd94fea "Create member function" quick fix: do not add redundant semicolons after enum entry
#KT-14899 Fixed
2019-09-24 19:40:31 +07:00
Igor Yakovlev 7b2f39530a Fix invalid testdata for ConvertToScopeIntention applicability 2019-08-28 16:31:49 +03:00
Mikhail Zarechenskiy d4d1648e1d [IDE-NI-MIGRATE] Migrate QuickFix tests for new inference 2019-05-06 13:59:24 +03:00
Toshiaki Kameyama 607325c6e5 Add "Round using roundToInt/roundToLong" quick fix
#KT-30389 Fixed
2019-04-11 18:58:05 +03:00
Dmitry Gridin c89d1af9fa Improve Create property from Usage
Place generated property next to other properties
 #KT-14886 Fixed
2019-02-27 00:07:55 +03:00
Mikhail Glukhikh c084eefb65 Fix a bunch of IDE quick-fix tests (related to "convert to run/...")
These actions became available more often some days ago
2019-02-25 10:37:46 +03:00
Mikhail Glukhikh 6e10235208 Make "Add name(s) to call arguments" available for generic arguments
#KT-15550 Fixed
2018-10-27 12:13:42 +03:00
Toshiaki Kameyama dc57887a4d Create function quick fix: fix visibility from inline method #KT-25228 Fixed 2018-09-04 19:01:22 +03:00
Alexey Sedunov a5a13b74f5 Create from Usage: Support smart casts on explicit receivers
#KT-24069 Fixed
2018-05-11 16:05:20 +03:00
Alexey Sedunov a4a10c7ba4 Create from Usage: Fix generation of extensions with nullable receiver
#KT-23796 Fixed
2018-05-11 16:05:19 +03:00
Toshiaki Kameyama a36e8c86f1 KT-22428 Create member function from usage shouldn't present type parameters as options (#1509)
* KT-22428 Create member function from usage shouldn't present type parameters as options

* Reformat & cleanup
2018-02-17 14:09:44 +03:00
Alexey Sedunov 84c6f9bf45 Create from Usage: Fix choosing superclass for abstract member
This applies to cases when non-existing member is called without
explicit receiver

 #KT-21332 Fixed
2017-11-30 12:49:25 +03:00
Alexey Sedunov eda747c0bf Minor: Fix tests 2017-07-19 11:34:30 +03:00
Alexey Sedunov e9bf1d2ab8 Create from Usage: Add test for KT-17537
#KT-17537 Fixed
2017-07-17 16:09:53 +03:00
Alexey Sedunov 2e76a76088 Control Flow: Fix CFG usage info for double-colon expressions
#KT-12551 Fixed
 #KT-17092 Fixed
2017-07-17 16:09:51 +03:00
Alexey Sedunov 26d6088c82 Create from Usage: Infer expected type for lambda body
#KT-18186 Fixed
2017-07-17 16:09:49 +03:00
Mikhail Glukhikh d08b18f5f8 Introduce "use expression body" inspection #KT-16063 Fixed
Converted from the relevant intention
Reported cases: one-liners, whens
Also, more exact caret detection in local inspection tests
2017-07-07 18:15:06 +03:00
Valentin Kipyatkov 92a763552c KT-17970 Intention actions to format parameter/argument list placing each on separate line
#KT-17970 Fixed
2017-05-19 12:20:51 +03:00
Nikolay Krasko 2bb48fc802 Allow empty single-line bodies in property accessors 2016-12-14 13:40:44 +03:00
Alexey Sedunov 2a594a5bcc Create from Usage: Support generation of abstract members for superclasses. Skip non-abstract superclasses when generating abstract member
#KT-14019 Fixed
2016-12-02 14:14:05 +03:00
Valentin Kipyatkov 3bd39df587 No parameter names in types for error messages 2016-10-11 23:38:50 +03:00
Valentin Kipyatkov 41ee06ec96 Use parameter names in DescriptorRenderer 2016-10-11 23:38:49 +03:00
Alexey Sedunov da1178fe0c Create from Usages: Do not suggest on type-mismatched expressions which are not call arguments
#KT-14143 Fixed
2016-10-07 20:20:35 +03:00
Valentin Kipyatkov 21c2268f70 Protection against "<caret>" missing in test data
Many incorrect tests fixed
2016-09-27 18:05:26 +03:00
Mikhail Glukhikh 9ad820205e Partial build fix (new convert to expression body opportunity in quick-fixes) 2016-09-19 10:37:39 +03:00
Alexey Sedunov c2b38cfa41 Create from Usage: Place extension properties after the usage and generate stub getter
#KT-11795 Fixed
2016-08-18 19:15:38 +03:00
Alexey Sedunov 99ba340236 Create from Usage: Make extension functions/properties 'private' by default
#KT-11799 Fixed
2016-08-18 19:15:37 +03:00
Alexey Sedunov 562488b348 Create from Usage: Disable "Create property" (non-abstract) in interfaces. Make "Create function" (non-abstract) generate function body in interfaces
#KT-13365 Fixed
2016-08-17 11:49:52 +03:00
Dmitry Jemerov a979c7e1d7 ugly fix for failing tests. without the string template, KotlinFilePathReferenceContributor injects a file reference into the string literal, and an unrelated intention (AddAnnotationIntention) tries to resolve it. resolving the reference caches the default contexts in FIleReferenceSet, which caches the order entries of a module in an OrderRootsCache. this creates VirtualFilePointers which are for some reason not disposed properly. 2016-07-23 21:18:26 +02:00
Alexander Udalov 5a6237b357 Refactor resolution of double colon expression LHS
Try resolving the LHS only when it looks (PSI-wise) like it could represent a
type element. This, for example, allows "illegal selector" error to be reported
on weird expressions like '""?.""::class'.

Also remove expression text from the "illegal selector" diagnostic, it's not
needed and can screw up the error message if the text is too big
2016-07-22 11:05:19 +03:00
Alexey Sedunov ae06f01c95 Create from Usage: Approximate unresolvable types
#KT-7722 Fixed
(cherry picked from commit 917cd22)
2016-07-20 16:36:12 +03:00
Alexey Sedunov a1e86e8bfa Create from Usage: Show target class name in the text of "Create member" quick fix
(cherry picked from commit a51d3fc)
2016-07-20 15:39:19 +03:00
Alexey Sedunov 1a13c21377 Create from Usage: Show receiver type in the text of "Create extension" quick fix
(cherry picked from commit c0d5df1)
2016-07-20 15:39:13 +03:00
Alexey Sedunov 2abcd17713 Create from Usage: Support "Create member/extension" corresponding to the extension receiver of enclosing function
#KT-10668 Fixed
(cherry picked from commit bc4c013)
2016-07-20 15:39:09 +03:00
Alexey Sedunov 49b6811b44 Create from Usage: Support "Create abstract function/property" inside an abstract class
#KT-7492 Fixed
(cherry picked from commit 75f6b7f)
2016-07-20 15:39:07 +03:00
Alexey Sedunov 3ba776fffa Code Insight: Format generated declarations
#KT-11176 Fixed
(cherry picked from commit 3641ad6)
2016-07-20 15:39:05 +03:00
Dmitry Jemerov 079d857aa2 update testdata for https://github.com/JetBrains/kotlin/pull/896/ 2016-07-19 17:58:09 +02:00
Alexey Sedunov 69704c017f Create from Usage: Suggest "Create function/secondary constructor" quick fix on argument type mismatch
#KT-11864 Fixed
(cherry picked from commit 1912783)
2016-06-28 15:07:12 +03:00
Pavel V. Talanov a4c005fefd Update existing test data depending on diagnostic parameter rendering 2016-02-26 14:45:11 +03:00
Mikhail Glukhikh eed4aa71db No assertion error in getContainingPseudocode #KT-10983 Fixed
Also #EA-72954 Fixed
2016-02-16 18:50:20 +03:00
Pavel V. Talanov a667aa2f71 Tests: add runtime (and runtime sources) to some tests that rely on being able to resolve references to built ins 2015-12-15 20:22:09 +03:00
Alexey Sedunov 44743aade5 Create from Usage: Allow type parameters in the receiver position
#KT-7497 Fixed
2015-12-10 20:06:26 +03:00
Alexey Sedunov e517cbcf78 Quick Fixes: Implement "Rename unresolved reference" fix
#KT-8795 Fixed
2015-12-08 16:20:56 +03:00
Yan Zhulanow a3ff3ffc45 Fix tests: "Placing function type parameters after the function name" error 2015-11-27 15:51:11 +03:00
Mikhail Glukhikh 4e44466cf9 Exposed visibility deprecation warnings made errors + relevant test fixes 2015-11-20 15:21:01 +03:00
Alexey Sedunov aeee8bafe6 Name Suggester: Suggest parameter name for the corresponding argument expression
#KT-8111 Fixed
2015-11-16 11:29:59 +03:00
Nikolay Krasko 911432c99c Use default render to check are all errors mentioned in tests. It's far more easier to read. 2015-10-28 13:39:46 +03:00