16 lines
726 B
Plaintext
Raw Normal View History

2020-06-30 12:47:33 +02:00
Function arguments should all have different names to prevent any ambiguity. Indeed, if arguments have the same name, the last duplicated argument hides all the previous arguments with the same name (those previous arguments remain available through arguments[i], so they're not completely inaccessible).
2021-02-02 15:02:10 +01:00
2020-06-30 12:47:33 +02:00
This hiding makes no sense, reduces understandability and maintainability, and obviously can be error prone. Furthermore, in strict mode, declaring arguments with the same name produces an error.
include::../noncompliant.adoc[]
include::../compliant.adoc[]
ifdef::env-github,rspecator-view[]
== Comments And Links
(visible only on this page)
include::../comments-and-links.adoc[]
endif::env-github,rspecator-view[]