Non-standard
This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.
InternalError
객체는 JavaScript 엔진 내부에서 발생한 에러를 나타냅니다. 예를 들면, "InternalError: too much recursion"라는 에러가 있으며, 이것은 "내부 에러: 너무 많은 재귀 호출" 상황이 발생했을 때 나타납니다.
구문
new InternalError([message[, fileName[, lineNumber]]])
파라메터
message
- 선택적 파라메터. 에러에 대한 설명.
fileName
- 선택적 파라메터. 예외(Exception)가 발생한 코드를 포함하고 있는 파일 명.
lineNumber
- 선택적 파라메터. 예외(Exception)이 발생한 코드의 라인 넘버.
설명
InternalError
는 JavaScript 엔진에서 내부 에러가 발생할 때마다 던져집니다.
다음의 에러 예시 들의 경우는 일반적으로 어떤 값이 너무 큰 경우 입니다.
- "too many switch cases", (swich case의 수가 너무 많음.)
- "too many parentheses in regular expression", (정규표현식에 너무 많은 괄호가 있음.)
- "array initializer too large", (배열 초기화 값이 너무 큼.)
- "too much recursion". (너무 많은 재귀 호출.)
속성
InternalError.prototype
InternalError
객체에 속성을 추가하도록 해줍니다.
메소드
전역(global)의 InternalError
는 고유의 함수를 가지고 있지 않지만, 몇 가지의 메소드를 프로토타입 체인으로부터 상속받습니다.
InternalError 인스턴스
속성
InternalError.prototype.constructor
- Specifies the function that created an instance's prototype.
InternalError.prototype.message
- Error message. Inherited from
Error
. InternalError.prototype.name
- Error name. Inherited from
Error
. InternalError.prototype.fileName
- Path to file that raised this error. Inherited from
Error
. InternalError.prototype.lineNumber
- Line number in file that raised this error. Inherited from
Error
. InternalError.prototype.columnNumber
- Column number in line that raised this error. Inherited from
Error
. InternalError.prototype.stack
- Stack trace. Inherited from
Error
.
메소드
Although the InternalError
prototype object does not contain any methods of its own, InternalError
instances do inherit some methods through the prototype chain.
스펙
Not part of any specifications.
브라우저 호환성
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
Basic support | No support | (Yes) | No support | No support | No support |
Feature | Android | Chrome for Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|---|
Basic support | No support | No support | (Yes) | No support | No support | No support |