summaryrefslogtreecommitdiff
path: root/module/system/base/message.scm
diff options
context:
space:
mode:
Diffstat (limited to 'module/system/base/message.scm')
-rw-r--r--module/system/base/message.scm11
1 files changed, 10 insertions, 1 deletions
diff --git a/module/system/base/message.scm b/module/system/base/message.scm
index 869afa783..92ec0389d 100644
--- a/module/system/base/message.scm
+++ b/module/system/base/message.scm
@@ -1,6 +1,6 @@
;;; User interface messages
-;; Copyright (C) 2009-2012,2016,2018,2020-2021 Free Software Foundation, Inc.
+;; Copyright (C) 2009-2012,2016,2018,2020-2021,2023 Free Software Foundation, Inc.
;;; This library is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU Lesser General Public License as published by
@@ -115,6 +115,15 @@
(emit port "~A: warning: possibly unused local top-level variable `~A'~%"
loc name)))
+ (unused-module
+ "report unused modules"
+ ,(lambda (port loc name definitely-unused?)
+ (if definitely-unused?
+ (emit port "~A: warning: unused module ~a~%"
+ loc name)
+ (emit port "~A: warning: possibly unused module ~a~%"
+ loc name))))
+
(shadowed-toplevel
"report shadowed top-level variables"
,(lambda (port loc name previous-loc)