forked from glayzzle/php-parser
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patherror.js
More file actions
33 lines (31 loc) · 711 Bytes
/
error.js
File metadata and controls
33 lines (31 loc) · 711 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/**
* Copyright (C) 2018 Glayzzle (BSD3 License)
* @authors https://github.com/glayzzle/php-parser/graphs/contributors
* @url http://glayzzle.com
*/
"use strict";
const Node = require("./node");
const KIND = "error";
/**
* Defines an error node (used only on silentMode)
* @constructor Error
* @extends {Node}
* @property {string} message
* @property {number} line
* @property {number|string} token
* @property {string|array} expected
*/
module.exports = Node.extends(KIND, function Error(
message,
token,
line,
expected,
docs,
location
) {
Node.apply(this, [KIND, docs, location]);
this.message = message;
this.token = token;
this.line = line;
this.expected = expected;
});