| @@ 516-520 (lines=5) @@ | ||
| 513 | private function parseValue($value, $exceptionOnInvalidType, $objectSupport, $objectForMap, $context) |
|
| 514 | { |
|
| 515 | if (0 === strpos($value, '*')) { |
|
| 516 | if (false !== $pos = strpos($value, '#')) { |
|
| 517 | $value = substr($value, 1, $pos - 2); |
|
| 518 | } else { |
|
| 519 | $value = substr($value, 1); |
|
| 520 | } |
|
| 521 | ||
| 522 | if (!array_key_exists($value, $this->refs)) { |
|
| 523 | throw new ParseException(sprintf('Reference "%s" does not exist.', $value), $this->currentLineNb + 1, $this->currentLine); |
|
| @@ 485-489 (lines=5) @@ | ||
| 482 | $scalarLower = strtolower($scalar); |
|
| 483 | ||
| 484 | if (0 === strpos($scalar, '*')) { |
|
| 485 | if (false !== $pos = strpos($scalar, '#')) { |
|
| 486 | $value = substr($scalar, 1, $pos - 2); |
|
| 487 | } else { |
|
| 488 | $value = substr($scalar, 1); |
|
| 489 | } |
|
| 490 | ||
| 491 | // an unquoted * |
|
| 492 | if (false === $value || '' === $value) { |
|