Dmitry Petrov
ef4c3bdae8
Don't expand types that don't contain type aliases or type parameters.
2016-06-08 15:55:52 +03:00
Dmitry Petrov
cf8cbad11c
Refactor: extract TypeAliasExpander as a separate class.
2016-06-08 15:55:52 +03:00
Dmitry Petrov
cb08d976d3
Tests for importing type aliases
2016-06-08 15:55:52 +03:00
Mikhail Glukhikh
4b6b35dadf
Type parameter is considered capable of taking any value for the purpose of cast possibility check #KT-6611 Fixed
2016-06-08 15:25:34 +03:00
Mikhail Glukhikh
99acbf16b2
CastDiagnosticsUtil.kt: converted to Kotlin
2016-06-08 15:25:29 +03:00
Mikhail Glukhikh
f3f7bff376
CastDiagnosticsUtil.java --> CastDiagnosticsUtil.kt
2016-06-08 15:25:25 +03:00
Ilya Chernikov
7153ea61d8
Restore logic of StandardScriptDefinition handling, fixes codegen tests
2016-06-07 21:13:06 +02:00
Ilya Chernikov
e8c13882b4
Make script detection API generic, fix tests
2016-06-07 21:13:05 +02:00
Ilya Chernikov
3393d7b7d2
Optimize script definitions handling
...
Loading script configs only from project root dir
Optimize script definition retrieval in the KtScript
2016-06-07 21:13:04 +02:00
Ilya Chernikov
656fcc9775
Refactor and fixes after review
...
improving script constructor search algorithm - now default params should be supported
remove prefix Customized- from scripts ModuleInfo-related classes
refactoring ideaModuleInfos after review
refactoring ResolveSessionProvider construction for readability
refactoring KotlinScriptConfigurationManager after review
fixing KotlinScriptDefinitionProvider after review
2016-06-07 21:13:04 +02:00
Pavel V. Talanov
d5b486eb80
Refactor LazyClassDescriptor and minor changes
...
Minor: get script definition once
Refactor: get rid of 'LazyClassDescriptor#getInjectedSupertypes'
Minor: rename scope
2016-06-07 21:13:03 +02:00
Ilya Chernikov
4d95e873a9
Add a guard for empty dependencies list, fixes EA-82348
2016-06-07 21:13:02 +02:00
Pavel V. Talanov
8e700cdb10
Do not limit scope when searching in index by default
2016-06-07 21:13:01 +02:00
Ilya Chernikov
478ae96e50
Implement a compiler config key to add preconfigured extra imports for scripts
2016-06-07 21:13:01 +02:00
Ilya Chernikov
956bcf6d7a
Fix permgen problems with script launching by avoiding reflection as much as possible
2016-06-07 21:13:00 +02:00
Ilya Chernikov
b9ea9513b1
Rewrite handing and caching of script configurations
...
The refactoring could enable lazy update of the index on script loading, but seems that makeRootsChange
call doesn't work as expected, therefore initial project scan is performed in the KotlinScriptConfigurationManager
anyway
2016-06-07 21:12:59 +02:00
Ilya Chernikov
3e6616de42
Read script config if appropriate flag is specified, fix classpath handling
2016-06-07 21:12:58 +02:00
Ilya Chernikov
abfda50077
Workaround URISyntaxException in tests on windows + JDK 6
2016-06-07 21:12:58 +02:00
Ilya Chernikov
0d7ecee6ee
Update index on definition/import files changes
2016-06-07 21:12:57 +02:00
Ilya Chernikov
1a98c5eb0e
Allow script dependnencies to be found as a candidates for decompilation
2016-06-07 21:12:56 +02:00
Ilya Chernikov
9ed8dec9fb
Make a marker interface to allow ScriptDependenciesClassFilter to be used in the resolving
2016-06-07 21:12:55 +02:00
Ilya Chernikov
5c37017484
Prepare infrastruct for fixing customized script resolving
...
Move ConfigManager and ClassFinder to the idea-analysis
Add (back) IndexableSetContributor
Add a method in ConfigManager to generate all dependencies scope
Add and use delegating scope with possibility to get base scope from it (used in the class finder)
2016-06-07 21:12:54 +02:00
Ilya Chernikov
3e17724e58
Implement class finder for customized scripts resolving - not yet completely functional
2016-06-07 21:12:54 +02:00
Ilya Chernikov
b63ed0f4aa
Make script launcher aware of custom scripts, minor correction is core env
2016-06-07 21:12:53 +02:00
Ilya Chernikov
8ba9d2b75c
minor: Fix daemon client diagnostic
2016-06-07 21:12:52 +02:00
Ilya Chernikov
06a586bb82
Add reading script configuration files on compilation
2016-06-07 21:12:51 +02:00
Ilya Chernikov
14ae795aaa
Support extra imports configuration for scripts (only classpath so far)
2016-06-07 21:12:51 +02:00
Ilya Chernikov
57f03332c2
Add module dependencies to script module info
2016-06-07 21:12:50 +02:00
Ilya Chernikov
dfc96d216b
Refactor configs loading, Add config script definitions reloading on config files changes
2016-06-07 21:12:49 +02:00
Ilya Chernikov
310e8014a8
Refactor KotlinScriptDefinitionProvider access to scriptDefinitions
2016-06-07 21:12:48 +02:00
Ilya Chernikov
f185d3639d
Move KotlinScriptConfigurationManager to idea module
2016-06-07 21:12:48 +02:00
Ilya Chernikov
95703786ee
Change error reporting for unresolved script definition types
2016-06-07 21:12:47 +02:00
Ilya Chernikov
3c18f98d3d
Make variables replacements in classpath be able to work with lists
2016-06-07 21:12:46 +02:00
Ilya Chernikov
0921258e5d
Add environment vars dictionary for classpath customization in script configs
2016-06-07 21:12:45 +02:00
Ilya Chernikov
339f945ce0
Implement searching for config files in th whole project directory tree
2016-06-07 21:12:45 +02:00
Ilya Chernikov
9273b0cd8d
Add config loader from stream
2016-06-07 21:12:44 +02:00
Pavel V. Talanov
24b4afb3b8
Enable full highlighting in script files everywhere (was inside source roots only)
...
Extract KotlinHighlightingUtil to hold this logic
2016-06-07 21:12:43 +02:00
Pavel V. Talanov
34f8e9303f
scopeUtils: support CustomizedScriptModuleInfo info in completion
2016-06-07 21:12:42 +02:00
Ilya Chernikov
834bb51643
Add tests with partial classpath for script compilation
2016-06-07 21:12:39 +02:00
Ilya Chernikov
9d9fe97a8e
Refactor script configuration for better functionality separation
2016-06-07 21:11:30 +02:00
Ilya Chernikov
5590bcf024
Add initial prototype of custom script support in IDE
2016-06-07 21:11:29 +02:00
Ilya Chernikov
770ef16ef7
Replace script recognition from by PsiFile to by virtual file, fix custom script name generation
2016-06-07 21:11:28 +02:00
Ilya Chernikov
ad7fcc92d2
Add configurable script definition and appropriate manager component
...
The component is intended for configuring script types defined in some specific xml files and add appropriate script definitions to the provider
2016-06-07 21:11:27 +02:00
Ilya Chernikov
d225385d19
Add name and classpath to KotlinScriptDefinition
2016-06-07 21:11:26 +02:00
Ilya Chernikov
d63b53886c
Convert KotlinScriptDefinitionProvider to kotlin - phase 2 - convert; related fixes and refactorings
2016-06-07 21:11:26 +02:00
Ilya Chernikov
b9836d8c87
Convert KotlinScriptDefinitionProvider to kotlin - phase 1 - rename
2016-06-07 21:11:25 +02:00
Ilya Chernikov
e1ca45f360
Add support for script base class with parameters
...
including possibility to describe which script params to pass to superclass
2016-06-07 21:11:24 +02:00
Ilya Chernikov
3c1503564e
Add possibility to specify supertypes for script, with tests
2016-06-07 21:11:23 +02:00
Ilya Chernikov
670627ac4e
Add helpers, compilation function and tests for passing classes as a parameters to a script
2016-06-07 21:11:23 +02:00
Ilya Chernikov
bd70481bea
Convert ScriptTest to Kotlin - phase 2 - convert
2016-06-07 21:11:16 +02:00