-
Notifications
You must be signed in to change notification settings - Fork 371
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
I got NotImplementError,
scala.NotImplementedError: unexpected expression 'PhpListExpr(List(Some(PhpArrayItem(None,PhpVariable(PhpNameExpr(to,PhpAttributes(Some(477),Some(477),None,16740,16743)),PhpAttributes(Some(477),Some(477),None,16740,16743)),false,false,PhpAttributes(Some(477),Some(477),None,16740,16743))), Some(PhpArrayItem(None,PhpVariable(PhpNameExpr(type,PhpAttributes(Some(477),Some(477),None,16745,16750)),PhpAttributes(Some(477),Some(477),None,16745,16750)),false,false,PhpAttributes(Some(477),Some(477),None,16745,16750))), Some(PhpArrayItem(None,PhpVariable(PhpNameExpr(path,PhpAttributes(Some(477),Some(477),None,16752,16757)),PhpAttributes(Some(477),Some(477),None,16752,16757)),false,false,PhpAttributes(Some(477),Some(477),None,16752,16757)))),PhpAttributes(Some(477),Some(477),None,16734,16759))' of type class io.joern.php2cpg.parser.Domain$PhpListExpr at io.joern.php2cpg.astcreation.AstForExpressionsCreator.astForExpr(AstForExpressionsCreator.scala:55) at io.joern.php2cpg.astcreation.AstForExpressionsCreator.astForExpr$(AstForExpressionsCreator.scala:18) at io.joern.php2cpg.astcreation.AstCreator.astForExpr(AstCreator.scala:18)
the error code is:
foreach ( self::$domain_map as $from => list( $to, $type, $path ) ) {
$data['domainMap'][ $from ] = ( 'core' === $type ? '' : "{$type}/" ) . $to;
if ( '' !== $path ) {
$data['domainPaths'][ $from ] = trailingslashit( $path );
}
}To Reproduce
Steps to reproduce the behavior:
- run php2cpg to generage cpg:
php2cpg test.php -o test.cpg - get the error above
Desktop (please complete the following information):
- OS: ubuntu 22.04
- Joern Version: 4.0.443
- Java version: openjdk 17.0.16 2025-07-15
- PHP 8.1.2-1ubuntu2.22 (cli) (built: Jul 15 2025 12:11:22) (NTS)
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working