http://www.perlmonks.org?node_id=588034


in reply to ?: and saving backreferences

I'm rather confused as to what "because the $1 backreference is lost once you exit the scope of the if/else" means to you, to me it sounds like you think $1 is cleared after you exit the scope it was declared in, which is clearly not true.

Am I missinterpreting your statements some how?

Yeah, I was missinterpreting. Consider this retracted.