Yan Zhulanow
471ddc5a93
Kapt: Write annotations with the "SOURCE" retention if kapt2 is enabled
...
(cherry picked from commit 6177b2b)
2016-09-10 17:36:15 +03:00
Michael Bogdanov
a12d7b6019
Check lambda inlining in package part files in test framework
2016-09-07 12:01:47 +03:00
Yan Zhulanow
9960e7f7cd
Kapt: Get rid of the 'compiler-tests' dependency in 'plugins-tests'
...
(cherry picked from commit bb370f1)
2016-08-29 16:31:16 +03:00
Ilya Gorbunov
403e2ab4ea
Redefine configuration kinds, so that the most of test dependent on JDK_ONLY now use mock kotlin runtime:
...
MOCK_RUNTIME -> JDK_ONLY
JDK_ONLY -> JDK_NO_RUNTIME
2016-08-17 12:40:50 +03:00
Pavel V. Talanov
cdbd7fbab0
Refactor: split classes in 'asJava' package into several subpackages to reflect their structure
2016-07-28 18:00:47 +03:00
Dmitry Jemerov
82babaff7e
to reduce VM contention between JVM with tests and JVM with Ant, run Ant with -Xmx128m
2016-07-18 16:56:46 +02:00
Michael Bogdanov
93f6761671
Print bytecode on linenumber test fail
2016-07-09 07:45:57 +03:00
Alexander Udalov
a533f8597d
Fix debug names for some slices
...
Also move RUNTIME_ASSERTION_INFO and LOAD_FROM_JAVA_SIGNATURE_ERRORS to a
single class for simplicity
2016-07-05 18:18:26 +03:00
Ilya Chernikov
55e084db8e
Refactor script resolving interface again
...
- remove Future from resovler since the idea need additional considerations
- simplify script contents interface
-extend script dependencies with additional javaHome property
2016-06-30 21:32:40 +02:00
Ilya Chernikov
dfec16d8e0
Refactor script resolving interface
...
- return Future from resovler
- pack script contents data to a separate interface
-extend script dependencies with additional scripts property
- minor renames and moves
2016-06-30 21:32:39 +02:00
Alexander Udalov
1690dcd8df
Refactor FakeCallResolver and usages
...
Remove useless overload, inline another to the single usage in tests, make some
parameters non-null
2016-06-30 21:29:23 +03:00
Ilya Chernikov
4f05f839a3
Add previous imports to resolving interfaces to enable effective caching implementations
2016-06-25 22:24:45 +03:00
Ilya Chernikov
64bb47ed37
Switch to File instead of String for classpaths in script dependencies
2016-06-25 22:24:30 +03:00
Ilya Chernikov
082290f8e3
Refactor script dependencies management
2016-06-25 22:24:23 +03:00
Ilya Chernikov
402e8c1e3e
Add dependency from annotation extraction mechanisms to the prototype, with tests
2016-06-25 22:24:14 +03:00
Alexander Udalov
b4f81d4bb5
Use 'JVM_TARGET: 1.8' directive in codegen tests on 1.8 target
2016-06-16 16:51:18 +03:00
Mikhael Bogdanov
fc8058848f
Added classVersion to KotlinJvmBinaryClass
2016-06-15 13:43:26 +03:00
Mikhael Bogdanov
0169f10bf3
Support directives in write flag tests
2016-06-15 13:43:23 +03:00
Mikhael Bogdanov
5d5734841b
Compile logic moved from AbstractBlackBoxCodegenTest to CodegenTestCase
2016-06-15 13:43:23 +03:00
Mikhael Bogdanov
dce260563c
Support directives in CompileKotlinAgainstKotlinTest
2016-06-15 13:43:22 +03:00
Stanislav Erokhin
1d9ca06b96
Remake KotlinTypes.
2016-06-09 12:57:59 +03:00
Stanislav Erokhin
3a451744c5
Introduce KotlinTypeFactory
2016-06-09 12:57:43 +03:00
Ilya Chernikov
e8c13882b4
Make script detection API generic, fix tests
2016-06-07 21:13:05 +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
abfda50077
Workaround URISyntaxException in tests on windows + JDK 6
2016-06-07 21:12:58 +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
834bb51643
Add tests with partial classpath for script compilation
2016-06-07 21:12:39 +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
d225385d19
Add name and classpath to KotlinScriptDefinition
2016-06-07 21:11:26 +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
Pavel V. Talanov
76971eca70
Refactor LanguageFeatureSettings: Add LanguageVersion and LanguageFeature entities
2016-05-26 22:16:47 +03:00
Alexander Udalov
e1ba4480d7
Support "-language-version" CLI option for compatibility with older releases
...
Introduce LanguageFeatureSettings, instance of which should be injected by the
container and be accessible everywhere during the compilation (front-end and
back-end).
Parameters of LanguageFeatureSettings are unused in this commit, will be used
later
2016-05-26 22:15:39 +03:00
Alexander Udalov
05f8836f46
Move some configuration keys to JVM or to CommonConfigurationKeys
...
Move CONTENT_ROOTS and SCRIPT_DEFINITIONS_KEY to JVMConfigurationKeys because
they are only used on JVM, rename the latter to SCRIPT_DEFINITIONS.
Move MODULE_NAME to CommonConfigurationKeys to be combined with MODULE_ID in
JSConfigurationKeys in the future
2016-05-26 11:47:30 +03:00
Alexander Udalov
6674412079
Rename compilerConfigurationForTests -> newConfiguration
2016-05-26 11:47:30 +03:00
Alexander Udalov
c5e2f55ea7
Get rid of getModuleName(), pass configuration to createContextWithSealedModule
...
Add KotlinTestUtils.newConfiguration() which creates a configuration and sets
the module name to the default test one ("test-module")
2016-05-26 11:47:30 +03:00
Alexander Udalov
69343549b7
Move TEST_MODULE_NAME to KotlinTestUtils and change value to "test-module"
...
This name is more generic and thus can be used everywhere, not only in Java
integration tests
2016-05-26 11:47:30 +03:00
Alexander Udalov
b9fb6c0d84
Remove dangerous readKotlinHeader() in inlineUtil.kt
...
It was creating a phantom FileBasedKotlinClass which was not based on any file
2016-05-23 20:00:50 +03:00
Alexander Udalov
29c5e655ab
Drop several more parameters of GenerationState's constructor
...
INCREMENTAL_COMPILATION_COMPONENTS and DECLARATIONS_JSON_PATH are already in
the configuration, and Progress was unused
2016-05-23 14:50:06 +03:00
Alexander Udalov
f8816b5d67
Pass CompilerConfiguration to GenerationState instead of ton of parameters
2016-05-23 14:49:26 +03:00
Alexander Udalov
1492c71e88
Refactor old test utility in LoadDescriptorUtil
...
Also make USE_TYPE_TABLE a flag in CompilerConfiguration instead of an extra
boolean parameter in numerous methods
2016-05-23 14:47:00 +03:00
Alexander Udalov
76d78ba666
Remove LazyResolveTestUtil, refactor usages to use JvmResolveUtil
...
LazyResolveTestUtil.resolve by now had almost exactly the same code as
JvmResolveUtil.analyze.
LazyResolveTestUtil.resolveLazily with 3 parameters was only used in
LoadBuiltinsTest, inline it there.
Move LazyResolveTestUtil.getTopLevelPackagesFromFileList to
AbstractDiagnosticsTest, the only place where it was used
2016-05-23 14:47:00 +03:00
Alexander Udalov
a85e98a078
Minor, inline unnecessary method of TopDownAnalyzerFacadeForJVM
...
The TopDownAnalysisMode parameter was TopLevelDeclarations everywhere
2016-05-23 14:47:00 +03:00
Alexander Udalov
0124cb64f0
Cleanup test utilities in JvmResolveUtil and GenerationUtils
...
Simplify usages and fix some warnings along the way.
Rename:
- analyzeFilesWithJavaIntegration, analyzeOneFileWithJavaIntegration -> analyze
- analyzeFilesWithJavaIntegrationAndCheckForErrors,
analyzeOneFileWithJavaIntegrationAndCheckForErrors -> analyzeAndCheckForErrors
- compileFilesGetGenerationState, compileManyFilesGetGenerationStateForTest ->
compileFiles
- compileFileGetGenerationStateForTest -> compileFile
- compileFileGetClassFileFactoryForTest -> compileFileTo
2016-05-23 14:47:00 +03:00
Alexander Udalov
6d6488e795
Pass CompilerConfiguration to TopDownAnalyzerFacadeForJVM
...
In most cases, the configuration can be loaded from KotlinCoreEnvironment. In
other cases, such as IDE tests, there's no environment, so we pass EMPTY. Since
currently the configuration is only used to load incremental compilation
components and module information, it's fine to pass EMPTY
2016-05-23 14:47:00 +03:00
Alexander Udalov
6c0ff40197
Move JVMConfigurationKeys to frontend.java
...
Similarly to K2JVMCompilerArguments, they will soon be needed in the IDE code.
Move COMPILER_JAR_LOCATOR to CLIConfigurationKeys because it's used both in JVM
and JS, and only in CLI. Other keys, non-relevant in the IDE, may be moved out
soon as well, such as incremental compilation components
2016-05-23 14:47:00 +03:00
Dmitry Petrov
a2ec580119
KT-11588 Type aliases
...
Type alias stubs indexing (required for index-based declaration providers)
2016-05-20 14:17:26 +03:00
Dmitry Petrov
a4406687f1
KT-11588 Type aliases
...
Resolution & expansion for type aliases.
NB: Nested type aliases capturing type parameters of outer classes are not supported yet.
2016-05-20 14:17:24 +03:00
Stanislav Erokhin
74bddcfb70
Refactoring. Convert Annotated to kotlin.
2016-05-20 09:32:55 +03:00