| _rui | optparse |
| kuja | it could be that optparse is removing the entry from ARGV try writing a small test script to verify that is the case a script that simply does a p ARGV ruby -e 'p ARGV' -f file err you gotta put that script in a file -e apparently doesn't allow ARGV |
| _rui | yes, its optparse :-\ thanks kuja |
| kuja | np |
| weirdo | heya i noticed that undeclared variable access errors are detected at runtime. can i somehow detect them at compile-time? |
| kuja | no |
| weirdo | :/ |
| kuja | because methods and variables can be defined dynamically. |
| Arsen7 | weirdo: There is no compile-time in ruby, at least not distinct from run-time. |
| zorglu_ | q. in ruby, do i have to handle the window/unix path difference myself, or ruby does it transparantly ? here i talk about difference like on window "my\path" while in linux "/my/path"? |
| weirdo | are there any plans for introducing the all-powerful goto instruction? |
| kuja | zorglu_: Using / will work in all cases |
| zorglu_ | kuja: great :) thanks |
| kuja | np weirdo: There is try/catch er throw/catch |
| weirdo | is inject() the same as lisp's REDUCE? |
| Arsen7 | I suppose you should ask on #lisp-lang ;-)))) |
| shevy | or explain what lisp's reduce does |
| ehird | is the ruby version number in a variable? i only want two digits i.e. 1.8 (that is, what's used in $PREFIX/lib/ruby/ paths) |
| kuja | RUBY_VERSION work with it to your needs. |
| ehird | ruby -e'puts RUBY_VERSION.split(".")[0..-2].join(".")' <-- heh |
| kuja | heh RUBY_VERSION[0...-2] |
| ehird | RUBY_VERSION is an array? |
| kuja | No, it's a string. |
| shevy | ruby -e'puts RUBY_VERSION[0..-3]' |
| ehird | ah, right... what if ruby 1.34.2 comes out |
| shevy | or 1.92.14 |