-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
27 lines (18 loc) · 1.05 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Python compiler for Parrot
$paranoid sampleinputs/filename
#The .pir code is written to a file named 'output.pir'
$shell
#Shell simulation. Supports for, assignment and print statements.
Interoperability:
-> perl: Executable wrapper to generate .pir from perl6 functions called from python programs. Removes the anonymous modifier from the .pir functions generated by perl6
Eg:
$perl perlsamples/python2perllist.pl python2perllist.pir
#The naming of the .pir is important as it is import in the python code
$paranoid sampleinputs/python2perllist.py
#This works only if the parrot installation being used is the one made from
#the rakudo source. There is a problem loading perl6 libraries otherwise.
-> perl2: Executable wrapper to generate .pir from perl6 programs which call python functions. Processes the importpython statement.
Eg:
$paranoid sampleinputs/perl2pythonlist.py perl2pythonlist.pir
$perl2 perlsamples/perl2pythonlist.pl output.pir
$parrot output.pir