Skip to content

Files

Latest commit

 

History

History
29 lines (21 loc) · 462 Bytes

duplicated_key_in_dictionary_literal.md

File metadata and controls

29 lines (21 loc) · 462 Bytes

Pattern: Duplicated key in dictionary literal

Issue: -

Description

Dictionary literals with duplicated keys will crash in runtime.

Examples of correct code:

[
	1: "1",
	2: "2"
]

Examples of incorrect code:

[
	1: "1",
	2: "2",
	1: "one"
]

Further Reading