code: function stripVariadic(val, variadic) {
      variadic = escape(variadic || constants_1.VARIADIC_CHAR);
      var exp = new RegExp(variadic + '$');
      return val.replace(exp, '');
  }
docs: Strips variadic chars from flag.
  
  @param val the value to be stripped.
  @param negate the characters denoting variadic.