Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ```c++
- struct Z80
- {
- volatile uint8_t& memory(const uint16_t address)
- {
- return *reinterpret_cast<uint8_t*>(address);
- }
- };
- int main()
- {
- Z80 z80;
- auto useFreeLambda = [&]() {
- z80.memory(0xa000) = 0x10;
- };
- useFreeLambda();
- return 0;
- }
- ```
Add Comment
Please, Sign In to add comment