summaryrefslogtreecommitdiffstats
path: root/lib.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib.c')
-rw-r--r--lib.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib.c b/lib.c
index fdba27d2..40cae588 100644
--- a/lib.c
+++ b/lib.c
@@ -2855,6 +2855,15 @@ val getplist_f(val list, val key, loc found)
return nil;
}
+val memp(val key, val plist)
+{
+ for (; plist; plist = cddr(plist)) {
+ if (car(plist) == key)
+ return plist;
+ }
+ return nil;
+}
+
val proper_plist_to_alist(val list)
{
list_collect_decl (out, ptail);