Bug Vanquisher

8 June 2007

A comparison of CPlusPlusCodeProvider to System.CodeDom

Filed under: C++ — Tanveer Badar @ 6:26 PM

I thought these were deficiencies in CppCodeProvider. Namely,

· It is very difficult to partially specialize a user-defined type.

· Union does not write anything at this point.

· It is not possible to initialize enumerators with values.

· A user defined type does not write anything at this point.

· Pointers to function, member function and member variables are very hard to work with.

· Friends cannot be declared at this point.

· Forward declarations are not possible.

But it turns out, some of these are feature which are really difficult to represent in any code graph for C++. CodeDom has much serious limitations, addressed here. A short listing is.

  • No unary operators like -,+,++,– etc.
  • No readonly for fields in a class/struct.
  • No break/continue in a loop/switch statement.
  • No type cast support in the form of as/is.
  • No while loop.
  • No switch statement.
  • Attributes on set/get of a property.
  • No default indexer in VB.Net.
  • Main always has void return type in C#.
  • No == operator.
  • No internal virtual functions.
  • No way to apply [field:] attributes to an event.

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: