Commit Graph

29 Commits

Author SHA1 Message Date
Nicolás Acosta
e89efe89a6 style(mapping-types): fix mapping style 2023-02-01 15:49:34 -03:00
Soham Zemse
fa78e0f3d4 feat: allow named parameters in mapping types
Co-authored-by: Hari <webmail.hari@gmail.com>

test: add parser and abi test cases

docs: add example on using named parameters for mappings

- Add changelog

feat: update antlr grammar to allow named parameters in mappings

fix: prevent conflicting mapping parameter names

ref: change order of mapping initializers

test: update expectations and fix build

test: add more tests

fix: use common error & code for conflicting params

fix: issue with accessing nested mapping

test: add conflicting params tests for more nested levels

Update libsolidity/analysis/DeclarationTypeChecker.cpp

Co-authored-by: Nikola Matić <nikola.matic@ethereum.org>

fix: error reported with the same code twice

test: add more tests for 3 level nested mapping

Address review comments
2022-12-08 11:56:58 +01:00
aathan
54fa215885
Update mapping-types.rst
typo
2022-03-23 17:15:17 -07:00
Richie
beb51068bb
fix: corrects _ prefixes 2022-03-14 08:03:10 -07:00
chriseth
fb7cdda891 Fix iterable mapping example. 2022-02-28 17:57:19 +01:00
Richie
49f06dacdf fix: remove lower_case_with_underscores and Capitalized_Words_With_Underscores from code examples 2022-02-21 10:53:35 -08:00
chriseth
0010027e17 Fix mapping example. 2021-12-30 15:28:09 +01:00
Kamil Śliwak
693b88e5f8 docs: Force highlighter to work despite errors on snippets that it cannot parse 2021-07-15 10:14:00 +02:00
iskanderandrews
a8e9d7a80d docs/
Enhancing all the .rst doc files by adding highlighting for the code snippets, including the following langs:
1. Solidity

2. bash

3. javascript

4. assembly
2021-06-25 12:33:55 +02:00
hrkrshnn
29e23efc93 Tests/Docs after "stricter explicit conversion from Literals to Integers" 2020-11-03 14:31:44 +01:00
Mathias Baumann
b72fb1333b Adjust docs example to work with v0.8.0 2020-09-08 13:36:16 +02:00
Harikrishnan Mulackal
eeadb5a6b5 Tests, Docs and Changelog 2020-06-30 16:53:41 +05:30
chriseth
257bc6a416 Merge remote-tracking branch 'origin/develop' into breaking 2020-05-14 13:04:46 +02:00
chriseth
d33b67b3c2 Add license tags to documentation snippets. 2020-05-13 22:16:34 +02:00
chriseth
ecbf216354 Merge remote-tracking branch 'origin/develop' into breaking 2020-05-04 18:46:45 +02:00
KaiYu Feng
15748e871e
fix(docs/mapping-types): fix wrong demo code.
get index before push, so the access of this index won't beyond the boundery.
2020-05-01 00:14:45 +08:00
chriseth
7d68f9f6c3 Merge remote-tracking branch 'origin/develop' into breaking 2020-03-24 13:35:41 +01:00
Erik Kundt
50c22f0800 Adds script which compiles docs example with minimum compiler version. 2020-03-18 19:27:38 +01:00
chriseth
06ad5b3200 Merge remote-tracking branch 'origin/develop' into HEAD 2020-02-27 15:06:36 +01:00
Daniel Kirchner
d3cbfb0c5c Allow user-defined types as mapping keys in parser and restrict to contracts during type checking. 2020-02-04 17:22:03 +01:00
Erik Kundt
fe1676203d Updates documentation to 0.7.0. 2020-01-10 18:56:38 +01:00
chriseth
c85103816c Update mapping types. 2019-12-16 17:09:52 +01:00
Daniel Kirchner
2d2fb547e7 Update mapping docs. 2019-11-19 21:11:14 +01:00
Chris Chinchilla
0c51dcc967 Explain mappings example, and add link to further details
Updates from review

Changes from review

Nested example

Update docs/types/mapping-types.rst

Co-Authored-By: chriseth <chris@ethereum.org>
Changes from review

Bring example inline with ERC20

Clarify what maps where

Use OZ contract example

Update docs/types/mapping-types.rst

Co-Authored-By: chriseth <chris@ethereum.org>

update code example
2019-11-06 21:32:24 +01:00
Chris Chinchilla
1a88bc97df Add updated iterable mapping example
Remove unused var
2019-11-05 17:10:27 +01:00
Leonardo Alt
df0b54d7c7 [DOCS] Clearing mappings 2019-09-17 11:58:00 +02:00
Chris Ward
7e4896740d Clarify that public applies to state variables 2019-06-17 16:55:31 +01:00
chriseth
8d401ba936 Update pragmas. 2019-03-05 18:10:09 +01:00
Chris Ward
29088c4f48 Split mapping types into new file 2019-01-14 10:58:10 +02:00