Repository: dotnet/runtime
File: src/libraries/System.Net.Security/src/System/Net/NegotiateAuthenticationPal.ManagedNtlm.cs (C#)

Code before:

            private enum AvId
            {
                EOL,
                NbComputerName,
                NbDomainName,
                DnsComputerName,
                DnsDomainName,
                DnsTreeName,
                Flags,
                Timestamp,
                SingleHost,
                TargetName,
                ChannelBindings,
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct MessageField
            {
                public ushort Length;
                public ushort MaximumLength;
                public int PayloadOffset;
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct MessageHeader
            {
                public fixed byte Header[HeaderLength];
                public MessageType MessageType;
                private byte _unused1;
                private byte _unused2;
                private byte _unused3;
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct Version
            {
                public byte VersionMajor;
                public byte VersionMinor;
                public ushort ProductBuild;
                private byte _unused4;
                private byte _unused5;
                private byte _unused6;
                public byte CurrentRevision;
            }

            // Type 1 message
            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct NegotiateMessage
            {
                public MessageHeader Header;

Review comment (suggestion):
Nit:
```suggestion
                    readonly get => BitConverter.IsLittleEndian? _payloadOffset: BinaryPrimitives.ReverseEndianness(_payloadOffset);
                    set => _payloadOffset = BitConverter.IsLittleEndian? value: BinaryPrimitives.ReverseEndianness(value);
```

Code after:

            private enum AvId
            {
                EOL,
                NbComputerName,
                NbDomainName,
                DnsComputerName,
                DnsDomainName,
                DnsTreeName,
                Flags,
                Timestamp,
                SingleHost,
                TargetName,
                ChannelBindings,
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct MessageField
            {
                public ushort Length;
                public ushort MaximumLength;
                private int _payloadOffset;
                public int PayloadOffset
                {
                    readonly get =>BitConverter.IsLittleEndian? _payloadOffset: BinaryPrimitives.ReverseEndianness(_payloadOffset);
                    set =>_payloadOffset = BitConverter.IsLittleEndian? value: BinaryPrimitives.ReverseEndianness(value);
                }
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct MessageHeader
            {
                public fixed byte Header[HeaderLength];
                public MessageType MessageType;
                private byte _unused1;
                private byte _unused2;
                private byte _unused3;
            }

            [StructLayout(LayoutKind.Sequential)]
            private unsafe struct Version
            {
                public byte VersionMajor;
                public byte VersionMinor;
                private ushort _productBuild;
                private byte _unused4;
                private byte _unused5;
                private byte _unused6;
                public byte CurrentRevision;
                public ushort ProductBuild
                {