| revdiablo | That's why I mean it can be a bit complicated |
| unfo | do i also want Perl::Critic::More? |
| revdiablo | I wouldn't You will get plenty from Perl::Critic |
| unfo | i see there's also Perl::Critic::Lax. If Perl::Critic is too much and I get frustrated of disabling certain warnings, I'll try that instead. :) |
| revdiablo | Generally you don't run Perl::Critic on every execution as with warnings, btw. A lot of people integrate it into their test suite, or just run it periodically |
| unfo | is there a way to set it to expect a certain number of criticisms and to tell you only if there are more than that number? Also is there a way to add annotations like splint(1)'s @SOMETHING@ annotations to have it suppress a certain criticism at a certain point? |
| petafile | noob question: @array = shift(shift(@otherArray)); does @array have otherArray minus the 2 first values(what I want) or the 2 first elements (what I DON"T want) Seems like there's a better way to do that anyway if someone could point me to it |
| revdiablo | unfo: Yes to the 2nd question unfo: I'm not sure about the first question petafile: No, that won't work petafile: shift() expects an array. The outer shift call will try to shift the return value from the inner shift. It won't work. |
| petafile | revdiablo: what would work? Do I have to ues a slice? ah, tha makes sense |
| revdiablo | @array = @otherArray[0,1]; |
| petafile | how do i fix it? |
| revdiablo | You want to remove them from @otherArray too? |
| petafile | it doesn't matter |
| revdiablo | Then the array slice is the easiest |
| petafile | so @array = @otherArray[2-$#otherArray] |
| revdiablo | (What I just showed you) What? I thought you wanted the first two elements |
| petafile | no, everything but |
| revdiablo | Oh, @array = @otherArray[2..$#otherArray]; |
| petafile | thanks |
| sbingner | this is C, but I like it better than my perl version: typedef short child; child* vagina (long penis) { short kid; if (penis>=MINSIZE) return &kid; return SAILORS; } |
| revdiablo | sbingner: Er |
| unfo | sbingner: please help us keep #perl family-friendly and work-safe so that we can have the most amount of help provided here. |
| sbingner | unfo, that's work safe lol |
| petafile | revdiablo: will that be out of bounds (ie last index + 1) or the last index? |
| revdiablo | sbingner: The phrase 'child vagina' is not work safe nor family friendly sbingner: Regardless of the intent |
| petafile | though funny. . . |
| revdiablo | petafile: $#array is the last index |
| petafile | thanks revdiablo: to be fair, its child* vagina, meaning that the vagina returns a child pointer :) |