6551-6839

6348-7087 subjects 6713-8377

^ A tool to generate tags?
6551 [bombadil wan] Does it exist such a tool for using tags in vim?
6703 [andy toolshe] Look in the irb distribution for rtags.rb -- it does both vi and emacs.

^ Prototype/Classless OOP in Ruby?
6558 [brannon lnc.] found out about Ruby and even bought the Ruby book from fatbrain.com
6575 [matz zetabit] * have instance variables.

^ Relational operators in Ruby.
6561 [hgs dmu.ac.u] I have been thinking about relational operators in Ruby, (which is
6562 [Dave thomase] Would '==' produce it's RHS on success? If so,
6572 [hgs dmu.ac.u] This is a tricky one.  This doesn't come up in Icon, because it has
6600 [schneik us.i] While I think the idea of supporting Icon-style goal-directed evaluation
6602 [Dave thomase] A worthy goal, I agree, but can you think of any time where this
6618 [schneik us.i] #
6641 [hgs dmu.ac.u] That is what I was trying to achieve.  I have only seen

^ Reading UTF-8 Streams
6563 [johan hotsip] I am pretty new to ruby and I am very happy with what I have seen so far! I
6577 [matz zetabit] Ruby's Regexp matcher handles UTF-8 properly.  No conversion is

^ tab-with within Xemacs
6564 [mjais web.de] does anybody know how to change the tab-with for ruby
6565 [gotoken math] You can control with ruby-indent-level.

^ Compiling Ruby on Mac OS X
6566 [jdnier execp] I'm trying to compile Ruby on Mac OS X (and am new to this list). I

^ Ruby/C extension build question
6570 [arjen aragor] I'm working on an extension for the GDCHART (http://www.fred.net/brv/chart/)
+ 6571 [arjen aragor] That would be this weekend.
+ 6573 [Dave thomase] You _could_ determine if they exist (using have_library), and if not

^ Does win32ole work with windows 2000?
6574 [mulperi iki.] I've been trying to get The Book's WIN32Ole samples to work, but they

^ 
6578 [duchene main] This is a multi-part message in MIME format.

^ ANN: Ruby/GDChart 0.0.1 available
6579 [arjen aragor] I've made a first version of my Ruby/GDChart library available at

^ booleans
6580 [maurice euro] I was experimenting the behaviour of ruby when I came across the
6581 [Dave thomase] a = 1.0/0		# => Infinity

^ best way to interleaf arrays?
6582 [dblack candl] Is there a nice Ruby idiom for interleafing arrays?  It's not hard to
+ 6583 [green FreeBS] What do you mean by interleave?  Normally I'd take this to mean that you'd
| 6584 [dblack candl] Hmmmm.... I'm not sure what I said that implied that.  Maybe throwing
| + 6586 [mtm csoft.ne] "
| + 6587 [green FreeBS] Yes, that would be the confusing part :)
| | 6588 [dblack candl] Except... you haven't (un)reversed what's left of a1 and a2.  So, for
| + 6639 [cjon sapphir] class Array
+ 6585 [Dave thomase] Matz has a technique for simulating external iterators using threads,
  6593 [dblack candl] What about a to_h method for arrays?  I mention this mainly for the
  6594 [Dave thomase] That was my thinking (if you can call it that ;-) It seems reasonable
  6611 [dblack candl] Although.... what about the cases where two types have to_* methods
  6612 [Dave thomase] I'm convinced by this, particular if we added the block form too.
  6613 [dblack candl] I was wondering about a block form.  I'm not sure exactly what it
  6614 [Dave thomase] or
  6663 [dblack candl] Oh, ok :-)

^ Q: refering to a Proc from class_eval
6589 [hipster xs4a] I'm trying to wrap function definitions, and cannot find a way to
+ 6590 [aleksi.nieme] Try this, it barks at me :).
| + 6591 [hipster xs4a] Great, thanks! Maybe some more name mangling to prevent inter-object
| + 6592 [Dave thomase] It used to have the behavior that leading spaces were stripped (and
+ 6595 [matz zetabit] The solution is supplied by Aleksi in [ruby-talk:6590].  And this

^ Short articles for Borders newsletter
6596 [Dave thomase] Borders (the bookstore chain) has asked for a submission about Ruby for
6598 [mjais web.de] Maybe you should also point out, that there is a very
6603 [Dave thomase] Friendly? This lot? Sharks, all of them!  ;-)

^ Question on sort!
6597 [Dave thomase] Someone asked about a strange inconsistency in Rubicon, and I didn't
6599 [matz zetabit] This is very preliminary behavior following
6601 [Dave thomase] Although I see the reason for returning nil on methods such as gsub!,
6604 [matz zetabit] OK, OK.  Let's discuss.
+ 6605 [Dave thomase] There's another way to view consistency: sort and sort! might be
| 6634 [matz zetabit] I don't call it consistency, but I have to admit that returning nil is
+ 6615 [matju cam.or] If a justification is required, i'd say that the no-bang-method-chain rule
| 6616 [Dave thomase] It what way is it different from the various File and IO class methods
| + 6617 [schneik us.i] <Stuff about chaining methods.>
| + 6644 [hgs dmu.ac.u] But we could introduce sub? -- takes same args as sub! but doesn't change
|   6648 [Dave thomase] OK, and that's effectively what Ruby does now. However, that isn't
|   6649 [hgs dmu.ac.u] Its ! ops make the changes, these would not.
+ 6623 [jimm fnord.i] []

^ Net::HTTP example from Ruby Book
6606 [mjais web.de] at work I have written an http-client in Perl and I wanted to do the
+ 6608 [aleksi.nieme] From the page 490, I assume.
+ 6609 [matz zetabit] Unlike get, get2 does not return an array.  So that code should be

^ popen vs. open3 vs. Windows....
6607 [Dave thomase] OK, I'll admit it. I'm spinning my wheels here, and need a clunk on
6610 [aleksi.nieme] Your first example works for W2000.

^ closures (rb vs lisp?)
6619 [peter.wood w] I am trying to figure out how to do closures in Ruby. In CL I can do
+ 6620 [hipster xs4a] list = []
+ 6621 [hipster xs4a] list = []
+ 6622 [yashi yashi.] I guess i'm missing the point.  could you enlighten me why it needs to

^ Hash operators
6624 [rpmohn panix] I know that Hash#- operator is defined (because I use it :-), but I can't
6625 [rpmohn panix] Oops, I forgot that I had actually defined it myself. Sorry.

^ Extending classes
6626 [bombadil wan] I have a little question :)
6627 [yashi yashi.] module Gtk

^ Why is WeakRef#__getobj__ missing from the pickaxe book?
6628 [cjon sapphir] I notice that the discussion of WeakRef from the pickaxe book
6632 [Dave thomase] There are two reasons I can think of, but neither is a show-stopper.
+ 6633 [aleksi.nieme] I don't know much about weak references, but I'd guess you risk losing the
+ 6717 [cjon sapphir] But something like this should be in the WeakRef lib.

^ Best way to convert a string to an array of numbers?
6629 [cjon sapphir] [ 2, 3, 3.5, 5, 1.2 ]
+ 6631 [aleksi.nieme] Cullen J O'Neill asked
+ 6636 [phasis hanan] How about
  6635 [spcoltri hro] Only if you can be sure s is not "2 3 3.5 exit 1.2" :)
  6721 [cjon sapphir] Yeah, this is much better.  Thanks!

^ RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!  (Revised 2000-11-11)
6630 [schneiker ju] RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!  (Revised 2000-11-11)

^ Array Intersect (&) question
6637 [rpmohn panix] I have many uses for the Set Intersection operator on Arrays, but while I
6646 [aleksi.nieme] Ross asked something about widely known and largely ignored language (on
+ 6647 [schneik us.i] # Ross asked something about widely known and largely ignored language (on
| 6701 [steve deaf.o] It'd be good if the code presented in the Recipe of the Day could then
+ 6652 [rpmohn panix] Wow! Much faster than the standard Ruby Array#&. Thanks much (I'll check
  6723 [matju cam.or] I translated the above code into Ruby. If you run the code below, Array#&
  6744 [matz zetabit] Using a hash makes it pretty fast, but it does not preserve the
  + 6747 [aleksi.nieme] I've been in need of "ordered hash" quite often. I've always hacked around,
  + 6752 [rpmohn panix] 1) I certainly would prefer the speed. I never assume that my array is in
  | 6754 [hal9000 hype] Hmm, I can't agree with you on this one. The very term "intersect"
  | 6757 [rpmohn panix] Is it valid (in math) to be intersecting sets that contain duplicates? We
  | 6760 [hal9000 hype] Well, if I were going to apply "intersection," which is a set operator,
  | + 6763 [peter.wood w] I agree with Ross.  Presumably, if you are intersecting "pseudo-sets"
  | | + 6764 [dblack candl] And order is significant, though (not(or(to digress into Lisp)anything))
  | | + 6767 [matz zetabit] Hmm, interesting.
  | |   + 6772 [matju cam.or] If we're implementing Sets using Arrays, yes. There is another formalism
  | |   | 6786 [chr subdimen] some of the examples in this thread are misleading since the elements of the
  | |   + 6800 [rpmohn panix] Yes, (1 2) is definitely the proper intersection in this case. Your
  | + 6771 [matju cam.or] in Array#|, receiver has priority. I adopted the same behaviour in my
  | + 6799 [rpmohn panix] Since this translates to something like a.&(b) I would preserve the order
  + 6755 [green FreeBS] Personally, I feel that a non-ordered &() method would violate the POLS for
  | 6765 [matz zetabit] I think I'm going to re-implement & and | using hash, preserving
  + 6756 [matju cam.or] Oh, I see.
  | 6759 [rpmohn panix] a1 = %w# a b c c c #
  | 6758 [rpmohn panix] Oops, nevermind. I didn't see the "uniq" first time through! -RPM
  + 6761 [c.hintze gmx] for me this would be ok! If I want to rely on order, I would simply
    6762 [dblack candl] I agree.  Even if & and | ignore order, there are still ways to order

^ Ruby & Java
6638 [rpmohn panix] My team seems to have their hearts set on doing a Java project next, though
6640 [Dave thomase] Could you give us some idea of the project? Perhaps we can help you

^ Hash with a key of nil ?
6642 [rpmohn panix] While reading data in from a file and populating a hash, I accidentally
6643 [Dave thomase] Perhaps the alternative questions might be: should you always be able
+ 6645 [rpmohn panix] I guess so, but I don't know if I'm convinced yet. Maybe it's just that I'm
+ 6657 [matz zetabit] It did.  But I consder it was a bug.

^ each/for binding confusion and resolution
6653 [grady scam.x] As I am still learning the language, I am hitting things which are
+ 6670 [hipster xs4a] -> [2,2]
+ 6671 [c.hintze gmx] Yes and no! The 'problem' with for vs. each is very easy to
  6680 [grady scam.x] The other overhead is the binding look-up every time through the loop.
  6681 [grady scam.x] Interesting.
  6697 [hipster xs4a] In the Hacker's Dictionary interpretation, I presume?   :)

^ printing/accessing arrays and hashes
6656 [raja cs.indi] I'm coming to Ruby with a Python & Common Lisp background.
+ 6658 [Dave thomase] #inspect returns a String representation of the array or hash
+ 6659 [raja cs.indi] I answer to part of my earlier post I've come up with the following using
| + 6660 [dblack candl] (See Dave's remarks on #inspect.)
| + 6661 [phasis hanan] class Array
| + 6662 [Dave thomase] If you don't want to use inspect, you could rewrite the above slightly
+ 6664 [raja cs.indi] Thanks to all for the pointer to #inspect and the behavior of #join in Ruby.
  + 6665 [Dave thomase] Actually, what happens is that when you concatenate something to an
  | + 6672 [hal9000 hype] That's interesting, Dave. Is the behavior of << the same? Because I
  | | 6676 [Dave thomase] It works the same way.
  | + 6678 [raja cs.indi] aha!  So it's not really #joins behavior but that of concatenation (akin to
  |   + 6683 [hgs dmu.ac.u] irb(main):001:0> print ( { "a" => "b" } )
  |   + 6684 [cjon sapphir] The problem with showing structure in join seems to me to be that
  |   + 6768 [matz zetabit] Probably Hash#fetch equivalent for Array is good answer.  What do you
  |     + 6769 [Dave thomase] at (for the Smalltalkers out there).
  |     | + 6774 [matz zetabit] Ruby already has Array#at which only gives an element, not a
  |     | | + 6775 [matz zetabit] Sorry, It was live only. not archived.
  |     | | + 6781 [Dave thomase] Yeah - I was thinking of extending it to accept ranges and/or a length
  |     | + 6776 [matju cam.or] I think that for the SmallTalkers out there, it will be called "fetch",
  |     |   6782 [Dave thomase] Which brings up a point I raise every now and then.
  |     |   + 6803 [hgs dmu.ac.u] I've wondered what the thing called "miniruby" (which is
  |     |   + 6808 [matju cam.or] I agree 100%.
  |     + 6785 [cjon sapphir] You could require || after the opening { for blocks, that would make
  + 6686 [matz zetabit] My short comment.  'inspect' is for human readable representation.  So
    6705 [aleksi.nieme] I'd love to see inspecting to have some warp on it's evolution. Basically
    6741 [hipster xs4a] Just an idea: introduce a Visitor pattern. The default implementation

^ Suggestion for addition to Begin/End syntax
6666 [drew localho] I'm very new to Ruby so this might be a bit of a shot in the dark,
+ 6667 [yashi yashi.] if end modifier(??) is optional how about
| + 6668 [grady scam.x] On a similar note, has the possibility of using more traditional
| | 6685 [matz zetabit] Yes.  Somewhere around 0.60, almost 6 years ago.  Braces did not fit
| + 6674 [drew localho] Well, _Ideally_ it would help the interpreter provide more usefull
|   + 6675 [hipster xs4a] I don't mean to be harsh, but adding syntactic sugar isn't going to
|   + 6688 [matz zetabit] The another reason I removed modifiers was that auto indentation of
+ 6673 [hal9000 hype] See below.
+ 6687 [matz zetabit] It used to, before version 0.60.  It was removed for control
  6698 [fit0298 fite] At last, "suffixed for" is... ??
  6711 [matz zetabit] Do you mean you want it?  Like Perl?
  6736 [fit0298 fite] Now, I don't want it. I like to use each method.

^ 
6669 [aamer and-or] unsubscribe

^ GTK on Win
6677 [mvesely sci.] My question is this: I like to use Gtk  on Windows. What everything I
6679 [hipster xs4a] Martin, could you please adjust your MUA not to send these weird

^ behavior of Proc#arity?
6682 [grady scam.x] I was looking at the library reference, and I have to say I'm confused
6712 [matz zetabit] They accept any number of arguments without causing error, thus their
6714 [grady scam.x] Ah.  That would certainly explain the behavior of Proc#arity (and
+ 6719 [matju cam.or] a = [1]   #=> [1]
| 6726 [grady scam.x] (Thanks for the pointer to the previous thread -- unfortunately,
+ 6743 [matz zetabit] Hmm, let me think about this for a while.
  6746 [ms iastate.e] a,b,c = 1,2,3    # a=1; b=2; c=3
  6766 [matz zetabit] What do you suppose the value of `a' after `a=1,2'?
  + 6770 [dblack candl] a,b = 1,2,3  # a==1, b==[2,3]
  | 6773 [matz zetabit] This should be
  | + 6777 [dblack candl] Wow -- what's it like? :-)
  | + 6779 [ms iastate.e] Sorry, I missed intervening messages in this thread before posting my
  |   6784 [dblack candl] Yes, me too -- mainly I was just musing on the fact that not every
  + 6778 [ms iastate.e] This illustrates how a Principle Of No Surprise language would be

^ MAKE REAL MONEY
6689 [dred010 home] ...

^ Syntax highlighting in XEmacs
6690 [ntalbott rol] For starters, I'm running XEmacs 21.1 on Windows 2000. I'm more new to emacs
+ 6691 [jweirich one] I get green strings and red comments.  But that's it.  Syntax
| 6692 [ntalbott rol] I was afraid you were going to say that. At least I don't feel left out any
+ 6693 [Dave thomase] The problem is that the ruby-mode.el file checks for the presence of
  6694 [schneik us.i] #
  + 6696 [hipster xs4a] Yes, the FAQ should be updated. Mirko Nasato and I--unknowingly of
  | 6709 [matz zetabit] I'm back from the conference.
  | 6740 [hipster xs4a] The ruby.vim syntax highlighting entry. It's obsolete.
  | 6812 [schneik us.i] Well, my expectation that syntax colored HTML pages of program code would
  | 6813 [aleksi.nieme] Producing output like
  | 6815 [jweirich one] Source2html only does HTML write now, and only uses bold/italics for
  | 6839 [jweirich one] In Version 0.9.3 the HTML code emitted for keywords and comments is
  + 6699 [hgs dmu.ac.u] About a quarter of males are red-green colour blind. (In Western
    6702 [peter.wood w] Fortunately, I don't think it's _possible_ to go down that route :-)
    6706 [schneik us.i] #
    6708 [aleksi.nieme] Before we (you :) delve into lengthy discussion, I'd like to note couple of

^ Re: Syntax highlighting in XEmacs [LARGE]
6695 [Dave thomase] Luddite ;-)

^ Problem executing gnobrows.rb
6700 [bombadil wan] I get an error executing example gnobrows.rb, distributed with Gnome
6780 [yashi yashi.] current gnome/ruby implicitly expect you to have imlib extension,

^ dump format error with recent snapshots
6704 [feldt ce.cha] Recent snapshots has started to "break" some of my older Ruby code. The
6710 [matz zetabit] I've never merged md5 dump patch yet.  Probably you applied the patch

^ Ruby and Emacs (was: Re: [...])
6707 [hgs dmu.ac.u] I had the feeling that Ruby inherited _some_ ideas from lisp.
+ 6716 [perin panix.] Not, I suspect, if the Ruby code were the output of a machine
| 6801 [hgs dmu.ac.u] I meant for the code that the user of Emacs adds, to tune it.
+ 6724 [dblack candl] Practical, I don't think so.  Really difficult, definitely :-)
| 6802 [hgs dmu.ac.u] That is why I thought it might be possible...
| 6804 [dblack candl] I said elisp, not Lisp :-)
+ 6809 [joe vpop.net] does it.  He links perl into emacs.  Here is part of the
threads.html
top