
// TODO: instanceof return false.

/**
 *  Error class specific to `Notation`.
 *  @name Notation.Error
 *  @memberof! Notation
 *  @class
 *
 */
class NotationError extends Error {

    /**
     *  Initializes a new `Notation.Error` instance.
     *  @constructs Notation.Error
     *  @param {String} message - The error message.
     */
    constructor(message = '') {
        super(message);
        this.name = this.constructor.name;

        Object.defineProperty(this, 'name', {
            enumerable: false,
            writable: false,
            value: 'NotationError'
        });

        Object.defineProperty(this, 'message', {
            enumerable: false,
            writable: true,
            value: message
        });

        // V8
        if (Error.hasOwnProperty('captureStackTrace')) { // eslint-disable-line no-prototype-builtins
            Error.captureStackTrace(this, this.constructor);
        } else {
            Object.defineProperty(this, 'stack', {
                enumerable: false,
                writable: false,
                value: (new Error(message)).stack
            });
        }
    }

}

export default NotationError;

@@ -1,38 +1,100 @@
-%0A// TODO: instanceof return false.
+/* eslint consistent-this:0, no-prototype-builtins:0 */%0A%0Aconst setProto = Object.setPrototypeOf;
 %0A%0A/*
@@ -464,41 +464,47 @@
     
-this.name = this.constructor.name
+setProto(this, NotationError.prototype)
 ;%0A%0A 
@@ -817,12 +817,33 @@
    /
-/ V8
+* istanbul ignore else */
 %0A   
@@ -903,49 +903,10 @@
  // 
-eslint-disable-line no-prototype-builtins
+V8
 %0A   
@@ -948,22 +948,19 @@
 is, 
-this.construct
+NotationErr
 or);

Fix instanceof NotationError