FqNameUnsafe
This commit is contained in:
@@ -40,7 +40,7 @@ public class JetPluginUtil {
|
||||
@NotNull
|
||||
public static FqName computeTypeFullName(@NotNull JetType type) {
|
||||
ClassDescriptor clazz = (ClassDescriptor) type.getConstructor().getDeclarationDescriptor();
|
||||
return DescriptorUtils.getFQName(clazz);
|
||||
return DescriptorUtils.getFQName(clazz).toSafe();
|
||||
}
|
||||
|
||||
@NotNull
|
||||
|
||||
@@ -134,7 +134,7 @@ public class JetFunctionInsertHandler implements InsertHandler<LookupElement> {
|
||||
ApplicationManager.getApplication().runWriteAction(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
final FqName fqn = DescriptorUtils.getFQName(functionDescriptor);
|
||||
final FqName fqn = DescriptorUtils.getFQName(functionDescriptor).toSafe();
|
||||
ImportClassHelper.addImportDirective(fqn.getFqName(), file);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -101,7 +101,7 @@ public class ImportClassAndFunFix extends JetHintAction<JetSimpleNameExpression>
|
||||
@Override
|
||||
public FqName apply(@Nullable DeclarationDescriptor declarationDescriptor) {
|
||||
assert declarationDescriptor != null;
|
||||
return DescriptorUtils.getFQName(declarationDescriptor);
|
||||
return DescriptorUtils.getFQName(declarationDescriptor).toSafe();
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -126,7 +126,7 @@ public class ImportClassAndFunFix extends JetHintAction<JetSimpleNameExpression>
|
||||
@Override
|
||||
public FqName apply(@Nullable DeclarationDescriptor declarationDescriptor) {
|
||||
assert declarationDescriptor != null;
|
||||
return DescriptorUtils.getFQName(declarationDescriptor);
|
||||
return DescriptorUtils.getFQName(declarationDescriptor).toSafe();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user