CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
A pattern question

 



zatlas1
User

Jan 30, 2018, 10:19 AM

Post #1 of 3 (2142 views)
A pattern question Can't Post

Hi All
I've encountered this pattern


Code
if ($aa =~ /(?(DEFINE)(?<optional_a>a?))^(?&optional_a)a$/x)


I pretty much understand, or could find in perldoc, an explanation for all components of that pattern. I assume that there is an explanation for what I could not find.

Could somebody point me the explanation of this component:
(DEFINE)

Thank you
ZA


FishMonger
Veteran / Moderator

Jan 30, 2018, 12:02 PM

Post #2 of 3 (2138 views)
Re: [zatlas1] A pattern question [In reply to] Can't Post

It's documented in perlretut.
https://perldoc.perl.org/perlretut.html#Defining-named-patterns


zatlas1
User

Jan 30, 2018, 12:08 PM

Post #3 of 3 (2136 views)
Re: [FishMonger] A pattern question [In reply to] Can't Post

Thank you
Don't know how I missed it
ZA

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives