| 1 |
// Copyright 2009 the Sputnik authors. All rights reserved. |
| 2 |
// This code is governed by the BSD license found in the LICENSE file. |
| 3 |
|
| 4 |
/*--- |
| 5 |
info: "CharacterEscape :: c ControlLetter" |
| 6 |
es5id: 15.10.2.10_A2.1_T1 |
| 7 |
description: "ControlLetter :: A - Z" |
| 8 |
---*/ |
| 9 |
|
| 10 |
//CHECK#0041-005A |
| 11 |
var result = true; |
| 12 |
for (var alpha = 0x0041; alpha <= 0x005A; alpha++) { |
| 13 |
var str = String.fromCharCode(alpha % 32); |
| 14 |
var arr = (new RegExp("\\c" + String.fromCharCode(alpha))).exec(str); |
| 15 |
if ((arr === null) || (arr[0] !== str)) { |
| 16 |
result = false; |
| 17 |
} |
| 18 |
} |
| 19 |
|
| 20 |
if (result !== true) { |
| 21 |
$ERROR('#1: CharacterEscape :: c A - Z'); |
| 22 |
} |