Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Greg London
Federico Lucifredi continues his quest to build a hardware-assisted automagic hard-drive wiper, using perl in an embedded device. *Shiny hardware! Demo! Code*! Federico, It was getting late, so I didn't want to throw in another tangent for how to write your code. But I was thinking you could

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Tom Metro
Greg London wrote: ...replace your printline() function with a closure. Instead of doing this over and over: printline($var1,\$y,text,font,$size); You could take $y and put it inside a lexical block... To me this looks like an example of where we suffer by not having OO truly baked into the

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Greg London
Greg London wrote: ...replace your printline() function with a closure. Instead of doing this over and over: printline($var1,\$y,text,font,$size); You could take $y and put it inside a lexical block... To me this looks like an example of where we suffer by not having OO truly baked into

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Tom Metro
Greg London wrote: I've pasted an OO version and the closure version of my script below. They're nearly identical. they both take about the same amount of lines of code. Nice that you fleshed out the examples a bit further. Meh. I don't blame that on perl's lack of builtin OO. The problem

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Ben Tilly
On Wed, Apr 10, 2013 at 1:33 PM, Tom Metro tmetro+boston...@gmail.com wrote: Greg London wrote: [...] Perl's bolt-on version of classes can fix this about as easily as perl's closure stuff can fix it. The closure version doesn't scale. You can't stick it in a library and call it from

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Greg London
But that's my point. The default, especially with a short script, becomes procedural. Well, I assume it varies from person to person, and the reason my default is procedural is because I've got about two decades of procedural programming under my belt, and only 5 or 10 of the last years has

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-10 Thread Greg London
I do not agree with this assertion. I've seen closure based solutions and OO versions both scale, and both fail. They are appropriate for different problems, and different designs. But as long as you know what they are (and aren't) good at, you can choose either. I'd agree. I've done quite

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-09 Thread Greg London
Checked my calendar. I'll be there. Greg Have a speaker, one RSVP, and me so far. Who else is coming? On Sun, Apr 7, 2013 at 5:13 PM, Bill Ricker bill.n1...@gmail.com wrote: *Tuesday, April 9, 2013, MIT E51-376 7pm-10pm* Embedded Perl with Federico Federico Lucifredi continues his

Re: [Boston.pm] Tech Meeting Tuesday Apr 9th, Embedded Perl with Federico, 7, MIT E51-376

2013-04-09 Thread Tom Metro
Bill Ricker wrote: Who else is coming? please RSVP for refreshments. I plan to. (But don't add me to the refreshment count.) I'll forward the announcement to the BLU Hardware Hacking list: http://blu.wikispaces.com/Hardware+Hacking where there should be an overlap of interest. -Tom --