if (is_alien (arg))
return (alien_address (arg));
if (FLONUM_P (arg))
- return ((void *) (OBJECT_ADDRESS (arg)));
+ return ((void *) (MEMORY_LOC ((arg), 1)));
error_wrong_type_arg (argn);
/*NOTREACHED*/
}
int
-flovec_length (SCM vector)
+flovec_length (double *first)
{
- return (FLOATING_VECTOR_LENGTH (vector));
-}
-
-double*
-flovec_loc (SCM vector)
-{
- return (FLOATING_VECTOR_LOC (vector, 0));
-}
+ /* FIRST must be the first double in a flonum/flovec. */
-double
-flovec_ref (SCM vector, int index)
-{
- int len = FLOATING_VECTOR_LENGTH (vector);
- if (0 <= index && index < len)
- return (FLOATING_VECTOR_REF (vector, index));
- error_external_return ();
+ SCM vector = MAKE_POINTER_OBJECT (TC_BIG_FLONUM, (((SCM *)first) - 1));
+ return (FLOATING_VECTOR_LENGTH (vector));
}
DEFINE_PRIMITIVE ("OUTF-ERROR", Prim_outf_error, 1, 1, 0)
extern void check_number_of_args (int num);
extern SCM unspecific (void);
extern SCM empty_list (void);
-extern int flovec_length (SCM vector);
-extern double* flovec_loc (SCM vector);
-extern double flovec_ref (SCM vector, int index);
+extern int flovec_length (double *first);
#ifndef MIT_SCHEME /* Do not include in the microcode, just shims. */
extern SCM cons (SCM car, SCM cdr);