NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Compiler Error CS0216

The operator ('operator') requires a matching operator to also be defined

A user-defined true operator requires a user-defined false operator, and vice versa.

The following sample generates CS0216:

class MyClass {
      public static bool operator true (MyClass MyInt) {   // CS0216
      return true;
   }
   
   // to resolve, uncomment the following operator definition
   /*
   public static bool operator false (MyClass MyInt) {
      return true;
   }
   */

   public static void Main() {
   }
}