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 Ambiguous symbol byte (Read 3898 times)
K S
Junior Member
**
Offline


Posts: 10
Joined: Dec 14th, 2015
Ambiguous symbol byte
May 29th, 2016 at 2:20pm
Print Post  
My static analysis tool is warning me about multiple definitions of the "byte" type.

The generated file .${PROJECT}.vsarduino.h contains a type definition for "byte"
typedef unsigned char byte;

Then it includes the main arduino header file
#include <arduino.h>

That file makes a different definition for "byte":
typedef uint8_t byte;

The "uint8_t" type is defined in ...\arduino-1.6.6\hardware\tools\avr\avr\include\stdint.h as

typedef unsigned int uint8_t __attribute__((__mode__(__QI__)));

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


Posts: 12187
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Ambiguous symbol byte
Reply #1 - May 29th, 2016 at 2:33pm
Print Post  
Hi,

The one in vs arduino needs to be removed. 

Visual micro started adding it some time ago because intellisense wasn't picking it up.

I will remove it for the next release.

You can remove yourself if you want to. The intellisense.code.h is simply a kick for the intellisense system and doesn't affect compile. In recent months Visual Micro has extended it's auto discovery of toolchain locations so gradually the intellisense.code.h becomes redundant. 

[visual micro location]\Micro Platforms\arduino16x\hardware\avr\intellisense.code.h

You can find the "visual micro location in tools>options>visual micro>system>assembly"

We will shortly move to using the new clang capabilities of visual studio which will entirely remove the need for the intellisense.code.h

Click the Rescan button on the explorer if you edit the .h or restart the ide.
« Last Edit: May 29th, 2016 at 2:34pm by Tim@Visual Micro »  
Back to top
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint