// I am trying to make a clone of String's replace function
// and then re-define the replace function (with a mind to
// call the original from the new one with some mods)
String.prototype.replaceOriginal = String.prototype.replace
String.prototype.replace = {}
この次の行は壊れています - どうすれば修正できますか?
"lorem ipsum".replaceOriginal(/(orem |um)/g,'')