Skip to content

Instantly share code, notes, and snippets.

@nedgrady
Created June 23, 2019 16:21
Show Gist options
  • Save nedgrady/df6cd3d7be4fcf68c8ee2f4e244221b4 to your computer and use it in GitHub Desktop.
Save nedgrady/df6cd3d7be4fcf68c8ee2f4e244221b4 to your computer and use it in GitHub Desktop.
bool p = ...;
bool q = ...;
bool r = p && q;
// p and q setup here…
// push p onto stack top
IL_0005: ldloc.0 // p [p]
// push q onto stack top
IL_0006: ldloc.1 // q [p, q]
// AND together top two stack values
IL_0007: and [p && q]
// Store our result into the memory location assigned to r
IL_0008: stloc.2 // r []
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment