Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 621ed57

Browse files
authored
Correcting Mismatch between ref and src (dotnet#39741)
* minor formatting * ref changes
1 parent fcacfcd commit 621ed57

File tree

23 files changed

+106
-104
lines changed

23 files changed

+106
-104
lines changed

src/libraries/Microsoft.Extensions.Logging/ref/Microsoft.Extensions.Logging.cs

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,16 @@ public static partial class LoggingServiceCollectionExtensions
1414
}
1515
namespace Microsoft.Extensions.Logging
1616
{
17+
[System.FlagsAttribute]
18+
public enum ActivityTrackingOptions
19+
{
20+
None = 0,
21+
SpanId = 1,
22+
TraceId = 2,
23+
ParentId = 4,
24+
TraceState = 8,
25+
TraceFlags = 16,
26+
}
1727
public static partial class FilterLoggingBuilderExtensions
1828
{
1929
public static Microsoft.Extensions.Logging.ILoggingBuilder AddFilter(this Microsoft.Extensions.Logging.ILoggingBuilder builder, System.Func<Microsoft.Extensions.Logging.LogLevel, bool> levelFilter) { throw null; }
@@ -39,21 +49,6 @@ public partial interface ILoggingBuilder
3949
{
4050
Microsoft.Extensions.DependencyInjection.IServiceCollection Services { get; }
4151
}
42-
[System.Flags]
43-
public enum ActivityTrackingOptions
44-
{
45-
None = 0x0000,
46-
SpanId = 0x0001,
47-
TraceId = 0x0002,
48-
ParentId = 0x0004,
49-
TraceState = 0x0008,
50-
TraceFlags = 0x0010
51-
}
52-
public class LoggerFactoryOptions
53-
{
54-
public LoggerFactoryOptions() { }
55-
public ActivityTrackingOptions ActivityTrackingOptions { get {throw null; } set { throw null; } }
56-
}
5752
public partial class LoggerFactory : Microsoft.Extensions.Logging.ILoggerFactory, System.IDisposable
5853
{
5954
public LoggerFactory() { }
@@ -67,6 +62,11 @@ public void AddProvider(Microsoft.Extensions.Logging.ILoggerProvider provider) {
6762
public Microsoft.Extensions.Logging.ILogger CreateLogger(string categoryName) { throw null; }
6863
public void Dispose() { }
6964
}
65+
public partial class LoggerFactoryOptions
66+
{
67+
public LoggerFactoryOptions() { }
68+
public Microsoft.Extensions.Logging.ActivityTrackingOptions ActivityTrackingOptions { get { throw null; } set { } }
69+
}
7070
public partial class LoggerFilterOptions
7171
{
7272
public LoggerFilterOptions() { }
@@ -87,8 +87,8 @@ public static partial class LoggingBuilderExtensions
8787
{
8888
public static Microsoft.Extensions.Logging.ILoggingBuilder AddProvider(this Microsoft.Extensions.Logging.ILoggingBuilder builder, Microsoft.Extensions.Logging.ILoggerProvider provider) { throw null; }
8989
public static Microsoft.Extensions.Logging.ILoggingBuilder ClearProviders(this Microsoft.Extensions.Logging.ILoggingBuilder builder) { throw null; }
90-
public static Microsoft.Extensions.Logging.ILoggingBuilder SetMinimumLevel(this Microsoft.Extensions.Logging.ILoggingBuilder builder, Microsoft.Extensions.Logging.LogLevel level) { throw null; }
9190
public static Microsoft.Extensions.Logging.ILoggingBuilder Configure(this Microsoft.Extensions.Logging.ILoggingBuilder builder, System.Action<Microsoft.Extensions.Logging.LoggerFactoryOptions> action) { throw null; }
91+
public static Microsoft.Extensions.Logging.ILoggingBuilder SetMinimumLevel(this Microsoft.Extensions.Logging.ILoggingBuilder builder, Microsoft.Extensions.Logging.LogLevel level) { throw null; }
9292
}
9393
[System.AttributeUsageAttribute(System.AttributeTargets.Class, AllowMultiple=false, Inherited=false)]
9494
public partial class ProviderAliasAttribute : System.Attribute

src/libraries/Microsoft.Win32.Registry/ref/Microsoft.Win32.Registry.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,6 @@ namespace Microsoft.Win32.SafeHandles
115115
public sealed partial class SafeRegistryHandle : Microsoft.Win32.SafeHandles.SafeHandleZeroOrMinusOneIsInvalid
116116
{
117117
public SafeRegistryHandle(System.IntPtr preexistingHandle, bool ownsHandle) : base (default(bool)) { }
118-
public override bool IsInvalid { get { throw null; } }
119118
protected override bool ReleaseHandle() { throw null; }
120119
}
121120
}

src/libraries/System.CodeDom/ref/System.CodeDom.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -993,7 +993,7 @@ protected virtual void GenerateSnippetCompileUnit(System.CodeDom.CodeSnippetComp
993993
protected abstract void GenerateSnippetMember(System.CodeDom.CodeSnippetTypeMember e);
994994
protected virtual void GenerateSnippetStatement(System.CodeDom.CodeSnippetStatement e) { }
995995
protected void GenerateStatement(System.CodeDom.CodeStatement e) { }
996-
protected void GenerateStatements(System.CodeDom.CodeStatementCollection stms) { }
996+
protected void GenerateStatements(System.CodeDom.CodeStatementCollection stmts) { }
997997
protected abstract void GenerateThisReferenceExpression(System.CodeDom.CodeThisReferenceExpression e);
998998
protected abstract void GenerateThrowExceptionStatement(System.CodeDom.CodeThrowExceptionStatement e);
999999
protected abstract void GenerateTryCatchFinallyStatement(System.CodeDom.CodeTryCatchFinallyStatement e);

src/libraries/System.ComponentModel.Primitives/ref/System.ComponentModel.Primitives.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ public sealed partial class ParenthesizePropertyNameAttribute : System.Attribute
261261
public ParenthesizePropertyNameAttribute() { }
262262
public ParenthesizePropertyNameAttribute(bool needParenthesis) { }
263263
public bool NeedParenthesis { get { throw null; } }
264-
public override bool Equals(object? o) { throw null; }
264+
public override bool Equals(object? obj) { throw null; }
265265
public override int GetHashCode() { throw null; }
266266
public override bool IsDefaultAttribute() { throw null; }
267267
}
@@ -291,7 +291,7 @@ public sealed partial class RefreshPropertiesAttribute : System.Attribute
291291
public static readonly System.ComponentModel.RefreshPropertiesAttribute Repaint;
292292
public RefreshPropertiesAttribute(System.ComponentModel.RefreshProperties refresh) { }
293293
public System.ComponentModel.RefreshProperties RefreshProperties { get { throw null; } }
294-
public override bool Equals(object? value) { throw null; }
294+
public override bool Equals(object? obj) { throw null; }
295295
public override int GetHashCode() { throw null; }
296296
public override bool IsDefaultAttribute() { throw null; }
297297
}

src/libraries/System.Diagnostics.StackTrace/ref/System.Diagnostics.StackTrace.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ public partial class StackFrame
1010
{
1111
public const int OFFSET_UNKNOWN = -1;
1212
public StackFrame() { }
13-
public StackFrame(bool fNeedFileInfo) { }
13+
public StackFrame(bool needFileInfo) { }
1414
public StackFrame(int skipFrames) { }
15-
public StackFrame(int skipFrames, bool fNeedFileInfo) { }
15+
public StackFrame(int skipFrames, bool needFileInfo) { }
1616
public StackFrame(string? fileName, int lineNumber) { }
1717
public StackFrame(string? fileName, int lineNumber, int colNumber) { }
1818
public virtual int GetFileColumnNumber() { throw null; }

src/libraries/System.Drawing.Common/ref/System.Drawing.Common.cs

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,6 @@ public sealed partial class BufferedGraphics : System.IDisposable
207207
internal BufferedGraphics() { }
208208
public System.Drawing.Graphics Graphics { get { throw null; } }
209209
public void Dispose() { }
210-
~BufferedGraphics() { }
211210
public void Render() { }
212211
public void Render(System.Drawing.Graphics? target) { }
213212
public void Render(System.IntPtr targetDC) { }
@@ -657,7 +656,7 @@ public void Dispose() { }
657656
~Icon() { }
658657
public static System.Drawing.Icon FromHandle(System.IntPtr handle) { throw null; }
659658
public void Save(System.IO.Stream outputStream) { }
660-
void System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }
659+
void System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo si, System.Runtime.Serialization.StreamingContext context) { }
661660
public System.Drawing.Bitmap ToBitmap() { throw null; }
662661
public override string ToString() { throw null; }
663662
}
@@ -731,7 +730,7 @@ public void SaveAdd(System.Drawing.Image image, System.Drawing.Imaging.EncoderPa
731730
public void SaveAdd(System.Drawing.Imaging.EncoderParameters? encoderParams) { }
732731
public int SelectActiveFrame(System.Drawing.Imaging.FrameDimension dimension, int frameIndex) { throw null; }
733732
public void SetPropertyItem(System.Drawing.Imaging.PropertyItem propitem) { }
734-
void System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }
733+
void System.Runtime.Serialization.ISerializable.GetObjectData(System.Runtime.Serialization.SerializationInfo si, System.Runtime.Serialization.StreamingContext context) { }
735734
public delegate bool GetThumbnailImageAbort();
736735
}
737736
public sealed partial class ImageAnimator
@@ -2096,17 +2095,17 @@ public sealed partial class Encoder
20962095
{
20972096
public static readonly System.Drawing.Imaging.Encoder ChrominanceTable;
20982097
public static readonly System.Drawing.Imaging.Encoder ColorDepth;
2098+
public static readonly System.Drawing.Imaging.Encoder ColorSpace;
20992099
public static readonly System.Drawing.Imaging.Encoder Compression;
2100+
public static readonly System.Drawing.Imaging.Encoder ImageItems;
21002101
public static readonly System.Drawing.Imaging.Encoder LuminanceTable;
21012102
public static readonly System.Drawing.Imaging.Encoder Quality;
21022103
public static readonly System.Drawing.Imaging.Encoder RenderMethod;
2104+
public static readonly System.Drawing.Imaging.Encoder SaveAsCmyk;
21032105
public static readonly System.Drawing.Imaging.Encoder SaveFlag;
21042106
public static readonly System.Drawing.Imaging.Encoder ScanMethod;
21052107
public static readonly System.Drawing.Imaging.Encoder Transformation;
21062108
public static readonly System.Drawing.Imaging.Encoder Version;
2107-
public static readonly System.Drawing.Imaging.Encoder ColorSpace;
2108-
public static readonly System.Drawing.Imaging.Encoder ImageItems;
2109-
public static readonly System.Drawing.Imaging.Encoder SaveAsCmyk;
21102109
public Encoder(System.Guid guid) { }
21112110
public System.Guid Guid { get { throw null; } }
21122111
}
@@ -2718,8 +2717,8 @@ public virtual void OnEndPrint(System.Drawing.Printing.PrintDocument document, S
27182717
public virtual System.Drawing.Graphics? OnStartPage(System.Drawing.Printing.PrintDocument document, System.Drawing.Printing.PrintPageEventArgs e) { throw null; }
27192718
public virtual void OnStartPrint(System.Drawing.Printing.PrintDocument document, System.Drawing.Printing.PrintEventArgs e) { }
27202719
}
2721-
[System.ComponentModel.DefaultPropertyAttribute("DocumentName")]
27222720
[System.ComponentModel.DefaultEventAttribute("PrintPage")]
2721+
[System.ComponentModel.DefaultPropertyAttribute("DocumentName")]
27232722
public partial class PrintDocument : System.ComponentModel.Component
27242723
{
27252724
public PrintDocument() { }

src/libraries/System.IO.IsolatedStorage/ref/System.IO.IsolatedStorage.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ public void DeleteFile(string file) { }
6363
public bool DirectoryExists(string path) { throw null; }
6464
public void Dispose() { }
6565
public bool FileExists(string path) { throw null; }
66-
~IsolatedStorageFile() { }
6766
public System.DateTimeOffset GetCreationTime(string path) { throw null; }
6867
public string[] GetDirectoryNames() { throw null; }
6968
public string[] GetDirectoryNames(string searchPattern) { throw null; }
@@ -111,8 +110,8 @@ public partial class IsolatedStorageFileStream : System.IO.FileStream
111110
public override long Length { get { throw null; } }
112111
public override long Position { get { throw null; } set { } }
113112
public override Microsoft.Win32.SafeHandles.SafeFileHandle SafeFileHandle { get { throw null; } }
114-
public override System.IAsyncResult BeginRead(byte[] buffer, int offset, int numBytes, System.AsyncCallback? userCallback, object? stateObject) { throw null; }
115-
public override System.IAsyncResult BeginWrite(byte[] buffer, int offset, int numBytes, System.AsyncCallback? userCallback, object? stateObject) { throw null; }
113+
public override System.IAsyncResult BeginRead(byte[] array, int offset, int numBytes, System.AsyncCallback? userCallback, object? stateObject) { throw null; }
114+
public override System.IAsyncResult BeginWrite(byte[] array, int offset, int numBytes, System.AsyncCallback? userCallback, object? stateObject) { throw null; }
116115
protected override void Dispose(bool disposing) { }
117116
public override System.Threading.Tasks.ValueTask DisposeAsync() { throw null; }
118117
public override int EndRead(System.IAsyncResult asyncResult) { throw null; }

src/libraries/System.IO.MemoryMappedFiles/src/Microsoft/Win32/SafeMemoryMappedFileHandle.Windows.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,7 @@ protected override bool ReleaseHandle()
1414
{
1515
return Interop.Kernel32.CloseHandle(handle);
1616
}
17+
18+
public override bool IsInvalid => base.IsInvalid;
1719
}
1820
}

src/libraries/System.Net.Http.WinHttpHandler/ref/System.Net.Http.WinHttpHandler.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ public WinHttpHandler() { }
3030
public System.Net.CookieContainer? CookieContainer { get { throw null; } set { } }
3131
public System.Net.Http.CookieUsePolicy CookieUsePolicy { get { throw null; } set { } }
3232
public System.Net.ICredentials? DefaultProxyCredentials { get { throw null; } set { } }
33+
public bool EnableMultipleHttp2Connections { get { throw null; } set { } }
3334
public int MaxAutomaticRedirections { get { throw null; } set { } }
3435
public int MaxConnectionsPerServer { get { throw null; } set { } }
3536
public int MaxResponseDrainSize { get { throw null; } set { } }
3637
public int MaxResponseHeadersLength { get { throw null; } set { } }
37-
public bool EnableMultipleHttp2Connections { get { throw null; } set { } }
3838
public bool PreAuthenticate { get { throw null; } set { } }
3939
public System.Collections.Generic.IDictionary<string, object> Properties { get { throw null; } }
4040
public System.Net.IWebProxy? Proxy { get { throw null; } set { } }

src/libraries/System.Net.Primitives/ref/System.Net.Primitives.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -253,11 +253,11 @@ public IPAddress(System.ReadOnlySpan<byte> address, long scopeid) { }
253253
public static short NetworkToHostOrder(short network) { throw null; }
254254
public static int NetworkToHostOrder(int network) { throw null; }
255255
public static long NetworkToHostOrder(long network) { throw null; }
256-
public static System.Net.IPAddress Parse(System.ReadOnlySpan<char> ipString) { throw null; }
256+
public static System.Net.IPAddress Parse(System.ReadOnlySpan<char> ipSpan) { throw null; }
257257
public static System.Net.IPAddress Parse(string ipString) { throw null; }
258258
public override string ToString() { throw null; }
259259
public bool TryFormat(System.Span<char> destination, out int charsWritten) { throw null; }
260-
public static bool TryParse(System.ReadOnlySpan<char> ipString, [System.Diagnostics.CodeAnalysis.NotNullWhenAttribute(true)] out System.Net.IPAddress? address) { throw null; }
260+
public static bool TryParse(System.ReadOnlySpan<char> ipSpan, [System.Diagnostics.CodeAnalysis.NotNullWhenAttribute(true)] out System.Net.IPAddress? address) { throw null; }
261261
public static bool TryParse([System.Diagnostics.CodeAnalysis.NotNullWhenAttribute(true)] string? ipString, [System.Diagnostics.CodeAnalysis.NotNullWhenAttribute(true)] out System.Net.IPAddress? address) { throw null; }
262262
public bool TryWriteBytes(System.Span<byte> destination, out int bytesWritten) { throw null; }
263263
}
@@ -305,7 +305,7 @@ public NetworkCredential(string? userName, string? password, string? domain) { }
305305
[System.Diagnostics.CodeAnalysis.AllowNullAttribute]
306306
public string UserName { get { throw null; } set { } }
307307
public System.Net.NetworkCredential GetCredential(string? host, int port, string? authenticationType) { throw null; }
308-
public System.Net.NetworkCredential GetCredential(System.Uri? uri, string? authType) { throw null; }
308+
public System.Net.NetworkCredential GetCredential(System.Uri? uri, string? authenticationType) { throw null; }
309309
}
310310
public partial class SocketAddress
311311
{

src/libraries/System.Numerics.Vectors/ref/System.Numerics.Vectors.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,8 @@ public static partial class Vector
208208
public static System.Numerics.Vector<System.UInt64> AsVectorUInt64<T>(System.Numerics.Vector<T> value) where T : struct { throw null; }
209209
public static System.Numerics.Vector<T> BitwiseAnd<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
210210
public static System.Numerics.Vector<T> BitwiseOr<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
211+
public static System.Numerics.Vector<System.Double> Ceiling(System.Numerics.Vector<System.Double> value) { throw null; }
212+
public static System.Numerics.Vector<System.Single> Ceiling(System.Numerics.Vector<System.Single> value) { throw null; }
211213
public static System.Numerics.Vector<System.Single> ConditionalSelect(System.Numerics.Vector<System.Int32> condition, System.Numerics.Vector<System.Single> left, System.Numerics.Vector<System.Single> right) { throw null; }
212214
public static System.Numerics.Vector<System.Double> ConditionalSelect(System.Numerics.Vector<System.Int64> condition, System.Numerics.Vector<System.Double> left, System.Numerics.Vector<System.Double> right) { throw null; }
213215
public static System.Numerics.Vector<T> ConditionalSelect<T>(System.Numerics.Vector<T> condition, System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
@@ -232,6 +234,8 @@ public static partial class Vector
232234
public static bool EqualsAll<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
233235
public static bool EqualsAny<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
234236
public static System.Numerics.Vector<T> Equals<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
237+
public static System.Numerics.Vector<System.Double> Floor(System.Numerics.Vector<System.Double> value) { throw null; }
238+
public static System.Numerics.Vector<System.Single> Floor(System.Numerics.Vector<System.Single> value) { throw null; }
235239
public static System.Numerics.Vector<System.Int64> GreaterThan(System.Numerics.Vector<System.Double> left, System.Numerics.Vector<System.Double> right) { throw null; }
236240
public static System.Numerics.Vector<System.Int32> GreaterThan(System.Numerics.Vector<System.Int32> left, System.Numerics.Vector<System.Int32> right) { throw null; }
237241
public static System.Numerics.Vector<System.Int64> GreaterThan(System.Numerics.Vector<System.Int64> left, System.Numerics.Vector<System.Int64> right) { throw null; }
@@ -292,10 +296,6 @@ public static partial class Vector
292296
[System.CLSCompliantAttribute(false)]
293297
public static void Widen(System.Numerics.Vector<System.UInt32> source, out System.Numerics.Vector<System.UInt64> dest1, out System.Numerics.Vector<System.UInt64> dest2) { throw null; }
294298
public static System.Numerics.Vector<T> Xor<T>(System.Numerics.Vector<T> left, System.Numerics.Vector<T> right) where T : struct { throw null; }
295-
public static System.Numerics.Vector<System.Single> Ceiling(System.Numerics.Vector<System.Single> value) { throw null; }
296-
public static System.Numerics.Vector<System.Double> Ceiling(System.Numerics.Vector<System.Double> value) { throw null; }
297-
public static System.Numerics.Vector<System.Single> Floor(System.Numerics.Vector<System.Single> value) { throw null; }
298-
public static System.Numerics.Vector<System.Double> Floor(System.Numerics.Vector<System.Double> value) { throw null; }
299299
}
300300
public partial struct Vector2 : System.IEquatable<System.Numerics.Vector2>, System.IFormattable
301301
{

src/libraries/System.Resources.Writer/ref/System.Resources.Writer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public ResourceWriter(string fileName) { }
2121
public System.Func<System.Type, string>? TypeNameConverter { get { throw null; } set { } }
2222
public void AddResource(string name, byte[]? value) { }
2323
public void AddResource(string name, System.IO.Stream? value) { }
24-
public void AddResource(string name, System.IO.Stream? value, bool closeAfterWrite) { }
24+
public void AddResource(string name, System.IO.Stream? value, bool closeAfterWrite = false) { }
2525
public void AddResource(string name, object? value) { }
2626
public void AddResource(string name, string? value) { }
2727
public void AddResourceData(string name, string typeName, byte[] serializedData) { }

0 commit comments

Comments
 (0)