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 VS2017 red line error sqrt() (Read 2780 times)
groz
Junior Member
**
Offline


Posts: 22
Joined: Feb 21st, 2018
VS2017 red line error sqrt()
Apr 8th, 2018 at 6:42pm
Print Post  
I'm getting a red line when using functions from math.h. As you can see in the attachment, the error message is "too many arguments in function call". The code compiles correctly and when I peek the definition, it pulls up the proper definition within math.h. 

Why is this happening ? Note: I've not changed any default settings with VS2017.

Thanks
  

Please Register or Login to the Forum to see File Attachments
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: VS2017 red line error sqrt()
Reply #1 - Apr 10th, 2018 at 1:35pm
Print Post  
Hi,

Sorry I missed this post.

If you did not previously see this intellisense error then either visual studio 2017 has updated or the arduino core you are using has been updated.

Please always say which board and core you have installed because they are all different.

I suspect the issue is that VS C++ does not understand the definition of _PARAMS. It's not perfect.

You can add intellisense redefines that do not alter compiler code to workaround this and when I know the hardware can look at visual micro applying the workaround automatically.

http://www.visualmicro.com/page/Extending-Visual-Studio-Intellisense.aspx
  
Back to top
IP Logged
 
groz
Junior Member
**
Offline


Posts: 22
Joined: Feb 21st, 2018
Re: VS2017 red line error sqrt()
Reply #2 - Apr 10th, 2018 at 3:40pm
Print Post  
Thanks for getting back. In the future, I will provide the board & core file directory.

Board: Industruino D21G, SAMD, ver 1.0.1
Core: nclude\math.h

I did see the page link prior but am confused on how to implement it. An example would be very helpful for us less seasoned coders... Specifically, please include function() definitions that intellisense will use and be  Smiley
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12163
Location: United Kingdom
Joined: Apr 10th, 2010
Re: VS2017 red line error sqrt()
Reply #3 - Apr 13th, 2018 at 10:38pm
Print Post  
There is a new release that should resolve this automatically but also an easier system to extend if required

Download 1804.12

If you need to redefine any other symbols then please let me know.

The extending arduino intellisense doc has been updated
  
Back to top
IP Logged
 
groz
Junior Member
**
Offline


Posts: 22
Joined: Feb 21st, 2018
Re: VS2017 red line error sqrt()
Reply #4 - Apr 16th, 2018 at 10:56pm
Print Post  
That took care of it.

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