Adding TODO for bad newlines

pull/25/head
Wilfred Hughes 2019-11-18 17:48:40 +07:00
parent 285f138d39
commit fb81bea0c4
1 changed files with 1 additions and 0 deletions

@ -52,6 +52,7 @@ pub fn infer_language(filename: &str) -> Option<Language> {
}
pub fn language_lexer(lang: Language) -> Regex {
// TODO: this doesn't handle newlines in comments well, see inline display of the elisp sample file.
match lang {
Language::JavaScript => {
Regex::new(r#"//.+|[a-zA-Z0-9_]+|"(\\.|[^"\\])*"|'(\\.|[^'\\])*'|[^ \t\n]"#).unwrap()