1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-16 08:40:19 +02:00

Refactor implementation of current-warning-port

* module/ice-9/boot-9.scm (current-warning-port):
* libguile/init.c (scm_init_standard_ports):
* libguile/ports.c (cur_warnport_fluid, scm_current_warning_port)
  (scm_set_current_warning_port, scm_init_ports): Define the warning
  port in the same way as the error/output/input ports, with a fluid
  that doesn't require calling out to Scheme.
This commit is contained in:
Andy Wingo 2016-07-14 16:18:47 +02:00
parent 1c98b78848
commit da757c6814
3 changed files with 22 additions and 34 deletions

View file

@ -223,6 +223,7 @@ scm_init_standard_ports ()
(scm_standard_stream_to_port (1, isatty (1) ? "w0" : "w"));
scm_set_current_error_port
(scm_standard_stream_to_port (2, isatty (2) ? "w0" : "w"));
scm_set_current_warning_port (scm_current_error_port ());
}