DescriptorFinder now can find class names in a package

This helps to get rid of "repeated class_name" field in Package protobuf
message. DescriptorFinder in resolve.java uses PSI to find all classes in a
package, and the finder for built-ins just reads .kotlin_class_names file
This commit is contained in:
Alexander Udalov
2013-07-15 22:54:55 +04:00
parent 047ed18901
commit b602db03f2
12 changed files with 114 additions and 191 deletions
@@ -32,8 +32,10 @@ import org.jetbrains.jet.lang.descriptors.impl.NamespaceDescriptorImpl;
import org.jetbrains.jet.lang.resolve.lazy.storage.LockBasedStorageManager;
import org.jetbrains.jet.lang.resolve.name.FqName;
import org.jetbrains.jet.lang.resolve.name.FqNameUnsafe;
import org.jetbrains.jet.lang.resolve.name.Name;
import java.io.IOException;
import java.util.Collection;
public class KotlinClassAnnotationTest extends CodegenTestCase {
public static final FqName NAMESPACE_NAME = new FqName("test");
@@ -90,6 +92,12 @@ public class KotlinClassAnnotationTest extends CodegenTestCase {
return namespace;
}
@NotNull
@Override
public Collection<Name> getClassNames(@NotNull FqName packageName) {
throw new UnsupportedOperationException();
}
@Override
protected void classDescriptorCreated(@NotNull ClassDescriptor classDescriptor) {
}