@@ -29,7 +29,8 @@ pub(crate) type DocumentationLink = String;
2929/// Rewrite documentation links in markdown to point to an online host (e.g. docs.rs)
3030pub ( crate ) fn rewrite_links ( db : & RootDatabase , markdown : & str , definition : & Definition ) -> String {
3131 let mut cb = broken_link_clone_cb;
32- let doc = Parser :: new_with_broken_link_callback ( markdown, Options :: empty ( ) , Some ( & mut cb) ) ;
32+ let doc =
33+ Parser :: new_with_broken_link_callback ( markdown, Options :: ENABLE_TASKLISTS , Some ( & mut cb) ) ;
3334
3435 let doc = map_links ( doc, |target, title : & str | {
3536 // This check is imperfect, there's some overlap between valid intra-doc links
@@ -64,8 +65,7 @@ pub(crate) fn rewrite_links(db: &RootDatabase, markdown: &str, definition: &Defi
6465pub ( crate ) fn remove_links ( markdown : & str ) -> String {
6566 let mut drop_link = false ;
6667
67- let mut opts = Options :: empty ( ) ;
68- opts. insert ( Options :: ENABLE_FOOTNOTES ) ;
68+ let opts = Options :: ENABLE_TASKLISTS | Options :: ENABLE_FOOTNOTES ;
6969
7070 let mut cb = |_: BrokenLink | {
7171 let empty = InlineStr :: try_from ( "" ) . unwrap ( ) ;
@@ -123,7 +123,7 @@ pub(crate) fn extract_definitions_from_markdown(
123123) -> Vec < ( TextRange , String , Option < hir:: Namespace > ) > {
124124 Parser :: new_with_broken_link_callback (
125125 markdown,
126- Options :: empty ( ) ,
126+ Options :: ENABLE_TASKLISTS ,
127127 Some ( & mut broken_link_clone_cb) ,
128128 )
129129 . into_offset_iter ( )
0 commit comments