Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Safar <marek.safar@gmail.com>2004-12-06 11:43:22 +0300
committerMarek Safar <marek.safar@gmail.com>2004-12-06 11:43:22 +0300
commitf1f8ed486d6f87b227ce94247bbcd310915de9b8 (patch)
treee1ba67b585c8ce14e2f629de687b5fadae672083 /mcs/errors/cs0429.cs
parentd88ab529830390ca45d9222f6f8fa83f0cc0f56c (diff)
2004-12-06 Marek Safar <marek.safar@seznam.cz>
Fixed #69195, #56821 * ecore.cs (ResolveBoolean): Tiny refactoring. * expression.cs (Binary.DoResolve): Add warning 429 and skipping of right expression resolving when left is false constant and operator is LogicalAnd OR true constant and operator is LogicalOr. * statement.cs (ResolveUnreachable): Always reports warning. svn path=/trunk/mcs/; revision=37173
Diffstat (limited to 'mcs/errors/cs0429.cs')
-rw-r--r--mcs/errors/cs0429.cs12
1 files changed, 12 insertions, 0 deletions
diff --git a/mcs/errors/cs0429.cs b/mcs/errors/cs0429.cs
new file mode 100644
index 00000000000..a1be2d9b2cf
--- /dev/null
+++ b/mcs/errors/cs0429.cs
@@ -0,0 +1,12 @@
+// cs0429.cs: Unreachable expression code detected
+// Line: 9
+// Compiler options: -warn:4 -warnaserror
+
+class Main
+{
+ public void Method (int i)
+ {
+ if (false && i > 10)
+ return;
+ }
+}