Fix DataFlowValue creation for Transient/Script receivers
This commit is contained in:
+1
-2
@@ -118,8 +118,7 @@ public class DataFlowValueFactory {
|
|||||||
if (receiverValue instanceof TransientReceiver || receiverValue instanceof ScriptReceiver) {
|
if (receiverValue instanceof TransientReceiver || receiverValue instanceof ScriptReceiver) {
|
||||||
// SCRIPT: smartcasts data flow
|
// SCRIPT: smartcasts data flow
|
||||||
JetType type = receiverValue.getType();
|
JetType type = receiverValue.getType();
|
||||||
boolean nullable = type.isMarkedNullable() || TypeUtils.hasNullableSuperType(type);
|
return new DataFlowValue(receiverValue, type, true, false, getImmanentNullability(type));
|
||||||
return new DataFlowValue(receiverValue, type, nullable, false, Nullability.NOT_NULL);
|
|
||||||
}
|
}
|
||||||
else if (receiverValue instanceof ClassReceiver || receiverValue instanceof ExtensionReceiver) {
|
else if (receiverValue instanceof ClassReceiver || receiverValue instanceof ExtensionReceiver) {
|
||||||
return createDataFlowValue((ThisReceiver) receiverValue);
|
return createDataFlowValue((ThisReceiver) receiverValue);
|
||||||
|
|||||||
Reference in New Issue
Block a user