Ejemplo n.º 1
0
            public MethodDebugInfoBytes Build()
            {
                // Global header
                _bytesBuilder.Insert(0, Version);
                _bytesBuilder.Insert(1, (byte)_recordCount);
                _bytesBuilder.Insert(2, Padding);
                _bytesBuilder.Insert(3, Padding);

                Assert.Equal(0, _bytesBuilder.Count % 4);

                var info = new MethodDebugInfoBytes(_bytesBuilder.ToImmutableAndFree(), _method);

                _bytesBuilder = null; // We'll blow up if any other methods are called.
                return(info);
            }
Ejemplo n.º 2
0
            public MethodDebugInfoBytes Build()
            {
                // Global header
                _bytesBuilder.Insert(0, Version);
                _bytesBuilder.Insert(1, (byte)_recordCount);
                _bytesBuilder.Insert(2, Padding);
                _bytesBuilder.Insert(3, Padding);

                Assert.Equal(0, _bytesBuilder.Count % 4);

                var info = new MethodDebugInfoBytes(_bytesBuilder.ToImmutableAndFree(), _method);
                _bytesBuilder = null; // We'll blow up if any other methods are called.
                return info;
            }