[pypy-svn] r56610 - pypy/dist/pypy/doc

hpk at codespeak.net hpk at codespeak.net
Thu Jul 17 11:13:46 CEST 2008


Author: hpk
Date: Thu Jul 17 11:13:42 2008
New Revision: 56610

Modified:
   pypy/dist/pypy/doc/faq.txt
Log:
* trying to make RPython section slightly more readable for
  people not knowing anything about pypy 

* add an entry regarding Zope's restricted python



Modified: pypy/dist/pypy/doc/faq.txt
==============================================================================
--- pypy/dist/pypy/doc/faq.txt	(original)
+++ pypy/dist/pypy/doc/faq.txt	Thu Jul 17 11:13:42 2008
@@ -249,17 +249,24 @@
            Report from the PyPy project to the E.U.,
            http://codespeak.net/svn/pypy/extradoc/eu-report/D05.1_Publish_on_translating_a_very-high-level_description.pdf
 
+.. _`PyPy's RPython`: 
+
 ------------------------------
 What is this RPython language?
 ------------------------------
 
-RPython is a restricted subset of the Python language. The restrictions are to
-ensure that type inference (and so, ultimately, translation to other languages) of
-the program is possible. These restrictions only apply after the full import
-happens, so at import time arbitrary Python code can be executed. Another
-important point is that the property of "being RPython" always applies to a full
-program, not to single functions or modules (the translation tool chain does a
-full program analysis).
+RPython is a restricted subset of the Python language.   It is used for 
+implementing dynamic language interpreters within the PyPy framework.  The
+restrictions are to ensure that type inference (and so, ultimately, translation
+to other languages) of RPython programs is possible. These restrictions only
+apply after the full import happens, so at import time arbitrary Python code can
+be executed. 
+
+The property of "being RPython" always applies to a full program, not to single
+functions or modules (the translation tool chain does a full program analysis).
+"Full program" in the context of "being RPython" is all the code reachable from
+an "entry point" function. The translation toolchain follows all calls
+recursively and discovers what belongs to the program and what not.
 
 The restrictions that apply to programs to be RPython mostly limit the ability
 of mixing types in arbitrary ways. RPython does not allow the usage of two
@@ -277,14 +284,17 @@
 
 .. _`RPython description`: coding-guide.html#restricted-python
 
+-------------------------------------------------------------------------
+Does RPython have anything to do with Zope's Restricted Python? 
+-------------------------------------------------------------------------
 
---------------------------------------------------------------------------
-What do you mean by "full program"? All the code in all the modules I use?
---------------------------------------------------------------------------
+No.  `Zope's RestrictedPython`_ aims to provide a sandboxed 
+execution environment for CPython.   `PyPy's RPython`_ is the implementation
+language for dynamic language interpreters.  However, PyPy also provides 
+a robust `sandboxed Python Interpreter`_. 
 
-"Full program" in the context of "being RPython" is all the code reachable from
-an "entry point" function. The translation toolchain follows all calls
-recursively and discovers what belongs to the program and what not.
+.. _`sandboxed Python Interpreter`: sandbox.html
+.. _`Zope's RestrictedPython`: http://pypi.python.org/pypi/RestrictedPython
 
 -------------------------------------------------------------------------
 Can I use PyPy and RPython to compile smaller parts of my Python program?



More information about the Pypy-commit mailing list