|
From: | Arno Waschk |
Subject: | Re: scheme night-mare... |
Date: | Sun, 11 Jul 2010 16:52:42 +0200 |
User-agent: | Opera Mail/10.60 (Linux) |
On 7/11/10 8:18 AM, "Arno Waschk" <address@hidden> wrote:On Sun, 11 Jul 2010 16:01:52 +0200, Carl Sorensen <address@hidden> wrote:On 7/11/10 7:53 AM, "Arno Waschk" <address@hidden> wrote:On Sun, 11 Jul 2010 15:48:57 +0200, Carl Sorensen <address@hidden> wrote:On 7/11/10 7:16 AM, "Arno Waschk" <address@hidden> wrote:Dear list, in the hope not for the x-th time having to give up due to that type mess scheme/c++ please forgive and help me: how can i convert/process/whatever the result ofwhateverGrob->get_property_alist_chain (SCM_EOL) into something easilyuseable in the c++ realm?Alist chains aren't easily handled in c++, as far as I know. But theycan be used with scheme functions by using scm_call_3.for the moment i am looking for either a complete dump of those properties, or at least a complete list of which properties could be addressed individually, although that would be less comfortable...If you don't need the alist chain, but just need individual properties,there are c++ functions to get the properties. If your question were a little bit more specific, we could probably help better.well, it is about getting around that types' things generally, too...OK, so here's the place to go to find what you need. The Guile referencehas an API reference that lists all of the c++ calls to execute schemefunctions. The stuff that deals with alists is found under the compounddata types section: http://www.gnu.org/software/guile/manual/html_node/Compound-Data-Types.html# Compound-Data-Types You can do anything that you can do in scheme in c++ with these calls.except for generating the list of keys, it seems... :(There is a scheme function in scm/lily-library.scm map-alist-keys that willapply a function to all the keys in an alist. That might be helpful...
How do i use this in a c line?
Your question isn't really about converting from scheme to c++, it's really about getting all of the keys and/or properties from an alist. That's notbuilt into scheme.
No, it is about easily accessing information buried into some scheme structures by some little c code.
As long this is not possible, this information is next to encrypted for me.Just finished a profile run with a larger score- ly_scm2interval is reported to have consumd 16% of computation time. There must be something wrong.
Thanks, Arno
Sorry, Carl
-- Erstellt mit Operas revolutionärem E-Mail-Modul: http://www.opera.com/mail/
[Prev in Thread] | Current Thread | [Next in Thread] |