develooper Front page | perl.perl6.users | Postings from June 2018


Thread Previous | Thread Next
June 14, 2018 15:57
Message ID:
>> <>> wrote:
>>     On 06/13/2018 12:27 PM, Brandon Allbery wrote:
>>         use MONKEY-SEE-NO-EVAL;
>>     Thank you.  Someone had fun with that name!
>>     Do I presume there is not other way around the issue?

On 06/14/2018 05:21 AM, The Sidhekin wrote:
> On Thu, Jun 14, 2018 at 8:01 AM, Todd Chester < =
>    That depends on your use case.  EVAL/eval is powerful enough it could 
> be pretty much anything, so bird's-eye view here:
>    If $RunSpecific is sufficiently non-generic (i.e. couldn't be any 
> code whatsoever), an approach with dispatch tables or similar (dynamic 
> method lookup, giant switch ...) might be an alternative.  Optionally 
> parsing the code (Perl subset, DSL?) yourself.
>    For use with any code whatsoever though, you need that kind of power, 
> and as Brandon wrote: You get to do your own data sanitization, and you 
> tell Perl 6 you did so with "use MONKEY-SEE-NO-EVAL;".
> Eirik

Hi Eirik,

The program goes out and checks for new updates to programs I carry
with me to support my customers.  To debug a sub individually,
I place the sub's name on the command line.  This way I don't
have to run them all at once to debug one sub.  $RunSpecific
is the name of a particular sub.  (If I misspell the sub name, I
get ignored.)

This is especially useful when adding a new program to check or
when someone changes their web page.

Chuckle: I catch a lot of boo-boos when they change their
web pages.

On one program, I can't get the vendor to place the program's
revision on the web.  But he does place a check sum to for
the download.  So, I download the checksum and compare it to
the previous checksum, if they don't match, I download the
actual program.  Then do an unzip list and find the revision
from one of the files inside the zip.  With the revision,
I name the zip file properly.  And yes, I have caught boo-boos
in his zip file before.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About