dlang-community / D-Scanner

Swiss-army knife for D source code
Boost Software License 1.0
243 stars 80 forks source link

parser rejects valid: class B : public A {} #67

Closed timotheecour closed 10 years ago

timotheecour commented 11 years ago
class A{}
class B : public A {}
Hackerpilot commented 11 years ago

http://dlang.org/deprecate.html#Base%20Class%20Protection

timotheecour commented 11 years ago

dmd still accepts it, so it should be a warning, not an error.

Hackerpilot commented 11 years ago

DMD accepts many things that it should not.

timotheecour commented 11 years ago

both dmd and ldc accept with -d flag (with no warning) and accept without -d (with warning). ideally, dscanner would match their behavior (with an additional optional -d flag that we would pass to dscanner, as a feature request)

On Tue, Oct 22, 2013 at 1:07 PM, Hackerpilot notifications@github.comwrote:

DMD accepts many things that it should not.

— Reply to this email directly or view it on GitHubhttps://github.com/Hackerpilot/Dscanner/issues/67#issuecomment-26839817 .

Hackerpilot commented 11 years ago

I really have no interest in adding new support for deprecated language features. (That doesn't mean I'll reject pull requests, just that I'm not going to spend my time on it)

timotheecour commented 11 years ago

I completely understand; marking it as bug instead of invalid will more likely end up in someone implementing it though...