This comment is outdated. We don't need KEYWORD_ALIASES anymore.
# because all input will eventually be evaluated as Ruby code,
# command names that conflict with Ruby keywords need special workaround
# we can remove them once we implemented a better command system for IRB
KEYWORD_ALIASES = { ... }
[:catch, OVERRIDE_PRIVATE_ONLY]
Just like exit and exit!, catch is already defined as a private method of Object.
IRB's command usually sets OVERRIDE_PRIVATE_ONLY in this case.
[:next , OVERRIDE_ALL], [:break , OVERRIDE_ALL]
both next abreak a are always syntax error. These input should be always treated as a command even if a method with the same name is defined.
This comment is outdated. We don't need KEYWORD_ALIASES anymore.
[:catch, OVERRIDE_PRIVATE_ONLY]
Just like
exit
andexit!
,catch
is already defined as a private method of Object. IRB's command usually sets OVERRIDE_PRIVATE_ONLY in this case.[:next , OVERRIDE_ALL], [:break , OVERRIDE_ALL]
both
next a
break a
are always syntax error. These input should be always treated as a command even if a method with the same name is defined.