perlapi overrides system read()/ioctl() methods

2016-05-12 Thread Timothy Madden
Hello I am trying to write an extension module (uses native C code) and I notice after including , that POSIX read() function is now overriden by a Perl macro. Can I find this explained somewhere please ? Is it safe to ignore ? Should I #undef it, or should I create a separate .c file without ju

Re: perlapi overrides system read()/ioctl() methods

2016-05-12 Thread Uri Guttman
On 05/12/2016 04:15 PM, Timothy Madden wrote: Hello I am trying to write an extension module (uses native C code) and I notice after including , that POSIX read() function is now overriden by a Perl macro. Can I find this explained somewhere please ? Is it safe to ignore ? Should I #undef

This is one of the things ...

2016-05-12 Thread lee
... I appreciate perl for: $dbh->do("INSERT INTO $T_ENTRIES (" . join(', ', map($dbh->quote_identifier($_), $cgi->param)) . ') VALUES (' . join(', ', map($dbh->quote($_), map($cgi->param($_), $cgi->param))) . ')') if(scalar($cgi->param) == 111); -- To unsubscribe, e-mail:

Re: This is one of the things ...

2016-05-12 Thread Aaron Wells
Thank you Lee. I had forgotten about that use case. I tried to do dibasic query building once upon a time with JavaScript before discovering the goodness of Perl. Ended up leaning on a library. It made things better, but it didn't make them Perl. On Thu, May 12, 2016, 5:06 PM lee wrote: > > ...

Re: This is one of the things ...

2016-05-12 Thread Uri Guttman
On 05/12/2016 08:04 PM, lee wrote: ... I appreciate perl for: $dbh->do("INSERT INTO $T_ENTRIES (" . join(', ', map($dbh->quote_identifier($_), $cgi->param)) . ') VALUES (' . join(', ', map($dbh->quote($_), map($cgi->param($_), $cgi->param))) . ')') if(scalar($cgi->param)

Re: This is one of the things ...

2016-05-12 Thread Shawn H Corey
On Thu, 12 May 2016 21:35:02 -0400 Uri Guttman wrote: > my $holders = join ',', ('?') x @cgi_params ; > > and i like here docs for sql so i can see the sql and not need all > those quotes and noise. PBP recommends that you put short strings that are all punctuation in q{}, so they will be

Re: This is one of the things ...

2016-05-12 Thread SSC_perl
On May 12, 2016, at 7:10 PM, Shawn H Corey wrote: >> my $holders = join ',', ('?') x @cgi_params; > PBP recommends that you put short strings that are all punctuation in > q{}, so they will be easier to read. > >my $holders = join q{,}, (q{?}) x @cgi_params; I realize stuff like this

Re: This is one of the things ...

2016-05-12 Thread Uri Guttman
On 05/12/2016 11:00 PM, SSC_perl wrote: On May 12, 2016, at 7:10 PM, Shawn H Corey wrote: my $holders = join ',', ('?') x @cgi_params; PBP recommends that you put short strings that are all punctuation in q{}, so they will be easier to read. my $holders = join q{,}, (q{?}) x @cgi_params;