On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Sun, 28 Jul 2024 09:48:21 GMT, Johan Sjölen wrote:
>> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>>
>> With this change, in DCmd::parse_and_execute() we will avoid needlessly
>> entering the code block to try and execute the command.
>>
>> DCmd tests all g
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Sun, 28 Jul 2024 09:48:21 GMT, Johan Sjölen wrote:
>> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>>
>> With this change, in DCmd::parse_and_execute() we will avoid needlessly
>> entering the code block to try and execute the command.
>>
>> DCmd tests all g
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Fri, 12 Jul 2024 09:41:04 GMT, Kevin Walls wrote:
> The jump is from the fact that nobody currently creates an empty CmdLine, to
> a ruling that nobody ever can in the future.
No my point is either it is impossible to create an empty cmdline or else we
should have a test that introduces one
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Fri, 12 Jul 2024 03:04:06 GMT, Serguei Spitsyn wrote:
> Do I understand this right that the suggestion is to add an explicit runtime
> check for non-emptiness and report an error if an empty line has been
> discovered? If so, then the `is_empty()`check can be removed from the
> `CmdLine::is
On Thu, 4 Jul 2024 23:08:37 GMT, David Holmes wrote:
> My concern is that the logic was wrong and so you fixed it, but this then
> screams out for a test that would have detected the error, but you can't
> write a test because the line can never be empty, so that becomes an
> invariant rather
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Thu, 4 Jul 2024 09:24:52 GMT, David Holmes wrote:
> But if it can't be empty can we not just assert that and get rid of the
> is_empty check from is_executable?
Yes, we might be able to do that.
I was going for just the obvious logic correction, because it's distracting to
read through thi
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Thu, 4 Jul 2024 05:20:38 GMT, David Holmes wrote:
> Can a line ever be empty?
No it can't. Runing "jcmd PID" becomes "help", and giving empty quotes as the
command like
jcmd PID ""
does pass an empty string to parse_and_execute(), but the DCmdIter in there
will never find anything to it
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
On Wed, 3 Jul 2024 13:58:51 GMT, Kevin Walls wrote:
> CmdLine::is_executable() looks wrong, surely an empty line is not executable.
>
> With this change, in DCmd::parse_and_execute() we will avoid needlessly
> entering the code block to try and execute the command.
>
> DCmd tests all good:
> m
18 matches
Mail list logo