Fix compile issues found during release.
This commit is contained in:
parent
2c19c43905
commit
a92cf394e8
@ -683,7 +683,7 @@ public final class Gson {
|
||||
*/
|
||||
public <T> T fromJson(Reader json, Type typeOfT) throws JsonIOException, JsonSyntaxException {
|
||||
JsonReader jsonReader = new JsonReader(json);
|
||||
T object = fromJson(jsonReader, typeOfT);
|
||||
T object = (T) fromJson(jsonReader, typeOfT);
|
||||
assertFullConsumption(object, jsonReader);
|
||||
return object;
|
||||
}
|
||||
@ -780,7 +780,7 @@ public final class Gson {
|
||||
if (json == null) {
|
||||
return null;
|
||||
}
|
||||
return fromJson(new JsonElementReader(json), typeOfT);
|
||||
return (T) fromJson(new JsonElementReader(json), typeOfT);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -39,7 +39,7 @@ final class GsonToMiniGsonTypeAdapterFactory implements TypeAdapter.Factory {
|
||||
|
||||
this.deserializationContext = new JsonDeserializationContext() {
|
||||
public <T> T deserialize(JsonElement json, Type typeOfT) throws JsonParseException {
|
||||
return gson.fromJson(json, typeOfT);
|
||||
return (T) gson.fromJson(json, typeOfT);
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user