code: function WError(options)
  {
  	Error.call(this);
  
  	var args, cause, ctor;
  	if (typeof (options) === 'object') {
  		args = Array.prototype.slice.call(arguments, 1);
  	} else {
  		args = Array.prototype.slice.call(arguments, 0);
  		options = undefined;
  	}
  
  	if (args.length > 0) {
  		this.message = mod_extsprintf.sprintf.apply(null, args);
  	} else {
  		this.message = '';
  	}
  
  	if (options) {
  		if (options instanceof Error) {
  			cause = options;
  		} else {
  			cause = options.cause;
  			ctor = options.constructorOpt;
  		}
  	}
  
  	Error.captureStackTrace(this, ctor || this.constructor);
  	if (cause)
  		this.cause(cause);
  
  }
docs: /*
  Like JavaScript's built-in Error class, but supports a "cause" argument which
  is wrapped, not "folded in" as with VError.	Accepts a printf-style message.
  The cause argument can be null.