Possible bug in Markdown.pl with `<<` handling

Michel Fortin michel.fortin at michelf.com
Mon Sep 11 18:48:05 EDT 2006

Le 11 sept. 2006 à 17:54, Jacob Rus a écrit :

> I'm just wondering… is there any case where you want `<<properly>>`

> not in a monospace font? That has to be some kind of codeword, and

> I can't imagine it coming up in regular prose.

The double less-than sign `<<` is a way to approximate double angle
quotes `«` in a plain ascii context, with old typewriters, and more
importantly for people who do not know about the right key
combinaison they have to use to type the character on their keyboard.

So I'm interested in preventing `<<` from starting a tag as it is a
small real-world problem I have seen from time to time.

Beside that reason, `&lt;&lt;` can be automatically converted by PHP
SmartyPants Typographer to proper angle quotes, so if Markdown
disambiguate it correctly as plain characters it could be converted
to angle-quotes automatically. And that'd be great.

> My suggestion is to either escape the second `<`, as in `\<

> \<properly>>`, or else just wrap the whole thing in `\`` marks, as

> in `` `<<properly` ``. Markdown shouldn't be expected to deal with

> such weird almost–html-tag things.

Your first suggestion, escaping `<`, doesn't work as Markdown doesn't
consider `<` to be an escapable character. I'd be interesting if it
did however, as it is currently impossible to write anything like a
<tag> outside a code span or a code block.

Michel Fortin
michel.fortin at michelf.com

More information about the Markdown-Discuss mailing list