Skip navigation.

Syndicate

Syndicate content

User login

c#

Things I do after programming in a language for too long

I’ve been going back and forth between C++ and C# alot in my current job. When switching between languages, certain elements bleed together leading to the same mistakes over and over. Some of mine:

C# to C++

  • Putting array braces ([]) on the type instead of the variable name (eg, int[] whatever in C# vs int whatever[] in C++)
  • Writing string literals with naked double quote (ala ") instead of the L prefix to denote Unicode
  • Naming methods with PascalCase instead of the camelCase in our C++ convention
  • Throwing exceptions with new, which particularly sucks since it won’t yield a compile error
Syndicate content