Thread overview
[Issue 1606] Cannot insert to void[int]. void[int] should be a hash set.
Nov 08, 2007
d-bugmail
Jan 24, 2008
d-bugmail
Jan 24, 2008
d-bugmail
May 22, 2010
Don
Nov 08, 2010
Don
November 08, 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1606


smjg@iname.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |smjg@iname.com
          Component|glue layer                  |DMD
           Keywords|                            |accepts-invalid
         OS/Version|Linux                       |All
            Product|DGCC aka GDC                |D
            Version|0.24                        |1.023




------- Comment #5 from smjg@iname.com  2007-11-08 15:09 -------
Fails with DMD 1.023 - so the problem is obviously in the DMD front end.


-- 

January 24, 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1606





------- Comment #6 from unknown@simplemachines.org  2008-01-24 00:06 -------
Created an attachment (id=221)
 --> (http://d.puremagic.com/issues/attachment.cgi?id=221&action=view)
Don't allow void as a value of an associative array.

I can't imagine how this could work, since the in operator would be useless (how can you return a pointer to a void?)  It should simply be rejected.

-[Unknown]


-- 

January 24, 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1606





------- Comment #7 from thecybershadow@gmail.com  2008-01-24 04:52 -------
I disagree - IMO it should return a bool, because the "in" operator is more often used to check if the key is part of the AA/set. I think sets are used commonly enough to be part of the base language, and not just achievable through the less efficient dummytype[type] hack. While I agree with the void[type] declaration syntax, I think adding new values should be done through a .add() "method", which would be in line with .remove().


-- 

May 22, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=1606


Don <clugdbug@yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |Justin.SpahrSummers@gmail.c
                   |                            |om


--- Comment #8 from Don <clugdbug@yahoo.com.au> 2010-05-22 07:06:43 PDT ---
*** Issue 3892 has been marked as a duplicate of this issue. ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 08, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=1606


Don <clugdbug@yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |FIXED


--- Comment #9 from Don <clugdbug@yahoo.com.au> 2010-11-08 08:25:31 PST ---
The "should be a hash set" enhancement is WONTFIX. The bug is fixed in svn 742 for DMD1, and in svn 741 for D2.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
November 08, 2010
http://d.puremagic.com/issues/show_bug.cgi?id=1606


bearophile_hugs@eml.cc changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bearophile_hugs@eml.cc


--- Comment #10 from bearophile_hugs@eml.cc 2010-11-08 09:45:49 PST ---
Are sets not desired as built-in data structure?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------