Migration to expect/actual: change some comments in compiler
This commit is contained in:
@@ -167,7 +167,7 @@ public class BodyResolver {
|
|||||||
@NotNull ClassConstructorDescriptor descriptor
|
@NotNull ClassConstructorDescriptor descriptor
|
||||||
) {
|
) {
|
||||||
if (descriptor.isExpect() || isEffectivelyExternal(descriptor)) {
|
if (descriptor.isExpect() || isEffectivelyExternal(descriptor)) {
|
||||||
// For header and external classes, we do not resolve constructor delegation calls because they are prohibited
|
// For expected and external classes, we do not resolve constructor delegation calls because they are prohibited
|
||||||
return DataFlowInfo.Companion.getEMPTY();
|
return DataFlowInfo.Companion.getEMPTY();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -185,8 +185,8 @@ public class ValueArgumentsToParametersMapper {
|
|||||||
if (nameReference != null) {
|
if (nameReference != null) {
|
||||||
if (candidate instanceof MemberDescriptor && ((MemberDescriptor) candidate).isExpect() &&
|
if (candidate instanceof MemberDescriptor && ((MemberDescriptor) candidate).isExpect() &&
|
||||||
candidate.getContainingDeclaration() instanceof ClassDescriptor) {
|
candidate.getContainingDeclaration() instanceof ClassDescriptor) {
|
||||||
// We do not allow named arguments for members of header classes until we're able to use both
|
// We do not allow named arguments for members of expected classes until we're able to use both
|
||||||
// headers and platform definitions when compiling platform code
|
// expected and actual definitions when compiling platform code
|
||||||
report(NAMED_ARGUMENTS_NOT_ALLOWED.on(nameReference, EXPECTED_CLASS_MEMBER));
|
report(NAMED_ARGUMENTS_NOT_ALLOWED.on(nameReference, EXPECTED_CLASS_MEMBER));
|
||||||
}
|
}
|
||||||
else if (!candidate.hasStableParameterNames()) {
|
else if (!candidate.hasStableParameterNames()) {
|
||||||
|
|||||||
+1
-1
@@ -194,7 +194,7 @@ public class RecursiveDescriptorComparator {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 'header' declarations do not belong to the platform-specific module, even though they participate in the analysis
|
// 'expected' declarations do not belong to the platform-specific module, even though they participate in the analysis
|
||||||
if (descriptor instanceof MemberDescriptor && ((MemberDescriptor) descriptor).isExpect() &&
|
if (descriptor instanceof MemberDescriptor && ((MemberDescriptor) descriptor).isExpect() &&
|
||||||
module.getCapability(MultiTargetPlatform.CAPABILITY) != MultiTargetPlatform.Common.INSTANCE) return false;
|
module.getCapability(MultiTargetPlatform.CAPABILITY) != MultiTargetPlatform.Common.INSTANCE) return false;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user