204285-208299 subjects 204596-207794

^ Creating hashes with duplicate keys
204456 [sy1234 gmail] g = { 1 => "test", 2 => "test", }
+ 204458 [farrel.lifso] Something like this?
| 204460 [Nuralanur ao] class Array
+ 204465 [robert.dober] In the following implementations there are two possible Approaches, the
+ 204467 [daniel.schie] hsh = Hash.new{|h, k| h[k] = (k == 1 ? "one" : h[k - 1])}
+ 204469 [botp delmont] # g = { 1 => "test", 2 => "test", }
+ 204525 [ara.t.howard] use rbtree (from the raa)
  204532 [ara.t.howard] require 'rbtree'

^ For performance, write it in C - Part 2, comparing C, Ruby and Java
204459 [peter semant] This is the follow up to my "Write it in C post" and is intended to
+ 204477 [isak.hansen ] *snip*
| + 204478 [peter semant] Interesting, so just how to you run a Java program without the JVM start-up time?
| | + 204479 [pedro pedroc] You can time it inside java by fetching the system clock before and after.
| | | + 204489 [peter semant] That would only get me the elapsed time of the execution which does not
| | | + 204685 [kmgaughan ei] It also makes sense to run the algorithm a few times to ensure the JIT
| | + 204480 [Roland.Schmi] It's like measuring database performance and including the startup time
| | | + 204494 [peter semant] I'm not too sure that your analogy holds. It's not like I included the
| | | | 204507 [Roland.Schmi] But startup time for the computer and so on is the same regardless of
| | | + 204496 [robert.dober] And mysql is as fast as Oracle, even faster unless Oracle is very, very
| | |   204550 [perrin apoth] . . . and timings without JVM startup time are at least as "useless"
| | |   204563 [GENIE prodig] Uh, you start your interpreter/jvm/whatever, get everything started,
| | |   204567 [perrin apoth] . . . and of course, in Perl (for instance), things like BEGIN blocks
| | + 204603 [headius head] The problem is that you're not controlling for that startup time. If you
| |   204609 [the.mindstor] Sorry to jump into discussion, but I am wondering once again (I cannot
| + 204483 [simon.kroege] Of course each Benchmark is to be taken with a lot of caution, but I
|   + 204557 [igouy yahoo.] Startup time varies with the classes that are being loaded,  this hello
|   + 204562 [isak.hansen ] This may seem like a reasonable assumption, but it really isn't that
+ 204505 [doodpants ma] Um, just a nitpick, but Java didn't exist in 1992. Unless you count Oak.
| 204515 [peter semant] Hmm. I left Uni in 1992 and it was around then that my, obviously flaky,
+ 204511 [pat.eyler gm] Was the code for the Java and Ruby versions posted somewhere in
| 204518 [peter semant] The Ruby version was posted in the previous thread by Simon. I didn't
+ 204519 [znmeb cesmai] In my younger days, I did a lot of development in assembler languages,
| + 204549 [jmg3000 gmai] Well, there's a number of "shoot yourself in the foot" and "C
| + 204608 [segfault has] I'm pretty sure it's manual memory management. Pointers are fun and
| + 204636 [w_a_x_man ya] So you know only clunky, crude, archaic languages, the newest
|   + 204645 [perrin apoth] It might be more accurate to say that he's just reformulated the same
|   | 204812 [znmeb cesmai] Well, no ... I'm simply saying that when I was doing it, I did not find
|   + 204809 [znmeb cesmai] Well ... I'm certainly moving towards Ruby. I just need to unlearn Perl.
|     204811 [perrin apoth] Wait -- what?  Why?  Learning Ruby is making me a better Perlist, and
|     204820 [znmeb cesmai] Most of what I have written in Perl is stuff that Perl (4) is good at.
|     204832 [perrin apoth] I pretty well loathe the Perl object model, and the syntax for
+ 204553 [headius head] Man, I needed a good laugh today. Where to begin...
| + 204564 [perrin apoth] I think you might be misunderstanding the usage of "arbitrary" here.  An
| + 204569 [peter semant] The Java numbers are what was genuinely produced by the Java system on
|   204629 [igouy yahoo.] Perhaps you could post the 5x5 Java and C programs on your website then
|   + 204631 [pat.eyler gm] And the Ruby version please.
|   | 204641 [perrin apoth] While the Ruby version (assuming it's the same version) was posted to
|   + 205151 [peter semant] I will put together some pages tonight to get all the source code up.
+ 204614 [w_a_x_man ya] Why is it so much slower on Peter Hickman's machine?

^ [ANN] RFuzz Web Destroyer 0.6 -- Doc'ed Out
204461 [zedshaw zeds] A quick announcement that RFuzz 0.6 is out and has a nearly complete

^ Catching all that goes to $stderr
204463 [smerk fi.mun] how can I catch all output going to $stderr (e.g. to send some warning
204529 [sean.ohalpin] Something like this?

^ Signaling Ruby from C/C++
204471 [asterixgalli] I would like to send a signal from c to ruby. So that ruby knows, that
+ 204816 [skurapat ucs] How about raising an exception from your C code and catching it in
| + 205073 [asterixgalli] Thank you vor this advice. But I didn't find a working solution with
| + 205074 [garbagecat10] I haven't tried your solution, but I would be surprised if a Ruby
|   205402 [asterixgalli] now I've tried another solution. I'm sending a signal to the Rubyprocess
|   205420 [garbagecat10] Does this actually work??? Windows doesn't have signals, so maybe
|   206737 [asterixgalli] the solution above works somehow, but i experienced that this is not
|   206753 [garbagecat10] Asterix, I don't have time right this moment to write and test a working
|   206846 [asterixgalli] Ok I guess I know how it should work, but I'm not able to implement.
|   206869 [garbagecat10] #---------------------------------
|   206950 [asterixgalli] What a shame! It doesn't work on Windows. When comming to the
|   206962 [simon.kroege] require 'socket'
|   206995 [garbagecat10] Simon, that was a nyyyyz idea to use a TCP socket, as ugly as it is,
|   207063 [logancapaldo] require 'timeout'
|   207202 [garbagecat10] Of course. Still, I don't like this because what about well-secured
+ 207211 [garbagecat10] Ok, Asterix, this was driving me crazy because I know I've done it
  207249 [asterixgalli] Thank you all very much for your help and so much code examples. You
  207270 [garbagecat10] I just tested it on Windows 2KServer with Ruby 1.8.4(2005-12-24) and it
  207514 [asterixgalli] I tried your code again by building a standard Ruby extension too, and
  + 207516 [garbagecat10] You're going to face this problem in any case, since you want your Ruby
  + 207560 [ara.t.howard] probably it's on the c end - you may be continuing to send data when the pipe

^ Weird problem with case expressions
204481 [daniel.schie] if foo :bar then
+ 204482 [angus quovad] case "foo"
| 204499 [daniel.schie] if foo: "bar"
+ 204486 [M.B.Smillie ] c = [something]
| + 204490 [dblack wobbl] I think in Daniel's example foo is a method, and :bar is a method
| | 204497 [M.B.Smillie ] Ah, that would explain it.  I admit the method/variable ambiguity
| + 204498 [daniel.schie] I expect `foo :bar' to be the same as `foo(:bar)'.
|   204503 [M.B.Smillie ] Indeed - mea culpa once again.
+ 204495 [dblack wobbl] I guess when binds more tightly than a parentheses-less method call.
  204535 [daniel.schie] Thank you for the response. Yes, it seems there is no way to get around
  204540 [ara.t.howard] you could do
  204558 [daniel.schie] That would work, but I don't think classes and types are always the
  204573 [ara.t.howard] %w( to_int to_str to_hash to_ary ).detect{|m| 'foo'.respond_to? m}
  204621 [daniel.schie] %w{int str ary}.detect{|type| obj.respond_to? "to_#{type}"}
  204702 [daniel.schie] class Object

^ keystroke logger
204484 [derekhaskin ] charset="iso-8859-1"
+ 204513 [benjohn fysh] a little background on why you're interested in such an application.
| 204537 [daniel.schie] The NSA uses Ruby? :D
| 204543 [brendan.spee] A lot of businesses use keystroke loggers on all their PCs to track usage.
| 204670 [benjohn fysh] had in mind!
+ 204948 [nahteecirp g] For Windows at least it looks like its done rather easily in C++ by making a
  204976 [aleks0 gmail] (OT) If you have a filter set up for to:ruby-talk@ruby-lang.org, then

^ Ruby::Tk on OS X event binding hint
204492 [m_goldberg a] On Macintosh OS X, one can use 'Command' and 'Option' as Tk event
+ 204501 [M.B.Smillie ] Just as an interface technicality, command-shift-q is a global
| + 204520 [m_goldberg a] Thanks for pointing this out. If ever I was aware of that short-cut,
| + 204536 [m_goldberg a] I've done the testing that I should have done before my first post on
|   204862 [bsmargiassi ] I would think you never want to bind Command-<key> and Command-Shift-
|   204866 [m_goldberg a] Regards, Morton
|   204880 [nagai ai.kyu] I'm very sorry. Probably, 'Command-Shift-q' doesn't work.
+ 204575 [nagai ai.kyu] It will not work on other toplevel widgets.
  204660 [m_goldberg a] Thank you for your comments. However, I'm pretty new to Ruby Tk, and
  204722 [nagai ai.kyu] I'm sorry if I misunderstanded your post.
  204857 [m_goldberg a] Ah, now I understand. I did not consider the points you bring up. Now

^ [UPDATE] RubyConf 2006 registration pre-info
204516 [dblack wobbl] My current plan, barring unforeseen whatever, is to open registration
204664 [tom helmetst] Given the small number of spots for the conference and the large number
+ 204690 [wrecklass1 g] I'd like to second Tom's suggestion. Given the supply vs. demand on
| 204736 [james graypr] I would rather not lead the Denial of Service attach on Ruby
+ 204756 [tom helmetst] Another interesting thing this would accomplish is to determine with
  204794 [gregory.t.br] Slap a page on the RubyGarden wiki, I imagine if people want to

^ Better profiling for ruby?
204517 [martin snowp] So the recent performance threads have all repeated the wisdom
+ 204521 [jan.svitok g] (registration needed)
| 204528 [pat.eyler gm] benchmarking for beginning Ruby programmers.  I (or someone)
+ 204600 [collinsj sea] ruby-prof is pretty neat. I haven't used it a lot, but I feel it's a bit
+ 205047 [cfis savagex] Daniel,
| + 205048 [cfis savagex] Hope this helps,
| + 205162 [martin snowp] While I have no doubt that it shows me something, I had no idea what
|   205609 [cfis savagex] I also updated my blog entry.
+ 205381 [snail objmed] <martin@snowplow.org> writes

^ Ruby LDAP --- Hooray!!
204522 [greg.kujawa ] After unsuccessfully trying to compile a Ruby LDAP implementation a
204527 [garbagecat10] Thanks. Let us know here if you hit any problems with the library or
+ 204531 [greg.kujawa ] For this one task all I am doing is pulling the Exchange Server global
| 204534 [garbagecat10] Out of curiosity, what kind of identities are you storing in Exchange
+ 204533 [ola.bini ki.] I'm also using it, and it's really good. I'm actually specifically _not_
  204539 [garbagecat10] notation
  204541 [ola.bini ki.] Haha, yes, I know it's there, but not as language syntax. That was the
  204546 [garbagecat10] the

^ SQL Server DBI insert silently fails
204538 [leslieviljoe] I am having problems when trying to insert records using dbi-0.1.0 on
204542 [Daniel.Berge] Did you commit after inserting?
204643 [leslieviljoe] You were right! I didn't realise that some databases don't commit automatically!

^ state of unicode support
204544 [perrin apoth] I've heard rumors that "oniguruma fixes everything", and the like.  I'm
+ 204547 [Daniel.Berge] Good grief, this was *just* covered ad nauseum recently.  Search the
| 204555 [perrin apoth] Good grief, you're a prick.  Thanks for the help.  Has everyone in the
| 204556 [perrin apoth] Whoops.  I offer my apologies to ruby-talk: that was meant to be an
| 204572 [perrin apoth] Maybe that has something to do with the fact that I've been an
| 204583 [cdc cyphers.] It shouldn't matter if one is constantly subscribed.  One should search
| 204591 [perrin apoth] News flash: I used Google and found a grand total of two posts from that
| + 204595 [Daniel.Berge] <snip rant>
| | 204598 [perrin apoth] Is that a joking bit of peace-offering, or should I confine my comments
| + 204599 [drosihn gmai] I think the real problem here is not that you happened to ask a
| | 204601 [perrin apoth] Thanks for the explanation.  It's nice to occasionally get a civil
| | 204617 [perrin apoth] . . . or already have some vague idea of what Ruby Unicode support was
| + 204914 [chneukirchen] In all politeness, I think you should count yourself in.
| | 204922 [perrin apoth] Perhaps I should.  I let my frustration at rudeness and similar poor
| + 205198 [listbox juli] This is not quite true - the problem is that when the subject comes
|   205240 [perrin apoth] . . . except that Why answered me beyond the expectations of the
|   205257 [listbox juli] It's always more entertaining to think globally and draw grand
|   205263 [perrin apoth] I would have thought so, but the general consensus seems to be that
+ 204577 [headius head] Oh man, I really don't have the energy for this thread again :) Chad: if you
  204634 [ruby-talk wh] This isn't a complete answer, but it's the best I can do to help Chad out.
  + 204638 [perrin apoth] That was most excellent.  Thank you for your kind assistance: it answers
  + 204646 [chiology gma] So, the problem with Unicode support in Ruby is that the code
  | + 204652 [headius head] This wasn't intended to be sarcastic, honestly! I didn't get the answer I
  | | 204671 [headius head] And I apologize for the lag...I've got my servers behaving now.
  | + 205158 [hramrach cen] Regexes in 1.8 can do utf-8.
  + 204673 [headius head] Very nice; it should be on a wiki somewhere under the bold, flashing
  + 204692 [Eric.Armstro] Spectacular summary. As a lurker on this thread,
  + 204840 [tbray textua] Er uh well it doesn't do unicode properties so you can't use things
  + 205199 [listbox juli] Which is actually useless because this breaks your string between
    205210 [pbattley gma] Whilst it's certainly useless for a lot of tasks, I'm not sure that
    205216 [listbox juli] AFAIK Python regexps do that properly, and ICU does for sure (both as
    205234 [pbattley gma] That's what I mean: ICU is a separate library, not part of a language
    + 205236 [listbox juli] PHP took the best of both - they are integrating ICU into the core.
    | 205389 [hramrach cen] Last time I looked ICU was in C++. Requiring a C++ compilier and
    | 205399 [listbox juli] It still is. And it's huge and takes ages to build. If only I knew
    + 205383 [dan-ml dan42] I second that. I see a lot of people asking for "transparent" unicode support
      + 205386 [hramrach cen] By transparent I mean that I can iterate, compare, match, index, ...
      + 205488 [tbray textua] It can be done.  Java gets it almost right, and in such a way that most

^ Using a '-' in a Key name in a Hash
204554 [aknott mac.c] This a ruby question but it comes up in the context of Rails, hope that
+ 204560 [sean.ohalpin] To include non-identifier characters in a symbol, use the quoted form,
| 204565 [aknott mac.c] Thanks a lot!
| 204578 [aknott mac.c] Ok, that's worked perfectly for the call... Unfortunately on the server
| 204622 [daniel.schie] No; "remote-ip" is here the name of a method and an instance variable,
| 204626 [ara.t.howard] but i think rails is autogenerating this method - it's a major design flaw if
| + 204633 [aknott mac.c] I would agree...
| | 204637 [chiology gma] Forgive my unfamiliarity with Rails, but in what context is this call
| + 204704 [daniel.schie] Yeah, I guess it would be smarter to replace the hyphen with an underscore.
|   204733 [chiology gma] @Daniel: That's very cool. So then the change for getting Andrew
|   204831 [aknott mac.c] In ActionWebService::Structs you define members using
|   204851 [chiology gma] 54,55c54,55
+ 204561 [gboyer gmail] You can have '-' in a key name, you simply can't have '-' in a symbol

^ Double quotes embedded in a string ...
204568 [devlists-rub] Here is something that I am struggling with -- I would like to execute a
204576 [ara.t.howard] use this

^ ruby-talk lag?
204582 [headius head] Has anyone been seeing high lag in getting ruby-talk mail? Today it's taking
204585 [khaines enig] I consistently see very little latency between when I send an email to the
+ 204587 [khaines enig] 40 seconds.  It took 40 seconds from when I sent this message to when the
+ 204588 [Daniel.Berge] It does seem to be sporadic.  It's *usually* very quick, though I have noticed
  204594 [perrin apoth] I haven't seen lags of more than about 11 minutes since I resubscribed
  + 204605 [james graypr] Obviously this doesn't apply if you are just posting to the list and
  | 204619 [perrin apoth] I haven't used the newsgroup side for either posting or receiving,
  + 204639 [headius head] It looks like it may be lag on a server in my return path; thanks for the
    204675 [headius head] one of the spam blackhole lists I was using appears to be having trouble.

^ OT: Perl parser
204586 [perrin apoth] Since it came up earlier and was the subject of some discussion, I

^ ruby threads? the point?
204589 [Eric.Armstro] Saw an archived message yesterday that
204597 [collinsj sea] This hasn't been my experience at all. Do you have a simple example that
204705 [Eric.Armstro] Yay! I'd rather be wrong!
+ 204709 [collinsj sea] <snip code>
| 204723 [wrecklass1 g] Tested it with cygwin under Windows XP, and it worked fine. Again,
| 204742 [Eric.Armstro] Ok, thanks much. One-click Ruby is /so/ convenient.
| + 204749 [khaines enig] def alpha
| | 204751 [Eric.Armstro] Interesting. I suppose it could be considered a
| | + 204754 [perrin apoth] You could always just implement your own text-based captive interface,
| | | 204762 [Eric.Armstro] Riiigghttt....
| | | + 204766 [perrin apoth] What is what -- a captive interface?  It's an interface that forces you
| | | + 204775 [ezmobius gma] Eric-
| | |   204777 [Eric.Armstro] Could be a useful option. Thanks for the tip.
| | + 204773 [ssmoot gmail] My experience has been that IO is blocking in Ruby/Windows. Just try
| | | + 204782 [matt technor] This has been brought up at previous Ruby Conferences.  It is my
| | | | 204923 [Eric.Armstro] Yay! Thanks for the news.
| | | + 204783 [Eric.Armstro] Ah. That explains why the two counter threads
| | |   204786 [headius head] I hate to make a plug here, but threads under JRuby are native and a single
| | |   205001 [garbagecat10] I assume I'm misreading you but it sounds like you're saying that Ruby's
| | + 204863 [jan.svitok g] Maybe you can use kbhit() and getch() from msvcrt.dll
| |   204924 [Eric.Armstro] Nice! Didn't know about that kbhit.
| |   205002 [garbagecat10] What happens if you just use select to read the file descriptor associated
| |   205338 [Eric.Armstro] Sounds promising. Do you have a bit of code
| + 204750 [wrecklass1 g] Startup the cygwin setup.exe program. Select Ruby from the list of
|   204781 [Eric.Armstro] Spectacular. Didn't know about the program.
+ 204848 [srinivas.j s] Here is an improvisation to your code. This automatically exits at the