[Issue 24169] Confusion between array literal and associative array literal
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Sep 29 03:20:33 UTC 2023
https://issues.dlang.org/show_bug.cgi?id=24169
--- Comment #1 from Walter Bright <bugzilla at digitalmars.com> ---
The fault appears to lie with init.ArrayInitializer.isAssociativeArray(), which
is way too eager to conclude it's an associative array.
I suggest that it be amended to require, for an associative array:
1. all keys are present
2. the key type is not integrably promotable to size_t
-or-
the range of key values is more than twice the number of entries
--
More information about the Digitalmars-d-bugs
mailing list