summaryrefslogtreecommitdiff
path: root/source4/build/pidl/Parse/Pidl/Util.pm
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2005-07-10 01:16:02 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:19:29 -0500
commit514ce32a894585b66d7dc276d10fe6f4b525e02b (patch)
treec8d5f194aba2ba1ca2738ca9d6d14dfbe51c2433 /source4/build/pidl/Parse/Pidl/Util.pm
parent76ecf81428c161a98a5621b55a64cb8515f80585 (diff)
downloadsamba-514ce32a894585b66d7dc276d10fe6f4b525e02b.tar.gz
samba-514ce32a894585b66d7dc276d10fe6f4b525e02b.tar.bz2
samba-514ce32a894585b66d7dc276d10fe6f4b525e02b.zip
r8274: Export some more symbols.
(This used to be commit d1f754a0a34c5938579a605b4f113100e14bac3d)
Diffstat (limited to 'source4/build/pidl/Parse/Pidl/Util.pm')
-rw-r--r--source4/build/pidl/Parse/Pidl/Util.pm29
1 files changed, 1 insertions, 28 deletions
diff --git a/source4/build/pidl/Parse/Pidl/Util.pm b/source4/build/pidl/Parse/Pidl/Util.pm
index fec18e6aeb..5e9544d40b 100644
--- a/source4/build/pidl/Parse/Pidl/Util.pm
+++ b/source4/build/pidl/Parse/Pidl/Util.pm
@@ -5,7 +5,7 @@
package Parse::Pidl::Util;
use Exporter 'import';
-@EXPORT_OK = qw(has_property property_matches);
+@EXPORT_OK = qw(has_property property_matches ParseExpr);
use strict;
@@ -52,33 +52,6 @@ sub FlattenHash($)
}
#####################################################################
-# traverse a perl data structure removing any empty arrays or
-# hashes and any hash elements that map to undef
-sub CleanData($)
-{
- sub CleanData($);
- my($v) = shift;
- if (ref($v) eq "ARRAY") {
- foreach my $i (0 .. $#{$v}) {
- CleanData($v->[$i]);
- if (ref($v->[$i]) eq "ARRAY" && $#{$v->[$i]}==-1) {
- $v->[$i] = undef;
- next;
- }
- }
- # this removes any undefined elements from the array
- @{$v} = grep { defined $_ } @{$v};
- } elsif (ref($v) eq "HASH") {
- foreach my $x (keys %{$v}) {
- CleanData($v->{$x});
- if (!defined $v->{$x}) { delete($v->{$x}); next; }
- if (ref($v->{$x}) eq "ARRAY" && $#{$v->{$x}}==-1) { delete($v->{$x}); next; }
- }
- }
- return $v;
-}
-
-#####################################################################
# return the modification time of a file
sub FileModtime($)
{