Mercurial > hg > cmmr2012-drupal-site
comparison vendor/symfony/dependency-injection/ChildDefinition.php @ 4:a9cd425dd02b
Update, including to Drupal core 8.6.10
author | Chris Cannam |
---|---|
date | Thu, 28 Feb 2019 13:11:55 +0000 |
parents | c75dbcec494b |
children | 12f9dff5fda9 |
comparison
equal
deleted
inserted
replaced
3:307d7a7fd348 | 4:a9cd425dd02b |
---|---|
93 * | 93 * |
94 * @throws InvalidArgumentException when $index isn't an integer | 94 * @throws InvalidArgumentException when $index isn't an integer |
95 */ | 95 */ |
96 public function replaceArgument($index, $value) | 96 public function replaceArgument($index, $value) |
97 { | 97 { |
98 if (is_int($index)) { | 98 if (\is_int($index)) { |
99 $this->arguments['index_'.$index] = $value; | 99 $this->arguments['index_'.$index] = $value; |
100 } elseif (0 === strpos($index, '$')) { | 100 } elseif (0 === strpos($index, '$')) { |
101 $this->arguments[$index] = $value; | 101 $this->arguments[$index] = $value; |
102 } else { | 102 } else { |
103 throw new InvalidArgumentException('The argument must be an existing index or the name of a constructor\'s parameter.'); | 103 throw new InvalidArgumentException('The argument must be an existing index or the name of a constructor\'s parameter.'); |