#!/usr/bin/perl
# this app shows the result of the regexp in the enum-comma.patch

my $test = <<EOF;
typedef enum {
  I = 1,
  AM,
  A, 
  TEST,
} EnumTest;
EOF

print "test string before removing empty ends: $test\n";
$test =~ s/,(\s*})/$1/g;
print "test string after removing empty ends: $test\n";
