remove all comments from your source code
while browsing the logs from this site I found that a lot of people are looking for a way to strip comments from their respective sources in visual studio.
Well here would be the solution for C/C++ sources at least (in visual studio regular expression dialect).

So just fire up your CTRL+H, search and replace dialog and strip away. Maybe you will find it wise to create a copy of your project beforehand in case I missed something.

(/\*(\n|.)@\*/)|(//.*$)
If you are interested in the visual studio specific dialect of regular expressions please have a look at this msdn reference.
About this entry
You’re currently reading “ remove all comments from your source code ,” an entry on coders
- Author:
- fschaper
- Published:
- 2.19.09 / 5pm
- Category:
- programming, regular expressions, visual studio
- Feedback:


3 Comments
Jump to comment form | comments rss [?] | trackback uri [?]