'int32' => 4,
'uint32' => 4,
'hyper' => 8,
+ 'double' => 8,
'pointer' => 8,
'dlong' => 4,
'udlong' => 4,
$is_fixed = 1 if (not $is_conformant and Parse::Pidl::Util::is_constant($size));
$is_inline = 1 if (not $is_conformant and not Parse::Pidl::Util::is_constant($size));
+ if ($i == 0 and $is_fixed and has_property($e, "string")) {
+ $is_fixed = 0;
+ $is_varying = 1;
+ $is_string = 1;
+ delete($e->{PROPERTIES}->{string});
+ }
+
push (@$order, {
TYPE => "ARRAY",
SIZE_IS => $size,
"bitmap64bit" => ["BITMAP"],
# array
- "range" => ["ELEMENT"],
+ "range" => ["ELEMENT", "PIPE"],
"size_is" => ["ELEMENT"],
"string" => ["ELEMENT"],
"noheader" => ["ELEMENT"],
}
}
+#####################################################################
+# validate a pipe
+sub ValidPipe($)
+{
+ my ($pipe) = @_;
+ my $data = $pipe->{DATA};
+
+ ValidProperties($pipe, "PIPE");
+
+ fatal($pipe, $pipe->{NAME} . ": 'pipe' is not yet supported by pidl");
+}
+
#####################################################################
# parse a typedef
sub ValidTypedef($)
STRUCT => \&ValidStruct,
UNION => \&ValidUnion,
ENUM => \&ValidEnum,
- BITMAP => \&ValidBitmap
+ BITMAP => \&ValidBitmap,
+ PIPE => \&ValidPipe
}->{$t->{TYPE}}->($t);
}
$d->{TYPE} eq "STRUCT" or
$d->{TYPE} eq "UNION" or
$d->{TYPE} eq "ENUM" or
- $d->{TYPE} eq "BITMAP") && ValidType($d);
+ $d->{TYPE} eq "BITMAP" or
+ $d->{TYPE} eq "PIPE") && ValidType($d);
}
}