delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/10/02/17:45:42

From: "Daniel" <cdnhermit DOT msn AT attcanada DOT net>
Newsgroups: comp.os.msdos.djgpp
Subject: Error: Implicit declaration of function
Lines: 30
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 5.50.4133.2400
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
Message-ID: <Lk7C5.14267$YG5.29312@tor-nn1.netcom.ca>
Date: Mon, 2 Oct 2000 17:48:46 -0400
NNTP-Posting-Host: 142.154.35.62
X-Complaints-To: abuse AT attcanada DOT ca
X-Trace: tor-nn1.netcom.ca 970523051 142.154.35.62 (Mon, 02 Oct 2000 17:44:11 EDT)
NNTP-Posting-Date: Mon, 02 Oct 2000 17:44:11 EDT
Organization: AT&T Canada IES
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Hello, I have a simple application that does not compile because of this
function:
print_result(a, x, power_for(a, x));

which cause the following error:
app.cc(23) Error: Implicit declaration of function 'int power_for(...)'

Here is part of the code:
int main() {
    int x;
    double a;

    get_input(a, x);
    print_result(a, x, power_for(a, x));
......

The function does return a double [ double power_for(double a, int x){  ]
of course, the function power_for(a, x) is define in another file

Is there a way to deal with that kind of problem?  Please note that it
compiles without any error with Borland 5.02.

Thank you
Daniel






- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019