From: Christopher Li <sparse@chrisli.org>
To: Jiri Slaby <jslaby@suse.cz>
Cc: Linux-Sparse <linux-sparse@vger.kernel.org>
Subject: Re: [PATCH 1/1] parser: add support for asm goto
Date: Fri, 18 Jun 2010 02:40:42 -0700 [thread overview]
Message-ID: <AANLkTil84_v2xi2HR_HjTTLMDAOZmyXbSmPrJ-KiQIzl@mail.gmail.com> (raw)
In-Reply-To: <4C1B2E77.3090404@suse.cz>
On Fri, Jun 18, 2010 at 1:29 AM, Jiri Slaby <jslaby@suse.cz> wrote:
> On 06/18/2010 10:21 AM, Jiri Slaby wrote:
>> Holy crap, in docco, there is nothing like that, but I checked gcc
>> parser sources to be sure, and there indeed is:
>> asm type-qualifier[opt] ( asm-argument ) ;
>> asm type-qualifier[opt] goto ( asm-goto-argument ) ;
>> So yes, asm volatile goto is valid. Would you take care of that?
>
> It is as easy as:
> diff --git a/parse.c b/parse.c
> index caf10b9..1d20658 100644
> --- a/parse.c
> +++ b/parse.c
> @@ -1915,7 +1915,8 @@ static struct token *parse_asm_statement(struct
> token *token, struct statement *
> stmt->type = STMT_ASM;
> if (match_idents(token, &__volatile___ident, &__volatile_ident,
> &volatile_ident, NULL)) {
> token = token->next;
> - } else if (match_idents(token, &goto_ident, NULL)) {
> + }
> + if (match_idents(token, &goto_ident, NULL)) {
> is_goto = 1;
> token = token->next;
> }
Looks good to me.
Chris
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2010-06-18 9:40 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1276158810-21313-1-git-send-email-jslaby@suse.cz>
2010-06-10 19:18 ` [PATCH 1/1] parser: add support for asm goto Christopher Li
2010-06-11 15:05 ` Jiri Slaby
2010-06-11 20:21 ` Christopher Li
2010-06-18 0:35 ` Christopher Li
2010-06-18 8:21 ` Jiri Slaby
2010-06-18 8:23 ` Jiri Slaby
2010-06-18 8:29 ` Jiri Slaby
2010-06-18 9:40 ` Christopher Li [this message]
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=AANLkTil84_v2xi2HR_HjTTLMDAOZmyXbSmPrJ-KiQIzl@mail.gmail.com \
--to=sparse@chrisli.org \
--cc=jslaby@suse.cz \
--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).