objectionary / lints

A collection of style checkers for XMIR: they don't predict runtime errors, but prevent compilation mistakes
MIT License
3 stars 0 forks source link

"Mystery" objects must be prohibited #20

Open yegor256 opened 2 hours ago

yegor256 commented 2 hours ago

Consider this code:

[] > foo
  bar 42 > x

Here, the bar doesn't have +alias, and it's not one of org.eolang objects (there are just about 20 of them there). Let's create a lint that would catch such a situation and complain about it (with an error).

Of course, we must not complain about objects that are defined somewhere in the current program. This code is valid:

[] > foo
  [t] > bar
  bar 42 > x
yegor256 commented 2 hours ago

@maxonfjvipon WDYT?