Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
4567d92a
Commit
4567d92a
authored
Aug 12, 2008
by
Matthias Braun
Browse files
add some more assert to make sure we don't use compound_path stuff on new style initializers
[r21117]
parent
47d43fb9
Changes
1
Hide whitespace changes
Inline
Side-by-side
ir/tr/entity.c
View file @
4567d92a
...
...
@@ -909,6 +909,7 @@ set_compound_ent_value_w_path(ir_entity *ent, ir_node *val, compound_graph_path
int
get_compound_ent_n_values
(
ir_entity
*
ent
)
{
assert
(
!
ent
->
has_initializer
);
assert
(
is_compound_entity
(
ent
)
&&
(
ent
->
variability
!=
variability_uninitialized
));
return
ARR_LEN
(
ent
->
attr
.
cmpd_attr
.
values
);
}
/* get_compound_ent_n_values */
...
...
@@ -916,6 +917,7 @@ get_compound_ent_n_values(ir_entity *ent) {
ir_node
*
get_compound_ent_value
(
ir_entity
*
ent
,
int
pos
)
{
assert
(
is_compound_entity
(
ent
)
&&
(
ent
->
variability
!=
variability_uninitialized
));
assert
(
!
ent
->
has_initializer
);
assert
(
0
<=
pos
&&
pos
<
ARR_LEN
(
ent
->
attr
.
cmpd_attr
.
values
));
return
ent
->
attr
.
cmpd_attr
.
values
[
pos
];
}
/* get_compound_ent_value */
...
...
@@ -923,6 +925,7 @@ get_compound_ent_value(ir_entity *ent, int pos) {
compound_graph_path
*
get_compound_ent_value_path
(
ir_entity
*
ent
,
int
pos
)
{
assert
(
is_compound_entity
(
ent
)
&&
(
ent
->
variability
!=
variability_uninitialized
));
assert
(
!
ent
->
has_initializer
);
assert
(
0
<=
pos
&&
pos
<
ARR_LEN
(
ent
->
attr
.
cmpd_attr
.
val_paths
));
return
ent
->
attr
.
cmpd_attr
.
val_paths
[
pos
];
}
/* get_compound_ent_value_path */
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment