()
| 1503 | }, |
| 1504 | |
| 1505 | object = function () { |
| 1506 | |
| 1507 | var key, |
| 1508 | object = {}; |
| 1509 | |
| 1510 | if (ch === '{') { |
| 1511 | next('{'); |
| 1512 | white(); |
| 1513 | if (ch === '}') { |
| 1514 | next('}'); |
| 1515 | return object; // empty object |
| 1516 | } |
| 1517 | while (ch) { |
| 1518 | key = string(); |
| 1519 | white(); |
| 1520 | next(':'); |
| 1521 | if (Object.hasOwnProperty.call(object, key)) { |
| 1522 | error('Duplicate key "' + key + '"'); |
| 1523 | } |
| 1524 | object[key] = value(); |
| 1525 | white(); |
| 1526 | if (ch === '}') { |
| 1527 | next('}'); |
| 1528 | return object; |
| 1529 | } |
| 1530 | next(','); |
| 1531 | white(); |
| 1532 | } |
| 1533 | } |
| 1534 | error("Bad object"); |
| 1535 | }; |
| 1536 | |
| 1537 | value = function () { |
| 1538 |
no test coverage detected