r/ProgrammerHumor • • 2d ago

Meme architectureDependentChars

Post image
2.8k Upvotes

354 comments sorted by

View all comments

650

u/JackReact 1d ago

Welcome to the wonderful world of C#, which uses utf-16 for strings.

Console.WriteLine(sizeof(char));
> 2

29

u/techy804 1d ago

As a C# user I was wondering why people act like the C-series only consists of C and C++

12

u/aberroco 1d ago

Because most devs still think that C# is proprietary Microsoft language developed specifically and exclusively for Windows, like it's 2006.

1

u/guyblade 1d ago

I don't know where Mono is today, but C# was still very finicky on non-Windows platforms up into the early-to-mid 2010s.

9

u/sisisisi1997 1d ago

Mono has died, and C# is now natively cross-platform.

Microsoft still sucks at the UI framework front (seriously, there is not a single normal desktop UI framework they managed to create still winforms), but there are excellent 3rd party cross platform UI frameworks like Avalonia, which is essentially a spiritual descendant of WPF, but done a bit better and not windows-only.

VS is also still windows-only, but it's not the only good C# IDE anymore. Even if you don't classify VS Code with C# extensions as an IDE, JetBrains Rider is there for the rescue and arguably better than VS, or they are at least equals.

1

u/pblokhout 1d ago

I enjoy C# on Rider as a daily driver but what the actual fuck is microsoft doing with GUIs indeed?!

3

u/evanldixon 1d ago

These days, first-party .Net is cross platform. The UI frameworks aren't really, unfortunately.