develooper Front page | perl.inline | Postings from August 2001

Inline::Brainfuck !

Thread Next
From:
João Pedro Gonçalves
Date:
August 30, 2001 07:38
Subject:
Inline::Brainfuck !
Message ID:
3B8E5E2E.2F397CFF@co.sapo.pt
Hi,
First of all congratulations to all involved in the amazing Inline
package.
You do deserve all the awards and beer that you're getting.
 
As a way to explore deeper the Inline details, and as Perl is a language
that was made to make your job easier, Inline allows us to include
in Perl languages developed to make our job *HARD*.
As ASM was already available, i went for more obscure ones,
and brainfuck was the chosen one.
 
 
If you don't know Urban Mueller's Brainfuck already, it's an
8 command set language, check http://www.catseye.mb.ca/esoteric/bf/
 
Basically it's just a regexp set that converts the brainfuck
instructions
to Perl code, this had already been done by Markko Nippula,
http://www.hut.fi/~mnippula/useless/
.
 
 
Here's the JaXH subroutine:
 
use Inline Brainfuck => <<EOF;
 
JaXH (
       
>+++++++++[<++++++++>-]<++.>+++++++[<++++++>-]<+.--.+.[-]>++++++++[<++++>-]<.>+
       
+++++++[<++++>-]<+.>+++++++[<++++++>-]<+++.+.+++++.>++++[<--->-]<.---.>++++[<++
       
+>-]<+.[-]>++++++++[<++++>-]<.,[.,][-]>++++++++[<++++>-]<.>+++++[<++++++++>-]<.
       
>+++++[<+++++>-]<.++.++++++++.------.>++++[<+++>-]<+.[-]++++++++++.
)
EOF
 
print JaXH("Inline");
 
 
The Brainfuck input command (",") reads from $_[0],
The Brainfuck print command (".") is buffered and returned.
 
 
Anyway, just another way to congratulate you guys for the wonderful work
and documentation that allowed me to get into Inline world in a morning.
 
Have fun!
 
João Pedro Gonçalves
Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About