From: Ian Lance Taylor <iant@google.com>
To: gcc-patches@gcc.gnu.org, gofrontend-dev@googlegroups.com
Subject: Go patch committed: Traverse function types
Date: Tue, 21 Dec 2010 18:59:00 -0000 [thread overview]
Message-ID: <mcrpqsvm1ys.fsf@google.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 230 bytes --]
In the function traversal routine, I forgot to traverse the function
type itself. Doing this avoids a crash when an array has an unknown
length. Bootstrapped and tested on x86_64-unknown-linux-gnu. Committed
to mainline.
Ian
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: crash --]
[-- Type: text/x-diff, Size: 565 bytes --]
diff -r 997516c45e8b go/gogo.cc
--- a/go/gogo.cc Mon Dec 20 22:11:12 2010 -0800
+++ b/go/gogo.cc Tue Dec 21 10:05:18 2010 -0800
@@ -2644,6 +2644,14 @@
{
unsigned int traverse_mask = traverse->traverse_mask();
+ if ((traverse_mask
+ & (Traverse::traverse_types | Traverse::traverse_expressions))
+ != 0)
+ {
+ if (Type::traverse(this->type_, traverse) == TRAVERSE_EXIT)
+ return TRAVERSE_EXIT;
+ }
+
// FIXME: We should check traverse_functions here if nested
// functions are stored in block bindings.
if (this->block_ != NULL
reply other threads:[~2010-12-21 18:10 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=mcrpqsvm1ys.fsf@google.com \
--to=iant@google.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=gofrontend-dev@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).