Shop OBEX P1 Docs P2 Docs Learn Events
Check source for bad function call or global variable name — Parallax Forums

Check source for bad function call or global variable name

Hello, I am working on reusable code functions and am doing the "try this" part. I have typed the example of code parallax provides and get this error message. I have checked other forums and tried their suggestions about having the learn folder in the correct spot and still no luck. does anyone have any idea what the problem is? the code I am trying to run is under the error message.

Function Call.c: In function 'main':
Function Call.c:16:4: warning: implicit declaration of function 'hello' [-Wimplicit-function-declaration]
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0x5): undefined reference to `_hello'
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0x8): undefined reference to `_hello'
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0xb): undefined reference to `_hello'
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0xe): undefined reference to `_hello'
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0x11): undefined reference to `_hello'
collect2: ld returned 1 exit status
Done. Build Failed!

Check source for bad function call or global variable name `_hello'
C:\Users\nikos\AppData\Local\Temp\cc0Hj8U1.o: In function `_main':
(.text+0x8):

#include "simpletools.h" // Include simpletools

int main() // main function
{
for(int i = 1; i <= 5; i++)
{
hello(); // Call hello function
}
print("Hello again from main!\n"); // Display message
}

Comments

Sign In or Register to comment.