Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic too many arguments to function... (Read 6936 times)
Gilles Plante
Full Member
***
Offline


Posts: 156
Location: Québec, Canada
Joined: Oct 31st, 2013
too many arguments to function...
Jan 22nd, 2014 at 2:43pm
Print Post  
Hi,

sorry if that was already mentioned. This  morning, I called strcpy() passing too many arguments. Thats was flagged by the compiler, but when I clicked on the message, I was brought to the.h file declaring strcpy() instead of being brought to the line in error in my code.

Thanks
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: too many arguments to function...
Reply #1 - Jan 22nd, 2014 at 2:48pm
Print Post  
Hi Giles, was there more than one error line? Did one take you to the code and one to the definition of the function?

The recent beta version of Visual Micro should show better error messages than the current release but in all case the dbl click should be based on what was returned to us by the compiler.

We get a load of text back from the arduino compiler and we display the error messages and locations that are returned to us within the text.

Maybe post a few lines of code and I'll give it a try later.

Thanks
  
Back to top
IP Logged
 
Gilles Plante
Full Member
***
Offline


Posts: 156
Location: Québec, Canada
Joined: Oct 31st, 2013
Re: too many arguments to function...
Reply #2 - Jan 22nd, 2014 at 3:09pm
Print Post  
Hi Tim,

wow, you arte pretty fast to reply  Smiley.

I reproduced the error, wrong code being
Code
Select All
	strcpy(Mess, "%d", m_tss);
	strcat(Mess, XB_REP_OK); 


From output window: Quote:
string.h : too many arguments to function 'char* strcpy(char*, const char*)'
UF_TSN_1.ino : at this point in file

My bad  Embarrassed if I double click on the first line, I am brought to the header file, but if it's on the second line, I am brought to my code  Undecided.

Sorry
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: too many arguments to function...
Reply #3 - Jan 22nd, 2014 at 3:41pm
Print Post  
Great thanks. 

Thanks for the update, it is good to hear the drill down from errors into both your own code and the Arduino core or library code is working. 

  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint