in reply to Better ways to make multi-line comments in Perl?
Was having a bit of concern due to multi-line comment feature not readily available in perl.
Started to look-out for options and came across this post, and subsequently came to know the various ways we implement the multi-line comment.
Just took one of the options and slightly modified it and have been using it in way like a "defacto" standard in my scripts.
It was nice when i started to use it, and thought would share it.
--- multi-line comment syntax ---
q##//q# ... comments ... ... comments ... #;
--- example ---
q# -- GLOBAL VARIABLES -- #//q# ---------------- $ps : holds the "ps" command binary $ps_opt : this extracts only "pid" and "command name" from the "ps" output $ps_opt1 : extracts "command name" along with its "arguments" for a given "pid" $dir : hold "/proc" as value. This is the source directory from where the search for required informations for each pid starts $total_swap : stores the sum of swap usage of all the individual threads/processes @proc_swap : this array holds the "ref_arrays" in each of its index $PROC : is the file/command handle which holds the information of all the contents within "/proc" directory #;
-------------------
Thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Answer: Better ways to make multi-line comments in Perl?
by jdporter (Paladin) on Aug 28, 2015 at 13:20 UTC | |
|
Re: Answer: Better ways to make multi-line comments in Perl?
by adefaria (Beadle) on Aug 25, 2015 at 16:43 UTC |