19272-20082

19093-19705 subjects 19524-20365

^ [META] Who kills the References?
19272 [stesch no-sp] It's a bit hard to read comp.lang.ruby. Some programs (the mail
+ 19340 [mikkelj-anti] I agree - this is kind of frustrating to see that somebody replied to a post
| 19411 [tsyk yk.rim.] I strongly agree too.  This inconvenience makes thousands of
+ 19365 [in6x059 publ] Some mail clients do not set the In-Reply-To- and References-Header
+ 19409 [stesch no-sp] I don't think so.

^ PATCH: fixed bug in "waitfor" in net/telnet.rb
19282 [ljz asfast.c] I'm using the Net::Telnet module and I'm quite
19293 [tobiasreif p] Lloyd,
19308 [ljz asfast.c] I'll take a look at it if I have some time soon, but
19372 [tobiasreif p] Lloyd
19415 [ljz asfast.c] Please post the program in which it happens frequently, if
19416 [tobiasreif p] Lloyd;
19419 [aamine mx.ed] ~/r/net $ unset RUBYLIB
19423 [tobiasreif p] ruby -rsocket -e 'TCPSocket.open(nil,80)'
19426 [aamine mx.ed] Hmmm... still I do not sure why your script hang.
19428 [tobiasreif p] Minero (or "Aoki"?),

^ Help with ternary operator syntax and grammar
19283 [furufuru ccs] I'm fairly new to Ruby and writing small scripts with the pickaxe
+ 19284 [decoux moulo] ruby interpret cond? as the method #cond?
+ 19285 [hipster xs4a] insert a space here. Otherwise Ruby will interpret it as a call to the
+ 19286 [dblack candl] You need a space between cond and '?', because it's possible for there
+ 19287 [chris atdesk] Ruby allows ? to be part of identifiers.  (In fact, it's standard
+ 19341 [furufuru ccs] Thank you all who responded!  Your explanations almost solved the
  + 19345 [decoux moulo] This is changed in ruby-1.7.*
  + 19356 [r2d2 acc.umu] There is a third example to consider
  + 19478 [furufuru ccs] Thank you for the clear explanation!  I understand the problem.

^ ParseDate questions.
19290 [hgs dmu.ac.u] Has anyone any examples of using ParseDate?

^ Lapidary GTK?
19291 [chadfowler y] Before I spend anymore time on it, is there anyone who
+ 19292 [jjthrash pob] I've gotten it working in Linux, but have since abandoned using it.
+ 19327 [ntalbott rol] actual release. I know the version in CVS works, if you want to try

^ Speaking of the ternary operator....
19297 [dblack candl] I seem to remember at one point someone saying that the ternary
19299 [dtillman oza] It isn't very pretty.  However; I do use it quite a bit
+ 19300 [neumann s-di] x = args[1]
| 19304 [dtillman oza] @border = x.fetch(H_border, 0)
+ 19303 [dblack candl] @border = if args[1].include?(H_border) then args[1][H_border] else 0 end
  19305 [dtillman oza] <various snippage>
  19361 [furufuru ccs] Personally I would miss it!  To me this

^ Virtual list
19306 [elanthis use] For starts, I'm new to Ruby still, forgive me naivette.  (Is that even a word?)
19309 [r2d2 acc.umu] I am not entirely sure I understand you, but to me it seems as if you are
+ 19312 [elanthis use] Got that part.  ^,^
+ 19344 [ljohnson res] It sounds like your C++ extension module needs to define at least the

^ Curses patch
19307 [wolfgang pro] I made a tiny but useful enhancement of the curses module. Attached is
19319 [ttate jaist.] I've maintained another curses extension which supports terminal

^ how to "die" in Ruby
19310 [info mjais.d] in Perl I can write
+ 19314 [Dave Pragmat] I think I'd be tempted to restructure just slightly to make the error
+ 19315 [matz ruby-la] The shortest way is

^ how to redirect $sdtout
19311 [info mjais.d] I am just trying to convert some perl cookbook examples
19318 [dblack candl] You don't like #puts? :-)
+ 19337 [chris atdesk] This works for me...
+ 19366 [jweirich one] This is something I've done in the past ...

^ Problems with UDP on Windows
19320 [nat.pryce b1] This is a multi-part message in MIME format.

^ code improvement (was:Re:  Re: ANN: Code Amelioration Contest (presented by  Ruby Conference 2001))
19321 [dblack candl] "Amelioration" is just the (somewhat whimsical) name of the contest --
19360 [tobiasreif p] My suggestions where directly aimed at the contest, the contest in
+ 19373 [dblack candl] s/specifically/exclusively/ :-)
+ 19375 [gc mandrakes] Be careful, there are already many projects that labelled themselves "Ruby

^ timeout blocks
19322 [joe vpop.net] I have a bit of a chicken and egg problem here.  I want to use timeout
19323 [dblack candl] s = nil
+ 19324 [joe vpop.net] It sure did!
+ 19397 [chadfowler y] Good point, but also:  Why would you want the messed

^ WIN32OLE
19326 [aleksei.guze] ev.on_event {|*args| default_handler(*args)}
19328 [Dave Pragmat] Have a look at line 11 of the same file
19350 [aleksei.guze] Assigning to a constant???????????!!!!!!!!!!!!!
19352 [Dave Pragmat] A constant's name starts with an upper case letter. $LOOP starts with
19354 [aleksei.guze] Are there global constants and how they are distinguished from locals?
19376 [Dave Pragmat] C1 = 99
19399 [aleksei.guze] Thus having local constant there is no way to access global one of the
19400 [decoux moulo] pigeon% ruby -e 'C2 = 99; class Dave; C2 = 101; p ::C2; end'
19401 [aleksei.guze] Then what is "$" symbol for???
19402 [decoux moulo] global variable (to simplify).
19403 [aleksei.guze] irb(main):001:0> C1 = 5
19404 [decoux moulo] re-read carefully the last phrase of [ruby-talk:19376] :-)
19405 [aleksei.guze] But every line of code seems residing inside a method body. Where could
19406 [decoux moulo] At the beginning of a class
19408 [aleksei.guze] # -----Original Message-----
19410 [decoux moulo] class A

^ Re: Perl/Python/Ruby common backend (Parrot, can
19334 [ptkwt shell1] I understand.  I don't like going back and looking at my Perl code anymore
+ 19348 [thegrandbrie] calypso \Ca*lyp"so\ (k[.a]*l[i^]p"s[-o]), n. [The Latinized Greek name of a
+ 19384 [ptkwt shell1] Oh, I thought that maybe Matz was working on a new Ruby backend codenamed

^ Re: redirecting stdout, stderr from
19336 [mikkelj-anti] The last.

^ Bug in raising RuntimeError?
19355 [   ml sph.de] Now that we talking about some assertive programming here,
19359 [decoux moulo] A message like this seems OK for you ?
19367 [   ml sph.de] Also las ich bei ts [mailto:decoux@moulon.inra.fr]

^ having to add '\r' for Microsoft hosted telnet daemon (RE: [ruby-
19374 [cbroult sapi] This message is in MIME format. Since your mail reader does not understand

^ preemption
19377 [wys helbling] Looks like Ruby (ruby 1.7.1 (2001-08-06) [i686-cygwin]) does not preemt
+ 19378 [decoux moulo] cygwin bug apparently
+ 19380 [Dave Pragmat] I've reported the same thing in the Rubicon tests. Something seems to
  19382 [WYS helbling] Under "pure cygwin" (i.e.: using the cywin-shell and running a ruby(.exe)

^ unsubcribe
19379 [frusti gmx.a] Aufgepasst - jetzt viele 1&1 New WebHosting Pakete ohne

^ Date handling.
19381 [hgs dmu.ac.u] For reading in dates we have parsedate.  This will cope

^ Not Echo On Gets
19386 [coder oxgoad] I ask to use TCPServer and prompt "Password: " and

^ Ruby and Apache on Windoze
19394 [mikepence ya] I feel incredibly stupid asking this, but how do you configure Apache

^ XPath...
19398 [sean-ruby-ta] Does anyone know of an XPath library for Ruby?  I dug through
19407 [info mjais.d] there is a new XSLT4R, which also mentions XPATH.
19414 [armin approx] Also look at xmlscan. (xpath.rb)
19470 [unnie blue.s] The latest version of xmlscan is 0.0.10 and you can download it from

^ Re: having to add '\r' for Microsoft hosted telnet daemon (RE: [ruby- talk:19308] Re: PATCH: fixed bug in "waitfor" in net/telnet.rb)
19412 [ljz asfast.c] I didn't see that particular '\r' problem in the current (ruby-1.6.4)

^ Setting $_ for the current scope
19413 [buter CWTS.L] Does Ruby have an syntactical sweetness to set $_ for a specific (aka
19417 [decoux moulo] What do you call current scope ?
19418 [buter CWTS.L] By local I meant block-local, e.g.
+ 19421 [Dave Pragmat] Possibly the Ruby case statement might help :)
| + 19424 [dblack candl] I think Renald wanted the possibility of more than one statement
| + 19425 [Dave Pragmat] Oops - sorry - I missed the part in your post about fall-through.
|   19430 [buter CWTS.L] Ah. I see. I hadn't thought of this one. Thank you.
+ 19583 [pdcawley ite] Nope, it's not block local.

^ Test
19420 [Dave Pragmat] ML
+ 19422 [Dave Pragmat] ML 2
| 19432 [Dave Pragmat] NG
+ 19433 [Dave Pragmat] NG
  19434 [green FreeBS] Probably because it would hopefully catch all the "subscribe" and

^ Simple Question
19427 [SAT MULTITEC] This message is in MIME format. Since your mail reader does not understand
+ 19429 [decoux moulo] b( *a )
+ 19431 [jonas.bulow ] irb(main):001:0> def f(a,b,c)

^ Simple Question 2
19435 [SAT MULTITEC] This message is in MIME format. Since your mail reader does not understand
+ 19436 [Pierre-Charl] String#hex does what you want. String#oct also exists for octal values.
+ 19437 [decoux moulo] #oct do this
+ 19438 [Dave Pragmat] "0xF0".hex
+ 19457 [harryo zip.c] It's an interesting point, though, in that you have to know, in advance,
  19469 [green FreeBS] Try Integer() :)  I don't use String#to_i much since Integer() actually

^ Test 2
19439 [Dave Pragmat] Very sorry about all this

^ Ruby Book online
19440 [SAT MULTITEC] This message is in MIME format. Since your mail reader does not understand
+ 19441 [Dave Pragmat] There's a Windows help version that I'd guess is searchable. You could
| 19459 [harryo zip.c] Would it be possible to get a simple text or HTML version of the index as
| 19471 [Dave Pragmat] Not easily - I'd have to emulate LaTeX index processing to get the
+ 19442 [ned bike-nom] Or sign up for one of the "free search" services and make a local search page.

^ eruby syntax file for vim?
19443 [stesch no-sp] Is there any eruby syntax file for vim? Similar to the phtml and

^ question about ::
19444 [jobeicus hot] class Foo
+ 19445 [cbroult sapi] This message is in MIME format. Since your mail reader does not understand
+ 19454 [jobeicus hot] def Foo::test()
+ 19455 [chris atdesk] Assuming from your other post that you declared it Foo.test(), then

^ Help! I'm still confused about threading in the ML
19446 [Dave Pragmat] I'm trying to track down these various message threading problems, and
+ 19447 [ned bike-nom] It sounds like a user agent or user problem. For all you know, Christophe
| + 19448 [cbroult sapi] This message is in MIME format. Since your mail reader does not understand
| + 19449 [Dave Pragmat] Yup - yours got threaded, Christophe's didn't.
|   19451 [chris.morris] it doesn't do it. I found a few other posts through Gooja of people asking
|   + 19452 [chris.morris] I doubt it ... I browsed around and didn't find anything (but it could be
|   + 19453 [Dave Pragmat] OK - in that case, I suggest that we ask for the mailing list to be
|     + 19474 [dblack candl] I find them useful, and I always find it exasperating when Micros**t
|     | + 19475 [joe vpop.net] You *know* what has to happen don't you?  Someone has to write the
|     | | 19481 [matju sympat] Better yet, separate the model from the view, so that you can slap the GUI
|     | + 19482 [hgs dmu.ac.u] Yes, RFC 2822, section 3.6.4
|     |   19498 [sean-ruby-ta] to
|     |   19502 [sharpd cisco] I just run the incoming messages through this little perl script
|     + 19479 [in6x059 publ] Sadly this problem annoys people on many lists. I often observed it,
|     + 19480 [tsyk yk.rim.] I think problem still exists except for mail/news reader which
|     | + 19485 [Dave Pragmat] Wonderful drawings!
|     | | 19491 [tsyk yk.rim.] No, there isn't.  The issue was gone after your test message
|     | + 19496 [will.sobel B] I have found one work-around (hack around) for this problem. Outlook
|     |   19497 [cbroult sapi] This message is in MIME format. Since your mail reader does not understand
|     + 19488 [sean chitten] I find that the subject thread IDs take up too much space, but=20
+ 19483 [sean-ruby-ta] This has been historically caused by M$ MUAs.  They're famous=20
  19513 [VardhanVarma] can i get a mutt on M$-Win32, which can replace my eudora.

^ Any Outlook expert? (was RE:  Re: Help! I'm stil l confused about threading in the ML)
19450 [cbroult sapi] This message is in MIME format. Since your mail reader does not understand

^ Ruby equivalent of Python's os.path.walk?
19458 [rlipscombe r] Like it says.  Is there one (or a suitable analogue), or do I have to roll
19468 [green FreeBS] I'm not sure exactly what os.path.walk does, but does the find.rb that comes

^ installation errors on win2000
19462 [hubert cs.ny] I have "fortunately" enough to have to try on Ruby on four different
19472 [eban os.rim.] Remove ';'.

^ problem with using Tempfile
19463 [gerry ucar.e] I've written a small script which removes ctrl-M's and an ending

^ RubyUnit: Avoid running setup for every test?
19464 [armin approx] I'm using Rubyunit on code where I would like to have setup executed
+ 19467 [kom mail1.ac] I guess someone call tell you a smarter solution, but maybe
+ 19473 [jweirich one] This is how I do it ...
+ 19484 [masaki.suket] How about RUNIT::EXT::TestSetup?

^ Re: s///eg in ruby
19476 [stesch no-sp] With String#gsub!

^ Gnus and [ruby-talk:xxxx] (was Re: [META] Who kills the References?)
19493 [sascha meta-] (setq gnus-list-identifiers '("\\[ruby-talk:[0-9]+\\]"))

^ Re: Gnus and [ruby-talk:xxxx] (was Re: [META] Who kills the
19495 [dtillman oza] * ^X-ML-Name.*ruby-talk

^ Ruby running as an NT service
19499 [clem well.co] I'm looking to install a Ruby script on several Windows systems.  I'd

^ Ruby running as an NT service
19500 [clem well.co] I'm looking to install a Ruby script on several Windows systems.  I'd
19503 [ms iastate.e] Tim
19505 [hotfusionman] I'm not a real Windows person either, but on NT and 2000 there is a utility in

^ Threading Problem
19501 [elbows spamc] x = ""
19521 [decoux moulo] Try to add
19619 [sascha meta-] You can set $stdout to flush automagically by setting it's sync state

^ ruby-python, vpython or 3D in Ruby
19504 [james lazyat] I'm a recent convert to ruby and python... I'd really like to focus on
19515 [mikkelj-anti] Not sure how easy, but FxRuby using the crossplatform Fox toolkit also
19537 [james lazyat] FXRuby certainly gets the 3D done, but it's nowhere near as simple of

^ the way class variables work
19506 [dblack candl] I've been puzzling over Ruby's treatment of class variables -- not so
+ 19507 [tobiasreif p] This is weird! I really would appreciate enlightening explanations
+ 19509 [ jimm io.com] Let me try. The key is that classes are objects too, and they have their
| 19512 [dblack candl] But creating a new class does create a new instance of class Class.
| + 19514 [mikkelj-anti] Initially, this was also my thought.
| | + 19516 [tobiasreif p] It seems as if subclasses just extend their parentclasses, but are no
| | | 19520 [dblack candl] That's the thing, though: subclasses *are* classes themselves.  If
| | + 19522 [dblack candl] That's true, but that power is parceled out in sync with certain
| + 19523 [decoux moulo] pigeon% cat b.rb
+ 19510 [nat.pryce b1] This makes sense to me.  @@tyres is defined as a class variable of Vehicle.
+ 19511 [chris atdesk] You bring up some good questions, which leads to only more questions.
+ 19518 [tobiasreif p] 5. para of
+ 19525 [jweirich one] [... example elided ...]
| + 19526 [mikkelj-anti] I was thinking about the C++ analogy as well. But it doesn't hold.
| | 19538 [jweirich one] Actually, it does.  You can hide it by declaring another variable in a
| | 19542 [mikkelj-anti] Of course you are right - I've been depending on this fact many times when
| + 19528 [dblack candl] Yes, it does, along with some of the other responses and some irc
|   + 19529 [tobiasreif p] Maaaatz!... heeelp!... where aaare youuuu ...
|   + 19530 [decoux moulo] This will probably not reply to your question, but initially they were
|   | 19532 [tobiasreif p] Maybe they can be called "family variables", because they are shared by
|   + 19544 [matju sympat] It's way easier to explain why "class variables" exist than to explain why
|   + 19547 [ptkwt shell1] It is kind of troubling, however, as I thought about it, in practice it
+ 19535 [matz ruby-la] Class variables are to share value among classes/modules and its

^ This is cool!
19508 [Dave Pragmat] Have a look at http://www.rubygarden.org/article.php?sid=80 to see
19680 [stesch no-sp] Look at it now: http://bocks.dhs.org/~pizman/myri/
19693 [Dave Pragmat] It will be added to the contrib directory on the next release of ri.
19776 [aaron.barnet] nice.  had to have me a web version -> http://outerbody.com/ruby/  its a day

^ Why not?: Assigning to self
19517 [furufuru ccs] class Array
19519 [gotoken notw] You can use "replace(res)" instead of "self = res".
19670 [furufuru ccs] Thank you for the answer!  That solves my current problem.
+ 19673 [matz ruby-la] Assignments in Ruby is changing reference.  There's no copy in
| + 19749 [furufuru ccs] Thanks for pointing that out here!  In fact I knew that, but my
| + 20082 [furufuru ccs] Thanks for pointing that out here!  In fact I knew that, but my
|   19754 [matz ruby-la] Yes.  There's no such thing like "reference (in C++)" in Ruby.  I
+ 19689 [ronjeffries ] As matz points out, assignment means reference. So we might have
  19694 [ned bike-nom] matju recently posted a 16 line patch that implements Object.become. It works
  19695 [decoux moulo] If you want to make reference to [ruby-talk:19575]
  19696 [ned bike-nom] Wouldn't a fixed version of this be useful? Are there any problems that you
  19697 [decoux moulo] To do what ?
  19700 [ned bike-nom] There was a discussion earlier here about the usefulness of become: . One
  19701 [decoux moulo] I've read this discussion
  19703 [ned bike-nom] What you showed there appears to be a problem with the implementation that
  + 19704 [decoux moulo] Personnaly I don't see the utility to change the class of an object from
  | 19708 [ned bike-nom] This is why become() is better than providing an arbitrary ability to change
  | + 19709 [decoux moulo] pigeon% ruby -e 'p Class < Object; p Array < Object'
  | | 19713 [ned bike-nom] I should have said "supertype". Clearly, if you swap a Class for an Array,
  | | + 19750 [matz ruby-la] Unfortunately, many internal assume the type (or class) of internal
  | | | 19819 [ned bike-nom] That's interesting. Doesn't this change the class of a?
  | | | 19852 [matz ruby-la] Ah, yes.
  | | | 19857 [fgp phlo.org] So, are there only problems when objects of class "class" are involved (you
  | | | + 19858 [matz ruby-la] I'm not sure.  Replacing ARGV, etc. might be problem.
  | | | | 19867 [pit capitain] I just remembered another situation where "become" could be
  | | | | + 19875 [r2d2 acc.umu] This is a somewhat problematic hierarchy. Suppose that the Rectangle has a
  | | | | | 19886 [pit capitain] Why not? In this class hierarchy each square is a (specialized)
  | | | | | + 19890 [Dave Pragmat] If you were to allow that, what is the difference between a Square and
  | | | | | | 19891 [decoux moulo] The advantage is that you have all the informations (type and class) to
  | | | | | + 19939 [spwhite char] That would mean that #set_shape in Square would have to handle all the
  | | | | + 19878 [matz ruby-la] I feel you're relying too much on inheritance hierarchy.  In Ruby,
  | | | | | 19883 [Erwan.David ] Well that's seems not to me inheritance for me, but definition by
  | | | | | 19887 [pit capitain] Searching the web for something like rectangle/become/square I
  | | | | | 19889 [tobiasreif p] template object rectangle isa shape;
  | | | | | 19894 [pit capitain] Too bad they don't implement Square... Do you know a link where
  | | | | | 19899 [tobiasreif p] No; I'm sure it would look alike.
  | | | | + 19888 [hipster xs4a] The C++ FAQ discusses an identical inheritance problem: circle
  | | | |   19893 [pit capitain] Thanks for the link. It clearly shows the conflict between the
  | | | |   + 19896 [lcb134 psu.e] Perhaps it is only because of the example used, but couldn't #become really
  | | | |   + 19897 [Dave Pragmat] I still don't see this. There's no difference between your two classes
  | | | |     19901 [pdcawley ite] Once again, I point at my 'state machine' example as an instance where
  | | | |     19903 [r2d2 acc.umu] My 2c.
  | | | |     19914 [pit capitain] one last reply to several messages concerning the rectangle /
  | | | |     19915 [pit capitain] Sorry, I just noticed that there are some formatting codes in my
  | | | + 19880 [decoux moulo] No, you can have a similar problem with T_DATA
  | | |   19917 [fgp phlo.org] Sorry, if this is a stupid FAQ - feel free to tell me to RTFM...
  | | |   19931 [decoux moulo] User type, nobody know what it contains except the author of the
  | | + 19761 [decoux moulo] Even this don't work
  | + 19747 [fgp phlo.org] I can think of an persistent object store, where objects are loaded
  + 19707 [Dave Pragmat] I think what Guy was saying was that he didn't see any need to do it,
    + 19711 [ned bike-nom] My discussion of archives was in a different context: that of changing
    | + 19751 [matz ruby-la] I've once read the pater titled "become considered harmful", but I
    | | 19856 [pulsar qks.c] is
    | + 19850 [jmichel bore] I came upon  something which is perhaps an exemple  where one might want
    |   19851 [dblack candl] I'd be interested.  I don't know why Ranges are immutable, but
    + 19719 [ptkwt shell1] Also, somebody presented an example of a state machine that would have
threads.html
top