comparison vendor/nikic/php-parser/lib/PhpParser/NodeAbstract.php @ 12:7a779792577d

Update Drupal core to v8.4.5 (via Composer)
author Chris Cannam
date Fri, 23 Feb 2018 15:52:07 +0000
parents 4c8ae668cc8c
children 5fb285c0d0e3
comparison
equal deleted inserted replaced
11:bfffd8d7479a 12:7a779792577d
19 * Gets the type of the node. 19 * Gets the type of the node.
20 * 20 *
21 * @return string Type of the node 21 * @return string Type of the node
22 */ 22 */
23 public function getType() { 23 public function getType() {
24 return strtr(substr(rtrim(get_class($this), '_'), 15), '\\', '_'); 24 $className = rtrim(get_class($this), '_');
25 return strtr(
26 substr(
27 $className,
28 strpos($className, 'PhpParser\Node') + 15
29 ),
30 '\\',
31 '_'
32 );
25 } 33 }
26 34
27 /** 35 /**
28 * Gets line the node started in. 36 * Gets line the node started in.
29 * 37 *