104456-105311

104244-105011 subjects 104643-105844

^ Win32 build fail: "syntax error : separator missing"
104456 [robertm spel] Checked out most recent version of ruby from cvs and tried to build it

^ IP address representation inconsistencies in Socket
104476 [dga lcs.mit.] I'm curious about the "standard" form for representing
104525 [decoux moulo] Dave Thomas has seen this problem and it's now corrected in the CVS

^ My Girlfriend Naked  7348
104477 [leepaterson ] Pictures of my girlfriend poseing naked

^ require "mylibrary" doesn't work in ASP
104484 [ssk chol.nos] I'm trying to write ASP codes in ruby.

^ Writing WEBrick Servlets
104487 [drbrain segm] I've written an article about how to write a WEBrick servlet and posted

^ Is it considered Harmful?
104494 [rohitlodha h] obj.class = MyClass
+ 104495 [sean celsoft] irb(main):002:0> {}.class = Array
| 104498 [drbrain segm] Even if there was a #class=3D for objects, it ranks up there with goto in
| 104499 [rohitlodha h] I knew it was evil, I think it should be norm.
| 104500 [sean celsoft] Good question.  I am personally having trouble thinking of a good reason why a
| + 104502 [gfb tonesoft] It would be nice to have in real life too. Just imagine: you hold an
| | 105311 [onurb xiludo] *I* would ! Try to eat a piece of gold !-)
| + 104517 [rcoder gmail] That's exactly the problem -- by forcing one object into another
| | 104536 [cm leetspeak] Heya,
| | 104544 [surrender_it] in evil.rb (you can find it at rubyforge) you even have Object#become
| | 104549 [jim weirichh] Are there limitations on evil.rb's implementation of become?  How do you
| | + 104558 [sean celsoft] I don't know what crashing he's talking about, really.  I see no reason for
| | | 104564 [decoux moulo] Well, apparently you don't want to look in ruby-talk, nor read the ruby
| | | 104570 [sean celsoft] I know what Ruby does, I just ran my own test.
| | + 104565 [rcoder gmail] The default implementation simply does a check to insure that you're
| | + 104572 [batsman.geo ] evil.rb's Object#become is restricted in several ways, to try to prevent
| + 104526 [decoux moulo] If you think that the possiblity to crash ruby is not a technical reason,
|   104539 [sean celsoft] You're wrong on that.  It wouldn't crash Ruby to change the class of an
|   + 104542 [dave pragpro] Singletons are effectively subclasses of the original.
|   | + 104552 [sean celsoft] class Regexp
|   | | 104557 [dave pragpro] Modules (such as Enumerable) only add methods. Classes also have state.
|   | | + 104561 [decoux moulo] This is worst than this : Enumerable rely on the method #each which is
|   | | | 104569 [sean celsoft] I have to admit when I'm wrong.
|   | | + 104562 [sean celsoft] a.read would do what #read does when it can't read because there's no open
|   | |   104566 [dave pragpro] How does it know there's no open file? Go have a look at the code.
|   | |   104573 [sean celsoft] #define GetOpenFile(obj,fp) rb_io_check_closed((fp) =
|   | + 104559 [ptkwt aracne] I have to admit that I too had to do a double-take when I saw someone
|   | + 104587 [sean celsoft] a = /cat/
|   |   104636 [decoux moulo] Try first to test your patch.
|   |   104646 [sean celsoft] I did; it works fine.
|   |   104663 [decoux moulo] * there is a french word for what you are doing : apprenti-sorcier
|   |   104694 [sean celsoft] I did it, and it worked like I said it could.  I didn't say Matz would accept
|   |   + 104695 [stopsod yaho] The question is, "Are you annoyed that matz didnt want
|   |   | 104697 [msparshatt y] Do you know one of the many things I like about Ruby?
|   |   + 104698 [stopsod yaho] Sean, this is what we think apprenti-sorcier means on
|   |   + 104699 [patrick hexa] I think that #become and #class= are _theoretically_ wrong.  Such a
|   |   | + 104700 [sean celsoft] This is a good question.  In the past, I've wished I could change objects into
|   |   | | + 104701 [patrick hexa] Delegation sounds like the solution here, either hand coded or with
|   |   | | | 104706 [sean celsoft] Well, I think the rule here is: buyer beware.  The only real use for class=
|   |   | | | + 104707 [patrick hexa] a = SomeClass.new
|   |   | | | + 104710 [patrick hexa] Sean,
|   |   | | |   104712 [sean celsoft] Well, in C extensions you have typing, period; you can't get around that.  In
|   |   | | |   104714 [patrick hexa] Classes defined in safe old 'script.rb' files will have to deal with
|   |   | | |   104715 [sean celsoft] Those variables will still exist; all that changes is the class that handles
|   |   | | |   104716 [patrick hexa] If an object of SomeClass becomes a Tempfile (or any other class with
|   |   | | |   104724 [sean celsoft] The class that created the object should have already initialized it.
|   |   | | |   104754 [patrick hexa] Sean,
|   |   | | |   104763 [sean celsoft] I think you're not understanding what class= does.
|   |   | | |   + 104764 [phubuh phubu] I think what Patrick means is that all methods assume that their class's
|   |   | | |   | + 104766 [sean celsoft] #class= can only be called on existing objects, so it can't prevent
|   |   | | |   | | 104767 [halostatue g] foo = Object.new
|   |   | | |   | | + 104769 [sean celsoft] Safely, yes.  Usefully, no.  Tempfile can't do much with just an Object
|   |   | | |   | | | + 104772 [phubuh phubu] evil.rb implements #become without traversing the entire set of live
|   |   | | |   | | | | 104773 [sean celsoft] You can't do that with #class= either.  You can only call #class= on objects
|   |   | | |   | | | | + 104775 [hal9000 hype] You're missing his point.
|   |   | | |   | | | | | 104782 [sean celsoft] Ah...I see why I haven't connected with that issue now.  I think of this as a
|   |   | | |   | | | | | + 104815 [gsinclair so] No it wouldn't.  Objects are supposed to represent data and behaviour.
|   |   | | |   | | | | | | 104817 [sean celsoft] I realized my error regarding #become after reading another post.
|   |   | | |   | | | | | + 104820 [patrick hexa] Sean,
|   |   | | |   | | | | |   104822 [sean celsoft] There are two problems with #class= that I was talking about, not just one.
|   |   | | |   | | | | + 104776 [phubuh phubu] By "whose #initialize", I meant "whose current class's #initialize".
|   |   | | |   | | | + 104777 [halostatue g] No, it wouldn't work safely, and your protestations to the contrary
|   |   | | |   | | | | 104784 [sean celsoft] Okay, I think I understand #become now.  The object is COMPLETELY replaced by
|   |   | | |   | | | + 104814 [gsinclair so] module SocketLogger
|   |   | | |   | | + 104771 [sean celsoft] Do me a favor.  I don't insert personal attacks here towards you during these
|   |   | | |   | + 104780 [flgr ccan.de] There's already Object#allocate which creates an Object without
|   |   | | |   + 104779 [rohitlodha h] I think Class and Modules in Ruby differ here. Modules are just set of
|   |   | | + 104719 [halostatue g] I think that Matz is going to provide a much better facility for this
|   |   | | | 104720 [gsinclair so] That sounds about right to me.  Aren't there two separate issues here?
|   |   | | | + 104722 [patrick hexa] Gavin,
|   |   | | | + 104725 [sean celsoft] That's funny, because the first one makes immediate sense to me, but I'm not
|   |   | | | | 104729 [gsinclair so] No, the object x points to is discarded and x points to y instead.
|   |   | | | | + 104734 [surrender_it] I think that #become is useful in ST even for changing a fixed size
|   |   | | | | + 104761 [sean celsoft] In that case, #become sounds like a better way to get pretty much the same
|   |   | | | + 104781 [flgr ccan.de] Does it have any use in real world code? I don't know. If anybody has an
|   |   | | + 104732 [horacio.lope] This particular example you propose with files can be done with
|   |   | |   + 104735 [surrender_it] Withouth the need to use AspectR, there is a wonderful trick from
|   |   | |   | 104736 [horacio.lope] Well, the "cleaner" part of that, is AOP as well
|   |   | |   + 104760 [sean celsoft] You can actually do it similarly by simply replacing methods you want to
|   |   | + 104711 [batsman.geo ] The Object#become in evil.rb does what you call #replace_self (AFAIK
|   |   |   104718 [patrick hexa] Mauricio,
|   |   + 104731 [decoux moulo] no comment
|   + 104543 [decoux moulo] Just search in http://www.ruby-talk.org/
|   | 104553 [sean celsoft] No I haven't.  That has no bearing on whether or not you can change an
|   + 104546 [billk cts.co] Supposed an object's class were changed to a different class
|   | + 104547 [decoux moulo] It's always ruby fault when it crash with a .rb file
|   | | 104550 [rcoder gmail] It's usually Ruby's fault, except for the fact that you can, in "pure
|   | | 104554 [decoux moulo] If you use a module like DL, it's not for me "pure ruby" code.
|   | | 104568 [rcoder gmail] My point was that DL was already a part of the Ruby standard library,
|   | + 104548 [drbrain segm] Smalltalk's classes are better factored to handle such occurances.
|   | | 104551 [jim weirichh] I found the following paragraph about Squeak Smalltalk interesting.  Most
|   | + 104556 [sean celsoft] No code should "expect" data to be there that isn't.  If a C extension wraps a
|   |   + 104571 [rcoder gmail] I agree with you about it being sloppy programming, but then again,
|   |   | 104574 [sean celsoft] I was actually speaking of Ruby C code, not so much Ruby script code.  Ruby
|   |   | 104577 [rcoder gmail] The point of this whole thread, though, is that adding #become and
|   |   | 104578 [sean celsoft] No, changing an object's class wouldn't cause Ruby code to be as prone to
|   |   + 104600 [billk cts.co] No ambulator should "expect" the rug to remain steady
|   |     104604 [sean celsoft] You can if it's nailed down.  You don't if it's a throw run with a rope tied
|   + 104567 [batsman.geo ] Yes it will, in the current implementation.
+ 104496 [quixoticsyco] I don't know -- is NoMethodError considered harmful? :)
+ 104533 [srubin fsisy] I can't possibly imagine it being useful to do this except when the
  104535 [jim weirichh] The "standard" application for the self.class= method (aka become(class))
  + 104537 [ahoward noaa] sounds like an RCR for Object#tie
  | 104541 [sean celsoft] Or class=.
  + 104540 [sean celsoft] I don't think it would be difficult at all.  In fact, think of what Ruby has
  | 104545 [decoux moulo] You are right, a C extension can effectively crash ruby
  | 104555 [sean celsoft] You can do all sorts of things with Ruby, I see no reason why changing an
  | 104590 [cc1 cec.wust] All of those places that you can assume the underlying datatype hasn't
  | + 104591 [sean celsoft] Actually, the comparison is a function call that mostly just checks a bit
  | + 104594 [sean celsoft] Ran some tests.  Ran this Ruby code, which causes the check to occur 100,000
  |   104634 [jean_hugues_] There is a theory that says that the speed of a language
  + 104582 [flgr ccan.de] There are operations which can't be forwarded. I can only think of the
    104586 [jim weirichh] Comparisons are problematic because the first line of a comparison is
    104593 [flgr ccan.de] It depends -- the answer to that question can be overloaded in most
    104595 [phubuh phubu] How about changing the object to a redirection pointer, and also
    104635 [jean_hugues_] OTOH you don't want to make a slow thing even slower and it

^ Building Ruby on AIX -- again
104501 [matt technor] I finally have a stable system to use to try to build Ruby.  Here's the
104510 [nobu.nokada ] What version of ruby?
104511 [matt technor] 1.8.1
104512 [nobu.nokada ] 2003-12-25, official release?
104513 [matt technor] Ok, I'm an idiot.  I needed to install the bos.adt.* packages.  Hopefully
+ 104515 [nobu.nokada ] Seems like iconv library doesn't get installed.  Show the
+ 104516 [matt technor] And the fix is shown in
  + 104519 [matt technor] I'm making progress.  Now socket isn't being built.  Here's an excerpt
  + 104520 [nobu.nokada ] It's the wrong workaround.
    104521 [matt technor] ]/usr/src/ruby-1.8.1/ext/iconv>cat mkmf.log
    104530 [nobu.nokada ] Ok, same as [ruby-talk:104519].
    104575 [matt technor] That patch worked perfectly.  I've been trying to stay with the current
    104617 [nobu.nokada ] 1.8.2 preview will be released soon, perhaps.
    104623 [matt technor] I double checked the patch.  Then I deleted the entire source directory
    104624 [nobu.nokada ] Sorry, TRY_LINK variable hasn't been exported.  Apply this
    104625 [matt technor] have_library: checking for t_open() in -lnsl... -------------------- no
    104628 [nobu.nokada ] Sounds like that something isn't installed properly.  Can you
    104629 [matt technor] Nope, same error.  Finding another prebuilt gcc for AIX 5.2 is going to be

^ Problem with mkmf and spaces in directory names?
104505 [djberg96 hot] Ruby 1.8.1
104509 [nobu.nokada ] It's a known restriction, but... it may be nasty.  Can you try
+ 104531 [djberg96 hot] No luck.  The libpathflag method is never actually reached because the
| 104619 [nobu.nokada ] libpathflag is called from every have_library, via try_link.
| 104630 [nobu.nokada ] This hunk was wrong, and unnecessary.
+ 104605 [djberg96 hot] Wayne Chin was kind enough to point out that you can specify the short

^ YAML custom load: Segmentation faults
104528 [eule space.c] using ruby 1.8.1 (2003-12-25) [i386-mingw32], I get segmentation faults
104529 [decoux moulo] No, it's important.
104534 [eule space.c] I did, but the problem stayed: Then I checked my code and the error was

^ rbconfig / libpathflag is wrong
104532 [quixoticsyco] Just got the latest stable ruby_1_8.  On mingw32 I can't link an

^ [ANN] nfsstore-0.4.0
104563 [Ara.T.Howard] URLS

^ I am confused with Value Type Objects
104576 [ssk chol.nos] In ruby, every object is reference type except for FixNum, NilClass,
+ 104579 [ahoward noaa] only 31 bits.  1 bit is used as a flag to say "this is a ptr to object or it
+ 104580 [batsman.geo ] In Ruby, Fixnums have 31 bits; the missing bit (least significant one)
+ 104581 [msparshatt y] Ruby checks the least significant bit of the value. If this is set then
+ 104583 [ssk chol.nos] Wow, I'm so impressed that within 30 minutes I got 3 answers...:-)
  104584 [batsman.geo ] /* special contants - i.e. non-zero and non-fixnum constants */

^ Blocking SOD in clients
104585 [stopsod yaho] Well, lots of people have been discussing this. Sean
+ 104588 [phubuh phubu] Not to take sides, but I find it quite cowardly of you to post this
+ 104589 [michael.camp] This is best handled at the client.
+ 104592 [surrender_it] Kindness and openness have always been a nice part of the ruby
+ 104596 [lyle.johnson] Your post angers me infinitely more than anything that Sean has posted
| 104597 [ahoward noaa] i've been blocking everyone's posts except my own.  since i've been doing so
| 104598 [sean celsoft] I was wondering why my emails back to you have been bouncing!
+ 104599 [hal9000 hype] This post is inappropriate.
+ 104607 [ptkwt aracne] Where have these discussions taken place among 'lots of people'?
+ 104633 [jean_hugues_] OTOH
+ 104672 [kristof vlee] everybody should be able to post wathever stupid

^ OSCON Ruby tutorials cancelled?
104601 [ptkwt aracne] I just looked on the OSCON website (
104606 [sdate everes] Yes !
+ 104608 [ptkwt aracne] That's too bad.
| + 104618 [sdate everes] Well, that plus the fact that we were pitched opposite Randal L. Schwartz
| + 104632 [surrender_it] just make enough noise this year, like we did in the last two, and we
+ 104611 [mailinglists] Sounds like the EURUKO where only 10 persons announced interest.
  + 104620 [sdate everes] And some changed their minds ;-)
  | 104621 [tom infoethe] If RubyForge stats are any measure, Ruby is certainly continuing to grow
  + 104688 [mneumann nte] Hm, last year we were around 30 people. I guess (or hope) that we'll get
    + 104689 [mailinglists] Our local (Berlin) python user user group gets around 25 persons each
    + 104690 [jamesUNDERBA] Any updates on the pre-reg response for the 2004 Ruby Conf in Virginia?
      + 104728 [god x-nc.net] Where and when in VA?  I live here in the northern VA area and
      | 104745 [lyle.johnson] Joe,
      + 104828 [chadfowler g] It's looking pretty much the same as every year (which is good).  I'd

^ Questions about SWIG, Ruby/DL and embedding calls to ruby within C++ Code
104602 [cc1 cec.wust] Is there any sort of tutorial on calling ruby functions from C++ code?
104603 [lyle.johnson] The latest versions of SWIG (in the 1.3.x development series) provide

^ gems with compiled extensions
104609 [quixoticsyco] Is there a convention for naming a gem with a prebuilt extension?  For

^ ruby-dev summary 23690-23762
104610 [maki rubycol] This is a summary of ruby-dev ML in these days.

^ "attr" like functions
104612 [bg-rubytalk ] I came across an interesting problem today.  Say you wanted to have an
104626 [bitserf gmai] not sure why you're putting a class method in Module, putting it in
104774 [rcoder gmail] Perhaps making Describable a module, rather than class, would be more

^ List of all operators, keywords and such
104613 [Meino.Cramer] where can I get a list of all keywords, operators and such (which
+ 104614 [phubuh phubu] Perhaps Vim's ruby.vim or Emacs' ruby-mode.el would help.
+ 104615 [sdate everes] HTH
| 104662 [NoOne Nowher] Great reference.  Thanks for posting it.
+ 104622 [nobu.nokada ] "keywords" file and op_tbl in parse.y would be most exact.

^ replacement for amavisd
104616 [jm transact.] Spending another day struggling  with amavisd-new has got me thinking
104631 [surrender_it] it is a mail filter, but I don't think it is integrated with amavis..
104816 [jm transact.] Thanks for the link, but I was looking for something that would listen

^ Thank you ! :) Was Re: List of all operators, keywords and such
104627 [Meino.Cramer] Thank you very much much for all help!

^ SQLite-Ruby and "other chrs"
104637 [Meino.Cramer] a problem with "other chars" hits me... :)
+ 104638 [ahoward noaa] fields.map!{|f| f.gsub(%r/'/o, "''")}
+ 104639 [rich lithino] I require the module 'base64' and then encode64 everything that could have
| + 104640 [Meino.Cramer] I dont want to encode64 everything (nearly 3197507 normal chars) to
| + 104641 [Meino.Cramer] I have a string containing a backslash.
|   + 104642 [rich lithino] You could URL encode it...
|   + 104648 [gsinclair so] str.gsub('\\', '')
+ 104644 [behrends cse] Escape single and and double quotes by doubling them, not by preceding
+ 104826 [ahoward noaa] ===============================================================================
| 104832 [surrender_it] I'm not sure you can have a generalized quoting method. Different
| 104848 [ahoward noaa] no, you are right and that's why i've not released this in any real capacity -
| 104849 [jim weirichh] "Beware of bugs in the above code; I have only proved it correct,
+ 104837 [jim weirichh] If you are using the DBI package to access the database, this is handled
threads.html
top