[Haddock] [haddock] #250: haddocs fails to parse U+00A0 (aka c2 a0 NO-BREAK SPACE) in @...@ block, but works in '>' (bird track)

haddock haddock at projects.haskell.org
Sat Jul 20 18:42:14 BST 2013


#250: haddocs fails to parse U+00A0 (aka c2 a0 NO-BREAK SPACE) in @...@ block,
but works in '>' (bird track)
-------------------+--------------------------------------------------------
Reporter:  slyfox  |        Owner:     
    Type:  defect  |       Status:  new
Priority:  major   |    Milestone:     
 Version:  2.13.1  |   Resolution:     
Keywords:          |  
-------------------+--------------------------------------------------------

Comment(by Fūzetsu):

 Short version: You'll have to wait. It has been fixed but changes aren't
 in HEAD yet. See bottom of the post for workaround info.

 Long version:
 Note that the difference between a birdtrack code and a block of code is
 that code between @ is treated as valid markup. That is, " " indicates a
 module name that's just a space. In a birdtrack, markup is not accepted so
 it's just a literal. What's happening is that Haddock fails to parse text
 with such module name (I can't exactly locate why it does this though, I
 believe it should just take whatever is given). The reason you're getting
 this particular error is because you're putting docs where the module
 header normally goes (see
 http://www.haskell.org/haskellwiki/Programming_guidelines#File_Format).

 In fact, with further investigation, it seems to fail whenever it
 encounters this character anywhere where valid markup can occur. Anything
 after a birdtrack is taken literally so that's why it doesn't happen
 there.


 For desperate:
 There's actually work being done on Haddock right now and this issue is no
 longer present. The changes are not in HEAD yet but if you're really
 desperate, you can pull and build from this branch of my repo:
 https://github.com/Fuuzetsu/haddock/tree/pullbase

 Mind that this is branch is very often buggy as changes are being made. I
 confirmed that your example parses with commit
 https://github.com/Fuuzetsu/haddock/tree/b466f95c1576784e6905703a32c5b7195ceaa72e
 and I believe that this commit doesn't have major regressions.

-- 
Ticket URL: <http://trac.haskell.org/haddock/ticket/250#comment:1>
haddock <http://www.haskell.org/haddock>
Haddock, The Haskell Documentation Tool


More information about the Haddock mailing list