> Am 12.05.2021 um 10:12 schrieb Nikita Popov <nikita....@gmail.com>: > > Hi internals, > > If the readline extension is enabled, PHP provides an interactive shell > under -a. If it is not enabled, it falls back to an "interactive mode" > (yes, the difference between "interactive shell" and "interactive mode" is > important here). The interactive mode is simply an stdin input, which needs > to be terminated using Ctrl+D. You can only run one script that way. > > I think the current behavior is quite confusing, because it's really not > obvious that you ended up in this fallback mode (you need to know the > difference between "shell" and "mode" in the output) and most people > wouldn't know what to do with it. The latest instance of this is > https://bugs.php.net/bug.php?id=81033. > > I think we would be better off disabling -a completely if readline is not > available, and exit with a helpful error message. I've opened > https://github.com/php/php-src/pull/6976 to that effect. Does that sound > reasonable? > > Regards, > Nikita
Hey Nikita, yes, please merge that PR, I've been annoyed more than once that the php -a was not actually interactive despite a seemingly good message. (and as cmb noted, it's effectively identical to bare php without args.) Bob -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: https://www.php.net/unsub.php