[erlang-patches] Tweaking regexp in erlang-font-lock-keywords-vars

Thomas Järvstrand tjarvstrand@REDACTED
Tue Nov 6 23:51:18 CET 2012


Please disregard this patch, it does not work as intended. Sorry for the
noise.

Thomas

2012/11/6 Thomas Järvstrand <tjarvstrand@REDACTED>

> Hi!
>
> Currently font-lock fontification in erlang-mode fails for the first
> erlang variable in the fontification region if the region to fontify starts
> on the same position as the variable. This is because the current regexp
> requires at least one character (any character except #) to be present
> before the actual variable names starts. This patch tweaks the regexp
> slightly to allow either a start-of-word or a non-# at the head of the
> variable-name.
>
> The use case is that I'm trying to accomplish syntax highlighting in the
> erlang-shell inside Emacs and the problem I encountered was that in the
> following example only Bar would be highlighted as a variable.
>
> 1> Foo = Bar.
>>
>
> Repo:
> git fetch git@REDACTED:tjarvstrand/otp.git erlang-font-lock-keyword-vars
>
> Comparison:
> https://github.com/tjarvstrand/otp/compare/erlang-font-lock-keyword-vars
>
> https://github.com/tjarvstrand/otp/compare/erlang-font-lock-keyword-vars.patch
>
> Regards
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-patches/attachments/20121106/9efc1d74/attachment.htm>


More information about the erlang-patches mailing list