Stackless/microthreads merge news

Paul Prescod paul at prescod.net
Fri May 12 09:34:18 EDT 2000


Christian Tismer wrote:
> 
> ...
>
> I've been looking quite closely at their code.
> This is quite a task. Stuff is well written,
> but it is much if you are not used to it.

I have been wondering for a while if it would be possible to merge the
Python interpreter with a Java VM so that Python and JPython themselves
could be merged. I think it would be cool to have a single
implementation with access to all Java classes and all Python extensions
too. That would be the ultimate glue language!

I would guess that the Python compiler would generate JVM byte codes
with a few optimization bytecodes that could be "turned off" to be
compatible with standard byte codes.

> ....  Java
> is explicit about what exceptions can be thrown where,
> and not declaring the right "throws" list is a syntax
> error. 
> ...
> The only thing that could be done is to capture
> continuations, store them in variables and call them
> later. This still gives the stack sharing problems
> which were quite hard to solve for Python.

I don't follow. Isn't it usual to use variables as continuations? I
would expect:

interface continuation{
	public Object apply( Object[] ) throws throwable;
}


-- 
 Paul Prescod  - ISOGEN Consulting Engineer speaking for himself
Art is always at peril in universities, where there are so many people, 
young and old, who love art less than argument, and dote upon a text 
that provides the nutritious pemmican on which scholars love to chew. 
				-- Robertson Davies in "The Cunning Man"




More information about the Python-list mailing list