under Win32 using either Visual C++ 4.0 or Watcom C/C++ 10.6.
/* Copyright (C) 1990 Free Software Foundation, Inc.
This file is part of the GNU C Library.
-$Id: ansidecl.h,v 1.4 1995/10/08 15:29:45 cph Exp $
+$Id: ansidecl.h,v 1.5 1996/10/02 18:56:19 cph Exp $
The GNU C Library is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
version 3.0 that is no longer allowed. What these fascists hope to
gain by this, besides angering programmers, is unclear. */
-#if defined(__STDC__) || defined(__IBMC__)
+#if defined(__STDC__) || defined(__IBMC__) || defined(CL386)
#define PTR void *
#define PTRCONST void *CONST
/* -*-C-*-
-$Id: avltree.c,v 1.1 1993/11/05 00:45:09 gjr Exp $
+$Id: avltree.c,v 1.2 1996/10/02 18:56:52 cph Exp $
-Copyright (c) 1993 Massachusetts Institute of Technology
+Copyright (c) 1993-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "avltree.h"
+int EXFUN (strcmp_ci, (char * s1, char * s2));
+
#ifndef NULL
# define NULL ((PTR) 0)
#endif
/* -*-C-*-
-$Id: bignmint.h,v 1.4 1993/10/27 23:57:07 gjr Exp $
+$Id: bignmint.h,v 1.5 1996/10/02 18:56:54 cph Exp $
-Copyright (c) 1989-1992 Massachusetts Institute of Technology
+Copyright (c) 1989-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#ifdef MIT_SCHEME
+#include "prims.h"
+
/* BIGNUM_ALLOCATE allocates a (length + 1)-element array of
`bignum_digit_type'; deallocation is the responsibility of the
user (in Scheme, the garbage collector handles this). */
/* -*-C-*-
-$Id: bignum.c,v 9.41 1994/02/09 00:53:27 cph Exp $
+$Id: bignum.c,v 9.42 1996/10/02 18:56:56 cph Exp $
-Copyright (c) 1989-94 Massachusetts Institute of Technology
+Copyright (c) 1989-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
fast bignum_digit_type * scan = (start + (BIGNUM_LENGTH (bignum)));
while (start < scan)
accumulator = ((accumulator << BIGNUM_DIGIT_LENGTH) + (*--scan));
- return ((BIGNUM_NEGATIVE_P (bignum)) ? (-accumulator) : accumulator);
+ return
+ ((BIGNUM_NEGATIVE_P (bignum))
+ ? (- ((long) accumulator))
+ : ((long) accumulator));
}
}
{
fast bignum_length_type length = (BIGNUM_LENGTH (bignum));
fast unsigned int max_digits = (BIGNUM_BITS_TO_DIGITS (n_bits));
- bignum_digit_type msd, max;
- return
- ((length < max_digits) ||
- ((length == max_digits) &&
- ((((msd = (BIGNUM_REF (bignum, (length - 1)))) <
- (max = (1L << (n_bits - ((length - 1) * BIGNUM_DIGIT_LENGTH))))) ||
- (twos_complement_p &&
- (msd == max) &&
- (BIGNUM_NEGATIVE_P (bignum)))))));
+ if (((unsigned int) length) < max_digits)
+ return (1);
+ if (((unsigned int) length) > max_digits)
+ return (0);
+ {
+ bignum_digit_type msd = (BIGNUM_REF (bignum, (length - 1)));
+ bignum_digit_type max
+ = (1L << (n_bits - ((length - 1) * BIGNUM_DIGIT_LENGTH)));
+ return
+ (((msd < max)
+ || (twos_complement_p
+ && (msd == max)
+ && (BIGNUM_NEGATIVE_P (bignum)))));
+ }
}
}
DEFUN (bignum_to_digit_stream, (bignum, radix, consumer, context),
bignum_type bignum
AND unsigned int radix
- AND void EXFUN ((*consumer),
- (bignum_procedure_context, bignum_digit_type))
+ AND void EXFUN ((*consumer), (bignum_procedure_context, long))
AND bignum_procedure_context context)
{
BIGNUM_ASSERT ((radix > 1) && (radix <= BIGNUM_RADIX_ROOT));
bignum_type x AND bignum_type y)
{
bignum_length_type length = (BIGNUM_LENGTH (x));
- if (length != (BIGNUM_LENGTH (y)))
+ if (length != ((bignum_length_type) (BIGNUM_LENGTH (y))))
return (0);
else
{
/* -*-C-*-
-$Id: bignum.h,v 9.28 1992/09/18 16:52:34 jinx Exp $
+$Id: bignum.h,v 9.29 1996/10/02 18:57:02 cph Exp $
-Copyright (c) 1989-1992 Massachusetts Institute of Technology
+Copyright (c) 1989-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
extern bignum_type EXFUN (bignum_make_one, (int negative_p));
extern int EXFUN (bignum_equal_p, (bignum_type, bignum_type));
extern enum bignum_comparison EXFUN (bignum_test, (bignum_type));
-extern enum bignum_comparison EXFUN (bignum_compare,
- (bignum_type, bignum_type));
+extern enum bignum_comparison EXFUN
+ (bignum_compare, (bignum_type, bignum_type));
extern bignum_type EXFUN (bignum_add, (bignum_type, bignum_type));
extern bignum_type EXFUN (bignum_subtract, (bignum_type, bignum_type));
extern bignum_type EXFUN (bignum_negate, (bignum_type));
extern bignum_type EXFUN (bignum_multiply, (bignum_type, bignum_type));
-extern int EXFUN (bignum_divide,
- (bignum_type numerator, bignum_type denominator,
- bignum_type * quotient, bignum_type * remainder));
+extern int EXFUN
+ (bignum_divide, (bignum_type numerator,
+ bignum_type denominator,
+ bignum_type * quotient,
+ bignum_type * remainder));
extern bignum_type EXFUN (bignum_quotient, (bignum_type, bignum_type));
extern bignum_type EXFUN (bignum_remainder, (bignum_type, bignum_type));
#ifndef BIGNUM_NO_ULONG
#endif /* not BIGNUM_NO_ULONG */
extern bignum_type EXFUN (double_to_bignum, (double));
extern double EXFUN (bignum_to_double, (bignum_type));
-extern int EXFUN (bignum_fits_in_word_p,
- (bignum_type, long word_length, int twos_complement_p));
+extern int EXFUN
+ (bignum_fits_in_word_p, (bignum_type,
+ long word_length,
+ int twos_complement_p));
extern bignum_type EXFUN (bignum_length_in_bits, (bignum_type));
extern bignum_type EXFUN (bignum_length_upper_limit, (void));
-extern bignum_type EXFUN (digit_stream_to_bignum,
- (unsigned int n_digits,
- unsigned int EXFUN ((*producer), ()),
- bignum_procedure_context context,
- unsigned int radix, int negative_p));
-extern void EXFUN (bignum_to_digit_stream,
- (bignum_type, unsigned int radix,
- void EXFUN((*consumer), ()),
- bignum_procedure_context context));
+extern bignum_type EXFUN
+ (digit_stream_to_bignum,
+ (unsigned int n_digits,
+ unsigned int EXFUN ((*producer), (bignum_procedure_context)),
+ bignum_procedure_context context,
+ unsigned int radix,
+ int negative_p));
+extern void EXFUN
+ (bignum_to_digit_stream,
+ (bignum_type, unsigned int radix,
+ void EXFUN ((*consumer), (bignum_procedure_context, long)),
+ bignum_procedure_context context));
extern long EXFUN (bignum_max_digit_stream_radix, (void));
/* -*-C-*-
-$Id: bigprm.c,v 1.3 1993/06/24 07:07:02 gjr Exp $
+$Id: bigprm.c,v 1.4 1996/10/02 18:57:03 cph Exp $
-Copyright (c) 1989-1991 Massachusetts Institute of Technology
+Copyright (c) 1989-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
\f
static void
DEFUN (listify_bignum_consumer, (previous_cdr, digit),
- SCHEME_OBJECT * previous_cdr AND unsigned int digit)
+ PTR previous_cdr AND
+ long digit)
{
- (*previous_cdr) =
- (cons ((LONG_TO_UNSIGNED_FIXNUM (digit)), (*previous_cdr)));
- return;
+ (* ((SCHEME_OBJECT *) previous_cdr)) =
+ (cons ((LONG_TO_UNSIGNED_FIXNUM (digit)),
+ (* ((SCHEME_OBJECT *) previous_cdr))));
}
DEFINE_PRIMITIVE ("LISTIFY-BIGNUM", Prim_listify_bignum, 2, 2,
/* -*-C-*-
-$Id: bitstr.c,v 9.56 1995/04/21 04:28:25 adams Exp $
+$Id: bitstr.c,v 9.57 1996/10/02 18:57:05 cph Exp $
-Copyright (c) 1987-95 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
\f
void
DEFUN (fill_bit_string, (bit_string, sense),
- SCHEME_OBJECT bit_string AND Boolean sense)
+ SCHEME_OBJECT bit_string AND
+ int sense)
{
SCHEME_OBJECT *scanner;
SCHEME_OBJECT filler;
if (! (bignum_fits_in_word_p (bignum, length, 0)))
error_bad_range_arg (2);
{
- void EXFUN (btbs_consumer, (unsigned char **, unsigned int));
+ void EXFUN (btbs_consumer, (unsigned char **, long));
SCHEME_OBJECT result = (zero_to_bit_string (length));
unsigned char * result_ptr =
((unsigned char *) (BIT_STRING_LOW_PTR (result)));
void
DEFUN (btbs_consumer, (result_ptr, digit),
unsigned char ** result_ptr
- AND unsigned int digit)
+ AND long digit)
{
- (* (INC_BIT_STRING_PTR (*result_ptr))) = digit;
- return;
+ (* (INC_BIT_STRING_PTR (*result_ptr))) = ((unsigned char) digit);
}
struct bitstr_to_bignm_context
/* -*-C-*-
-$Id: boot.c,v 9.96 1995/07/26 18:31:47 adams Exp $
+$Id: boot.c,v 9.97 1996/10/02 18:57:09 cph Exp $
-Copyright (c) 1988-95 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
extern void EXFUN (compiler_initialize, (long fasl_p));
extern SCHEME_OBJECT EXFUN (make_primitive, (char *, int));
extern void EXFUN (OS_announcement, (void));
+extern SCHEME_OBJECT EXFUN (char_pointer_to_symbol, (unsigned char *));
\f
static void EXFUN (Start_Scheme, (int, CONST char *));
static void EXFUN (Enter_Interpreter, (void));
/* -*-C-*-
-$Id: cmpint.c,v 1.89 1996/03/23 19:25:23 adams Exp $
+$Id: cmpint.c,v 1.90 1996/10/02 19:01:12 cph Exp $
Copyright (c) 1989-96 Massachusetts Institute of Technology
#define ASM_ENTRY_POINT(name) name
#endif
-#if defined(__STDC__) || defined(__IBMC__)
+#if defined(__STDC__) || defined(__IBMC__) || defined(CL386)
#define EXFNX(name, proto) ASM_ENTRY_POINT (name) proto
#define DEFNX(name, arglist, args) ASM_ENTRY_POINT (name) (args)
#define DEFNX_VOID(name) ASM_ENTRY_POINT (name) (void)
C_UTILITY Boolean
DEFUN (bkpt_p, (ep), PTR ep)
{
- return (SHARP_F);
+ return (FALSE);
}
C_UTILITY SCHEME_OBJECT
PTR ep AND SCHEME_OBJECT handle AND SCHEME_OBJECT state)
{
error_external_return ();
+ return (UNSPECIFIC);
}
C_UTILITY PTR
/* -*-C-*-
-$Id: debug.c,v 9.47 1995/07/26 21:04:40 adams Exp $
+$Id: debug.c,v 9.48 1996/10/02 18:57:21 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
outf_console ("Missing constant header.\n");
return;
}
- if (OBJECT_DATUM (Obj_Address[Pure_Size]) != Pure_Size)
+ if (((long) (OBJECT_DATUM (Obj_Address[Pure_Size]))) != Pure_Size)
{
outf_console ("Pure size mismatch 0x%lx.\n",
((long) (OBJECT_DATUM (Obj_Address[Pure_Size]))));
outf_console ("Missing ending header.\n");
return;
}
- if (OBJECT_DATUM (Obj_Address[Total_Size]) != Total_Size)
+ if (((long) (OBJECT_DATUM (Obj_Address[Total_Size]))) != Total_Size)
{
outf_console ("Total size mismatch 0x%lx.\n",
((long) (OBJECT_DATUM (Obj_Address[Total_Size]))));
print_expression (stream, Temp, " ...");
if ((OBJECT_TYPE (Temp)) == TC_MANIFEST_NM_VECTOR)
{
- Stack_Pointer = (STACK_LOC (OBJECT_DATUM (Temp)));
+ Stack_Pointer = (STACK_LOC (- ((long) (OBJECT_DATUM (Temp)))));
outf (stream, " (skipping)");
}
outf (stream, "\n");
{
signal_error_from_primitive (ERR_UNIMPLEMENTED_PRIMITIVE);
/*NOTREACHED*/
+ return (0);
}
#endif /* not ENABLE_DEBUGGING_FLAGS */
/* -*-C-*-
-$Id: extern.c,v 9.34 1993/08/03 08:29:45 gjr Exp $
+$Id: extern.c,v 9.35 1996/10/02 18:57:24 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
procedure), it finds the number for the external representation for\n\
the internal address.")
{
- fast long tc;
+ fast SCHEME_OBJECT tc;
fast SCHEME_OBJECT address;
PRIMITIVE_HEADER (2);
tc = (arg_nonnegative_integer (1));
CHECK_ARG (1, PRIMITIVE_P);
{
fast SCHEME_OBJECT primitive = (ARG_REF (1));
- if ((PRIMITIVE_NUMBER (primitive)) > (NUMBER_OF_PRIMITIVES ()))
+ if ((PRIMITIVE_NUMBER (primitive))
+ > ((unsigned long) (NUMBER_OF_PRIMITIVES ())))
error_bad_range_arg (1);
PRIMITIVE_RETURN (LONG_TO_FIXNUM (PRIMITIVE_ARITY (primitive)));
}
CHECK_ARG (1, PRIMITIVE_P);
{
fast SCHEME_OBJECT primitive = (ARG_REF (1));
- if ((PRIMITIVE_NUMBER (primitive)) > (NUMBER_OF_PRIMITIVES ()))
+ if ((PRIMITIVE_NUMBER (primitive))
+ > ((unsigned long) (NUMBER_OF_PRIMITIVES ())))
error_bad_range_arg (1);
{
fast char * answer = (PRIMITIVE_DOCUMENTATION (primitive));
/* -*-C-*-
-$Id: fasdump.c,v 9.60 1993/12/07 20:35:58 gjr Exp $
+$Id: fasdump.c,v 9.61 1996/10/02 18:57:28 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "scheme.h"
#include "prims.h"
+#include "osscheme.h"
#include "osio.h"
#include "osfile.h"
#include "osfs.h"
static Tchannel dump_channel;
#define Write_Data(size, buffer) \
- ((OS_channel_write_dump_file \
- (dump_channel, \
- ((char *) (buffer)), \
- ((size) * (sizeof (SCHEME_OBJECT))))) \
- / (sizeof (SCHEME_OBJECT)))
+ ((long) \
+ ((OS_channel_write_dump_file \
+ (dump_channel, \
+ ((char *) (buffer)), \
+ ((size) * (sizeof (SCHEME_OBJECT))))) \
+ / (sizeof (SCHEME_OBJECT))))
#include "dump.c"
/* -*-C-*-
-$Id: fasload.c,v 9.81 1995/07/26 23:23:38 adams Exp $
+$Id: fasload.c,v 9.82 1996/10/02 18:57:31 cph Exp $
-Copyright (c) 1987-1994 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
static Tchannel load_channel;
#define Load_Data(size, buffer) \
- ((OS_channel_read_load_file \
- (load_channel, \
- ((char *) (buffer)), \
- ((size) * (sizeof (SCHEME_OBJECT))))) \
- / (sizeof (SCHEME_OBJECT)))
+ ((long) \
+ ((OS_channel_read_load_file \
+ (load_channel, \
+ ((char *) (buffer)), \
+ ((size) * (sizeof (SCHEME_OBJECT))))) \
+ / (sizeof (SCHEME_OBJECT))))
#include "load.c"
extern char * EXFUN (malloc, (int));
+extern int EXFUN (strlen, (const char *));
+extern char * EXFUN (strcpy, (char *, const char *));
extern char * Error_Names [];
extern char * Abort_Names [];
AND SCHEME_OBJECT ** prim_table_ptr
AND SCHEME_OBJECT ** c_code_table_ptr)
{
- SCHEME_OBJECT * prim_table, * c_code_table, * ignore;
+ SCHEME_OBJECT * prim_table, * c_code_table;
extern unsigned long checksum_area ();
if ((Load_Data (Heap_Count, ((char *) Free))) != Heap_Count)
DEFUN (check_primitive_numbers, (table, length),
fast SCHEME_OBJECT * table AND fast long length)
{
- fast long count, top;
+ fast long count;
for (count = 0; count < length; count += 1)
if (table[count] != (MAKE_PRIMITIVE_OBJECT (count)))
/* Return in a non-standard way. */
PRIMITIVE_ABORT (PRIM_DO_EXPRESSION);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
#ifdef BYTE_INVERSION
/* -*-C-*-
-$Id: findprim.c,v 9.49 1993/08/21 01:56:51 gjr Exp $
+$Id: findprim.c,v 9.50 1996/10/02 18:57:35 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
return (result);
}
+extern void EXFUN (free, (void *));
+
#define FIND_INDEX_LENGTH(index, size) \
{ \
char index_buffer [64]; \
fprintf (output, "\n");
fprintf (output, " %s;\n", error_string);
fprintf (output, " /%cNOTREACHED%c/\n", '*', '*');
+ fprintf (output, " PRIMITIVE_RETURN (UNSPECIFIC);\n");
fprintf (output, "}\n");
return;
/* -*-C-*-
-$Id: generic.c,v 9.37 1993/06/24 07:08:40 gjr Exp $
+$Id: generic.c,v 9.38 1996/10/02 18:57:39 cph Exp $
-Copyright (c) 1987-1991 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
Pushed (); \
PRIMITIVE_ABORT (PRIM_APPLY); \
/*NOTREACHED*/ \
+ PRIMITIVE_RETURN (UNSPECIFIC); \
}
#define INDIRECT_TEST_1(test, slot) \
/* -*-C-*-
-$Id: hooks.c,v 9.53 1993/09/12 03:21:01 gjr Exp $
+$Id: hooks.c,v 9.54 1996/10/02 18:57:42 cph Exp $
-Copyright (c) 1988-1993 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
PRIMITIVE_CANONICALIZE_CONTEXT ();
CWCC (RC_RESTORE_HISTORY, SHARP_F, (ARG_REF (1)));
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
DEFINE_PRIMITIVE ("NON-REENTRANT-CALL-WITH-CURRENT-CONTINUATION",
PRIMITIVE_CANONICALIZE_CONTEXT();
CWCC (NON_REENTRANT_RC_RESTORE, NON_REENTRANT_FLAG, (ARG_REF (1)));
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
/* (WITHIN-CONTROL-POINT control-point thunk)
PRIMITIVE_ABORT (PRIM_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
DEFINE_PRIMITIVE ("ERROR-PROCEDURE", Prim_error_procedure, 3, 3,
Pushed ();
PRIMITIVE_ABORT (PRIM_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
}
}
PRIMITIVE_ABORT (PRIM_DO_EXPRESSION);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
DEFINE_PRIMITIVE ("FORCE", Prim_force, 1, 1,
Pushed ();
Translate_To_Point (new_point);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
}
}
}
PRIMITIVE_ABORT (PRIM_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
DEFINE_PRIMITIVE ("WITH-STACK-MARKER", Prim_with_stack_marker, 3, 3,
POP_PRIMITIVE_FRAME (1);
PRIMITIVE_ABORT (PRIM_POP_RETURN);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
DEFINE_PRIMITIVE ("WITH-HISTORY-DISABLED", Prim_with_history_disabled, 1, 1,
Pushed ();
PRIMITIVE_ABORT (PRIM_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
}
\f
/* -*-C-*-
-$Id: intern.c,v 9.54 1994/10/04 21:09:15 cph Exp $
+$Id: intern.c,v 9.55 1996/10/02 18:57:45 cph Exp $
-Copyright (c) 1987-94 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "prims.h"
#include "trap.h"
+extern int EXFUN (strlen, (const char *));
+
/* These are exported to other parts of the system. */
extern SCHEME_OBJECT EXFUN (string_to_symbol, (SCHEME_OBJECT));
/* -*-C-*-
-$Id: interp.c,v 9.85 1995/09/15 05:51:12 cph Exp $
+$Id: interp.c,v 9.86 1996/10/02 19:01:28 cph Exp $
-Copyright (c) 1988-94 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
nactuals = (OBJECT_DATUM (nargs));
data = (MEMORY_REF (Function, ENTITY_DATA));
if ((VECTOR_P (data))
- && (nactuals < (VECTOR_LENGTH (data)))
+ && (nactuals < ((long) (VECTOR_LENGTH (data))))
&& ((VECTOR_REF (data, nactuals)) != SHARP_F)
&& ((VECTOR_REF (data, 0))
== (Get_Fixed_Obj_Slot (ARITY_DISPATCHER_TAG))))
Apply_Future_Check(formals,
FAST_MEMORY_REF (Function, LAMBDA_FORMALS));
- if ((nargs != VECTOR_LENGTH (formals)) &&
- ((OBJECT_TYPE (Function) != TC_LEXPR) ||
- (nargs < VECTOR_LENGTH (formals))))
+ if ((nargs != ((long) (VECTOR_LENGTH (formals))))
+ && ((OBJECT_TYPE (Function) != TC_LEXPR)
+ || (nargs < ((long) (VECTOR_LENGTH (formals))))))
{
STACK_PUSH (STACK_FRAME_HEADER + nargs - 1);
Apply_Error(ERR_WRONG_NUMBER_OF_ARGUMENTS);
/* -*-C-*-
-$Id: lookup.c,v 9.54 1993/09/09 18:17:46 gjr Exp $
+$Id: lookup.c,v 9.55 1996/10/02 19:01:34 cph Exp $
-Copyright (c) 1988-1993 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
\f
scan = (OBJECT_ADDRESS (extension));
- if ((temp + (AUX_LIST_FIRST - 1)) == (VECTOR_LENGTH (extension)))
+ if ((temp + (AUX_LIST_FIRST - 1)) == ((long) (VECTOR_LENGTH (extension))))
{
fast long i;
fast SCHEME_OBJECT *fast_free;
/* -*-C-*-
-$Id: lookup.h,v 9.48 1993/06/24 07:08:58 gjr Exp $
+$Id: lookup.h,v 9.49 1996/10/02 19:01:38 cph Exp $
-Copyright (c) 1988-92 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
{ \
fast SCHEME_OBJECT frame; \
\
-label: \
+/* Deleted this label to eliminate compiler warnings: */ \
+/* label: */ \
\
frame = (MEMORY_FETCH (hunk [VARIABLE_COMPILED_TYPE])); \
\
break; \
} \
depth = verified_offset(offset, get_offset(hunk)); \
- if (depth > VECTOR_LENGTH (frame)) \
+ if (depth > ((long) (VECTOR_LENGTH (frame)))) \
{ \
cell = uncompiled_trap_object; \
break; \
/* -*-C-*-
-$Id: memmag.c,v 9.62 1996/04/08 23:41:35 cph Exp $
+$Id: memmag.c,v 9.63 1996/10/02 19:01:40 cph Exp $
Copyright (c) 1987-96 Massachusetts Institute of Technology
Pushed ();
PRIMITIVE_ABORT (PRIM_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
DEFINE_PRIMITIVE ("GC-TRACE-REFERENCES", Prim_gc_trace_references, 2, 2, 0)
/* -*-C-*-
-$Id: memmag.h,v 1.4 1996/03/23 19:25:10 adams Exp $
+$Id: memmag.h,v 1.5 1996/10/02 18:58:05 cph Exp $
Copyright (c) 1993-96 Massachusetts Institute of Technology
#include "ntscmlib.h"
+extern BOOL win32_under_win32s_p (void);
+
#ifdef WINNT_RAW_ADDRESSES
#define WIN32_ALLOCATE_HEAP win32_system_utilities.allocate_heap
/* -*-C-*-
-$Id: ntfile.c,v 1.5 1996/04/09 20:19:13 adams Exp $
+$Id: ntfile.c,v 1.6 1996/10/02 18:58:07 cph Exp $
-Copyright (c) 1992-1996 Massachusetts Institute of Technology
+Copyright (c) 1992-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
STD_UINT_SYSTEM_CALL
(syscall_lseek,
result,
- (_llseek ((CHANNEL_HANDLE (channel)), 0L, SEEK_CUR)));
+ (_llseek (((HFILE) (CHANNEL_HANDLE (channel))), 0L, SEEK_CUR)));
return (result);
}
STD_UINT_SYSTEM_CALL
(syscall_lseek,
result,
- (_llseek ((CHANNEL_HANDLE (channel)), position, SEEK_SET)));
+ (_llseek (((HFILE) (CHANNEL_HANDLE (channel))), position, SEEK_SET)));
if (result != position)
error_external_return ();
}
/* -*-C-*-
-$Id: ntgui.c,v 1.16 1996/03/21 16:38:16 adams Exp $
+$Id: ntgui.c,v 1.17 1996/10/02 18:58:10 cph Exp $
Copyright (c) 1993-96 Massachusetts Institute of Technology
#include "ntscreen.h"
\f
extern /*static*/ HANDLE ghInstance = 0;
+extern void scheme_main (int argc, const char ** argv);
BOOL InitApplication(HANDLE);
BOOL InitInstance(HANDLE, int);
void xfree(void*);
#ifdef GUI
-int PASCAL
+int WINAPI
WinMain (HANDLE hInst, HANDLE hPrevInst, LPSTR lpCmdLine, int nCmdShow)
{
int argc;
if (!InitInstance(ghInstance, nCmdShow))
return FALSE;
- return (scheme_main (argc, argv));
+ scheme_main (argc, argv);
+ return (0);
}
#endif
if (thunk==0)
return DefWindowProc (hwnd, message, wParam, lParam);
- result = apply4(thunk,
- ulong_to_integer(hwnd), ulong_to_integer(message),
- ulong_to_integer(wParam), ulong_to_integer(lParam));
+ result
+ = (apply4 (thunk,
+ (ulong_to_integer ((unsigned long) hwnd)),
+ (ulong_to_integer (message)),
+ (ulong_to_integer (wParam)),
+ (ulong_to_integer (lParam))));
return scheme_object_to_windows_object (result);
}
if (general_scheme_wndproc == SHARP_F)
return DefWindowProc (hwnd, message, wParam, lParam);
- result = apply4(general_scheme_wndproc,
- ulong_to_integer(hwnd), ulong_to_integer(message),
- ulong_to_integer(wParam), ulong_to_integer(lParam));
+ result
+ = (apply4 (general_scheme_wndproc,
+ (ulong_to_integer ((unsigned long) hwnd)),
+ (ulong_to_integer (message)),
+ (ulong_to_integer (wParam)),
+ (ulong_to_integer (lParam))));
return scheme_object_to_windows_object (result);
}
class_name = STRING_LOC (ARG_REF (1), 0);
window_name = STRING_LOC (ARG_REF (2), 0);
style = integer_to_ulong (ARG_REF (3));
- x = arg_ulong_default (4, CW_USEDEFAULT);
- y = arg_ulong_default (5, CW_USEDEFAULT);
- w = arg_ulong_default (6, CW_USEDEFAULT);
- h = arg_ulong_default (7, CW_USEDEFAULT);
+ x = (int) arg_ulong_default (4, ((unsigned long) CW_USEDEFAULT));
+ y = (int) arg_ulong_default (5, ((unsigned long) CW_USEDEFAULT));
+ w = (int) arg_ulong_default (6, ((unsigned long) CW_USEDEFAULT));
+ h = (int) arg_ulong_default (7, ((unsigned long) CW_USEDEFAULT));
hWndParent = (HWND) arg_ulong_default (8, 0);
hMenu = (HMENU) arg_ulong_default (9, 0);
lpvParam = (LPVOID) ARG_REF (10);
result = CreateWindowEx (0, class_name, window_name, style, x, y, w, h,
hWndParent, hMenu, ghInstance, lpvParam);
- return ulong_to_integer (result);
+ return ulong_to_integer ((unsigned long) result);
}
CHECK_ARG (1, STRING_P);
it = GetModuleHandle (STRING_LOC (ARG_REF (1), 0));
- PRIMITIVE_RETURN (long_to_integer (it));
+ PRIMITIVE_RETURN (long_to_integer ((long) it));
}
DEFINE_PRIMITIVE ("NT:LOAD-LIBRARY", Prim_nt_load_library, 1, 1,
CHECK_ARG (1, STRING_P);
it = LoadLibrary ((LPSTR)STRING_LOC (ARG_REF (1), 0));
- PRIMITIVE_RETURN (long_to_integer (it));
+ PRIMITIVE_RETURN (long_to_integer ((long) it));
}
DEFINE_PRIMITIVE ("NT:FREE-LIBRARY", Prim_nt_free_library, 1, 1,
it = GetProcAddress (module, function_name);
- PRIMITIVE_RETURN (it==NULL ? SHARP_F : long_to_integer (it));
+ PRIMITIVE_RETURN (it==NULL ? SHARP_F : long_to_integer ((long) it));
}
\f
DEFINE_PRIMITIVE ("NT:SEND-MESSAGE", Prim_send_message, 4, 4,
SendMessage (hwnd, SCREEN_SETMODES,
(WPARAM) arg_integer (2), (LPARAM) 0);
- PRIMITIVE_RETURN (hwnd ? long_to_integer (hwnd) : SHARP_F);
+ PRIMITIVE_RETURN (hwnd ? long_to_integer ((long) hwnd) : SHARP_F);
}
}
/* -*-C-*-
-$Id: ntscreen.c,v 1.23 1996/03/21 16:35:15 adams Exp $
+$Id: ntscreen.c,v 1.24 1996/10/02 18:58:14 cph Exp $
-Copyright (c) 1993-1996 Massachusetts Institute of Technology
+Copyright (c) 1993-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#define xfree free
#define xmalloc malloc
-LRESULT FAR PASCAL ScreenWndProc (HWND, UINT, WPARAM, LPARAM);
+LRESULT FAR CALLBACK ScreenWndProc (HWND, UINT, WPARAM, LPARAM);
VOID RegisterScreen (SCREEN);
VOID UnregisterScreen (SCREEN);
}
\f
//---------------------------------------------------------------------------
-// LRESULT FAR PASCAL ScreenWndProc (HWND hWnd, UINT uMsg,
-// WPARAM wParam, LPARAM lParam )
+// LRESULT FAR CALLBACK ScreenWndProc (HWND hWnd, UINT uMsg,
+// WPARAM wParam, LPARAM lParam )
//
// This is the TTY Window Proc. This handles ALL messages to the tty
// window.
//
//---------------------------------------------------------------------------
-LRESULT FAR PASCAL
+LRESULT FAR CALLBACK
ScreenWndProc (HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
SCREEN screen = GETSCREEN (hWnd);
/* -*-C-*-
-$Id: ntsig.c,v 1.17 1996/03/23 19:24:53 adams Exp $
+$Id: ntsig.c,v 1.18 1996/10/02 18:58:19 cph Exp $
Copyright (c) 1992-96 Massachusetts Institute of Technology
{ \
if (keyboard_interrupt_enables & (mask)) \
{ \
- tty_set_next_interrupt_char (interrupt_char); \
+ tty_set_next_interrupt_char ((cc_t) interrupt_char); \
interrupt_p = 1; \
} \
else \
/* -*-C-*-
-$Id: ntsys.c,v 1.5 1996/04/09 20:16:32 adams Exp $
+$Id: ntsys.c,v 1.6 1996/10/02 18:58:21 cph Exp $
-Copyright (c) 1992-1996 Massachusetts Institute of Technology
+Copyright (c) 1992-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
unsigned char * buffer = vbuffer;
int i;
- for (i = 0; i < nsize; i++)
+ for (i = 0; i < ((int) nsize); i++)
putchar (buffer[i]);
return (nsize);
/* -*-C-*-
-$Id: nttty.c,v 1.5 1995/10/24 05:07:31 cph Exp $
+$Id: nttty.c,v 1.6 1996/10/02 18:58:24 cph Exp $
-Copyright (c) 1992-95 Massachusetts Institute of Technology
+Copyright (c) 1992-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
DEFUN_VOID (NT_initialize_tty)
{
extern Tchannel EXFUN (OS_open_handle, (int fd));
- input_channel = (OS_open_handle (master_tty_window));
+ input_channel = (OS_open_handle ((int) master_tty_window));
(CHANNEL_INTERNAL (input_channel)) = 1;
output_channel = input_channel;
(CHANNEL_INTERNAL (output_channel)) = 1;
tty_command_beep = ALERT_STRING;
tty_command_clear = "\014";
-
- return;
}
\f
/* Fake TERMCAP capability */
/* -*-C-*-
-$Id: scheme32.c,v 1.10 1996/04/09 20:09:04 adams Exp $
+$Id: scheme32.c,v 1.11 1996/10/02 19:00:09 cph Exp $
Copyright (c) 1993-96 Massachusetts Institute of Technology
#include <stdlib.h>
#include <mmsystem.h>
\f
-static BOOL
+static BOOL __cdecl
win32_under_win32s_p (void)
{
return ((BOOL) 0);
//}
-static char *
+static char * __cdecl
win32_allocate_heap (unsigned long size, unsigned long * handle)
{
LPVOID base;
return ((char *) base);
}
-static void
+static void __cdecl
win32_release_heap (char * area, unsigned long handle)
{
VirtualFree (((LPVOID) area),
return;
}
-static BOOL
+static BOOL __cdecl
win32_lock_memory_area (void * area, unsigned long size)
{
return (VirtualLock (area, size));
}
-static void
+static void __cdecl
win32_unlock_memory_area (void * area, unsigned long size)
{
(void) VirtualUnlock (area, size);
return;
}
-static void
+static void __cdecl
win32_flush_async_timer (void * state)
{
struct win32_timer_closure_s * scm_timer
return;
}
\f
-static UINT
+static UINT __cdecl
win32_install_async_timer (void ** state_ptr,
unsigned long * base,
long memtop_off,
\f
/* These are NOPs in this version. */
-static BOOL
+static BOOL __cdecl
win32_alloc_scheme_selectors (unsigned long base,
unsigned long size,
unsigned short * scheme_cs,
return (FALSE);
}
-static void
+static void __cdecl
win32_release_scheme_selectors (unsigned short scheme_cs,
unsigned short scheme_ds,
unsigned short scheme_ss)
}
-void
+void FAR WINAPI
install_win32_system_utilities (WIN32_SYSTEM_UTILITIES *utils)
{
#define EXPORT(field) utils->field = win32_##field
ntfile.obj
ntfs.obj
ntgui.obj
-ntgui.rbj
+ntgui.res
ntio.obj
ntsig.obj
ntsys.obj
/* -*-C-*-
-$Id: option.c,v 1.42 1995/07/27 00:10:55 adams Exp $
+$Id: option.c,v 1.43 1996/10/02 18:58:26 cph Exp $
-Copyright (c) 1990-95 Massachusetts Institute of Technology
+Copyright (c) 1990-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#ifdef WINNT
#include <io.h>
#include <string.h>
+#include <stdlib.h>
#else
extern int strlen ();
+extern char * malloc ();
#endif
#ifndef NULL
static PTR
DEFUN (xmalloc, (n), unsigned long n)
{
- extern char * malloc ();
PTR result = (malloc (n));
if (result == 0)
{
/* -*-C-*-
-$Id: osscheme.c,v 1.8 1994/11/14 05:10:53 cph Exp $
+$Id: osscheme.c,v 1.9 1996/10/02 18:58:30 cph Exp $
-Copyright (c) 1990-94 Massachusetts Institute of Technology
+Copyright (c) 1990-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "scheme.h"
#include "osscheme.h"
+#include "prims.h"
\f
extern void
EXFUN (signal_error_from_primitive, (long error_code));
/* -*-C-*-
-$Id: prim.c,v 9.37 1993/10/27 23:55:26 gjr Exp $
+$Id: prim.c,v 9.38 1996/10/02 18:58:31 cph Exp $
-Copyright (c) 1988-92 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
PRIMITIVE_HEADER (2);
PRIMITIVE_RETURN
(BOOLEAN_TO_OBJECT
- ((OBJECT_TYPE (ARG_REF (2))) ==
- (arg_index_integer (1, (MAX_TYPE_CODE + 1)))));
+ (((long) (OBJECT_TYPE (ARG_REF (2))))
+ == (arg_index_integer (1, (MAX_TYPE_CODE + 1)))));
}
DEFINE_PRIMITIVE ("PRIMITIVE-OBJECT-DATUM", Prim_prim_obj_datum, 1, 1,
TOUCH_IN_PRIMITIVE ((ARG_REF (2)), object);
PRIMITIVE_RETURN
(BOOLEAN_TO_OBJECT
- ((OBJECT_TYPE (object)) ==
- (arg_index_integer (1, (MAX_TYPE_CODE + 1)))));
+ (((long) (OBJECT_TYPE (object)))
+ == (arg_index_integer (1, (MAX_TYPE_CODE + 1)))));
}
DEFINE_PRIMITIVE ("OBJECT-DATUM", Prim_object_datum, 1, 1, 0)
/* -*-C-*-
-$Id: primutl.c,v 9.69 1993/11/05 00:44:57 gjr Exp $
+$Id: primutl.c,v 9.70 1996/10/02 18:58:34 cph Exp $
-Copyright (c) 1988-1993 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
signal_error_from_primitive (ERR_UNIMPLEMENTED_PRIMITIVE);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
static void
/* -*-C-*-
-$Id: prntfs.c,v 1.5 1995/10/28 01:03:30 cph Exp $
+$Id: prntfs.c,v 1.6 1996/10/02 18:58:37 cph Exp $
-Copyright (c) 1993-95 Massachusetts Institute of Technology
+Copyright (c) 1993-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
DEFUN (file_mode_string, (s, a), struct stat * s AND char * a)
{
(a[0]) = (file_type_letter (s));
- rwx ((((s -> st_mode) & 0700) << 0), (& (a [1])));
- rwx ((((s -> st_mode) & 0070) << 3), (& (a [4])));
- rwx ((((s -> st_mode) & 0007) << 6), (& (a [7])));
+ rwx (((unsigned short) (((s -> st_mode) & 0700) << 0)), (& (a [1])));
+ rwx (((unsigned short) (((s -> st_mode) & 0070) << 3)), (& (a [4])));
+ rwx (((unsigned short) (((s -> st_mode) & 0007) << 6)), (& (a [7])));
#ifdef S_ISUID
if (((s -> st_mode) & S_ISUID) != 0)
(a[3]) = (((a[3]) == 'x') ? 's' : 'S');
{
PRIMITIVE_HEADER (3);
{
- time_t times[2];
-
- times[0] = (time_t) arg_integer (2);
- times[1] = (time_t) arg_integer (3);
- STD_VOID_SYSTEM_CALL(syscall_utime, (utime ((STRING_ARG (1)), ×)));
+ struct utimbuf times;
+ (times . actime) = ((time_t) (arg_integer (2)));
+ (times . modtime) = ((time_t) (arg_integer (3)));
+ STD_VOID_SYSTEM_CALL
+ (syscall_utime, (utime ((STRING_ARG (1)), (×))));
PRIMITIVE_RETURN (SHARP_F);
}
}
/* -*-C-*-
-$Id: prntio.c,v 1.2 1993/09/03 17:52:46 gjr Exp $
+$Id: prntio.c,v 1.3 1996/10/02 18:58:40 cph Exp $
-Copyright (c) 1993 Massachusetts Institute of Technology
+Copyright (c) 1993-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
DEFINE_PRIMITIVE ("CHANNEL-DESCRIPTOR", Prim_channel_descriptor, 1, 1, 0)
{
PRIMITIVE_HEADER (1);
- PRIMITIVE_RETURN (long_to_integer (CHANNEL_HANDLE (arg_channel (1))));
+ PRIMITIVE_RETURN
+ (long_to_integer ((long) (CHANNEL_HANDLE (arg_channel (1)))));
}
static HANDLE *
{
if (result == WAIT_TIMEOUT)
return (FIXNUM_ZERO);
- else if ((result >= WAIT_OBJECT_0) && (result <= (WAIT_OBJECT_0 + limit_object)))
+ else if ((result >= WAIT_OBJECT_0)
+ && (result <= (WAIT_OBJECT_0 + limit_object)))
return (long_to_integer ((result + 1) - WAIT_OBJECT_0));
- else if ((result >= WAIT_ABANDONED_0) && (result <= (WAIT_ABANDONED_0 + limit_abandoned)))
- return (long_to_integer (- ((result + 1) - WAIT_ABANDONED_0)));
+ else if ((result >= WAIT_ABANDONED_0)
+ && (result <= (WAIT_ABANDONED_0 + limit_abandoned)))
+ return (long_to_integer (- ((long) ((result + 1) - WAIT_ABANDONED_0))));
else
error_system_call ((GetLastError ()), syscall_select);
}
int timeout = (arg_nonnegative_integer (3));
int nhand = (VECTOR_LENGTH (schhands));
HANDLE * handles = (to_win_hand_vec (nhand, (VECTOR_LOC (schhands, 0))));
- DWORD result = (WaitForMultipleObjects (nhand, handles, wait_for_all, timeout));
-
+ DWORD result
+ = (WaitForMultipleObjects (nhand, handles, wait_for_all, timeout));
if (handles != ((HANDLE *) NULL))
free (handles);
PRIMITIVE_RETURN (wait_result (result, (nhand - 1), (nhand - 1)));
/* -*-C-*-
-$Id: prosio.c,v 1.12 1994/11/14 02:50:58 cph Exp $
+$Id: prosio.c,v 1.13 1996/10/02 18:58:41 cph Exp $
-Copyright (c) 1987-94 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
error_wrong_type_arg (arg_number);
{
fast long channel = (integer_to_long (argument));
- if (! ((channel >= 0) || (channel < OS_channel_table_size)))
+ if (! ((channel >= 0) || (channel < ((long) OS_channel_table_size))))
error_wrong_type_arg (arg_number);
return (channel);
}
/* -*-C-*-
-$Id: prosterm.c,v 1.14 1994/11/28 07:36:06 cph Exp $
+$Id: prosterm.c,v 1.15 1996/10/02 18:58:43 cph Exp $
-Copyright (c) 1990-94 Massachusetts Institute of Technology
+Copyright (c) 1990-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
CHECK_ARG (2, STRING_P);
{
SCHEME_OBJECT state = (ARG_REF (2));
- if ((STRING_LENGTH (state)) != (OS_terminal_state_size ()))
+ if (((unsigned int) (STRING_LENGTH (state)))
+ != (OS_terminal_state_size ()))
error_bad_range_arg (2);
OS_terminal_set_state ((arg_terminal (1)), (STRING_LOC (state, 0)));
}
/* -*-C-*-
-$Id: prostty.c,v 1.5 1993/06/24 07:09:30 gjr Exp $
+$Id: prostty.c,v 1.6 1996/10/02 18:58:47 cph Exp $
-Copyright (c) 1987-1992 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
unsigned char * scan;
if (! ((STRING_P (argument))
- && ((STRING_LENGTH (argument)) == (num_chars * 2))))
+ && (((unsigned int) (STRING_LENGTH (argument)))
+ == (num_chars * 2))))
error_wrong_type_arg (1);
for (i = 0, scan = (STRING_LOC (argument, 0)); i < num_chars; i++)
/* -*-C-*-
-$Id: purutl.c,v 9.47 1993/12/07 20:36:04 gjr Exp $
+$Id: purutl.c,v 9.48 1996/10/02 18:58:49 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "prims.h"
#include "gccode.h"
#include "zones.h"
+
+#ifdef WINNT
+#include <stdlib.h>
+#include <malloc.h>
+#endif
\f
static void
DEFUN (update, (From, To, Was, Will_Be),
/* -*-C-*-
-$Id: step.c,v 9.32 1994/06/28 19:03:13 cph Exp $
+$Id: step.c,v 9.33 1996/10/02 18:58:51 cph Exp $
-Copyright (c) 1987-94 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
}
PRIMITIVE_ABORT (PRIM_NO_TRAP_EVAL);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
/* (PRIMITIVE-APPLY-STEP OPERATOR OPERANDS HUNK3)
}
PRIMITIVE_ABORT (PRIM_NO_TRAP_APPLY);
/*NOTREACHED*/
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
\f
/* (PRIMITIVE-RETURN-STEP VALUE HUNK3)
Install_Traps (hooks);
Val = (value);
PRIMITIVE_ABORT (PRIM_NO_TRAP_POP_RETURN);
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
}
/* -*-C-*-
-$Id: string.c,v 9.36 1993/06/24 07:09:55 gjr Exp $
+$Id: string.c,v 9.37 1996/10/02 18:58:53 cph Exp $
-Copyright (c) 1987-92 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
STRING_SET \
(string, \
(arg_index_integer (2, (STRING_LENGTH (string)))), \
- (get_ascii (3))); \
+ ((unsigned char) (get_ascii (3)))); \
} \
PRIMITIVE_RETURN (UNSPECIFIC); \
}
while ((length--) > 0) \
{ \
temp = (*scan); \
- (*scan++) = (char_map (temp)); \
+ (*scan++) = ((unsigned char) (char_map (temp))); \
} \
PRIMITIVE_RETURN (UNSPECIFIC); \
}
{
VECTOR_8B_SUBSTRING_PREFIX_FORWARD ();
while (scan < limit)
- (*scan++) = ascii;
+ (*scan++) = ((unsigned char) ascii);
PRIMITIVE_RETURN (UNSPECIFIC);
}
{
VECTOR_8B_SUBSTRING_PREFIX_FORWARD ();
{
- fast unsigned char char1 = (char_upcase (ascii));
+ fast unsigned char char1 = ((unsigned char) (char_upcase (ascii)));
while (scan < limit)
if ((char_upcase (*scan++)) == char1)
PRIMITIVE_RETURN (LONG_TO_UNSIGNED_FIXNUM ((scan - 1) - string_start));
{
VECTOR_8B_SUBSTRING_PREFIX_BACKWARD ();
{
- fast unsigned char char1 = (char_upcase (ascii));
+ fast unsigned char char1 = ((unsigned char) (char_upcase (ascii)));
while (scan > limit)
if ((char_upcase (*--scan)) == char1)
PRIMITIVE_RETURN (LONG_TO_UNSIGNED_FIXNUM (scan - string_start));
/* -*-C-*-
-$Id: sysprim.c,v 9.41 1995/06/30 22:28:11 nick Exp $
+$Id: sysprim.c,v 9.42 1996/10/02 18:58:56 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
{
PRIMITIVE_HEADER (0);
termination_normal (0);
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
DEFINE_PRIMITIVE ("EXIT-WITH-VALUE",
{
PRIMITIVE_HEADER (1);
termination_normal ((int) arg_integer (1));
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
DEFINE_PRIMITIVE ("HALT", Prim_restartable_exit, 0, 0,
{
PRIMITIVE_HEADER (0);
OS_restartable_exit ();
+ PRIMITIVE_RETURN (UNSPECIFIC);
}
DEFINE_PRIMITIVE ("UNDER-EMACS?", Prim_under_emacs_p, 0, 0, 0)
/* -*-C-*-
-$Id: term.c,v 1.12 1995/10/24 05:11:10 cph Exp $
+$Id: term.c,v 1.13 1996/10/02 18:58:59 cph Exp $
-Copyright (c) 1990-95 Massachusetts Institute of Technology
+Copyright (c) 1990-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#include "scheme.h"
#include "ostop.h"
+#include "osio.h"
+#include "osfs.h"
+#include "osfile.h"
#include "edwin.h"
extern long death_blow;
#if defined(WINNT) || defined(_OS2)
#define USING_MESSAGE_BOX_FOR_FATAL_OUTPUT
+extern void winnt_deallocate_registers (void);
#endif
static void EXFUN (edwin_auto_save, (void));
{
SCHEME_OBJECT Term_Vector = (Get_Fixed_Obj_Slot (Termination_Proc_Vector));
if ((! (VECTOR_P (Term_Vector)))
- || ((VECTOR_LENGTH (Term_Vector)) <= code))
+ || (((long) (VECTOR_LENGTH (Term_Vector))) <= code))
return;
{
SCHEME_OBJECT Handler = (VECTOR_REF (Term_Vector, code));
/* -*-C-*-
-$Id: usrdef.h,v 9.41 1993/08/28 05:43:00 gjr Exp $
+$Id: usrdef.h,v 9.42 1996/10/02 18:59:01 cph Exp $
-Copyright (c) 1987-1993 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#ifndef SCM_USRDEF_H
#define SCM_USRDEF_H
-#include "ansidecl.h"
-#include "config.h"
-#include "object.h"
-#include "errors.h"
-#include "prim.h"
+#include "scheme.h"
#include "prims.h"
extern SCHEME_OBJECT EXFUN ((* (Static_Primitive_Procedure_Table[])), (void));
/* -*-C-*-
-$Id: utils.c,v 9.69 1995/10/24 05:11:33 cph Exp $
+$Id: utils.c,v 9.70 1996/10/02 18:59:03 cph Exp $
-Copyright (c) 1987-95 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
long interrupt_number)
{
if ((VECTOR_P (interrupt_masks))
- && (interrupt_number <= (VECTOR_LENGTH (interrupt_masks))))
+ && (interrupt_number <= ((long) (VECTOR_LENGTH (interrupt_masks)))))
{
SCHEME_OBJECT mask =
(VECTOR_REF (interrupt_masks, interrupt_number));
outf_fatal ("\nInvalid handlers vector (0x%lx).", interrupt_handlers);
terminate_no_interrupt_handler (masked_interrupts);
}
- if (interrupt_number >= (VECTOR_LENGTH (interrupt_handlers)))
+ if (interrupt_number >= ((long) (VECTOR_LENGTH (interrupt_handlers))))
{
outf_fatal("\nInterrupt out of range: %ld (vector length = %ld).",
interrupt_number,
/*NOTREACHED*/
}
- if ((Err < 0) || (Err >= (VECTOR_LENGTH (Error_Vector))))
+ if ((Err < 0) || (Err >= ((long) (VECTOR_LENGTH (Error_Vector)))))
{
if (VECTOR_LENGTH (Error_Vector) == 0)
error_death (Err, "No error handlers: Empty handlers vector");
/* -*-C-*-
-$Id: vector.c,v 9.36 1992/12/02 19:29:50 cph Exp $
+$Id: vector.c,v 9.37 1996/10/02 18:59:08 cph Exp $
-Copyright (c) 1987-92 Massachusetts Institute of Technology
+Copyright (c) 1987-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
TOUCH_IN_PRIMITIVE ((arg_type (1)), vector); \
start = (arg_nonnegative_integer (2)); \
end = (arg_nonnegative_integer (3)); \
- if (end > (VECTOR_LENGTH (vector))) \
+ if (end > ((long) (VECTOR_LENGTH (vector)))) \
error_bad_range_arg (3); \
if (start > end) \
error_bad_range_arg (2); \
end1 = (arg_nonnegative_integer (3)); \
TOUCH_IN_PRIMITIVE ((ARG_VECTOR (4)), vector2); \
start2 = (arg_nonnegative_integer (5)); \
- if (end1 > (VECTOR_LENGTH (vector1))) \
+ if (end1 > ((long) (VECTOR_LENGTH (vector1)))) \
error_bad_range_arg (3); \
if (start1 > end1) \
error_bad_range_arg (2); \
length = (end1 - start1); \
end2 = (start2 + length); \
- if (end2 > (VECTOR_LENGTH (vector2))) \
+ if (end2 > ((long) (VECTOR_LENGTH (vector2)))) \
error_bad_range_arg (5); \
if (ADDRESS_PURE_P (OBJECT_ADDRESS (vector2))) \
signal_error_from_primitive (ERR_WRITE_INTO_PURE_SPACE)
start = (arg_nonnegative_integer (2));
end = (arg_nonnegative_integer (3));
fill_value = (ARG_REF (4));
- if (end > (VECTOR_LENGTH (vector)))
+ if (end > ((long) (VECTOR_LENGTH (vector))))
error_bad_range_arg (3);
if (start > end)
error_bad_range_arg (2);
/* -*-C-*-
-$Id: wabbit.c,v 1.3 1994/03/25 00:58:52 gjr Exp $
+$Id: wabbit.c,v 1.4 1996/10/02 18:59:11 cph Exp $
-Copyright (c) 1994 Massachusetts Institute of Technology
+Copyright (c) 1994-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
{
long n_wabbits, buf_len, ctr;
SCHEME_OBJECT
- * result, * area, * saved_area, * wabbit_ptr,
+ * result, * area, * saved_area,
wabbit_buffer, wabbit_vector, * wabbit_vector_ptr;
wabbit_vector = (VECTOR_REF (wabbit_descriptor, 1));
/* -*-C-*-
-$Id: cmpint.c,v 1.87 1995/10/08 15:31:46 cph Exp $
+$Id: cmpint.c,v 1.88 1996/10/02 18:57:13 cph Exp $
-Copyright (c) 1989-1995 Massachusetts Institute of Technology
+Copyright (c) 1989-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
#define ASM_ENTRY_POINT(name) name
#endif
-#if defined(__STDC__) || defined(__IBMC__)
+#if defined(__STDC__) || defined(__IBMC__) || defined(CL386)
#define EXFNX(name, proto) ASM_ENTRY_POINT (name) proto
#define DEFNX(name, arglist, args) ASM_ENTRY_POINT (name) (args)
#define DEFNX_VOID(name) ASM_ENTRY_POINT (name) (void)
C_UTILITY Boolean
DEFUN (bkpt_p, (ep), PTR ep)
{
- return (SHARP_F);
+ return (FALSE);
}
C_UTILITY SCHEME_OBJECT
PTR ep AND SCHEME_OBJECT handle AND SCHEME_OBJECT state)
{
error_external_return ();
+ return (UNSPECIFIC);
}
C_UTILITY PTR
/* -*-C-*-
-$Id: interp.c,v 9.87 1995/09/15 05:48:48 cph Exp $
+$Id: interp.c,v 9.88 1996/10/02 18:57:49 cph Exp $
-Copyright (c) 1988-1995 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
nactuals = (OBJECT_DATUM (nargs));
data = (MEMORY_REF (Function, ENTITY_DATA));
if ((VECTOR_P (data))
- && (nactuals < (VECTOR_LENGTH (data)))
+ && (nactuals < ((long) (VECTOR_LENGTH (data))))
&& ((VECTOR_REF (data, nactuals)) != SHARP_F)
&& ((VECTOR_REF (data, 0))
== (Get_Fixed_Obj_Slot (ARITY_DISPATCHER_TAG))))
Apply_Future_Check(formals,
FAST_MEMORY_REF (Function, LAMBDA_FORMALS));
- if ((nargs != VECTOR_LENGTH (formals)) &&
- ((OBJECT_TYPE (Function) != TC_LEXPR) ||
- (nargs < VECTOR_LENGTH (formals))))
+ if ((nargs != ((long) (VECTOR_LENGTH (formals))))
+ && ((OBJECT_TYPE (Function) != TC_LEXPR)
+ || (nargs < ((long) (VECTOR_LENGTH (formals))))))
{
STACK_PUSH (STACK_FRAME_HEADER + nargs - 1);
Apply_Error(ERR_WRONG_NUMBER_OF_ARGUMENTS);
/* -*-C-*-
-$Id: lookup.c,v 9.55 1995/07/26 23:44:54 adams Exp $
+$Id: lookup.c,v 9.56 1996/10/02 18:57:55 cph Exp $
-Copyright (c) 1988-1993 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
\f
scan = (OBJECT_ADDRESS (extension));
- if ((temp + (AUX_LIST_FIRST - 1)) == (VECTOR_LENGTH (extension)))
+ if ((temp + (AUX_LIST_FIRST - 1)) == ((long) (VECTOR_LENGTH (extension))))
{
fast long i;
fast SCHEME_OBJECT *fast_free;
/* -*-C-*-
-$Id: lookup.h,v 9.49 1995/07/26 23:45:49 adams Exp $
+$Id: lookup.h,v 9.50 1996/10/02 18:58:01 cph Exp $
-Copyright (c) 1988-92 Massachusetts Institute of Technology
+Copyright (c) 1988-96 Massachusetts Institute of Technology
This material was developed by the Scheme project at the Massachusetts
Institute of Technology, Department of Electrical Engineering and
{ \
fast SCHEME_OBJECT frame; \
\
-label: \
+/* Deleted this label to eliminate compiler warnings: */ \
+/* label: */ \
\
frame = (MEMORY_FETCH (hunk [VARIABLE_COMPILED_TYPE])); \
\
break; \
} \
depth = verified_offset(offset, get_offset(hunk)); \
- if (depth > VECTOR_LENGTH (frame)) \
+ if (depth > ((long) (VECTOR_LENGTH (frame)))) \
{ \
cell = uncompiled_trap_object; \
break; \