How to workaround IntelliSense Bug In VS 2010 when using a namespace with extern "C"?

EDN Admin

Well-known member
Joined
Aug 7, 2010
Messages
12,794
Location
In the Machine
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed Here is a snippet of my problem:
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas; color:blue namespace<span style="font-size:9.5pt; font-family:Consolas
<span style="color:#010001 MyNameSpace
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas {
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas <span>
<span style="color:blue extern <span style="color:#A31515 "C"
<span style="color:blue void <span style="color:#010001 MyFunc()
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas <span>
{
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas <span>
}
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas }
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas; color:blue void<span style="font-size:9.5pt; font-family:Consolas
<span style="color:#010001 main()
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas {
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas <span>
<span style="color:#010001 MyNameSpace::<span style="color:#010001 MyFunc();
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas }
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas
<p dir="LTR" style="margin-bottom:0cm; margin-bottom:.0001pt; text-align:left; line-height:normal; text-autospace:none; direction:ltr; unicode-bidi:embed
<span style="font-size:9.5pt; font-family:Consolas
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed If I start to write "<span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 MyNameSpace<span style="font-size:9.5pt; line-height:115%; font-family:Consolas ::<span style="color:#010001 M"
inside the main function – <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001
MyFunc will not be suggested by IntelliSense auto complete.
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 The reason is the
<span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:blue extern<span style="font-size:9.5pt; line-height:115%; font-family:Consolas
<span style="color:#A31515 "C" <span style="color:#010001 – but it is needed in my case – to backward support my DLL.
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 I wasnt able to find any workaround.
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 Removing the
<span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:blue extern<span style="font-size:9.5pt; line-height:115%; font-family:Consolas
<span style="color:#A31515 "C" <span style="color:#010001 or the namespace is not an option – the best solution will be a fix to IntelliSense, but I am not sure where to open a bug for Microsoft and when (if ever) they will fix it.
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 Is there a workaround?
<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed <span style="font-size:9.5pt; line-height:115%; font-family:Consolas; color:#010001 Any idea how to get Microsoft to fix this bug in IntelliSense?<br/>

<p dir="LTR" style="text-align:left; direction:ltr; unicode-bidi:embed Thanks.

View the full article
 
Back
Top