doc search: fix mismatch between generator and renderer

This change revisits commit eb7fa6f066. I think the problem
is not in the rendering of index entries but on the generation
side. The generator was converting Xexprs to strings, except
that strings were left as-is, which is inconsistent. So,
I've reverted commit eb7fa6f066 and fixed the generator.
This commit is contained in:
Matthew Flatt 2013-04-06 07:43:49 -06:00
parent b82cadaf99
commit ee78b70e4a
2 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@
[`() xexprs] [`() xexprs]
[`("" . ,r) (compact r)] [`("" . ,r) (compact r)]
[`(,(? string? s) ...) [`(,(? string? s) ...)
(list (apply string-append xexprs))] (list (xexpr->string (apply string-append xexprs)))]
[`(,(? string? s1) ,(? string? s2) . ,r) [`(,(? string? s1) ,(? string? s2) . ,r)
(compact `(,(string-append s1 s2) . ,r))] (compact `(,(string-append s1 s2) . ,r))]
[`((span ([class ,c]) . ,b1) (span ([class ,c]) . ,b2) . ,r) [`((span ([class ,c]) . ,b1) (span ([class ,c]) . ,b2) . ,r)

View File

@ -643,7 +643,7 @@ function UncompactUrl(url) {
function UncompactHtml(x) { function UncompactHtml(x) {
if (typeof x == "string") { if (typeof x == "string") {
return SanitizeHTML(x); return x;
} else if (!(x instanceof Array)) { } else if (!(x instanceof Array)) {
return alert("Internal error in PLT docs"); return alert("Internal error in PLT docs");
} else if ((x.length == 2) && (typeof(x[0]) == "number")) { } else if ((x.length == 2) && (typeof(x[0]) == "number")) {