write method

int write(
  1. int bits,
  2. int value
)

Implementation

int write(int bits, int value) => (bits & ~mask) | ((value << start) & mask);