Example of writing to state variables packed into a single slot
Bit masking
• Bit Masking | EVM Storage 2
0:00 Intro
3:25 Write to slot 0
4:41 Write to state variable s_a
7:12 Write to state variable s_b
10:00 Write to state variable s_c
12:08 Write to state variable s_d
13:49 Fix code
14:00 Test test_sstore
14:19 slot and offset
19:06 Test test_sstore_using_offset
Code corrections
9:15 add should be and
11:38 add should be and
13:08 add should be and
Playlist
• EVM
Code
https://solidity-by-example.org/evm/s...
Take a course
https://www.smartcontract.engineer/
Remix
https://remix.ethereum.org
#Solidity #SmartContract #Ethereum #スマートコントラクト
Follow
https://odysee.com/@SmartContractProg...
/ programmersmart
/ discord
https://t.me/smartcontractprogrammer
https://smartcontractprogrammer.com
Watch video State Variables Packed into a Slot | EVM Storage 3 online without registration, duration hours minute second in high quality. This video was added by user Smart Contract Programmer 13 April 2024, don't forget to share it with your friends and acquaintances, it has been viewed on our site 1,181 once and liked it 57 people.