projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8ed8ea7
)
Avoid crash with extra struct initializers with abstract types.
author
Ian Lance Taylor
<ian@gcc.gnu.org>
Wed, 19 Jan 2011 06:04:00 +0000
(06:04 +0000)
committer
Ian Lance Taylor
<ian@gcc.gnu.org>
Wed, 19 Jan 2011 06:04:00 +0000
(06:04 +0000)
From-SVN: r168984
gcc/go/gofrontend/expressions.cc
patch
|
blob
|
history
diff --git
a/gcc/go/gofrontend/expressions.cc
b/gcc/go/gofrontend/expressions.cc
index a11e3d6fa176ffd3ed31398f4eab155ad6a66c2c..819fb616452b786f59a3658526e2011b22cace03 100644
(file)
--- a/
gcc/go/gofrontend/expressions.cc
+++ b/
gcc/go/gofrontend/expressions.cc
@@
-10609,6
+10609,10
@@
Struct_construction_expression::do_determine_type(const Type_context*)
(*pv)->determine_type(&subcontext);
}
}
+ // Extra values are an error we will report elsewhere; we still want
+ // to determine the type to avoid knockon errors.
+ for (; pv != this->vals_->end(); ++pv)
+ (*pv)->determine_type_no_context();
}
// Check types.