Skip to content

Commit

Permalink
Normalize whitespaces inside code spans
Browse files Browse the repository at this point in the history
  • Loading branch information
Julow committed Jul 22, 2019
1 parent 6a94892 commit 179e0a5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/Fmt_odoc.ml
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ let rec fmt_inline_element : inline_element -> Fmt.t = function
escape $ str_normalized w
| `Code_span s ->
let s = escape_brackets s in
hovbox 0 (wrap "[" "]" (str s))
hovbox 0 (wrap "[" "]" (str_normalized s))
| `Raw_markup (lang, s) ->
let lang =
match lang with
Expand Down
8 changes: 4 additions & 4 deletions test/passing/doc_comments.mli.ref
Original file line number Diff line number Diff line change
Expand Up @@ -330,9 +330,9 @@ end

(** {%html:<p>Raw markup</p>%} {%Without language%} {%other:Other language%} *)

(** [Multi
Line]
(** [Multi Line]

[ A lot of spaces ]
[A lot of spaces]

[Very looooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooong] *)
[Very
looooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooong] *)

0 comments on commit 179e0a5

Please sign in to comment.