mirror of
https://github.com/enso-org/enso.git
synced 2024-11-27 02:55:06 +03:00
7b0759f8b3
It appears that we were always adding builtin methods to the scope of the module and the builtin type that shared the same name. This resulted in some methods being accidentally available even though they shouldn't. This change treats differently builtins of types and modules and introduces auto-registration feature for builtins. By default all builtin methods are registered with a type, unless explicitly defined in the annotation property. Builtin methods that are auto-registered do not have to be explicitly defined and are registered with the underlying type. Registration correctly infers the right type, depending whether we deal with static or instance methods. Builtin methods that are not auto-registered have to be explicitly defined **always**. Modules' builtin methods are the prime example. # Important Notes Builtins now carry information whether they are static or not (inferred from the lack of `self` parameter). They also carry a `autoRegister` property to determine if a builtin method should be automatically registered with the type. |
||
---|---|---|
.. | ||
src | ||
THIRD-PARTY | ||
package.yaml |