ELENA-LANG / elena-lang

ELENA is a general-purpose language with late binding. It is multi-paradigm, combining features of functional and object-oriented programming. Rich set of tools are provided to deal with message dispatching : multi-methods, message qualifying, generic message handlers, run-time interfaces
https://elena-lang.github.io/
MIT License
233 stars 24 forks source link

Interface dispatcher : Check if all abstract methods are implemented #517

Closed arakov closed 3 years ago

arakov commented 3 years ago

Describe the bug When interface template is used to implement an interface, the compiler does not check if all the interface methods are implemented. As a result an error is raised only in run-time.

To Reproduce

import extensions;

interface I
{
    abstract testMe() {}
}

A : interface<I>
{
}

public program()
{
    I i := new A();

    i.testMe();
}

Expected behavior An error / warning should be generated in compile-time

arakov commented 3 years ago

A warning if the class is normal, an error if closed / sealed

arakov commented 3 years ago

done