On Mon, Oct 31, 2022 at 11:24:06AM -0700, Roger Marquis wrote:
> scott wrote:
> >Historically, '[[' was implemented directly by the shell, while '['
> >was implemented using fork(), exec("[").    There is clearly a benefit
> >to eliminating process creation.
> 
> Isn't that an implementation detail that can be easily changed?  If so
> not sure it'd be relevant to the compatibility or syntax issues with '[['.

The current standard allows the shell to treat any command as a
builtin and execute it as such, so long as it preserves the semantics.

However, another benefit of the '[[' builtin is that it does not
do word splitting or pattern expansion.

scott

  • [1003.1(2008... Austin Group Bug Tracker via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group
    • Re: [10... Scott Lurndal via austin-group-l at The Open Group
      • Re:... Roger Marquis via austin-group-l at The Open Group
        • ... Tapani Tarvainen via austin-group-l at The Open Group
        • ... Scott Lurndal via austin-group-l at The Open Group
          • ... Stephane Chazelas via austin-group-l at The Open Group
      • Re:... Stephane Chazelas via austin-group-l at The Open Group
      • Re:... Robert Elz via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group
    • [1003.1... Austin Group Bug Tracker via austin-group-l at The Open Group

Reply via email to