anchor.diff:      //     we should check beforehand if stdin is connected to a terminal or not
       //     (requires https://github.com/dart-lang/sdk/issues/29083 to be resolved).
       try {
  -      stdin.lineMode = !value;
  +      // The order of setting lineMode and echoMode is important on Windows.
  +      if (value) {
  +        stdin.echoMode = false;
  +        stdin.lineMode = false;
  +      } else {
  +        stdin.lineMode = true;
  +        stdin.echoMode = true;
  +      }
       } on StdinException catch (error) {
         if (!_lineModeIgnorableErrors.contains(error.osError?.errorCode))
           rethrow;
  
positive.code:   static const int _ENXIO = 6;
    static const int _ENOTTY = 25;
    static const int _ENETRESET = 102;
    static const int _ERROR_INVALID_PARAMETER = 87;
    static const int _INVALID_HANDLE = 6;
  
    /// Setting the line mode can throw for some terminals (with "Operation not
  
negative.code:     _ENXIO,
      _ENOTTY,
      _ENETRESET,
      _INVALID_HANDLE,
    ];
  
  