Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

no color in .cu file in VS 2010

I'm developing simple CUDA app. I followed steps given on http://www.ademiller.com/blogs/tech/2010/10/visual-studio-2010-adding-intellisense-support-for-cuda-c/ but still there is no color in .cu file. I mean everything is simply in black color what could be the reason? I'm able to run program.

like image 918
username_4567 Avatar asked Dec 05 '25 13:12

username_4567


1 Answers

add the cu extension

This image says it all. Go to Tools > Options, then select Text Editor in the left column. Then click on File Extension as shown. Type cu under extension, pick Microsoft Visual C++ as the editor, and then hit Add. In my experience, this is all that was necessary to make Visual Studio interpret/color my .cu files with c++ syntax.

Also note that this is similar to what the link you posted suggests. This method is simply a visual description of that. Also note that I didn't really do the extra steps listed on that website either because having shared and device and all colored didn't seem that important.

Hope that helps.

like image 69
user1477622 Avatar answered Dec 08 '25 11:12

user1477622



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!