Skip to content

Instantly share code, notes, and snippets.

@krk
Created June 27, 2017 16:45
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save krk/17b8300bce8c40bf3200029a9b7f6888 to your computer and use it in GitHub Desktop.
private void ReadCustomMetadata(BitAccess bits)
{
int position = bits.Position;
byte b;
bits.ReadUInt8(out b);
if (b != 4)
{
throw new PdbDebugException("Unknown custom metadata item version: {0}", new object[]
{
b
});
}
byte b2;
bits.ReadUInt8(out b2);
bits.Align(4);
uint num;
bits.ReadUInt32(out num);
switch (b2)
{
case 0:
this.ReadUsingInfo(bits);
break;
case 1:
this.ReadForwardInfo(bits);
break;
case 2:
break;
case 3:
this.ReadIteratorLocals(bits);
break;
case 4:
this.ReadForwardIterator(bits);
break;
default:
throw new PdbDebugException("Unknown custom metadata item kind: {0}", new object[]
{
b2
});
}
bits.Position = position + (int)num;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment