D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 6444 - Using != to compare with null does not cause a compiler error
Summary: Using != to compare with null does not cause a compiler error
Status: RESOLVED DUPLICATE of issue 1896
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: x86_64 Windows
: P2 minor
Assignee: No Owner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-06 13:17 UTC by eatingstaples
Modified: 2012-01-29 19:56 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description eatingstaples 2011-08-06 13:17:17 UTC
When using the == operator to compare a class reference to null, the compiler gives an error, telling the programmer to use the "is" operator instead. However, using the != operator fails to generate a similar message.
Comment 1 yebblies 2012-01-29 19:56:40 UTC

*** This issue has been marked as a duplicate of issue 1896 ***