From be8dd0eb3da3422fa5c89a1270ce36d8d5d86efd Mon Sep 17 00:00:00 2001 From: Sidharth Kshatriya Date: Thu, 28 Oct 2021 09:41:23 +0530 Subject: [PATCH] Erlang syntax highlighting: Improved support for numeric literals, refs, ports and pids --- rc/filetype/erlang.kak | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/rc/filetype/erlang.kak b/rc/filetype/erlang.kak index 79a38cef..35b60cf2 100644 --- a/rc/filetype/erlang.kak +++ b/rc/filetype/erlang.kak @@ -45,9 +45,15 @@ add-highlighter shared/erlang/default/funtion_call regex '\b[a-z][\w@]*(?=\()' 0 add-highlighter shared/erlang/default/keywords regex '\b(after|begin|case|try|catch|end|fun|if|of|receive|when|andalso|orelse|bnot|not|div|rem|band|and|bor|bxor|bsl|bsr|or|xor)\b' 0:keyword add-highlighter shared/erlang/default/variable_name regex '\b(? +add-highlighter shared/erlang/default/ref regex '#Ref<\d+\.\d+\.\d+\.\d+>' 0:value +# e.g. #Port<0.1> +add-highlighter shared/erlang/default/port regex '#Port<\d+\.\d+>' 0:value +# e.g. <0.401.0> +add-highlighter shared/erlang/default/pid regex '<\d+\.\d+\.\d+>' 0:value +add-highlighter shared/erlang/default/base_number regex '\b(\d[_\d]*(?