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

2496 commits

Author SHA1 Message Date
Rutger van Beusekom
786fbcd327 popen: Add 'pipeline' procedure.
* libguile/posix.c (scm_open_process): Remove.
(scm_piped_process): Add to replace open_process.
* module/ice-9/popen.scm (pipe->fdes): Add to convert pipe pair to fdes pair.
(open-process): Add open-process for backwards compatibility.
(pipeline): Add to implement a pipeline using piped-process.
* doc/ref/posix.texi (Pipes): Document it.
* test-suite/tests/popen.test ("open-process")
("piped-process", "piped-process: with output")
("pipeline"): New tests.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-05-16 22:36:19 +02:00
Andy Wingo
3385f6e08c Update NEWS for baseline compiler
* NEWS: Update.
2020-05-12 11:10:03 +02:00
Andy Wingo
6083020199 Update documentation on <language>
* doc/ref/compiler.texi (Compiler Tower): Update.
2020-05-12 10:43:10 +02:00
Andy Wingo
d6b6daca37 Add intrinsics for a baseline compiler
Since there's no optimization in the baseline compiler, there's no sense
in instruction explosion.

* libguile/intrinsics.h:
* libguile/intrinsics.c ($car, $cdr, $set-car!, $set-cdr!,
  $variable-ref, $variable-set!, $vector-length, $vector-ref,
  $vector-set!, $vector-ref/immediate, $vector-set!, $allocate-struct,
  $struct-vtable, $struct-ref, $struct-set!  $struct-ref/immediate,
  $struct-set!): New intrinsics.
* libguile/jit.c (compile_call_scm_scm, compile_call_scm_scm_slow)
  (compile_call_scm_scm_scm, compile_call_scm_scm_scm_slow)
  (compile_call_scm_uimm_scm, compile_call_scm_uimm_scm_slow): New
  code generators.
* libguile/vm-engine.c (call-scm-scm, call-scm-scm-scm,
  call-scm-uimm-scm): New instructions.
* module/system/vm/assembler.scm (emit-null?, emit-false?, emit-nil?):
  Export these.  Also export emitters for the new intrinsics.
  (define-scm-scm-intrinsic, define-scm-uimm-scm-intrinsic)
  (define-scm-scm-scm-intrinsic): New helpers.
* doc/ref/vm.texi (Intrinsic Call Instructions): Add new instructions.
2020-04-29 21:47:37 +02:00
Andy Wingo
607183679e Deprecate scm_bitvector, scm_make_bitvector, scm_bitvector_p
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c:
* libguile/deprecated.c:
* libguile/deprecated.h: Deprecate scm_bitvector, scm_make_bitvector,
  and scm_bitvector_p.
* libguile/read.c (scm_read_guile_bit_vector): Use scm_list_to_bitvector
  instead of scm_bitvector.
2020-04-29 11:14:17 +02:00
Andy Wingo
8861af39ae Prefer C-like interfaces for scm_c_bitvector_{set,clear}_bits_x
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_set_bits_x)
  (scm_c_bitvector_clear_bits_x): Expose only C-like interfaces.  No
  need to have a SCM_UNDEFINED return.
* libguile/deprecated.c (scm_bit_set_star_x): Adapt.
* doc/ref/api-data.texi (Bit Vectors): Update.
2020-04-29 11:14:17 +02:00
Andy Wingo
b517a91ba4 Deprecate useless C bitvector interface
C should use scm_c_bitvector_length, not scm_bitvector_length.

* doc/ref/api-data.texi (Bit Vectors): Reorganize a bit to put typed C
  interfaces in their own section.
* libguile/bitvectors.h:
* libguile/bitvectors.c (bitvector-length, bitvector-count): Make
  SCM-flavored C interface private.
  (scm_c_bitvector_count): New function.
* libguile/deprecated.c (scm_bitvector_length): Deprecate.
  (scm_bit_count): Adapt to changes.
2020-04-29 11:14:17 +02:00
Andy Wingo
bfd38b8577 bitvector-count-bits replaces bit-count*
* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_count_bits): New function.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bit_count_star): Deprecate.
* module/ice-9/sandbox.scm (bitvector-bindings): Replace bit-count* with
  bitvector-count-bits.
* test-suite/tests/bitvectors.test: Update.
2020-04-29 11:14:17 +02:00
Matt Wette
d3d7696072 doc: Fix typo.
* doc/ref/tour.texi (Reporting Bugs): Fix typo.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-04-26 16:30:31 +02:00
Andy Wingo
f897efa9f1 bitvector-flip-all-bits! replaces bit-invert!
* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_flip_all_bits_x): New function.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bit_invert_x): Deprecate.
* module/ice-9/sandbox.scm (mutable-bitvector-bindings): Replace
  bit-invert! with bitvector-flip-all-bits!.
* module/system/vm/frame.scm (available-bindings): Use the new
  interface.
* test-suite/tests/bitvectors.test: Update.
2020-04-18 22:16:31 +02:00
Andy Wingo
d7fea13453 bitvector-set-all-bits! / bitvector-clear-all-bits! replace bitvector-fill!
* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_set_all_bits_x)
  (scm_c_bitvector_clear_all_bits_x): New functions.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bitvector_fill_x): Deprecate.
* module/ice-9/sandbox.scm (mutable-bitvector-bindings): Replace
  bitvector-fill! with bitvector-set-all-bits! /
  bitvector-clear-all-bits!.
* module/system/vm/disassembler.scm (static-opcode-set): Use
  bitvector-set-bit!.
* module/system/vm/frame.scm (available-bindings): Use the new
  interfaces.
* test-suite/tests/bitvectors.test: Update.
2020-04-15 22:14:25 +02:00
Andy Wingo
8110061e64 bitvector-set-bit! / bitvector-clear-bit! replace bitvector-set!
* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/array-handle.h (bitvector_set_x, scm_array_get_handle): Adapt
  to bitvector changes.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_set_bit_x)
  (scm_c_bitvector_clear_bit_x): New functions.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bitvector_set_x): Deprecate.
* module/ice-9/sandbox.scm (mutable-bitvector-bindings): Replace
  bitvector-set! with bitvector-set-bit! / bitvector-clear-bit!.
* module/system/vm/disassembler.scm (static-opcode-set): Use
  bitvector-set-bit!.
* module/system/vm/frame.scm (compute-defs-by-slot, available-bindings):
  Use bitvector-set-bit!.
* test-suite/tests/bitvectors.test: Update.
2020-04-14 22:40:43 +02:00
Andy Wingo
d804177be4 bitvector-bit-set? / bitvector-bit-clear? replace bitvector-ref
This is an opportunity to make a new interface that can be more
efficient in 3.0 (because no generic array support), easier to read (no
need for 'not'), and more consistent with other bitvector interfaces.

* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/array-handle.h (bitvector_ref, scm_array_get_handle): Adapt
  to bitvector changes.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_c_bitvector_bit_is_set)
  (scm_c_bitvector_bit_is_clear): New functions.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bitvector_ref): Deprecate.
* module/ice-9/sandbox.scm (bitvector-bindings): Replace
  bitvector-ref with bitvector-bit-set? / bitvector-bit-clear?.
* module/system/vm/disassembler.scm (instruction-has-fallthrough): Use
  bitvector-bit-clear?.
* test-suite/tests/bitvectors.test: Update.
2020-04-14 22:18:02 +02:00
Andy Wingo
ff9979b6bc Replace bit-set*! with bitvector-set-bits! / bitvector-clear-bits!
The old name was wonky and hard to read: you almost always pass a
literal as the value to set, so better to make separate functions.

* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_bitvector_set_bits_x)
  (scm_bitvector_clear_bits_x): New functions.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bit_set_star_x): Deprecate.
* module/ice-9/sandbox.scm (mutable-bitvector-bindings): Replace
  bit-set*! with bitvector-set-bits! / bitvector-clear-bits!.
* module/system/vm/frame.scm (available-bindings, compute-killv): Use
  bitvector-set-bits! and bitvector-clear-bits!.
* test-suite/tests/bitvectors.test: Update.
2020-04-13 22:06:56 +02:00
Andy Wingo
06709d77b9 Replace bit-position with bitvector-position
The old name was wonky and had bad argument order.

* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (scm_bitvector_position): New function.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bit_position): Deprecate.
* module/ice-9/sandbox.scm (bitvector-bindings): Replace bit-position
  with bitvector-position.
* module/language/cps/intset.scm (bitvector->intset): Use
  bitvector-position.
* module/system/vm/frame.scm (available-bindings): Use
  bitvector-position.
* test-suite/tests/bitvectors.test ("bitvector-position"): Add test.
2020-04-12 22:39:55 +02:00
Andy Wingo
cae74359de Replace bit-count with bitvector-count
The old name was wonky and had bad argument order.

* NEWS: Add entry.
* doc/ref/api-data.texi (Bit Vectors): Update.
* libguile/bitvectors.h:
* libguile/bitvectors.c (VALIDATE_BITVECTOR): New helper.
  (scm_bitvector_count): New function.
* libguile/deprecated.h:
* libguile/deprecated.c (scm_bit_count): Deprecate.
* module/ice-9/sandbox.scm (bitvector-bindings): Replace bit-count with
  bitvector-count.
* module/srfi/srfi-60.scm: No need to #:replace bit-count.
* module/system/vm/frame.scm (available-bindings): Use bitvector-count.
* test-suite/tests/bitvectors.test ("bitvector-count"): Add test.
2020-04-12 22:17:22 +02:00
Andy Wingo
24a34074ef Deprecate bitvector-ref on array slices
* NEWS: Update.
* doc/ref/api-data.texi (Bit Vectors): Update documentation on bit-set*!
  and bit-count*.
* libguile/bitvectors.c: Add a to-do list.
  (scm_c_bitvector_ref, scm_c_bitvector_set_x, scm_bitvector_fill_x)
  (scm_bitvector_to_list, scm_bit_count, scm_bit_position):
  Issue deprecation warnings when used on array slices.
  (scm_list_to_bitvector): Simplify.
  (scm_bit_set_star_x, scm_bit_count_star): Deprecate arrays as target
  bitvectors, and also use of u32vector as selection vector.
* libguile/bitvectors.h:
* libguile/deprecated.h:
* libguile/deprecated.c (scm_istr2bve): Deprecate.
* test-suite/tests/bitvectors.test ("bit-count*"): Remove test of u32
  selectors.
2020-04-12 21:36:30 +02:00
Matt Wette
e37b1fb34c doc: Improve tree-il 'lambda-case' description.
* doc/ref/compiler.texi (Tree-IL): for description of lambda-case
argument 'kw' added "or @code{#f} if there are no keyword arguments".

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-03-28 12:42:09 +01:00
Arun Isaac
b9a09f1ec3 doc: Replace square brackets with round brackets.
* doc/ref/sxml-match.texi: Replace all square brackets with round
brackets in order to be consistent with the rest of the documentation.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-03-25 22:50:26 +01:00
Linus Björnstam
5f60eb6bb5 Add SRFI-171 to guile
This adds SRFI-171 (transducers) to guile.

The two guile-specific additions are powerful transducers which can be
used to generalize transducers like tsegment. They are hard to get
right, but powerful and useful enough to warrant inclusion.

 * doc/ref/srfi-modules.texi: added srfi-171 section
 * module/Makefile.am (SOURCES):
 * module/srfi/srfi-171.scm:
 * module/srfi/srfi-171/meta.scm: Add SRFI-171
 * module/srfi/srfi-171/gnu.scm: Add 2 guile-specific extensions.
 * test-suite/Makefile.am (SCM_TESTS):
 * test-suite/tests/srfi-171.test: Add tests.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-03-25 22:44:27 +01:00
Isaac Jurado
bef5e0b393 Interpret dynamic library name as literal file name first.
Fixes <https://bugs.gnu.org/21076>.

* libguile/dynl.c (sysdep_dyn_link): Try plain lt_dlopen first, to
  interpret fname as a literal path.
* doc/ref/api-foreign.texi: Update explanation to describe the new
  behavior.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2020-03-22 00:27:12 +01:00
Jan Synacek
18c7637640 doc: Fix typo in api-debug.texi.
* doc/ref/api-debug.texi (Debugging): Fix typo.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-03-11 12:14:24 +01:00
Ludovic Courtès
41d470f0e9 Reintroduce 'SCM_MEMORY_ERROR' in terms of 'scm_report_out_of_memory'.
Suggested by Dale P. Smith <dsmich@roadrunner.com>.

* libguile/deprecated.h (SCM_MEMORY_ERROR): New macro.
* doc/ref/api-control.texi (Dynamic Wind): Use 'scm_report_out_of_memory'.
2020-02-11 14:47:16 +01:00
Ludovic Courtès
1a3e316c32 Remove traces of 'scm_memory_error'.
'scm_memory_error' was deprecated in 2014 in commit
c2247b782a and removed in 2017 in commit
c248ea10be.  This is a followup.

* libguile/error.h (SCM_MEMORY_ERROR): Remove.
* doc/guile-api.alist: Remove 'scm_memory_error'.
* doc/ref/api-control.texi (Handling Errors): Likewise.
(Dynamic Wind): Use 'scm_misc_error' instead of 'scm_memory_error'.
2020-02-10 00:10:10 +01:00
Ludovic Courtès
c4b2bd3781 texinfo: Add '*line-width*' fluid to control line wrapping.
* module/texinfo/plain-text.scm (*line-width*): New variable.
(wrap*): Honor it.
* doc/ref/texinfo.texi (texinfo plain-text): Document it.
* test-suite/tests/texinfo.plain-text.test: New file.
* test-suite/Makefile.am (SCM_TESTS): Add it.
2020-01-29 15:19:37 +01:00
Daniel Llorens
0fee413ff8 Clarify open-input-pipe example in doc 2020-01-24 12:28:29 +01:00
shack@muto.ca
656ce936ed doc: Use gender-neutral language in Preface
* doc/ref/preface.texi: Avoid gendered pronoun.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2020-01-20 10:23:33 +01:00
Andy Wingo
20219f4037 Update release.org
* doc/release.org: Update for 3.0
2020-01-15 21:15:47 +01:00
Andy Wingo
eadeda40f5 Wording tweak to history.texi
* doc/ref/history.texi (A Scheme of Many Maintainers): Fix wording.
2020-01-13 21:35:15 +01:00
Andy Wingo
838135ca0d Mention Mark Weaver in Guile history section
* doc/ref/history.texi (A Scheme of Many Maintainers): Credit to Mark
  for co-maintaining Guile for more than 5 years.  Thanks!!
2020-01-13 21:33:29 +01:00
Ludovic Courtès
38f14ce65d web: 'open-socket-for-uri' can verify the server's X.509 certificate.
This is largely based on Guix commit
bc3c41ce36349ed4ec758c70b48a7059e363043a and subsequent changes to that
code.

* module/web/client.scm (x509-certificate-directory): New variable.
(set-certificate-credentials-x509-trust-file!*)
(make-credendials-with-ca-trust-files, peer-certificate)
(assert-valid-server-certificate, print-tls-certificate-error): New
procedures.
<top level>: Add call to 'set-exception-printer!'.
(tls-wrap): Add #:verify-certificate? parameter.  When it is true, call
'make-credendials-with-ca-trust-files', pass it to
'set-session-credentials!', and call 'assert-valid-server-certificate'.
(open-socket-for-uri): Add #:verify-certificate? parameter and pass it
to 'tls-wrap'.
(http-request): Add #:verify-certificate? parameter and pass it to
'open-socket-for-uri'.
(define-http-verb): Add #:verify-certificate? parameter and pass it to
'http-request'.
* doc/ref/web.texi (Web Client): Update documentation of
'open-socket-for-uri' and 'http-request'.  Document
'x509-certificate-directory'.
2020-01-13 11:06:01 +01:00
Ludovic Courtès
80bbebef4d web: Add 'current-https-proxy' and honor $https_proxy.
* module/web/client.scm (current-https-proxy): New variable.
(setup-http-tunnel): New procedure.
(open-socket-for-uri): Move 'http-proxy', 'uri', and 'addresses' inside
'open-socket'.  Remove 'with-https-proxy' macro.  Add call to
'setup-http-tunnel'.  Honor 'current-https-proxy' in 'open-socket'.
* doc/ref/web.texi (Web Client): Document 'current-https-proxy'.
* doc/ref/guile.texi: Update copyright years.

Based on Guix commit 9bc8175cfa6b23c31f6c43531377d266456e430e.

Co-authored-by: Sou Bunnbu (宋文武) <iyzsong@gmail.com>
2020-01-13 11:06:01 +01:00
Andy Wingo
287d513ef1 Bump manual year, and fix NEWS typo
* NEWS: Fix a typo.
* doc/ref/guile.texi: Bump copyright year.
2020-01-13 09:52:01 +01:00
Andy Wingo
86a9f9a271 Optionally allow duplicate field names in core records
* NEWS: Update.
* doc/ref/api-data.texi (Records): Update docs.
* module/ice-9/boot-9.scm (make-record-type): Add
  #:allow-duplicate-field-names? keyword argument.
  (record-accessor, record-modifier): Allow passing indexes to identify
  fields.
* module/rnrs/records/procedural.scm (make-record-type-descriptor):
  Allow duplicate field names.  Fixes #38611.
2020-01-12 21:51:22 +01:00
Andy Wingo
ba05f1dd6d Mention WebAssembly in status section
* doc/ref/history.texi (Status): Add mention of WebAssembly.
2020-01-06 21:51:02 +01:00
Andy Wingo
272bc09d97 Update compiler.texi and history.texi
* doc/ref/compiler.texi (Extending the Compiler):
* doc/ref/history.texi (A Timeline of Selected Guile Releases):
  (Status): Update.  Thanks to Mikael Djurfeldt for the bug report.
2020-01-06 21:45:33 +01:00
Daniel Llorens
6cfee36543 New function string-replace-substring in (ice-9 string-fun)
By A. Wingo in
https://lists.gnu.org/archive/html/guile-devel/2014-03/msg00058.html.

* module/ice-9/string-fun.scm (string-replace-substring): As stated.
* doc/ref/api-data.texi: Document the new function.
* test-suite/tests/strings.test: Test.
2020-01-06 09:44:01 +01:00
Andy Wingo
c23fe0ec5a Document JIT environment variables
* doc/ref/guile-invoke.texi (Environment Variables): Remove
  GUILE_STACK_SIZE which is no longer needed, and document some JIT
  debugging environment variables.
* doc/ref/vm.texi (Why a VM?, Just-In-Time Native Code): Update and link
  to environment variables documentation.
2019-12-11 21:55:49 +01:00
Andy Wingo
0f61d8d797 Add --r6rs and --r7rs options to "guild compile"
* module/scripts/compile.scm (%options, compile): Add --r6rs and --r7rs
  options.
* doc/ref/api-evaluation.texi (Compilation): Add docs.
2019-12-02 17:32:34 +01:00
Andy Wingo
82127b3ad9 Add guile-3, r6rs, r7rs cond-expand features
* module/ice-9/boot-9.scm (%cond-expand-features): Add new features.
* doc/ref/srfi-modules.texi (SRFI-0): Document new features.
2019-12-02 14:34:52 +01:00
Andy Wingo
cf08dbdc18 Associate #:replace info with modules, not variables
* doc/ref/api-modules.texi (Creating Guile Modules): Document
  #:re-export-and-replace.
* module/ice-9/boot-9.scm (module-replacements): New module field.
  (make-module, make-autoload-interface): Initialize replacements to an
  empty hash table.
  (resolve-interface): Propagate replacement info when making custom
  interfaces.
  (define-module): Parse a #:re-export-and-replace keyword arg.
  (define-module*): Handle #:re-export-and-replace.
  (module-export!, module-re-export!): Add a keyword arg to indicate
  whether to replace or not.
  (module-replace!): Call module-export! with #:replace? #t.
  (duplicate-handlers): Update replace duplicate handler to look for
  replacement info on the interfaces.
* module/srfi/srfi-18.scm (srfi):
* module/srfi/srfi-34.scm (srfi): Update to #:re-export-and-replace
  raise-continuable as raise.
2019-11-29 11:51:29 +01:00
Andy Wingo
59febb4b2d Fix port-position documentation
* doc/ref/r6rs.texi (rnrs io ports): Update the translation for
  port-position.
2019-11-25 09:47:04 +01:00
Andy Wingo
cc3190ed95 Fix texinfo in r7rs.texi
* doc/ref/r7rs.texi (R7RS Standard Libraries): Fix syntax.
2019-11-22 15:56:24 +01:00
Andy Wingo
1907e59c09 Install exception converters and printers from boot-9
* doc/ref/intro.texi (Guile and Scheme): Fix a date.
* module/ice-9/boot-9.scm: Load (ice-9 exceptions).
2019-11-21 16:48:35 +01:00
Andy Wingo
b634071dd4 Add R7RS documentation and --r7rs command-line option
* doc/ref/Makefile.am: Add r7rs.texi.
* doc/ref/guile-invoke.texi (Command-line Options): Document --r7rs.
* doc/ref/guile.texi (Guile Modules): Link to R7RS.
* doc/ref/intro.texi (Guile and Scheme): Update for R7RS support.
* doc/ref/r7rs.texi: New file.
* doc/ref/scheme-intro.texi (Guile Scheme): Update for R7RS.
* module/ice-9/command-line.scm (*usage*, compile-shell-switches): Add
  --r7rs option.
2019-11-17 15:30:59 +01:00
Andy Wingo
4b2c512b94 Update NEWS for records and exceptions work
* NEWS: Update.
* doc/ref/api-data.texi (Records): Fix a typo.
2019-11-14 21:37:00 +01:00
Andy Wingo
44ee8c5559 Update documentation for with-exception-handler et al
* doc/ref/api-control.texi (Prompt Primitives): Reference the newer
  exception facilities.
  (Exceptions): Rewrite to use the new exception primitives.
  (Exception Terminology): Remove superfluous section.
  (Exception Objects): New section.
  (Raising and Handling Exceptions): New section.
  (Throw and Catch): New section, coalescing the previous catch,
  with-throw-handler, and throw sections.
  (Exceptions and C): New section, for miscellaneous procedures.
  (Handling Errors): Mention the transitional period regarding exception
  handling.
* doc/ref/api-debug.texi (Catching Exceptions): Rewrite to use newer
  exception facilities.
  (Capturing Stacks): Remove, as it's not really recommendable any
  more.
  (Pre-Unwind Debugging): Rewrite to use the new primitives.
  (Standard Error Handling): Add note about transitional status.
  (Stack Overflow): Reference new exception section.
* doc/ref/api-scheduling.texi (Mutexes and Condition Variables):
  Reference new exception section.
* doc/ref/r6rs.texi (rnrs exceptions, rnrs conditions): Update to
  mention compatibility with SRFI-34/35 and to relate to core
  exceptions.
* doc/ref/srfi-modules.texi (SRFI-34): Document.
2019-11-13 22:33:09 +01:00
Andy Wingo
315fabdfe7 Add support for immutable fields in core records
* module/ice-9/boot-9.scm (make-record-type): Allow (mutable NAME)
  or (immutable NAME) as a field name, and record field mutability in a
  bitfield.
  (record-modifier): Throw an error if the field isn't mutable.
* test-suite/tests/records.test ("records"): Add tests.
* doc/ref/api-data.texi (Records): Update.
2019-10-28 16:59:58 +01:00
Andy Wingo
f963bdf02d Rename final? record type flag; add support for opaque?
* module/ice-9/boot-9.scm (record-type-extensible?): Rename from
  record-type-final?, with the opposite sense.
  (record-type-opaque?): New accessor.
  (make-record-type): Change #:final? to #:extensible?, with the
  opposite meaning.  Add #:opaque? arg.
* test-suite/tests/records.test ("records"): Add opaque tests; update
  extensible tests.
* doc/ref/api-data.texi (Records): Update.
* module/srfi/srfi-35.scm (&condition, make-condition-type): Update for
  make-record-type API change.
2019-10-27 21:31:18 +01:00
Andy Wingo
7a8e314d31 Guile `make-record-type' supports non-generative definition
* module/ice-9/boot-9.scm (prefab-record-types): New definition.
  (make-record-type): Add #:uid keyword.
* test-suite/tests/records.test ("records"): Add tests.
* doc/ref/api-data.texi (Records): Document #:uid
2019-10-27 20:55:01 +01:00