1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-03 13:20:26 +02:00
Commit graph

3414 commits

Author SHA1 Message Date
Marius Vollmer
53e82297cd Turn off debugging output in scm_compile_shell_switches. 2001-11-06 12:53:22 +00:00
Marius Vollmer
7ab89df17c *** empty log message *** 2001-11-05 23:12:20 +00:00
Marius Vollmer
3682a51a35 (scm_shell_usage, scm_compile_shell_switches): Prepend
a call to turn-on-debugging when --debug has been given instead of
turning it on directly.  Also, handle new `--no-debug' option,
which might suppress the call to turn-on-debugging.
2001-11-05 23:11:50 +00:00
Stefan Jahn
0233bfc11b 2001-11-05 Stefan Jahn <stefan@lkcc.org>
* struct.c (s_scm_struct_vtable_p): Corrected docstring.
2001-11-05 21:12:33 +00:00
Stefan Jahn
8f99e3f38b 2001-11-04 Stefan Jahn <stefan@lkcc.org>
* NEWS: Corrected remarks about SCM_API.

        * configure.in: Defining USE_DLL_IMPORT definition to indicate
        usage of DLL import macros in `libguile/__scm.h'.
        (LIBOBJS): Removed `fileblocks.o' from the list of object files.
        Somehow Jim Blandy's patch from 1997 did not survive.

2001-11-04  Stefan Jahn  <stefan@lkcc.org>

        * configure.in (EXTRA_DEFS): Follow-up patch.  Using SCM_IMPORT
        instead of __SCM_IMPORT__.

        * readline.c (scm_readline_init_ports): Disable input/output
        stream redirection for Win32.  The readline package for Win32
        does not support this.  The guile-readline library works fine
        for command line editing.

        * readline.h (SCM_RL_API): Renamed __FOO__ macros into FOO.

2001-11-04  Stefan Jahn  <stefan@lkcc.org>

        * Makefile.am (libguile_la_LIBADD): Added $(THREAD_LIBS_LOCAL)
        here (was at guile_LDADD) which describes the dependency
        correctly and allows a clean build on Win32.

        * __scm.h (SCM_API): Follow-up patch.  Renamed __FOO__ macros
        into FOO.

        * __scm.h: USE_DLL_IMPORT indicates the usage of the DLL
        import macros for external libraries (libcrypt, libqthreads,
        libreadline and libregex).

        * coop-defs.h: Include <winsock2.h> for `struct timeval'.

        * posix.c (flock): Added support for flock() in M$-Windows.

        * guile.c (SCM_IMPORT): Follow-up patch.  Use SCM_IMPORT instead
        of __SCM_IMPORT__.

        * fports.c (getflags): Differentiate reading and writing pipes
        descriptors.

        * filesys.c (S_IS*): Redefine all of the S_IS*() macros for
        M$-Windows.

        * coop.c (coop_condition_variable_timed_wait_mutex): Use
        conditionalized error code if `ETIMEDOUT' is not available.
        (scm_thread_usleep): Remove bogus declaration of `struct timeval
        timeout'.

        * numbers.c (PTRDIFF_MIN): Moved this definition where it actually
        belongs.  That is because NO_PREPRO_MAGIC gets undefined after
        each inclusion of `num2integral.i.c'.
        (SIZE_MAX): Define NO_PREPRO_MAGIC if SIZE_MAX is undefined.

2001-11-04  Stefan Jahn  <stefan@lkcc.org>

        * md/Makefile.am (EXTRA_DIST): Added `i386.asm'.

        * md/i386.asm: New file.  Contains the Intel syntax version for
        nasm/tasm/masm of the file `i386.s'.

        * qt.h.in: Definition of QT_API, QT_IMPORT and QT_EXPORT.
        Prefixed each symbols which is meant to go into a DLL.

        * Makefile.am (libqthreads_la_LDFLAGS):  Put `-no-undefined'
        into LDFLAGS to support linkers which do not allow unresolved
        symbols inside shared libraries.
        (EXTRA_DIST): Add `libqthreads.def', which is an export file
        definition for M$-Windows.  It defines exported symbols.  This is
        necessary because the M$VC linker does not know how to export
        assembler symbols into a DLL.

2001-11-04  Stefan Jahn  <stefan@lkcc.org>

        * srfi-13.h, srfi-14.h, srfi-4.h: Follow-up patch.  Renamed
        __FOO__ macros into FOO.

2001-11-04  Stefan Jahn  <stefan@lkcc.org>

        * tests/ports.test: Run (close-port) before (delete-file) if
        necessary/advisory.
2001-11-04 15:52:30 +00:00
Marius Vollmer
4e21fa6096 *** empty log message *** 2001-11-03 18:46:31 +00:00
Marius Vollmer
b8113bc8dc (scm_m_begin): Allow (begin), with no subforms.
(SCM_CEVAL): Evaluate an empty `begin' to SCM_UNSPECIFIED.
2001-11-03 18:45:33 +00:00
Mikael Djurfeldt
7663c008a5 * print.c (scm_iprin1): Mark print state as revealed when
dispatching to generic write or display.
2001-11-02 13:55:38 +00:00
Mikael Djurfeldt
08112c957b * unif.c (scm_ra2contig): Fixed memory overwrite bug. 2001-11-02 12:31:50 +00:00
Marius Vollmer
f712d833cc *** empty log message *** 2001-11-02 00:21:34 +00:00
Marius Vollmer
33b001fd89 Prefixed each each exported symbol with SCM_API. 2001-11-02 00:19:12 +00:00
Marius Vollmer
1dcb9876f5 * win32-uname.c: Include "win32-uname.h", not "uname.h". 2001-11-02 00:18:32 +00:00
Marius Vollmer
21e11a3b15 * win32-dirent.c: Include "win32-dirent.h", not "dirent.h". 2001-11-02 00:18:22 +00:00
Marius Vollmer
79dcdf5188 On M$-Windows tzname[]' is known to be _tzname[]'. 2001-11-02 00:17:10 +00:00
Marius Vollmer
ed618cc9c1 Made `usleep()' avalable on MinGW. 2001-11-02 00:16:57 +00:00
Marius Vollmer
4f68365d03 Remove unnecessary dirent includes and defines. Include
local `win32-uname.h' for MinGW.  Extern declaration of
`mkstemp()' for systems where it does not exists.  Make
`getlogin()' available on M$-Windows.
2001-11-02 00:16:46 +00:00
Marius Vollmer
e2c801663c Disable extern declaration of `h_errno' for __CYGWIN__,
too.
Put `scm_return_entry()' into HAVE_GETSERVENT conditional.
2001-11-02 00:16:28 +00:00
Marius Vollmer
5507e7260b Include `process.h' is possible. 2001-11-02 00:16:19 +00:00
Marius Vollmer
d7db9f60c2 Make sure to define __SCM_IMPORT__ for shared library
build on Win32.  Disable preloaded symbols on Win2 platforms.
2001-11-02 00:15:53 +00:00
Marius Vollmer
ec65f5dadc * fports.c: Include io.h' is possible. Put *fp' into referring
statement block in `scm_fport_buffer_add()'.
Some corrections in `getflags()'.

* ioext.c, ports.c: Include `io.h' is possible.
2001-11-02 00:15:41 +00:00
Marius Vollmer
c01a6af52f * __scm.h, alist.h, arbiters.h, async.h, backtrace.h, boolean.h,
chars.h, continuations.h, coop-defs.h, coop-threads.h,
debug-malloc.h, debug.h, deprecation.h, dynl.h, dynwind.h,
environments.h, eq.h, error.h, eval.h, evalext.h, extensions.h,
feature.h, filesys.h, fluids.h, fports.h, gc.h, gdb_interface.h,
gdbint.h, gh.h, goops.h, gsubr.h, guardians.h, hash.h, hashtab.h,
hooks.h, init.h, ioext.h, iselect.h, keywords.h, lang.h, list.h,
load.h, macros.h, mallocs.h, modules.h, net_db.h, numbers.h,
objects.h, objprop.h, options.h, pairs.h, ports.h, posix.h, print.h,
procprop.h, procs.h, properties.h, ramap.h, random.h, rdelim.h,
read.h, regex-posix.h, root.h, rw.h, scmsigs.h, script.h, simpos.h,
smob.h, socket.h, sort.h, srcprop.h, stackchk.h, stacks.h, stime.h,
strings.h, strop.h, strorder.h, strports.h, struct.h, symbols.h,
tags.h, threads.h, throw.h, unif.h, values.h, variable.h, vectors.h,
vports.h, weaks.h:
Prefixed each each exported symbol with SCM_API.

* gdb_interface.h (GDB_INTERFACE): Also support __CYGWIN__.
2001-11-02 00:09:41 +00:00
Marius Vollmer
bb1180ef26 `__libc_ia64_register_backing_store_base'
is meant to be a `unsigned long *'.
2001-11-02 00:09:28 +00:00
Marius Vollmer
b8b17bfd31 Include io.h' is possible. Put *fp' into referring
statement block in `scm_fport_buffer_add()'.
Some corrections in `getflags()'.
2001-11-02 00:09:14 +00:00
Marius Vollmer
e0c73a1cb6 Include `direct.h' if possible. Use local
`win32-dirent.h' for the native M$-Windows port.  Define S_IS*()
macros for M$-Windows.  Implementation of `fstat_Win32()' which is
able to differentiate between sockets and other file descriptors.
Use this function as wrapper in `scm_fstat()'.  Fixed typo in
`scm_dirname()'.
2001-11-02 00:09:02 +00:00
Marius Vollmer
87855fa2c4 * __scm.h, alist.h, arbiters.h, async.h, backtrace.h, boolean.h,
chars.h, continuations.h, coop-defs.h, coop-threads.h,
debug-malloc.h, debug.h, deprecation.h, dynl.h, dynwind.h,
environments.h, eq.h, error.h, eval.h, evalext.h, extensions.h,
feature.h, filesys.h, fluids.h, fports.h, gc.h, gdb_interface.h,
gdbint.h, gh.h, goops.h, gsubr.h, guardians.h, hash.h, hashtab.h,
hooks.h, init.h, ioext.h, iselect.h, keywords.h, lang.h, list.h,
load.h, macros.h, mallocs.h, modules.h, net_db.h, numbers.h,
objects.h, objprop.h, options.h, pairs.h, ports.h, posix.h, print.h,
procprop.h, procs.h, properties.h, ramap.h, random.h, rdelim.h,
read.h, regex-posix.h, root.h, rw.h, scmsigs.h, script.h, simpos.h,
smob.h, socket.h, sort.h, srcprop.h, stackchk.h, stacks.h, stime.h,
strings.h, strop.h, strorder.h, strports.h, struct.h, symbols.h,
tags.h, threads.h, throw.h, unif.h, values.h, variable.h, vectors.h,
vports.h, weaks.h:
Prefixed each each exported symbol with SCM_API.

* continuations.c: Added comment about the use of the extern
declarations of {get,set}context() functions used in the ia64 port.

* continuations.h, gc.c: `__libc_ia64_register_backing_store_base'
is meant to be a `unsigned long *'.
2001-11-02 00:08:41 +00:00
Marius Vollmer
e4e933734c Prefixed each each exported symbol with SCM_API. 2001-11-02 00:08:10 +00:00
Marius Vollmer
1174045c9a * __scm.h: Defined SCM_API. This macro gets prepended to all
function and data definitions which should be exported or imported
in the resulting dynamic link library in the Win32 port.

* __scm.h, alist.h, arbiters.h, async.h, backtrace.h, boolean.h,
chars.h, continuations.h, coop-defs.h, coop-threads.h,
debug-malloc.h, debug.h, deprecation.h, dynl.h, dynwind.h,
environments.h, eq.h, error.h, eval.h, evalext.h, extensions.h,
feature.h, filesys.h, fluids.h, fports.h, gc.h, gdb_interface.h,
gdbint.h, gh.h, goops.h, gsubr.h, guardians.h, hash.h, hashtab.h,
hooks.h, init.h, ioext.h, iselect.h, keywords.h, lang.h, list.h,
load.h, macros.h, mallocs.h, modules.h, net_db.h, numbers.h,
objects.h, objprop.h, options.h, pairs.h, ports.h, posix.h, print.h,
procprop.h, procs.h, properties.h, ramap.h, random.h, rdelim.h,
read.h, regex-posix.h, root.h, rw.h, scmsigs.h, script.h, simpos.h,
smob.h, socket.h, sort.h, srcprop.h, stackchk.h, stacks.h, stime.h,
strings.h, strop.h, strorder.h, strports.h, struct.h, symbols.h,
tags.h, threads.h, throw.h, unif.h, values.h, variable.h, vectors.h,
vports.h, weaks.h:
Prefixed each each exported symbol with SCM_API.
2001-11-02 00:07:21 +00:00
Marius Vollmer
94b1762d32 Add win32-uname.c, win32-uname.h, win32-dirent.c
and win32-dirent.h to extra source and header files.  These
include the uname() and the POSIX dirent interface implementation
for M$-Windows.  Put `-no-undefined' into LDFLAGS to support
linkers which do not allow unresolved symbols inside shared
libraries.  Corrected `guile_filter_doc_snarfage$(EXEEXT)'
dependency.
2001-11-02 00:07:11 +00:00
Marius Vollmer
8dd6dfdcd2 New files with implementations of dirent and uname for Win32. 2001-11-01 23:23:41 +00:00
Mikael Djurfeldt
d245ce231d * unif.c (scm_uniform_array_read_x, scm_uniform_array_write):
Don't apply scm_uniform_vector_length on arrays.
2001-10-28 11:13:35 +00:00
Dirk Herrmann
8ea4624953 * eval.c (scm_lookupcar, scm_m_letstar, scm_m_do, iqq,
scm_m_define, scm_m_letrec1, scm_m_let, scm_m_expand_body,
scm_macroexp, unmemocopy, scm_eval_args, scm_deval_args,
SCM_CEVAL, scm_map, scm_init_eval):  When building lists, prefer
scm_list_<n> over scm_cons[2]?.

(scm_unmemocar, scm_m_cond, scm_m_letstar, scm_m_letrec1,
scm_m_let, scm_m_atbind, unmemocopy, SCM_CEVAL, SCM_APPLY):  Use
SCM_C[AD][AD]R instead of explicit form.

(scm_m_set_x, scm_m_cond, scm_m_letstar, scm_m_do):  Reordered
comparison parameters.

(scm_m_case, scm_m_cond, scm_m_letstar, scm_m_do, SCM_CEVAL):  Use
!SCM_NULLP instead of SCM_NIMP.

(scm_m_case):  Don't copy the form.  Renamed proc to clause and
minimized its scope.  Renamed x to clauses.  Removed side
effecting operation from macro call.

(scm_m_cond):  Don't copy the form.  Renamed arg1 to clause and
minimized its scope.  Renamed x to clauses.  Minimized the scope
of variable 'len'.  Make sure the else clause is treated specially
even in case of '=>' occurences.  Don't change the else to #t in
order to be able to distinguish this case in the evaluator.  Leave
type checking of the recipient to the evaluator.

(scm_c_improper_memq):  Made the comment somewhat clearer.

(scm_m_lambda):  Renamed proc to formals.  Removed unnecessary
test for SCM_IM_LET at the place of the formal parameters.
Simplified the formal parameter checking.

(scm_m_letstar):  Added Comment.  Renamed proc to bindings.
Renamed arg1 to binding and minimized its scope.  Eliminated
unnecessary consing.

(scm_m_do):  Renamed proc to bindings.  Minimized the scope of
variable 'len'.

(build_binding_list):  New static function.

(unmemocopy):  Don't use SCM_TYP7 on pairs (it's unclean).
Further, split up the 'letrec' unmemoizing code to the
corresponding parts for 'do', 'let' and 'letrec', adding comments
to each form.  Cleanup the handling of the do form (This removes
some *real* code :-).

(SCM_CEVAL):  Removed side effecting operation from macro call.
Handle the 'else clause of the 'cond form specially - the symbol
'else is not replaced with #t any more.
2001-10-18 21:38:04 +00:00
Gary Houston
8186c4f536 * version.c (scm_version): use sprintf instead of snprintf,
for portability.  thanks to Bill Schottstaedt.
2001-10-14 21:28:23 +00:00
Mikael Djurfeldt
89759084ab * read.c (scm_lreadr): When user-defined hash procedure returns
SCM_UNSPECIFIED: Fall back to standard handling instead of raising
an exception.  (This prevents parsing of uniform vectors from
interfering with parsing of numbers.)

* arrays.scm (read:uniform-vector): Return *unspecified* instead
of raising an exception if hash extend character isn't followed by
the array list. (This prevents parsing of uniform vectors from
interfering with parsing of numbers.)
2001-10-14 16:05:04 +00:00
Marius Vollmer
9c7ce56302 *** empty log message *** 2001-10-13 15:42:52 +00:00
Marius Vollmer
143883dd3f (EXTRA_libguile_la_SOURCES): Added "mkstemp.c". 2001-10-13 15:42:07 +00:00
Marius Vollmer
4110fa69b0 (display_backtrace_file_and_line): Only use scm_basename when POSIX
support is compiled in.  Thanks to Chris Cramer.
2001-10-13 15:41:40 +00:00
Marius Vollmer
311f67823d (scm_m_atbind): First try to find the variable without defining it
locally; when it has not been found, define it locally.
2001-10-13 15:41:12 +00:00
Marius Vollmer
dc187f33fd (module_variable): Pass over variables that exist but are unbound. 2001-10-13 15:40:29 +00:00
Marius Vollmer
3756da52d9 Set NO_PREPRO_MAGIC when defining our version of PTRDIFF_MIN. Thanks
to Ken Raeburn.
2001-10-13 15:39:53 +00:00
Dirk Herrmann
1fe5e088ff * numbers.c (mem2uinteger): Return number read so far when coming
across a hexdigit after having read a # or if not reading a hex
value.  This will enable the calling code to correctly handle
forms like 1e2.  (The background is, that the exponent markers d,
e and f are also hexdigits.)  Thanks to Mikael Djurfeldt for
providing this patch.

(mem2complex):  Fix erroneous double-negation.  Now, numbers like
1-i will be read correctly.
2001-10-13 12:39:26 +00:00
Mikael Djurfeldt
aa5e5d63eb * debug.c (scm_mem_to_proc): Fixed typo in previous change. 2001-10-12 09:02:03 +00:00
Mikael Djurfeldt
68665a9708 * validate.h (SCM_VALIDATE_DOUBLE_DEF_COPY): New macro. 2001-10-12 08:55:05 +00:00
Dirk Herrmann
d5cf5324a3 * print.c (scm_print_state_vtable, print_state_pool):
Initialize.  These variables are now registered as gc roots.

(scm_current_pstate):  Update documentation.

(scm_current_pstate, scm_make_print_state, scm_free_print_state,
scm_prin1, scm_init_print):  print_state_pool is registered as a
gc root and thus does not need to be protected by a surrounding
pair any more.

(make_print_state):  The car of print_state_pool no longer holds
the scm_print_state_vtable.

(scm_current_pstate, scm_make_print_state, print_circref,
scm_iprin1, scm_prin1, scm_iprlist):  Prefer !SCM_<foo> over
SCM_N<foo>.

(scm_prin1):  When building lists, prefer scm_list_<n> over
scm_cons[2]?.

(scm_iprlist):  Removed a redundant SCM_IMP test.

(scm_simple_format):  Use SCM_EQ_P to compare SCM values.
2001-10-11 23:20:52 +00:00
Dirk Herrmann
37c56aecf8 * debug.c (scm_make_iloc): Prefer !SCM_<foo> over SCM_N<foo>.
(scm_memcons, scm_mem_to_proc):  When building lists, prefer
scm_list_<n> over scm_cons[2]?.

(scm_mem_to_proc):  Prefer SCM_CONSP over SCM_NIMP.

(scm_procedure_name):  Use SCM_CADR instead of explicit form.

(debugobj_print):  Coerce scm_intprint arg 1 to long, not int.
Thanks to Rob Browning for the patch (see log entry 2001-09-21) -
for some reason his patch didn't make it into the cvs.
2001-10-11 22:26:25 +00:00
Dirk Herrmann
79d34f68e7 * numbers.c (mem2decimal_from_point): Cleaned up the parsing a
little bit - should even be somewhat more accurate now.
2001-10-09 20:56:36 +00:00
Rob Browning
d918965272 * gc.c: support ia64 register backing store.
(SCM_MARK_BACKING_STORE): new macro.
2001-10-09 03:33:16 +00:00
Rob Browning
766c5eaf49 * continuations.h: support ia64 register backing store.
(struct scm_t_contregs): add ia64 register backing store.
2001-10-09 03:33:06 +00:00
Rob Browning
193297d8b5 * continuations.c: support ia64 register backing store.
(continuation_mark): mark ia64 register backing store.
(continuation_free): free ia64 register backing store.
(scm_make_continuation): capture ia64 register backing store.
(copy_stack_and_call): copy ia64 register backing store.
2001-10-09 03:32:20 +00:00
Rob Browning
5e137c657b *** empty log message *** 2001-10-09 03:32:12 +00:00
Dirk Herrmann
ee083ac29f * hashtab.c (scm_hash_fn_create_handle_x): The result of assoc_fn
is known to be #f if no entry is found.  Thus, use !SCM_FALSEP
instead of SCM_NIMP to test for that case.

* strings.h (SCM_SET_STRING_LENGTH):  Cast the length to
scm_t_bits instead of long.
2001-10-08 21:23:00 +00:00