diff --git a/doc/asdf.texinfo b/doc/asdf.texinfo
index c19752ac750f2fefc7286ea403c3b91142d67c25..49691f46d86805b127ea9a0ab099a0f69b89e802 100644
--- a/doc/asdf.texinfo
+++ b/doc/asdf.texinfo
@@ -3452,8 +3452,7 @@ you may omit the above @code{type} slot definition and instead define:
   "cl")
 @end lisp
 
-Then make your system use this subclass in preference to the standard
-one:
+Then make your system use this subclass in preference to the standard one:
 
 @lisp
 (defsystem my-cl-system
@@ -3463,8 +3462,8 @@ one:
 @end lisp
 
 We assume that these definitions are loaded into a package that uses
-@code{ASDF}.
-
+@code{ASDF} --- which will be the case by default
+if your @file{.asd} file doesn't specify an @code{in-package} statement.
 
 
 @node  TODO list, Inspiration, FAQ, Top
diff --git a/test/test-package.asd b/test/test-package.asd
index 627ea79a17bc03c0db27ac45c9aec916fad06ae9..1c726ee5238eca89d7287b8738175f089d61a0cd 100644
--- a/test/test-package.asd
+++ b/test/test-package.asd
@@ -7,4 +7,4 @@
 (in-package :cl-user) ; BAD BAD BAD
 
 (asdf:defsystem test-package
-  :components ((:module "foo" :components ((:file "bar") (:file "baz")))))
\ No newline at end of file
+  :components ((:module "foo" :components ((:file "bar") (:file "baz")))))
diff --git a/test/test-source-file-type-1.asd b/test/test-source-file-type-1.asd
new file mode 100644
index 0000000000000000000000000000000000000000..8dd60852b0b161c232b50c161e1258d362c33329
--- /dev/null
+++ b/test/test-source-file-type-1.asd
@@ -0,0 +1,13 @@
+;; Should work with both ASDF 1 and ASDF 2.
+(defclass cl-source-file-1 (cl-source-file)
+  ())
+
+(defmethod source-file-type ((f cl-source-file-1) (m module))
+  (declare (ignorable f m))
+  "cl")
+
+(defsystem test-source-file-type-1
+    :default-component-class cl-source-file-1
+    :serial t
+    :components ((:cl-source-file "file1") ; for the package
+                 (:file "test-tmp")))
diff --git a/test/test-source-file-type-2.asd b/test/test-source-file-type-2.asd
new file mode 100644
index 0000000000000000000000000000000000000000..ec7253a28218d0b67431b7be969eefb8c442b70d
--- /dev/null
+++ b/test/test-source-file-type-2.asd
@@ -0,0 +1,8 @@
+;; Works only in ASDF 2
+(defclass cl-source-file-2 (cl-source-file)
+   ((type :initform "cl")))
+
+(defsystem test-source-file-type-2
+    :depends-on (:test-source-file-type-1)
+    :default-component-class cl-source-file-2
+    :components ((:file "test-tmp")))
diff --git a/test/test-source-file-type.script b/test/test-source-file-type.script
new file mode 100644
index 0000000000000000000000000000000000000000..86ec0a92d73990461baa2fdf3ee2ade1e51ecdee
--- /dev/null
+++ b/test/test-source-file-type.script
@@ -0,0 +1,12 @@
+;;; -*- Lisp -*-
+(load "script-support.lisp")
+(load-asdf)
+
+(quit-on-error
+ (setf asdf:*central-registry* '(*default-pathname-defaults*))
+ (asdf:load-system 'test-source-file-type-1 :verbose t)
+ (let ((sym (read-from-string "test-package::*test-tmp-cl*")))
+  (assert (symbol-value sym))
+  (set sym nil)
+  (asdf:load-system 'test-source-file-type-2 :verbose t)
+  (assert (symbol-value sym))))