On 02/20/2013 06:41 AM, Daniel P. Berrange wrote:
On Wed, Feb 20, 2013 at 06:34:33AM -0700, Eric Blake wrote:
> Automating a sorting check is the only way to ensure we don't
> regress. Suggested by Dan Berrange.
>
>
> - if (/^\s*$/) {
> + if (/^#/) {
This can match plain comments, or comments with a filename
> + $_ =~ s/^# //;
> + $groupfile = $_;
So I'd split this into two:
if (/^#\s*((\w+\/)*(\w+\.h$))\s*$) {?
$groupfile = $1;
} elif (/^#\s*$/) {
# Ignore comments
...
Good idea.
> + } elsif (/^\s*$/) {
ACK either with or without the change
Pushed with the split check.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library
http://libvirt.org