Questions tagged [mapping]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer

how to remove Mapping storage when tuple is used as input

Lets assume we have an ink! smart contract On a vanilla Mapping alpha: Mapping<[u8;32], Astruct> we can use self.alpha.remove(&somehash) My question is this: if we have the following ...
Sokrates's user avatar
  • 409
4 votes
0 answers

Migration from legacy HashMap to Mapping

I have following code where I want to use with new Mapping (now it works but with legacy HashMap). I think that the source code below is self-explanatory: self.balances .entry(caller) ...
Tomasz Waszczyk's user avatar