tests/cases/conformance/types/objectTypeLiteral/methodSignatures/objectTypesWithOptionalProperties.ts(12,6): error TS1112: A class member cannot be declared optional.
tests/cases/conformance/types/objectTypeLiteral/methodSignatures/objectTypesWithOptionalProperties.ts(20,6): error TS1112: A class member cannot be declared optional.
tests/cases/conformance/types/objectTypeLiteral/methodSignatures/objectTypesWithOptionalProperties.ts(24,6): error TS1162: An object member cannot be declared optional.


==== tests/cases/conformance/types/objectTypeLiteral/methodSignatures/objectTypesWithOptionalProperties.ts (3 errors) ====
    // Basic uses of optional properties
    
    var a: {
        x?: number; // ok
    }
    
    interface I {
        x?: number; // ok
    }
    
    class C {
        x?: number; // error
         ~
!!! error TS1112: A class member cannot be declared optional.
    }
    
    interface I2<T> {
        x?: T; // ok
    }
    
    class C2<T> {
        x?: T; // error
         ~
!!! error TS1112: A class member cannot be declared optional.
    }
    
    var b = {
        x?: 1 // error
         ~
!!! error TS1162: An object member cannot be declared optional.
    }