JavaScript allows duplicate property names in classes and object literals, but only the last instance of a duplicated name determines the actual value that will be used for it. Therefore, changing values of other occurrences of a duplicated name will have no effect and may cause misunderstandings and bugs.
Defining a ``++class++`` with a duplicated ``++constructor++`` will generate an error.
Before ECMAScript 2015, using duplicate names will generate an error in JavaScript strict mode code.