Bug 18574 – Unclear error message when trying to inherit from multiple classes

Status
RESOLVED
Resolution
FIXED
Severity
enhancement
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2018-03-07T22:23:42Z
Last change time
2018-03-10T04:34:50Z
Assigned to
No Owner
Creator
monkeyworks12

Comments

Comment #0 by monkeyworks12 — 2018-03-07T22:23:42Z
class Test: Foo, Bar, Baz { } class Foo {} class Bar {} class Baz {} Error: class `Test` base type must be interface, not Bar Error: class `Test` base type must be interface, not Baz I thought this error message used to be a lot better; along the lines of "D does not support multiple inheritance. Use interfaces instead." It'd be nice if it was changed to be clearer about what the error is.
Comment #1 by github-bugzilla — 2018-03-10T04:34:49Z
Commits pushed to master at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/f669389682636b0d2902f4c4567b04e1cc72cb4d Fix issue 18574: Unclear error message when trying to inherit from multiple classes https://github.com/dlang/dmd/commit/0f10515281a9fc0f57f121567af81beac59e56f1 Merge pull request #7987 from thewilsonator/patch-2 Fix issue 18574: Unclear error message when trying to inherit from mu… merged-on-behalf-of: Mike Franklin <[email protected]>