Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Block comments ala Ray



On 2021-02-14 12:15:31 -0800, Bart Schaefer wrote:
> On Sat, Feb 13, 2021 at 12:35 AM Stephane Chazelas
> <stephane@xxxxxxxxxxxx> wrote:
> > Also consider
> >   scripts that do:
> >
> >   cat > script <<EOF
> >   #! /bin/sh -
> >   ...
> >   EOF
> >
> >   making it difficult to comment out those codes
> 
> That one has some relevance, and argues for requiring #! to be
> followed immediately by a newline, if not also preceded by one.

This could be very confusing and error prone.

How about the "'' " prefix (two single quotes followed by a space)
to start and end a block comment?

I doubt that a command starting with these characters is something
useful. What follows could then be decided to allow nesting of block
comments.

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)




Messages sorted by: Reverse Date, Date, Thread, Author