diff --git a/pkgs/scribble-pkgs/scribble-lib/scribble/decode.rkt b/pkgs/scribble-pkgs/scribble-lib/scribble/decode.rkt index d354e658..463845b9 100644 --- a/pkgs/scribble-pkgs/scribble-lib/scribble/decode.rkt +++ b/pkgs/scribble-pkgs/scribble-lib/scribble/decode.rkt @@ -245,9 +245,13 @@ (part-to-collect part) para (cons s (part-parts part)))) - (if (splice? (car l)) - (loop (append (splice-run (car l)) (cdr l)) s-accum) - (loop (cdr l) (cons (car l) s-accum))))))] + (cond + [(splice? (car l)) + (loop (append (splice-run (car l)) (cdr l)) s-accum)] + [(list? (car l)) + (loop (append (car l) (cdr l)) s-accum)] + [else + (loop (cdr l) (cons (car l) s-accum))]))))] [(splice? (car l)) (loop (append (splice-run (car l)) (cdr l)) next? keys colls accum title tag-prefix tags vers style)] diff --git a/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.scrbl b/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.scrbl new file mode 100644 index 00000000..bbc8a90a --- /dev/null +++ b/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.scrbl @@ -0,0 +1,9 @@ +#lang scribble/base + +@title{A} + +@section{B} + +@(list @subsection{C}) + +@(list @subsection{D}) diff --git a/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.txt b/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.txt new file mode 100644 index 00000000..ee3c33c0 --- /dev/null +++ b/pkgs/scribble-pkgs/scribble-test/tests/scribble/docs/list-section.txt @@ -0,0 +1,9 @@ +A + +1. B + +1.1. C + + +1.2. D +