From 56128b054f63f45c96f6fdbe0f3576c5fe49821b Mon Sep 17 00:00:00 2001 From: Matt Birkholz Date: Fri, 22 Nov 2013 13:54:41 -0700 Subject: [PATCH] Add load-option/suppress-loading-message? for load-ffi-quietly. --- src/runtime/ffi.scm | 2 +- src/runtime/option.scm | 10 +++++++--- src/runtime/runtime.pkg | 3 ++- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/runtime/ffi.scm b/src/runtime/ffi.scm index 8266650c1..6da746fe8 100644 --- a/src/runtime/ffi.scm +++ b/src/runtime/ffi.scm @@ -547,7 +547,7 @@ USA. (define (load-ffi-quietly) (if (not (name->package '(FFI))) (let ((kernel (lambda () - (fluid-let ((load/suppress-loading-message? #t)) + (fluid-let ((load-option/suppress-loading-message? #t)) (load-option 'FFI))))) (if (nearest-cmdl/batch-mode?) (kernel) diff --git a/src/runtime/option.scm b/src/runtime/option.scm index bcb9ec430..c7470fbcd 100644 --- a/src/runtime/option.scm +++ b/src/runtime/option.scm @@ -29,6 +29,8 @@ USA. (declare (usual-integrations)) +(define load-option/suppress-loading-message? #f) + (define (load-option name #!optional no-error?) (let ((no-error? (and (not (default-object? no-error?)) no-error?))) @@ -40,9 +42,11 @@ USA. (define (notifier option) (named-lambda (notify port) - (write-string "Loading " port) - (write-string (symbol-name option) port) - (write-string " option" port))) + (if (not load-option/suppress-loading-message?) + (begin + (write-string "Loading " port) + (write-string (symbol-name option) port) + (write-string " option" port))))) (define (load-entry entry) (with-notification diff --git a/src/runtime/runtime.pkg b/src/runtime/runtime.pkg index cb47a8165..ea6aac30e 100644 --- a/src/runtime/runtime.pkg +++ b/src/runtime/runtime.pkg @@ -3340,7 +3340,8 @@ USA. compile-shim link-shim install-shim - install-load-option) + install-load-option + load-option/suppress-loading-message?) (initialization (initialize-package!))) (define-package (runtime program-copier) -- 2.25.1