unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* guile-lib <p> handling
@ 2020-03-16 13:40 Michal Herko
  2020-03-16 17:15 ` tomas
  2020-03-16 17:16 ` sirgazil
  0 siblings, 2 replies; 3+ messages in thread
From: Michal Herko @ 2020-03-16 13:40 UTC (permalink / raw)
  To: guile-user

[-- Attachment #1: Type: text/plain, Size: 457 bytes --]

Dear maintainor of guile-lib.
I believe the special handling of <p> elements in (htmlprag) module to 
be a bug.
For example:

(use-modules (htmlprag))
(html->shtml "<html><body><div><p>text</p></div></body></html>")
; expected result (*TOP* (html (body (div (p "text")))))
; actual (*TOP* (html (body (div) (p "text"))))

Note that the <p> element is parsed outside the <div> element.
I attach the simple patch to remove the special case for <p> elements.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: p.diff --]
[-- Type: text/x-patch, Size: 405 bytes --]

diff --git a/src/htmlprag.scm b/src/htmlprag.scm
index 3bd352b..df99612 100644
--- a/src/htmlprag.scm
+++ b/src/htmlprag.scm
@@ -1099,7 +1099,6 @@
               (meta     . (head))
               (noframes . (frameset))
               (option   . (select))
-              (p        . (body td th))
               (param    . (applet))
               (tbody    . (table))
               (td       . (tr))

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-03-16 17:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-16 13:40 guile-lib <p> handling Michal Herko
2020-03-16 17:15 ` tomas
2020-03-16 17:16 ` sirgazil

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).