lilypond-devel
[Top][All Lists]
Advanced

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

how to assign a Scheme procedure to an SCM variable?


From: Werner LEMBERG
Subject: how to assign a Scheme procedure to an SCM variable?
Date: Fri, 05 Jan 2024 09:32:07 +0000 (UTC)

Folks,


I ask for help with a Guile question.

Naively, I tried

```
SCM proc = scm_boolean_p;
```

However, this bombs out with

```
error: cannot convert 'scm_unused_struct* (*)(SCM)'
       {aka 'scm_unused_struct* (*)(scm_unused_struct*)'}
       to 'SCM' {aka 'scm_unused_struct*'}
```

What is the correct way to assign a built-in procedure like `boolean?`
(i.e., `scm_boolean_p`) to a variable of type `SCM`?


    Werner



reply via email to

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