From: Martin Nagy <nagy.martin@gmail.com>
To: linux-sparse@vger.kernel.org
Subject: [PATCH] Add missing checks for Waddress-space
Date: Thu, 23 Apr 2009 22:25:19 +0200 [thread overview]
Message-ID: <20090423222519.48191d61@notas> (raw)
Some of these are missing in evaluate.c. Maybe we should change the
option to not consider address space at all, if unset. It would be much
easier to make attribute_address_space() ignore it.
Signed-off-by: Martin Nagy <nagy.martin@gmail.com>
---
evaluate.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/evaluate.c b/evaluate.c
index 5c3812e..be7a17c 100644
--- a/evaluate.c
+++ b/evaluate.c
@@ -1149,7 +1149,7 @@ static struct symbol *evaluate_conditional_expression(struct expression *expr)
goto Err;
}
/* OK, it's pointer on pointer */
- if (ltype->ctype.as != rtype->ctype.as) {
+ if (Waddress_space && ltype->ctype.as != rtype->ctype.as) {
typediff = "different address spaces";
goto Err;
}
@@ -1339,7 +1339,7 @@ static int compatible_assignment_types(struct expression *expr, struct symbol *t
* we do not remove qualifiers from pointed to [C]
* or mix address spaces [sparse].
*/
- if (t->ctype.as != s->ctype.as) {
+ if (Waddress_space && t->ctype.as != s->ctype.as) {
typediff = "different address spaces";
goto Err;
}
--
1.6.0.6
next reply other threads:[~2009-04-23 20:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-23 20:25 Martin Nagy [this message]
2009-04-24 22:53 ` [PATCH] Add missing checks for Waddress-space Christopher Li
2009-04-25 7:36 ` Martin Nagy
2009-04-27 6:08 ` Christopher Li
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=20090423222519.48191d61@notas \
--to=nagy.martin@gmail.com \
--cc=linux-sparse@vger.kernel.org \
/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 NNTP newsgroup(s).