Garrett Goebel wrote:
>
> Brian Ingerson wrote:
> > BTW, I think Inline::Ruby is kind of backwards. Inline.pm helps Perl
> > programmers make use of old legacy C code. Ruby should have an inline
> > facility for making use of old legacy Perl code!
>
> Uh oh...
>
> Will Ruby be a current obsession passing into "yet another tool", or a
> conversion of faith?
Most likely the former. Perl Rocks. And things like CPAN don't just come
out of thin air.
But Ruby is pretty compelling. When I read about Ruby, I see the result
of a guy who studied a lot of different languages, took the the best
parts of each, and left the rest behind. And what language did he
'steal' the most from? Overwhelmingly Perl! Sounds like a smart guy to
me.
I heard that Larry Wall was recently at an O'Reilly Ruby conference in
Japan. Perl6 will be interesting for sure.
Cheers, Brian
PS If you don't believe Ruby takes from Perl, compare the command
switches as a simple example (They're almost identical):
> perl -h
Usage: perl [switches] [--] [programfile] [arguments]
-0[octal] specify record separator (\0, if no argument)
-a autosplit mode with -n or -p (splits $_ into @F)
-c check syntax only (runs BEGIN and END blocks)
-d[:debugger] run scripts under debugger
-D[number/list] set debugging flags (argument is a bit mask or flags)
-e 'command' one line of script. Several -e's allowed. Omit
[programfile].
-F/pattern/ split() pattern for autosplit (-a). The //'s are
optional.
-i[extension] edit <> files in place (make backup if extension
supplied)
-Idirectory specify @INC/#include directory (may be used more than
once)
-l[octal] enable line ending processing, specifies line
terminator
-[mM][-]module.. executes `use/no module...' before executing your
script.
-n assume 'while (<>) { ... }' loop around your script
-p assume loop like -n but print line also like sed
-P run script through C preprocessor before compilation
-s enable some switch parsing for switches after script
name
-S look for the script using PATH environment variable
-T turn on tainting checks
-u dump core after parsing script
-U allow unsafe operations
-v print version number, patchlevel plus VERY IMPORTANT
perl info
-V[:variable] print perl configuration information
-w TURN WARNINGS ON FOR COMPILATION OF YOUR SCRIPT.
Recommended.
-x[directory] strip off text before #!perl line and perhaps cd to
directory
> ruby -h
Usage: ruby [switches] [--] [programfile] [arguments]
-0[octal] specify record separator (\0, if no argument)
-a autosplit mode with -n or -p (splits $_ into $F)
-c check syntax only
-Cdirectory cd to directory, before executing your script
-d set debugging flags (set $DEBUG to true)
-e 'command' one line of script. Several -e's allowed. Omit
[programfile]
-Fpattern split() pattern for autosplit (-a)
-i[extension] edit ARGV files in place (make backup if extension
supplied)
-Idirectory specify $LOAD_PATH directory (may be used more than
once)
-Kkcode specifies KANJI (Japanese) code-set
-l enable line ending processing
-n assume 'while gets(); ... end' loop around your script
-p assume loop like -n but print line also like sed
-rlibrary require the library, before executing your script
-s enable some switch parsing for switches after script
name
-S look for the script using PATH environment variable
-T[level] turn on tainting checks
-v print version number, then turn on verbose mode
-w turn warnings on for your script
-x[directory] strip off text before #!ruby line and perhaps cd to
directory
--copyright print the copyright
--version print the version
--
perl -le 'use Inline C=>q{SV*JAxH(char*x){return newSVpvf
("Just Another %s Hacker",x);}};print JAxH+Ruby'