haskell / alex

A lexical analyser generator for Haskell
https://hackage.haskell.org/package/alex
BSD 3-Clause "New" or "Revised" License
298 stars 82 forks source link

validation #216

Closed ghost closed 2 years ago

ghost commented 2 years ago

Valid XHTML 1.0 Transitional

Valid XHTML 1.0 Transitional

ghost commented 2 years ago

for the really pedantic

output of HTML Tidy for Linux version 5.8.0

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Alex</title>
</head>
<body>
<table border="0" cellpadding="0" cellspacing="0" style=
"border-collapse: collapse; font-family: Arial" width="800" align=
"center">
<tr>
<td width="100%" style="font-size: 24pt; padding-bottom: 0px"
bgcolor="#77AAFF">Alex: A lexical analyser generator for
Haskell</td>
</tr>
<tr>
<td width="100%" style="padding-top: 20px">
<ul>
<li><a href="#Overview">Overview</a></li>
<li><a href="#Documentation">Documentation</a></li>
<li><a href="#Download">Download</a></li>
<li><a href="#Development">Development</a></li>
</ul>
</td>
</tr>
<tr style="border-bottom: 1px dotted">
<td width="100%" style="font-size: 18pt; padding-top: 10px">
<a name="Overview" id="Overview">Overview</a></td>
</tr>
<tr>
<td width="100%" style="padding-left: 10px; padding-top: 5px">
<p>Alex is a tool for generating lexical analysers in Haskell,
given a description of the tokens to be recognised in the form of
regular expressions. It is similar to the tool <q>lex</q> or
<q>flex</q> for C/C++.</p>
</td>
</tr>
<tr style="border-bottom: 1px dotted">
<td width="100%" style="font-size: 18pt; padding-top: 10px">
<a name="Documentation" id="Documentation">Documentation</a></td>
</tr>
<tr>
<td width="100%" style="padding-left: 10px; padding-top: 5px">
<p>Documentation is hosted on <a href=
"https://haskell-alex.readthedocs.io">Read the Docs</a>.</p>
<ul>
<li><a href="https://haskell-alex.readthedocs.io">Online
(HTML)</a></li>
<li><a href=
"https://haskell-alex.readthedocs.io/_/downloads/en/latest/pdf/">PDF</a></li>
<li><a href=
"https://haskell-alex.readthedocs.io/_/downloads/en/latest/htmlzip/">
Downloadable HTML</a></li>
</ul>
</td>
</tr>
<tr style="border-bottom: 1px dotted">
<td width="100%" style="font-size: 18pt; padding-top: 10px">
<a name="Download" id="Download">Download</a></td>
</tr>
<tr>
<td width="100%" style="padding-left: 10px; padding-top: 5px">
<p>From <a href=
"https://hackage.haskell.org/package/alex">Hackage</a> via <a href=
"https://www.haskell.org/cabal/"><code>cabal-install</code></a>:</p>
<pre>
        cabal install alex
      </pre>
<p>From <a href=
"https://www.stackage.org/package/alex">Stackage</a> via <a href=
"https://haskellstack.org"><code>stack</code></a>, e.g.:</p>
<pre>
        stack install --resolver nightly alex
      </pre>
<p>Alex might also be pre-packaged for your OS (unconfirmed as of
2022-04-06):</p>
<ul>
<li>Ubuntu users: packages should be available from the universe
repository.</li>
<li>Debian GNU/Linux users: packages are available <a href=
"http://packages.debian.org/alex">here</a>.</li>
<li>RPMs for other versions of Linux can be built directly from the
source, using <tt>rpmbuild -ta</tt>.</li>
<li>FreeBSD/x86 users: Alex is in the ports tree, so either
<tt>pkg_add -r hs-alex</tt>, or install it from the ports tree in
<tt>/usr/ports/devel/hs-alex</tt>.</li>
<li>OpenBSD users: Alex is in the -current ports tree, you can
install it from <tt>/usr/ports/devel/alex</tt>.</li>
</ul>
</td>
</tr>
<tr style="border-bottom: 1px dotted">
<td width="100%" style="font-size: 18pt; padding-top: 10px">
<a name="Development" id="Development">Development</a></td>
</tr>
<tr>
<td width="100%" style="padding-left: 10px; padding-top: 5px">
<p>Alex is licensed under a <a href=
"http://www.haskell.org/alex/doc/html/license.html">BSD-style
license</a>. The current sources are on <a href=
"https://github.com/haskell/alex">github</a>, get the latest
version with:</p>
<pre>   git clone https://github.com/haskell/alex.git</pre>
<p>Contribute by opening <a href=
"https://github.com/haskell/alex/issues">issues</a> which can be
followed up by <a href="https://github.com/haskell/alex/pulls">pull
requests</a>.</p>
</td>
</tr>
</table>
<hr />
<p style="font-family: Arial">Source of this page: <a href=
"https://github.com/haskell/alex/blob/master/www/index.html"><code>index.html</code></a>,
deployed 2022-04-06.</p>
</body>
</html>
andreasabel commented 2 years ago

output of HTML Tidy for Linux version 5.8.0

This tool does not preserve indentation, it seems, nor produce sensible indentation. Also, it put line breaks in a tags which I don't like.
The overall effect is that the code is much less readable.