Sha256: e35fe68460137b8ed6e71177c220ae4fb45bb15177a307da24b89bb322c29977

Contents?: true

Size: 952 Bytes

Versions: 134

Compression:

Stored size: 952 Bytes

Contents

/*!
 * Stylus - errors
 * Copyright(c) 2010 LearnBoost <dev@learnboost.com>
 * MIT Licensed
 */

/**
 * Expose constructors.
 */

exports.ParseError = ParseError;
exports.SyntaxError = SyntaxError;

/**
 * Inherit from `Error.prototype`.
 */

SyntaxError.prototype.__proto__ = Error.prototype;

/**
 * Initialize a new `ParseError` with the given `msg`.
 *
 * @param {String} msg
 * @api private
 */

function ParseError(msg) {
  this.name = 'ParseError';
  this.message = msg;
  Error.captureStackTrace(this, ParseError);
}

/**
 * Inherit from `Error.prototype`.
 */

ParseError.prototype.__proto__ = Error.prototype;

/**
 * Initialize a new `SyntaxError` with the given `msg`.
 *
 * @param {String} msg
 * @api private
 */

function SyntaxError(msg) {
  this.name = 'SyntaxError';
  this.message = msg;
  Error.captureStackTrace(this, ParseError);
}

/**
 * Inherit from `Error.prototype`.
 */

SyntaxError.prototype.__proto__ = Error.prototype;

Version data entries

134 entries across 87 versions & 2 rubygems

Version Path
ela-2.0.0 node_modules/poised/node_modules/nib/node_modules/stylus/lib/errors.js
ela-2.0.0 node_modules/codo/node_modules/nib/node_modules/stylus/lib/errors.js
ela-1.1.0 node_modules/codo/node_modules/nib/node_modules/stylus/lib/errors.js
ela-1.1.0 node_modules/poised/node_modules/stylus/lib/errors.js
ela-1.1.0 node_modules/poised/node_modules/nib/node_modules/stylus/lib/errors.js
ela-1.1.0 node_modules/codo/node_modules/stylus/lib/errors.js
stylus-source-0.49.3 vendor/lib/errors.js
stylus-source-0.42.2 vendor/lib/errors.js
stylus-source-0.42.1 vendor/lib/errors.js
stylus-source-0.42.0 vendor/lib/errors.js
stylus-source-0.41.3 vendor/lib/errors.js
stylus-source-0.41.2 vendor/lib/errors.js
stylus-source-0.41.1 vendor/lib/errors.js
stylus-source-0.41.0 vendor/lib/errors.js
stylus-source-0.40.3 vendor/lib/errors.js
stylus-source-0.40.2 vendor/lib/errors.js
stylus-source-0.40.1 vendor/lib/errors.js
stylus-source-0.40.0 vendor/lib/errors.js
stylus-source-0.39.4 vendor/lib/errors.js
stylus-source-0.39.3 vendor/lib/errors.js