Commit Graph

1031 Commits

Author SHA1 Message Date
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
Alexander Udalov b208995d73 Render different class kinds differently in bytecode listing test 2016-05-20 00:36:56 +03:00
Stanislav Erokhin f376c418dc Fix SOE related exact annotation and completion 2016-05-16 18:32:16 +03:00
Denis Zharkov e90c92f8d3 Separate additional built-in members from JDK into three groups
- White list: can be used as common built-in declaration
- Black list: can be used only for overrides and super-calls-
- Not considered members: ones that is not in black or white list.
Such members can be used in any context, but they usages marked as deprecated

Third kind is needed to make possible use declarations added in future JDK versions.
Deprecation is necessary because they may get into black list in next Kotlin compiler version
2016-05-16 15:38:13 +03:00
Alexey Tsvetkov 10b9be9f51 Fix collecting source retention annotations
#KT-12187 fixed
2016-05-11 20:41:48 +03:00
Mikhael Bogdanov ed60cf8c55 Added support for reflection tests on android 2016-05-11 18:07:26 +03:00
Dmitry Jemerov d7b1526cd5 preserve leading indentation in KDoc code blocks
#KT-9933 Fixed
2016-05-06 22:11:38 +02:00
Michael Bogdanov e2ae2f313c Support test with self imports, kotlin multifile tests 2016-04-29 16:33:04 +03:00
Valentin Kipyatkov b551886889 Code cleanup: removed redundant semicolons 2016-04-29 11:26:25 +03:00
Denis Zharkov 5bc5722051 Load additional JDK functions into built-ins member scope
#KT-5990 Fixed
 #KT-7127 Fixed
 #KT-10370 Fixed
2016-04-25 17:41:08 +03:00
Denis Zharkov dbc8830acd Fix ResolveTest
Compare descriptors by their FQ-names instead of references
2016-04-25 17:41:08 +03:00
Denis Zharkov 5bf39689e9 Replace irrelevant usages of JvmBuiltIns.Instance with DefaultBuiltIns.Instance 2016-04-25 17:41:08 +03:00
Denis Zharkov c667f50741 Delete TargetPlatform.builtins
Replace it's usages with relevant singleton reference
2016-04-25 17:41:08 +03:00
Denis Zharkov ef18d64931 Parametrize module creation by platform with built-ins 2016-04-25 17:41:08 +03:00
Michael Bogdanov af68f3d019 Added additional strata for stacktraces 2016-04-20 17:07:12 +03:00
Michael Bogdanov 286da1fc5f Properly calculate maxUsedValue 2016-04-20 17:07:07 +03:00
Michael Bogdanov dfabad324b Additional checker for smap 2016-04-20 17:07:07 +03:00
Alexander Udalov 2ab68d53fa J2K KotlinJvmBinaryClass & AnnotationAndConstantLoader: convert 2016-04-14 21:08:36 +03:00
Nikolay Krasko 8ccb442009 Do not guard downloading artifacts for compiler tests with dependencies.properties 2016-04-08 17:40:38 +03:00
Nikolay Krasko 47c7181f2a Extract tests-common module without any actual tests
The main reasoning for the module is to avoid running any compiler tests while executing run configuration that searches tests across module dependencies.
2016-04-08 17:40:38 +03:00