9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: rog@vitanuova.com
To: 9fans@cse.psu.edu
Subject: Re: [9fans] function inconsistently declared
Date: Tue,  1 Oct 2002 17:44:03 +0100	[thread overview]
Message-ID: <bd474a67ebb8d0fc5e2cf6c76f5ea840@vitanuova.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 68 bytes --]

don't mix ANSI and non-ANSI function declarations and definitions!

[-- Attachment #2: Type: message/rfc822, Size: 1610 bytes --]

From: "Zoltan Jarai" <jarai@mail.tvnet.hu>
To: 9fans@cse.psu.edu
Subject: [9fans] function inconsistently declared
Date: Tue, 1 Oct 2002 18:23:26 +0200
Message-ID: <9b9bee4f2f9cf8257bfa185a67d8f8d5@mail.tvnet.hu>

I suspect this must be elementary but could someone, please, enlighten
me why the code fragment below produces an error message:

cpu% 8c -FVw c.c
c.c:4 function inconsistently declared: f
cpu% cat c.c
int f(int,char);
int f(a,b)
	int a;
	char b;
{
  return a+b;
}
cpu%

             reply	other threads:[~2002-10-01 16:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-01 16:44 rog [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-10-01 17:42 C H Forsyth
2002-10-02  9:01 ` Douglas A. Gwyn
2002-10-01 16:51 Zoltan Jarai
2002-10-01 16:32 Russ Cox
2002-10-01 16:23 Zoltan Jarai

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=bd474a67ebb8d0fc5e2cf6c76f5ea840@vitanuova.com \
    --to=rog@vitanuova.com \
    --cc=9fans@cse.psu.edu \
    /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).