Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Metaclasses appear to be completely ignored #41

Open
davidchisnall opened this issue May 25, 2018 · 0 comments
Open

Metaclasses appear to be completely ignored #41

davidchisnall opened this issue May 25, 2018 · 0 comments

Comments

@davidchisnall
Copy link

In the most recent head (and possibly some earlier ones), even trivial examples fail. It appears that the metaclass definitions are not being applied at all. For example, in the interface example, adding an int to the interface does not generate an error; however, the Circle class that is a subclass of the interface generates the following two errors:

interface.cc:54:22: error: only virtual member functions can be marked 'override'
    int area() const override { return 1; }
                     ^~~~~~~~~
interface.cc:55:34: error: only virtual member functions can be marked 'override'
    void scale_by(double factor) override { }
                                 ^~~~~~~~~
2 errors generated.

It appears as if any metaclass name is treated as equivalent to class. This is compiling with -std=c++1z -Xclang -reflection. It appears that the metaclass definition is being parsed, but is then ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant