re.Scanner - match python dot notation

Christian K. ckkart at
Mon Feb 7 16:34:41 CET 2011


I am trying to find a regexp to be used with re.Scanner that matches the 
'package.module.member' syntax. More specifically I want to parse 
function strings like


and sort out variables/constants.

This one here works using re.match but fails when used with Scanner (due 
to the grouping () I guess).


I highly appreciate your comments.

Regards, christian

More information about the Python-list mailing list