lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: scheme night-mare...


From: Boris Shingarov
Subject: Re: scheme night-mare...
Date: Sun, 11 Jul 2010 19:42:52 -0400
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.12pre) Gecko/20100703 Shredder/3.0.6pre

On 07/11/2010 06:47 PM, Arno Waschk wrote:
okay, what are arg1 and arg2, and what is the type of result beyond being called "SCM"?

An ID for a Scheme entity. This is a fundamental concept in languages such as Scheme, Smalltalk, Self of Java. The value of the SCM itself is completely opaque to the client of the VM. It can be an index into a table, or it can be a direct address. The entity that it refers to, can in turn be any Scheme object: it can be a pair, or an atom, or the entity may even be immediately encoded in the SCM itself (for example, in Guile, #f is encoded in a special SCM).

If you are familiar with JNI, then you can think of SCM as something similar to "jobject".
In Smalltalk, the equivalent concept is "OOP".

If you want to understand the communication between the Scheme and C++ code, the best reading explaining the underlying concepts are books on implementation of functional programming languages. But any VM book will do just as well (I started from Goldberg&Robson's Smalltalk Blue Book back in 1994; Simon Jones is more directly applicable to Scheme).

Boris




reply via email to

[Prev in Thread] Current Thread [Next in Thread]