While this actually can be done, it's much harder than you'd think. You see, it's too simple-minded for certain kinds of C programs, in particular, those with what appear to be comments in quoted strings. No, regular expressions just aren't powerful enough. But they are not the proper tool for every nail. You still need to use non-regex techniques to parse balanced text, such as the text enclosed between matching parentheses or braces, for example.
Most people mean that greedy regexes match as much as they can.
Because once Perl sees that you need one of these variables anywhere in the program, it has to provide them on each and every pattern match. But then you lose the vertical alignment of the patterns. Strictly speaking, nothing. Stylistically speaking, it's not a good way to write maintainable code. This is hard, and there's no good way.