Broken syntax highlighting for the Julia language

There are situations where the Julia syntax highlighter fails, as seen here:

https://github.com/davidavdav/GaussianMixtures.jl/blob/f140ad931d7e36e86d27561e4d93c2f0b4f2620e/src/train.jl#L17

It seems that μ' is somehow causing problems. Note that the single quote in Julia (') directly attached to a variable or expression can be used to transpose it. Maybe the lexer is confused and searches for a closing one? No idea…

Thanks for the feedback and apologies for the delay! I’ve taken your suggestion and passed it along to the appropriate teams. Thanks again for reaching out :grinning:

This doesn’t seem to be fixed yet. Any julia instance with quotes is broken: https://gist.github.com/guenter-r/7274ec3fbf349ed7ce70444bf0be1f1a#file-start-jl

The syntax highlighter is broken in many ways. It already fails for a line where I see no reason why the highlighter would choke: https://github.com/JuliaPhysics/Corpuscles.jl/blob/a56416f7a042c09f75b00635df869e7c93b6c36f/src/Corpuscles.jl#L14

I am not sure how to contribute to this but if it’s somehow open source, I am sure that we (Julia users) can jump in and help out.
There is also a Julia package which can help: https://github.com/JuliaDocs/Highlights.jl

Given that Julia is already in the top 30 of the most popular languages (according to TIOBE: https://www.tiobe.com/tiobe-index/), I think this problem deserves a bit more priority :wink: