-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
multi-byte utf-8 characters in doc comments break docify #7
Labels
bug
Something isn't working
Comments
-static DOC_COMMENT_ATTR: Lazy<Regex> = Lazy::new(|| Regex::new(r#"#\[doc = ".*"]"#).unwrap());
+static DOC_COMMENT_ATTR: Lazy<Regex> =
+ Lazy::new(|| Regex::new(r#"#\[doc\s*=\s*".*"\s*]"#).unwrap()); |
sam0x17
changed the title
Sep 14, 2023
source_excerpt
: can't find item in source when doc comments longer than 70 characters on exported itemsource_excerpt
: can't find item in source when special characters are in doc comments
Re-opening because the real reason this is happening is the presence of special characters in doc comments in the file. The following being present anywhere in the source file being embedded will reproduce the bug: //! ```text
//! ├
//! ``` |
ah and the reason this is an issue is multi-byte UTF-8 characters |
sam0x17
changed the title
multi-byte utf-8 characters in doc comments break docify
Sep 14, 2023
source_excerpt
: can't find item in source when special characters are in doc comments
sam0x17
added a commit
that referenced
this issue
Sep 14, 2023
fixed in v0.2.3 |
sam0x17
added a commit
to paritytech/polkadot-sdk
that referenced
this issue
Sep 15, 2023
Upgrades to docify v0.2.3, which includes a fix for sam0x17/docify#7 and full support for multi-byte UTF-8 characters
bgallois
pushed a commit
to duniter/duniter-polkadot-sdk
that referenced
this issue
Mar 25, 2024
Upgrades to docify v0.2.3, which includes a fix for sam0x17/docify#7 and full support for multi-byte UTF-8 characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Code sample:
Fixes when word wrapping is tweaked to:
cc @liamaharon
The text was updated successfully, but these errors were encountered: