예제 #1
0
 {
   primitiveTypes = new HashSet<FqNameUnsafe>(0);
   primitiveArrays = new HashSet<FqNameUnsafe>(0);
   for (PrimitiveType primitiveType : PrimitiveType.values()) {
     primitiveTypes.add(fqNameUnsafe(primitiveType.getTypeName().asString()));
     primitiveArrays.add(fqNameUnsafe(primitiveType.getArrayTypeName().asString()));
   }
 }
예제 #2
0
  private void makePrimitive(@NotNull PrimitiveType primitiveType) {
    KotlinType type = getBuiltInTypeByClassName(primitiveType.getTypeName().asString());
    KotlinType arrayType = getBuiltInTypeByClassName(primitiveType.getArrayTypeName().asString());

    primitiveTypeToArrayKotlinType.put(primitiveType, arrayType);
    primitiveKotlinTypeToKotlinArrayType.put(type, arrayType);
    kotlinArrayTypeToPrimitiveKotlinType.put(arrayType, type);
  }
예제 #3
0
  private void makePrimitive(@NotNull PrimitiveType primitiveType) {
    JetType type = getBuiltInTypeByClassName(primitiveType.getTypeName().asString());
    JetType arrayType = getBuiltInTypeByClassName(primitiveType.getArrayTypeName().asString());

    primitiveTypeToNullableJetType.put(primitiveType, TypeUtils.makeNullable(type));
    primitiveTypeToArrayJetType.put(primitiveType, arrayType);
    primitiveJetTypeToJetArrayType.put(type, arrayType);
    jetArrayTypeToPrimitiveJetType.put(arrayType, type);
  }
예제 #4
0
 {
   fqNameToPrimitiveType = new HashMap<FqNameUnsafe, PrimitiveType>(0);
   arrayClassFqNameToPrimitiveType = new HashMap<FqNameUnsafe, PrimitiveType>(0);
   for (PrimitiveType primitiveType : PrimitiveType.values()) {
     fqNameToPrimitiveType.put(
         fqNameUnsafe(primitiveType.getTypeName().asString()), primitiveType);
     arrayClassFqNameToPrimitiveType.put(
         fqNameUnsafe(primitiveType.getArrayTypeName().asString()), primitiveType);
   }
 }
예제 #5
0
 @NotNull
 public ClassDescriptor getPrimitiveClassDescriptor(@NotNull PrimitiveType type) {
   return getBuiltInClassByName(type.getTypeName().asString());
 }