private static object?ReadCore( Type returnType, JsonSerializerOptions options, ref Utf8JsonReader reader) { ReadStack state = default; state.InitializeRoot(returnType, options); ReadCore(options, ref reader, ref state); return(state.Current.ReturnValue); }
public override sealed T Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options) { // Bridge from resumable to value converters. if (options == null) { options = JsonSerializerOptions.s_defaultOptions; } ReadStack state = default; state.InitializeRoot(typeToConvert, options); TryRead(ref reader, typeToConvert, options, ref state, out T value); return(value); }