什么`!!〜'在javascript中意味着什么?

Fre*_*ind 45 javascript operators bitwise-operators mongoose comparison-operators

可能重复:
jQuery对象之前的tilde(〜)是做什么的?

!!~在阅读时在代码中发现了一个奇怪的内容:https://github.com/LearnBoost/mongoose/blob/master/lib/document.js#L678

Document.prototype.isModified = function (path) {
  return !!~this.modifiedPaths.indexOf(path);
};
Run Code Online (Sandbox Code Playgroud)

我读过那是什么!! (不是)JavaScript中的运算符?以及如何:〜运算符?; 为什么作者!!~在这里使用?

我试过了:

!!~1  // -> true
!!~0  // -> true
!!~-1 // -> false
!!~-2 // -> true
Run Code Online (Sandbox Code Playgroud)

似乎它只是false在数字的时候-1.这样对吗?为什么不核对一下电话号码是不是-1还是>=0