1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00
Commit graph

2229 commits

Author SHA1 Message Date
Mark H Weaver
2095033b42 Fix documentation of R6RS 'binary-port?' to reflect reality.
* doc/ref/r6rs.texi (rnrs io ports): Improve the descriptions of
'binary-port?' and 'textual-port?'.
* module/rnrs/io/ports.scm (binary-port?, textual-port?): Update the
docstrings.
2019-06-18 03:09:42 -04:00
Mark H Weaver
cc73c2ab5d Add get-bytevector-some!.
* libguile/r6rs-ports.c (scm_get_bytevector_some_x): New procedure.
* libguile/r6rs-ports.h (scm_get_bytevector_some_x): Add prototype.
(scm_unget_bytevector): Move prototype next to 'scm_get_bytevector_some_x'.
* module/ice-9/binary-ports.scm: Export 'get-bytevector-some!'.
* doc/ref/api-io.texi (Binary I/O): Document it.
2019-06-18 02:05:20 -04:00
Andy Wingo
9fd978ed7e Add bind-optionals instruction
* doc/ref/vm.texi (Function Prologue Instructions): Document new
  instruction.
* libguile/jit.c (compile_bind_optionals): New compiler.
* libguile/vm-engine.c (VM_NAME): New interpreter.
* module/system/vm/assembler.scm (opt-prelude): Emit bind-optionals as
  appropriate.
* module/system/vm/disassembler.scm (define-stack-effect-parser)
  (code-annotation): Handle bind-optionals.
2019-06-06 16:36:32 +02:00
Andy Wingo
6880ced4c2 Reference Lightening instead of GNU Lightning
* doc/ref/vm.texi (Just-In-Time Native Code): Update with link to
  Lightening.
2019-05-23 21:00:20 +02:00
Mark H Weaver
cca381ce17 Update user-visible copyright years.
* doc/ref/guile.texi: Update years in copyright notice.
* module/ice-9/command-line.scm (version-etc): Update 'copyright-year'.
* module/system/repl/common.scm (*version*): Update copyright years.
2019-05-23 17:40:59 +02:00
Daniel Llorens
347ec3f088 Support ~N in SRFI-19 string->date
* module/srfi/srfi-19.scm (fractional-integer-reader,
  make-fractional-integer-reader): From reference implementation.
  (reader-directives): Handle #\N, from reference implementation.
* test-suite/tests/srfi-19: Add tests for string->date ~N.
* doc/ref/srfi-modules.texi (string->date): Add line for ~N.
2019-05-23 17:14:27 +02:00
Mikael Djurfeldt
a83de07e35 Documentation fixes
* doc/ref/api-control:
* doc/ref/compiler.texi: Language fixes
* doc/ref/compiler ($kfun): Renamed argument clauses -> clause.
2019-05-23 17:14:21 +02:00
Mark H Weaver
e00563492a SRFI-19: Fix TAI->UTC conversions, leap second handling, etc.
Fixes <https://bugs.gnu.org/21911>.
Fixes <https://bugs.gnu.org/22034>.
Fixes <https://bugs.gnu.org/21902>.
Partially fixes <https://bugs.gnu.org/21904>.
Reported by Zefram <zefram@fysh.org>.

* doc/ref/srfi-modules.texi (SRFI-19 Introduction): Fix the definitions
of Julian Day and Modified Julian Day.  Give the correct full names of
UTC and TAI.
* module/srfi/srfi-19.scm: Import (srfi srfi-1).  Use modern Guile
keyword syntax in the 'define-module' form.
(leap-second-neg-delta): New procedure, derived from a similar procedure
in the latest upstream SRFI-19 reference implementation.
(priv:time-tai->time-utc!, time-tai->julian-day)
(time-monotonic->julian-day): Use 'leap-second-neg-delta'.
(local-tz-offset): Fix comment.
(leap-second?): Remove.
(tai-before-leap-second?): New procedure, derived from upstream SRFI-19.
(time-utc->date): Use 'define*' to handle the optional argument.  Remove
the leap second handling, following upstream SRFI-19.
(time-tai->date): Rewrite in terms of 'time-utc->date'.  Add special
leap second handling, following upstream SRFI-19.
(time-monotonic->date): Rewrite in terms of 'time-tai->date'.
(date->time-tai, date->time-monotonic): Add special leap second
handling, following upstream SRFI-19.
(directives): In the entry for the "~Y" escape in 'date->string', pad
the year field to 4 characters, following upstream SRFI-19.
* test-suite/tests/srfi-19.test: Add tests.
2019-05-23 17:13:03 +02:00
Chris Marusich
3c87313628 Clarify the manual's "Processes" section.
* doc/ref/posix.texi (Processes): Use the phrase "integer status value"
consistently, and add a cross-reference to the section of the glibc
manual that explains what it is.
2019-05-23 16:09:49 +02:00
Mark H Weaver
0c0a658c56 Improve the documentation for 'nil?'.
* libguile/boolean.c (scm_nil_p): Improve docstring.
* doc/ref/api-languages.texi (Nil): Add documentation for 'nil?', along
with a description of how Elisp interprets Scheme booleans and
end-of-list.
2019-05-23 15:53:55 +02:00
Ludovic Courtès
827e88b4b7 Define AT_SYMLINK_NOFOLLOW et al.
* libguile/posix.c (scm_init_posix): Define AT_SYMLINK_NOFOLLOW,
AT_SYMLINK_FOLLOW, AT_NO_AUTOMOUNT, and AT_EMPTY_PATH when available.
(scm_utime): Mention AT_SYMLINK_NOFOLLOW.
* doc/ref/posix.texi (File System): Update accordingly.
* test-suite/tests/posix.test ("utime")["AT_SYMLINK_NOFOLLOW"]: New test.
2019-05-23 15:43:28 +02:00
Mark H Weaver
423ad3632f Update user-visible copyright years.
* doc/ref/guile.texi: Update years in copyright notice.
* module/ice-9/command-line.scm (version-etc): Update 'copyright-year'.
* module/system/repl/common.scm (*version*): Update copyright years.
2019-04-16 16:54:55 -04:00
Daniel Llorens
f74cfce4f1 Support ~N in SRFI-19 string->date
* module/srfi/srfi-19.scm (fractional-integer-reader,
  make-fractional-integer-reader): From reference implementation.
  (reader-directives): Handle #\N, from reference implementation.
* test-suite/tests/srfi-19: Add tests for string->date ~N.
* doc/ref/srfi-modules.texi (string->date): Add line for ~N.
2018-12-11 22:44:34 +01:00
Mikael Djurfeldt
d81253b292 Documentation fixes
* doc/ref/api-control:
* doc/ref/compiler.texi: Language fixes
* doc/ref/compiler ($kfun): Renamed argument clauses -> clause.
2018-10-31 19:14:01 +01:00
Mikael Djurfeldt
1f6786db06 Another language fix
* doc/ref/vm.texi: Fix bad sentence.
2018-10-29 20:52:03 +01:00
Mikael Djurfeldt
52398d1db4 Language fix
* doc/ref/vm.texi: Fix bad sentence.
2018-10-29 16:00:44 +01:00
Mikael Djurfeldt
bb0860a0e5 Spelling fixes
* doc/ref/data-rep.texi: Spelling
* doc/ref/vm.texi: Spelling
2018-10-21 14:54:38 +02:00
Mark H Weaver
5106377a34 SRFI-19: Fix TAI->UTC conversions, leap second handling, etc.
Fixes <https://bugs.gnu.org/21911>.
Fixes <https://bugs.gnu.org/22034>.
Fixes <https://bugs.gnu.org/21902>.
Partially fixes <https://bugs.gnu.org/21904>.
Reported by Zefram <zefram@fysh.org>.

* doc/ref/srfi-modules.texi (SRFI-19 Introduction): Fix the definitions
of Julian Day and Modified Julian Day.  Give the correct full names of
UTC and TAI.
* module/srfi/srfi-19.scm: Import (srfi srfi-1).  Use modern Guile
keyword syntax in the 'define-module' form.
(leap-second-neg-delta): New procedure, derived from a similar procedure
in the latest upstream SRFI-19 reference implementation.
(priv:time-tai->time-utc!, time-tai->julian-day)
(time-monotonic->julian-day): Use 'leap-second-neg-delta'.
(local-tz-offset): Fix comment.
(leap-second?): Remove.
(tai-before-leap-second?): New procedure, derived from upstream SRFI-19.
(time-utc->date): Use 'define*' to handle the optional argument.  Remove
the leap second handling, following upstream SRFI-19.
(time-tai->date): Rewrite in terms of 'time-utc->date'.  Add special
leap second handling, following upstream SRFI-19.
(time-monotonic->date): Rewrite in terms of 'time-tai->date'.
(date->time-tai, date->time-monotonic): Add special leap second
handling, following upstream SRFI-19.
(directives): In the entry for the "~Y" escape in 'date->string', pad
the year field to 4 characters, following upstream SRFI-19.
* test-suite/tests/srfi-19.test: Add tests.
2018-10-20 17:23:39 -04:00
Chris Marusich
8cdd3a0773 Clarify the manual's "Processes" section.
* doc/ref/posix.texi (Processes): Use the phrase "integer status value"
consistently, and add a cross-reference to the section of the glibc
manual that explains what it is.
2018-10-14 17:57:50 -04:00
Mark H Weaver
b44f505f15 Improve the documentation for 'nil?'.
* libguile/boolean.c (scm_nil_p): Improve docstring.
* doc/ref/api-languages.texi (Nil): Add documentation for 'nil?', along
with a description of how Elisp interprets Scheme booleans and
end-of-list.
2018-10-14 01:37:37 -04:00
Andy Wingo
94e66d2384 Minor additional manual updates
* doc/ref/api-debug.texi (VM Hooks): Update for changes in VM hook API.
* doc/ref/guile.texi: Update copyright years.
* doc/ref/preface.texi (Contributors): Update.
2018-10-07 12:28:51 +02:00
Andy Wingo
a3b32f839b Add manual section on JIT compiler
* doc/ref/vm.texi (Just-In-Time Native Code): New section.
* doc/ref/compiler.texi (Extending the Compiler): Update.
2018-10-07 11:36:45 +02:00
Andy Wingo
6a243e1ba0 Update compiler.texi
* doc/ref/compiler.texi: Update for compiler changes in Guile 3.
2018-10-03 23:24:22 +02:00
Andy Wingo
4e8d27f0d1 Finish updating vm.texi
* doc/ref/compiler.texi (Bytecode): Update macro-assembler instructions,
  and move most of them to the instruction set reference.
* doc/ref/vm.texi (A Virtual Machine for Guile, VM Programs): Minor
  fixes.
(Instruction Set): Update for Guile 3 instruction set.
* libguile/vm-engine.c (vm_engine): Update a few instruction
  docstrings.
2018-09-30 16:08:40 +02:00
Andy Wingo
4c53593bbe Update "Variables and the VM"
* doc/ref/vm.texi (Variables and the VM): Update.
2018-09-28 12:24:06 +02:00
Andy Wingo
5e671cea02 Update "Stack Layout"
* doc/ref/vm.texi (Stack Layout): Update.
2018-09-28 12:15:58 +02:00
Andy Wingo
7e623d1014 Update "VM Concepts"
* doc/ref/vm.texi (VM Concepts): Update.
2018-09-28 12:15:30 +02:00
Andy Wingo
2018609a69 Update "Why a VM?"
* doc/ref/vm.texi (Why a VM?): Update.
2018-09-28 12:14:55 +02:00
Andy Wingo
f1b745eec5 Update "A Virtual Machine for Guile"
* doc/ref/vm.texi (A Virtual Machine for Guile): Update.
2018-09-28 12:14:09 +02:00
Andy Wingo
6be54f4526 Update data representation chapter in the manual
* doc/ref/data-rep.texi (The SCM Type in Guile): Refer to scm.h.
(Relationship Between SCM and scm_t_bits): Better title-case.
(Immediate Objects): Better title-case.  Prefer "heap object" over
"cell".
(Non-Immediate Objects): Better title-case.  Deprecate the concept of
cells.
(Allocating Heap Objects): Rename from Allocating Cells.
(Heap Object Type Information): Rename from Heap Cell Type Information.
(Accessing Heap Object Fields): Rename from Accessing Cell Entries.
* doc/ref/vm.texi: Update references.
2018-09-27 13:48:09 +02:00
Andy Wingo
a691540703 Update Conservative GC section of manual
* doc/ref/data-rep.texi (Conservative GC): Update notes with more
  details.
2018-09-27 09:50:37 +02:00
Andy Wingo
179f6610a2 Update history.texi.
* doc/ref/history.texi (A Timeline of Selected Guile Releases)
(Status): Update.
2018-09-25 10:44:08 +02:00
Ludovic Courtès
3ee7673cc9 Define AT_SYMLINK_NOFOLLOW et al.
* libguile/posix.c (scm_init_posix): Define AT_SYMLINK_NOFOLLOW,
AT_SYMLINK_FOLLOW, AT_NO_AUTOMOUNT, and AT_EMPTY_PATH when available.
(scm_utime): Mention AT_SYMLINK_NOFOLLOW.
* doc/ref/posix.texi (File System): Update accordingly.
* test-suite/tests/posix.test ("utime")["AT_SYMLINK_NOFOLLOW"]: New test.
2018-09-23 16:41:13 +02:00
Ludovic Courtès
c6f70e4b04 Add -Wshadowed-toplevel.
* module/language/tree-il/analyze.scm (shadowed-toplevel-analysis): New
variable.
* module/language/tree-il/compile-cps.scm (%warning-passes): Add it.
* module/system/base/message.scm (%warning-types): Add it.
* test-suite/tests/tree-il.test ("warnings")["shadowed-toplevel"]: New
test prefix.
* module/ice-9/boot-9.scm (%auto-compilation-options): Add it.
* doc/ref/api-evaluation.texi (Compilation): Add 'shadowed-toplevel' and
'macro-use-before-definition'.
2018-08-07 12:34:32 +02:00
Ludovic Courtès
44cdabd9e3 compile: Add '-x' flag.
* module/scripts/compile.scm (%options, compile): Add '-x'.
* doc/ref/api-evaluation.texi (Compilation): Document it.
2018-08-07 12:34:11 +02:00
Ludovic Courtès
2656f37c87 Update copyright years in '--version' and the manual.
* module/ice-9/command-line.scm (version-etc): Change #:copyright-year
to 2018.
* doc/ref/guile.texi: Add 2017 and 2018 to the copyright years.
* configure.ac (GUILE_CONFIGURE_COPYRIGHT): Add 2018.
2018-08-07 12:31:54 +02:00
Arun Isaac
e40b5b54ff web: Export http-request.
* module/web/client.scm (request): Rename to http-request, add a
docstring, and export it.
(http-get, http-head, http-post, http-put, http-delete, http-trace,
http-options): Update docstring.
* doc/ref/web.texi (Web Client): Document http-request.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-08-07 12:13:19 +02:00
Arun Isaac
f0c045443f doc: Document (ice-9 match) macros.
* doc/ref/match.texi: Document match-lambda, match-lambda*, match-let,
  match-let* and match-letrec.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-08-07 12:09:39 +02:00
Ludovic Courtès
b77d7b0204 doc: Fix typo.
Fixes <https://bugs.gnu.org/30941>.
Reported by Fis Trivial <ybbs.daans@hotmail.com>.

* doc/ref/libguile-foreign-objects.texi (Defining Foreign Object Types):
Remove extraneous 'image_type' in example.
2018-08-07 12:09:33 +02:00
Christopher Allan Webber
26fc11a2ae Add SRFI 71: Extended LET-syntax for multiple values.
* module/srfi/srfi-71.scm: New file.
* module/srfi/Makefile.am: Add it.
* doc/ref/srfi-modules.texi: Document it.
* NEWS: Update.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-08-07 12:08:56 +02:00
Arun Isaac
a600b9f186 Fix minor typo in the PEG documentation.
* doc/ref/api-peg.texi (PEG Internals): Fix minor typo.

Signed-off-by: Mark H Weaver <mhw@netris.org>
2018-08-07 11:41:06 +02:00
Mark H Weaver
313b1c4469 Fix a few typos in the manual.
Fixes <https://bugs.gnu.org/30276>.
Reported by Matt Wette <matt.wette@gmail.com>.

* doc/ref/api-macros.texi (Macro Expansion)
doc/ref/vm.texi (Procedure Call and Return Instructions): Fix typos.
2018-08-07 11:41:01 +02:00
Ludovic Courtès
4024a5beb3 doc: Fix typo about SRFI-4 syntax.
Reported by Matt Wette <matt.wette@gmail.com>.
Fixes <https://bugs.gnu.org/29910>.

* doc/ref/api-data.texi (Array Syntax): Fix typo.
2018-08-07 11:40:22 +02:00
Ludovic Courtès
f7e306b863 doc: Update LALR URL.
Reported by Chris Vine <vine35792468@gmail.com>.

* doc/ref/api-lalr.texi (LALR(1) Parsing): Update URL.
2018-08-07 11:33:06 +02:00
Ludovic Courtès
bdcd0ba8a7 Add -Wshadowed-toplevel.
* module/language/tree-il/analyze.scm (shadowed-toplevel-analysis): New
variable.
* module/language/tree-il/compile-cps.scm (%warning-passes): Add it.
* module/system/base/message.scm (%warning-types): Add it.
* test-suite/tests/tree-il.test ("warnings")["shadowed-toplevel"]: New
test prefix.
* module/ice-9/boot-9.scm (%auto-compilation-options): Add it.
* doc/ref/api-evaluation.texi (Compilation): Add 'shadowed-toplevel' and
'macro-use-before-definition'.
2018-07-24 11:53:02 +02:00
Ludovic Courtès
887e495c6b compile: Add '-x' flag.
* module/scripts/compile.scm (%options, compile): Add '-x'.
* doc/ref/api-evaluation.texi (Compilation): Document it.
2018-07-19 18:00:19 +02:00
Ludovic Courtès
be1e6e6ab0 Update copyright years in '--version' and the manual.
* module/ice-9/command-line.scm (version-etc): Change #:copyright-year
to 2018.
* doc/ref/guile.texi: Add 2017 and 2018 to the copyright years.
* configure.ac (GUILE_CONFIGURE_COPYRIGHT): Add 2018.
2018-07-01 23:33:26 +02:00
Arun Isaac
919979ac39 web: Export http-request.
* module/web/client.scm (request): Rename to http-request, add a
docstring, and export it.
(http-get, http-head, http-post, http-put, http-delete, http-trace,
http-options): Update docstring.
* doc/ref/web.texi (Web Client): Document http-request.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-06-23 23:32:13 +02:00
Arun Isaac
1c970da59e doc: Document (ice-9 match) macros.
* doc/ref/match.texi: Document match-lambda, match-lambda*, match-let,
  match-let* and match-letrec.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-06-18 14:14:47 +02:00
Ludovic Courtès
33363f7ec3 doc: Fix typo.
Fixes <https://bugs.gnu.org/30941>.
Reported by Fis Trivial <ybbs.daans@hotmail.com>.

* doc/ref/libguile-foreign-objects.texi (Defining Foreign Object Types):
Remove extraneous 'image_type' in example.
2018-06-18 14:14:47 +02:00