Skip to content

Conversation

@andrei-marinica
Copy link
Contributor

@andrei-marinica andrei-marinica commented Jan 27, 2026

Rust docs for all storage mappers, detailing the storage layout and main functionality.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds comprehensive Rust documentation to all storage mapper types in the MultiversX framework, detailing their storage layouts, main operations, trade-offs, use cases, and practical examples.

Changes:

  • Added detailed Rust documentation (docstrings) for 17 storage mapper types covering storage layout, operations, trade-offs, and usage examples
  • Converted error message and suffix constants from &[u8] byte string literals to &str string literals with corresponding .as_bytes() calls where needed
  • Reorganized constant declarations (changing from static to const and reordering for consistency)

Reviewed changes

Copilot reviewed 17 out of 17 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
whitelist_mapper.rs Added extensive documentation and converted error constant from &[u8] to &str
vec_mapper.rs Added documentation explaining 1-based indexing and storage patterns
user_mapper.rs Added documentation for user management and converted suffix constants to &str
unordered_set_mapper.rs Added documentation explaining O(1) set operations
unique_id_mapper.rs Added documentation for ID permutation tracking with space optimization
token/token_attributes_mapper.rs Added comprehensive NFT/SFT attribute management documentation and converted constants to &str
token/non_fungible_token_mapper.rs Added NFT/SFT lifecycle documentation and converted error constant to &str
token/fungible_token_mapper.rs Added fungible token management documentation with DeFi examples
single_value_mapper.rs Added documentation for simple key-value storage pattern
set_mapper.rs Added documentation explaining ordered set with insertion order preservation
queue_mapper.rs Added documentation for double-ended queue operations
ordered_binary_tree_mapper.rs Added BST documentation and converted error/suffix constants to &str
map_storage_mapper.rs Added documentation for nested storage mapper pattern
map_mapper.rs Added HashMap-like documentation and converted constant to &str
linked_list_mapper.rs Added documentation for doubly-linked list operations
bi_di_mapper.rs Added documentation for bidirectional mapping
address_to_id_mapper.rs Added documentation for address-to-ID mapping and converted constants to &str

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link

github-actions bot commented Jan 27, 2026

Contract comparison - from 64f2da4 to d1470e8

Path                                                                                             size                  has-allocator                     has-format
fractional-nfts.wasm 8302 false without message
multisig-view.wasm 5590 false None
multisig-full.wasm 15111 false without message
multisig.wasm 13606 false without message
nft-minter.wasm 9726 false without message
ping-pong-egld.wasm 6397 false None
factorial.wasm 579 false None
nft-subscription.wasm 8725 false without message
kitty-auction.wasm 9394 false without message
kitty-genetic-alg.wasm 3494 false without message
kitty-ownership.wasm 12953 false without message
nft-storage-prepay.wasm 2609 false None
crypto-bubbles.wasm 2561 false None
esdt-transfer-with-fee.wasm 7505 false without message
seed-nft-minter.wasm 14189 false without message
adder.wasm 699 false None
bonding-curve-contract.wasm 14016 false None
proxy-pause.wasm 4165 false None
empty.wasm 244 false None
crowdfunding.wasm 3574 false None
digital-cash.wasm 9563 false None
token-release.wasm 6948 false without message
lottery-esdt.wasm 10585 false without message
rewards-distribution.wasm 9449 false without message
check-pause.wasm 1240 false None
order-book-factory.wasm 3401 false None
order-book-pair.wasm 13848 false without message
crypto-zombies.wasm 9276 false without message
set-repeat.wasm 6511 false None
single-value-repeat.wasm 4253 false None
map-repeat.wasm 7363 false without message
queue-repeat.wasm 5536 false None
linked-list-repeat.wasm 6838 false without message
vec-repeat.wasm 4872 false None
str-repeat-mb-builder-cached.wasm 1109 false without message
str-repeat-mb-builder-basic.wasm 757 false None
str-repeat.wasm 2733 false without message
large-storage.wasm 1656 false None
send-tx-repeat.wasm 1292 false None
abi-tester.wasm 8612 true without message
abi-tester-ev.wasm 760 false None
exchange-features.wasm 1514 false None
use-module.wasm 32365 false without message
use-module-view.wasm 736 false None
panic-message-features.wasm 12838 false with message
panic-message-std.wasm 15886 false with message
big-float-features.wasm 6373 false without message
scenario-tester.wasm 1374 false None
forbidden-opcodes.wasm 842 false None
basic-features.wasm 85420 false without message
basic-features-storage-bytes.wasm 541 false None
payable-features.wasm 6046 false None
std-contract.wasm 3469 true without message
forwarder-queue.wasm 12712 false without message
forwarder-queue-promises.wasm 13336 false without message
forwarder-raw.wasm 13081 false None
forwarder-raw-init-sync-call.wasm 2958 false None
forwarder-raw-init-async-call.wasm 2374 false None
forwarder-legacy.wasm 33267 false without message
recursive-caller.wasm 5163 false without message
second-contract.wasm 1158 false None
first-contract.wasm 3450 false None
proxy-test-first.wasm 5711 false without message
transfer-role-features.wasm 8605 false without message
vault.wasm 8857 false None
vault-upgrade.wasm 708 false None
forwarder.wasm 48800 ➡️ 48797 🟢 (-3) false without message
proxy-test-second.wasm 2327 false without message
local-esdt-and-nft.wasm 12259 false without message
parent.wasm 1999 false None
child.wasm 3982 false without message
builtin-func-features.wasm 3828 false None
rust-snippets-generator-test.wasm 4708 false None
rust-testing-framework-tester.wasm 8584 false None
multi-contract-features-view.wasm 1113 false None
multi-contract-features.wasm 681 false None
multi-contract-alt-impl.wasm 353 false None
multi-contract-example-feature.wasm 680 false None
alloc-mem-leaking.wasm 23325 false without message
alloc-features.wasm 23168 false without message
alloc-mem-fail.wasm 17720 true without message
erc1155-user-mock.wasm 1229 false None
erc721.wasm 2232 false None
crowdfunding-erc20.wasm 4909 false without message
lottery-erc20.wasm 12886 false without message
erc1155.wasm 11969 false without message
erc1155-marketplace.wasm 10608 false without message
erc20.wasm 1887 false None
esdt-system-sc-mock.wasm 4199 false None
formatted-message-features.wasm 3613 false without message
multiversx-price-aggregator-sc.wasm 17901 false without message
multiversx-wegld-swap-sc.wasm 4309 false None

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 17 out of 17 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@andrei-marinica andrei-marinica merged commit d68598c into master Jan 29, 2026
23 checks passed
@andrei-marinica andrei-marinica deleted the sm-docs branch January 29, 2026 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants