$if->{PROPERTIES}->{pointer_default_top} ne "ref") {
warning($if, "pointer_default_top() is pidl-specific");
}
-
- foreach my $x (@{$if->{DATA}}) {
- if ($x->{TYPE} eq "DECLARE") {
- warning($if, "the declare keyword is pidl-specific");
- next;
- }
- }
}
sub Check($)
return 0 if (Parse::Pidl::Typelist::is_scalar($type));
- return 1 if ($type->{TYPE} eq "DECLARE"); # assume the worst
-
return can_contain_deferred($type->{DATA}) if ($type->{TYPE} eq "TYPEDEF");
return 0 unless defined($type->{ELEMENTS});
my $dt = getType($e);
- if ($dt->{TYPE} eq "TYPEDEF" or $dt->{TYPE} eq "DECLARE") {
+ if ($dt->{TYPE} eq "TYPEDEF") {
return align_type($dt->{DATA});
} elsif ($dt->{TYPE} eq "ENUM") {
return align_type(Parse::Pidl::Typelist::enum_type_fn($dt));
my @consts = ();
my @functions = ();
my @endpoints;
- my @declares = ();
my $opnum = 0;
my $version;
}
foreach my $d (@{$idl->{DATA}}) {
- if ($d->{TYPE} eq "DECLARE") {
- push (@declares, $d);
- } elsif ($d->{TYPE} eq "FUNCTION") {
+ if ($d->{TYPE} eq "FUNCTION") {
push (@functions, ParseFunction($idl, $d, \$opnum));
} elsif ($d->{TYPE} eq "CONST") {
push (@consts, ParseConst($idl, $d));
FUNCTIONS => \@functions,
CONSTS => \@consts,
TYPES => \@types,
- DECLARES => \@declares,
ENDPOINTS => \@endpoints
};
}
my ($prefix, $t) = @_;
return "$prefix\_$t->{NAME}" if (ref($t) eq "HASH" and
- ($t->{TYPE} eq "TYPEDEF" or $t->{TYPE} eq "DECLARE"));
+ $t->{TYPE} eq "TYPEDEF");
return "$prefix\_$t->{TYPE}_$t->{NAME}" if (ref($t) eq "HASH");
return "$prefix\_$t";
}
my ($prefix, $t) = @_;
return "$prefix\_$t->{NAME}" if (ref($t) eq "HASH" and
- ($t->{TYPE} eq "TYPEDEF" or $t->{TYPE} eq "DECLARE"));
+ $t->{TYPE} eq "TYPEDEF");
return "$prefix\_$t->{TYPE}_$t->{NAME}" if (ref($t) eq "HASH");
return "$prefix\_$t";
}
return 1 if (ref($type) eq "HASH" and $type->{TYPE} eq "SCALAR");
if (my $dt = getType($type)) {
- return is_scalar($dt->{DATA}) if ($dt->{TYPE} eq "TYPEDEF" or
- $dt->{TYPE} eq "DECLARE");
+ return is_scalar($dt->{DATA}) if ($dt->{TYPE} eq "TYPEDEF");
return 1 if ($dt->{TYPE} eq "SCALAR" or $dt->{TYPE} eq "ENUM" or
$dt->{TYPE} eq "BITMAP");
}
my ($t, $n) = @_;
return mapType($t->{DATA}, $n) if ($t->{TYPE} eq "TYPEDEF");
- return mapType($t->{DATA}, $n) if ($t->{TYPE} eq "DECLARE");
return mapScalarType($n) if ($t->{TYPE} eq "SCALAR");
return "enum $n" if ($t->{TYPE} eq "ENUM");
return "struct $n" if ($t->{TYPE} eq "STRUCT");
foreach my $y (@{$x->{DATA}}) {
addType($y) if (
$y->{TYPE} eq "TYPEDEF"
- or $y->{TYPE} eq "DECLARE"
or $y->{TYPE} eq "UNION"
or $y->{TYPE} eq "STRUCT"
or $y->{TYPE} eq "ENUM"