Merge pull request #5439 from alexrp/master
[mono.git] / mcs / tests / test-484.cs
1 using System;
2
3 namespace Test
4 {
5         public class TestBit {
6                 const bool a00 = false & false;
7                 const bool a01 = false & true;
8                 const bool a10 = true  & false;
9                 const bool a11 = true  & true;
10
11                 const bool o00 = false | false;
12                 const bool o01 = false | true;
13                 const bool o10 = true  | false;
14                 const bool o11 = true  | true;
15
16                 const bool x00 = false ^ false;
17                 const bool x01 = false ^ true;
18                 const bool x10 = true  ^ false;
19                 const bool x11 = true  ^ true;
20
21                 const bool correct = !a00 & !a01 & !a10 & a11 & !o00 & o01 & o10 & o11 & !x00 & x01 & x10 & !x11;
22
23                 public static void Main()
24                 {
25                         if (!correct)
26                                 throw new Exception ();
27                 }
28         }
29 }