comparison vendor/psy/psysh/src/Reflection/ReflectionLanguageConstruct.php @ 16:c2387f117808

Routine composer update
author Chris Cannam
date Tue, 10 Jul 2018 15:07:59 +0100
parents 5fb285c0d0e3
children 129ea1e6d783
comparison
equal deleted inserted replaced
15:e200cb7efeb3 16:c2387f117808
74 * 74 *
75 * @param string $keyword 75 * @param string $keyword
76 */ 76 */
77 public function __construct($keyword) 77 public function __construct($keyword)
78 { 78 {
79 if (self::isLanguageConstruct($keyword)) { 79 if (!self::isLanguageConstruct($keyword)) {
80 throw new \InvalidArgumentException('Unknown language construct: ' . $keyword); 80 throw new \InvalidArgumentException('Unknown language construct: ' . $keyword);
81 } 81 }
82 82
83 $this->keyword = $keyword; 83 $this->keyword = $keyword;
84 } 84 }
127 127
128 return $params; 128 return $params;
129 } 129 }
130 130
131 /** 131 /**
132 * Gets the file name from a language construct.
133 *
134 * (Hint: it always returns false)
135 *
136 * @return bool false
137 */
138 public function getFileName()
139 {
140 return false;
141 }
142
143 /**
132 * To string. 144 * To string.
133 * 145 *
134 * @return string 146 * @return string
135 */ 147 */
136 public function __toString() 148 public function __toString()