4 ms·
I wonder why it feels like I can't move at the same pace with C++ compared to C#; want to have a file copied to your output dir? Create a post-compile task; wit
by NKCSS 10y ago
I wonder why it feels like I can't move at the same pace with C++ compared to C#; want to have a file copied to your output dir? Create a post-compile task; with C# you can just set a property to 'copy always'. Want to add a reference? Set up which dir's to look for, type names, etc. with C#: add reference, choose your dll/whatever and you're done! And those are just a few. One of the biggest hurdles with C++ is type conversion; I recently wrote a small app; most time was spent writing functions to cast/convert all the 9000 ways to define numbers and strings... It's when you start to appreciate the System.Object model that makes sure everything can be represented as a Unicode string that everything knows how to work with.
- koja86 10y agoYou are comparing apples to oranges here. I also agree that type system in C++ is not perfect and is rarely used in a sensible manner. Yet I would rather look for inspiration in functional statically-typed languages rather than in specialized "multi-paradigm" dynamically-typed ones.
- NKCSS 10y agoI know it's not fair, but because I write identical apps in both languages, it's one that comes to mind frequently and it becomes very apparent how powerful C# is when it comes to Rapid Application Development.
- nicolapede 10y ago> dynamically-typed ones Why you consider C# to be dynamically-typed?
- blakeyrat 10y agoJust as an FYI, C# is more strongly-typed than C++.
- psyc 10y agoOn the flip side: Want to read a file of records into an array of structs?
- loup-vaillant 10y agoEvery machine in the world is Little Endian, and I'm going to specify a file format -- https://en.wikipedia.org/wiki/WAV https://en.wikipedia.org/wiki/WAV -- with C structs and type punning. Seriously, Microsoft? Me, I just static uint32_t load32_le(const uint8_t s[8]) { return (uint32_t)s[0] | ((uint32_t)s[1] << 8) | ((uint32_t)s[2] << 16) | ((uint32_t)s[3] << 24); }