(chore/fix) Elixir keywords need some serious help #3210
Labels
bug
good first issue
Should be easier for first time contributors
help welcome
Could use help from community
language
I know that this PR merely reformats the list, but it caught my attention because there are a lot of keywords in it that I have never seen in Elixir. Also let my starts by saying that I am not sure if there is a formal definition of a "keyword". I'm using that term rather intuitively.
As far as I know, those are not Elixir keywords at all:
begin
break
(Inspect.Algebra.break/1
is a function in the standard lib, but it has nothing to do with breaking out of loops like it might do in other languages)defined
ensure
include
module
next
(OptionParser.next/2
is a function in the standard lib, it has nothing to do with skipping to another iteration in a loop like it might do in other languages)redo
retry
return
until
while
I'm unsure about:
self
. It exists, but IMO it is a normal macro, not a keyword. I wouldn't expect it to be colored differently than other normal macros (likerem
,round
,trunc
etc).then
. It's a new macro added in Elixir 1.12 together withtap
, I don't think those are keywords.with|0
. I'm not sure what the pipe and zero mean here.with
on its own is definitely a keyword.Missing IMO:
case
,cond
, andunless
qualify as keywords,if
andelse
should too.quote
qualifies as a keyword,unquote
andunquote_splicing
should too.receive
/after
https://hexdocs.pm/elixir/Kernel.SpecialForms.html#receive/1try
/rescue
/catch
/after
https://hexdocs.pm/elixir/Kernel.SpecialForms.html#try/1raise
https://hexdocs.pm/elixir/Kernel.html#raise/1reraise
https://hexdocs.pm/elixir/Kernel.html#reraise/2Originally posted by @angelikatyborska in #3207 (comment)
The text was updated successfully, but these errors were encountered: