Skip to main content
Update title of linked question
Source Link
CPlus
  • 9.2k
  • 2
  • 33
  • 96

Are there good reasons to attempt to keep the number of keywords/reserved tokens in a language to a minimum? Such as by repurposing existing keywords for new syntax instead of adding new ones. ExRelated: Why do some PL choose to have a dedicated keyword for elseif instead of like in C?

I suspect that more keywords may make implementing a compiler more complicated, slower as there are more keywords to compare tokens against or similar. But are these concerns legitimate and are there other advantages to having/maintaining a low number of keywords?

Are there good reasons to attempt to keep the number of keywords/reserved tokens in a language to a minimum? Such as by repurposing existing keywords for new syntax instead of adding new ones. Ex: Why do some PL choose to have a dedicated keyword for elseif instead of like in C?

I suspect that more keywords may make implementing a compiler more complicated, slower as there are more keywords to compare tokens against or similar. But are these concerns legitimate and are there other advantages to having/maintaining a low number of keywords?

Are there good reasons to attempt to keep the number of keywords/reserved tokens in a language to a minimum? Such as by repurposing existing keywords for new syntax instead of adding new ones. Related: Why do some PL choose to have a dedicated keyword for elseif instead of like in C?

I suspect that more keywords may make implementing a compiler more complicated, slower as there are more keywords to compare tokens against or similar. But are these concerns legitimate and are there other advantages to having/maintaining a low number of keywords?

Became Hot Network Question
Source Link
CPlus
  • 9.2k
  • 2
  • 33
  • 96

Are there good reasons to minimize the number of keywords in a language?

Are there good reasons to attempt to keep the number of keywords/reserved tokens in a language to a minimum? Such as by repurposing existing keywords for new syntax instead of adding new ones. Ex: Why do some PL choose to have a dedicated keyword for elseif instead of like in C?

I suspect that more keywords may make implementing a compiler more complicated, slower as there are more keywords to compare tokens against or similar. But are these concerns legitimate and are there other advantages to having/maintaining a low number of keywords?