CTL_CODE function Null safety

int CTL_CODE(
  1. int DeviceType,
  2. int Function,
  3. int Method,
  4. int Access
)

Maps a control code to a constant

Implementation

//
// #define CTL_CODE( DeviceType, Function, Method, Access ) (
//   ((DeviceType) << 16) | ((Access) << 14) | ((Function) << 2) | (Method)
int CTL_CODE(int DeviceType, int Function, int Method, int Access) =>
    (((DeviceType) << 16) | ((Access) << 14) | ((Function) << 2) | (Method))
        .toSigned(32);