[php-src] Issue #20871: Bad error line and file for invalid "-d" arguments

[email protected] (kkmuffme)
Newsgroups php.bugs
Message-ID <668BaCWmZn1lJTE5pmtAKe5oIG3m8TC1qlgjhl75WO0@main.internal.php.net>
Issue: https://github.com/php/php-src/issues/20871
Author: kkmuffme

### Description

The following code:

```php
php -d 'foo=bar=asd' -r "echo 'hello' . PHP_EOL;"
```

Resulted in this output:
```
PHP:  syntax error, unexpected '=' in Unknown on line 6
hello
```

But I expected this output instead:
```
PHP:  syntax error, unexpected '=' in -d option on line 0
hello
```

Not sure where it gets that line 6 from, and the "Unknown" could also be improved

### PHP Version

```plain
8.5
```

### Operating System

_No response_
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.