blob: 15e8b6990cc7c5e0eb0f7bf49787b651375152e9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
--- a/src/c-ffi.c
+++ b/src/c-ffi.c
@@ -347,7 +347,11 @@
}
sa = SCM_SLOT_ACCESSOR(SCM_CDR(p));
if (0 <= sa->slotNumber) {
+#if !defined(GAUCHE_API_VERSION) || GAUCHE_API_VERSION < 98
return SCM_FFI_TYPE_DATA(Scm_InstanceSlotRef(ctype, sa->slotNumber));
+#else
+ return SCM_FFI_TYPE_DATA(Scm_InstanceSlotRef(ctype, sa->slotNumber, SCM_UNBOUND));
+#endif
} else {
Scm_Error("wrong slot number: %d", sa->slotNumber);
}
--- a/src/c-lexlib.stub
+++ b/src/c-lexlib.stub
@@ -40,7 +40,11 @@
"if (nptr == endptr) {"
" SCM_RETURN(SCM_FALSE);"
"} else {"
+ "#if !defined(GAUCHE_API_VERSION) || GAUCHE_API_VERSION < 98"
" SCM_RETURN(Scm_MakeInteger64((ScmInt64) v));"
+ "#else"
+ " SCM_RETURN(Scm_MakeInteger64((int64_t) v));"
+ "#endif"
"}"))
(define-cproc strtod (nptr::<const-cstring>)
|