Mercurial > urweb
diff src/monoize.sml @ 1840:146ec8e90063
Add some name-mangling rules to allow XML attribute 'name' and attributes with dashes
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Thu, 27 Dec 2012 15:34:11 -0500 |
parents | 276fa06428ba |
children | 184d00f7be74 |
line wrap: on
line diff
--- a/src/monoize.sml Thu Dec 13 17:51:34 2012 -0500 +++ b/src/monoize.sml Thu Dec 27 15:34:11 2012 -0500 @@ -3364,8 +3364,13 @@ val x = case x of "Typ" => "Type" + | "Nam" => "Name" | "Link" => "Href" | _ => x + + val x = String.translate (fn #"_" => "-" + | ch => String.str ch) x + val xp = " " ^ lowercaseFirst x ^ "=\"" val (e, fm) = fooify env fm (e, t)