Set#merge

Discussion in 'Ruby' started by Joel VanderWerf, Jan 31, 2006.

  1. Can anybody explain why Set#merge is destructive, but Hash#merge is not?

    --
    vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407
     
    Joel VanderWerf, Jan 31, 2006
    #1
    1. Advertisements

  2. Joel VanderWerf

    Stefan Walk Guest

    Joel VanderWerf wrote:
    > Can anybody explain why Set#merge is destructive, but Hash#merge is not?
    >


    Probably the same reason that Array#delete is destructive, but
    String#delete is not.

    Regards,
    Stefan
     
    Stefan Walk, Jan 31, 2006
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    2
    Views:
    5,437
  2. Replies:
    1
    Views:
    1,257
    Jonathan Bromley
    Mar 31, 2005
  3. Joe Cosby

    Perl "test merge"

    Joe Cosby, Apr 10, 2004, in forum: Perl
    Replies:
    2
    Views:
    626
    Joe Cosby
    Apr 11, 2004
  4. mark

    merge two asp.net website?

    mark, Aug 13, 2003, in forum: ASP .Net
    Replies:
    3
    Views:
    1,516
    John Saunders
    Aug 13, 2003
  5. A.M

    Merge Modules

    A.M, Apr 23, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    3,917
    Ken Cox [Microsoft MVP]
    Apr 23, 2004
  6. VB Programmer

    How to emulate Word mail merge in HTML?

    VB Programmer, May 20, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,243
    VB Programmer
    May 20, 2004
  7. Mark Goldin

    Merge cells

    Mark Goldin, Jun 24, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    513
    Mark Goldin
    Jun 24, 2004
  8. Phil Winstanley [Microsoft MVP ASP.NET]

    Re: Merge cells

    Phil Winstanley [Microsoft MVP ASP.NET], Jun 24, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    495
    Mark Goldin
    Jun 25, 2004
Loading...