From abe1c66061fa28551c25b6b0cd3c18597f70b48b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20K=C5=82osko?= Date: Tue, 18 Feb 2025 21:12:12 +0100 Subject: [PATCH] Fix code highlighting for languages with non-alphanumeric characters (#2092) --- lib/ex_doc/doc_ast.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ex_doc/doc_ast.ex b/lib/ex_doc/doc_ast.ex index cb20a602b..766b7b222 100644 --- a/lib/ex_doc/doc_ast.ex +++ b/lib/ex_doc/doc_ast.ex @@ -165,7 +165,7 @@ defmodule ExDoc.DocAST do ## Html cannot be parsed with regex, but we try our best... Regex.replace( - ~r/]*)?>([^<]*)<\/code><\/pre>/, + ~r/]*)?>([^<]*)<\/code><\/pre>/, html, &highlight_code_block(&1, &2, &3, &4, highlight_info, opts) )