CoreRT – A .NET Runtime for AOT
mattwarren.org
mattwarren.org
https://github.com/dotnet/corert/blob/master/src/Runtime.Bas...
and type-casting:
https://github.com/dotnet/corert/blob/master/src/Runtime.Bas...
Turns out that even more components could be written in C#, but the ROI just isn't worth it, see https://github.com/dotnet/coreclr/issues/17576 for an interesting discussion
https://en.wikipedia.org/wiki/Cosmos_(operating_system)
I also usually bring up Oberon and House given safe languages can handle low-level stuff if you turn off safety plus hide it in some module.
I know .NET quite well, I've used it a lot in enterprise, but I just never find it to be my go-to language. It just feels like work, it doesn't feel fun.
I usually end up with nodejs, nim, or even pascal.
This is subjective thought. C# isn't empirically the most efficient language, but for me, I can really focus on the features/requirements and not the tooling.
Go has been awesome as well. My second home.
I'm going to visit Rust next.
So with that in mind, C# with the right IDE (VS + Resharper, or Rider) is faster to write than anything else I've ever used and makes working on projects incredibly nice. Add in the solid standard libraries and the ability to make everything from websites to desktop apps in the same language and it's the best choice around, for both work and play.
If I need a quick GUI, either Qt or C# will cut it. It mostly depends on the third party libraries.
Also don't have to deal with Winforms.
That being said, I use C# at work, and recently started using F# for side projects (which does actually feel fun to write (for now anyway)).
If you can't use F# at work I really like this https://github.com/louthy/language-ext for a more functional flavor of C#.
That said, I would love to start using F# for everything even though I have never used it for anything aside from brief experimenting :)
I want to take F# for a spin, but I haven't broken the bond yet.
Javascript is like the complete opposite of this, for languages I have to deal with. Just painful and slow and error-prone.
Languages without good GUI frameworks or nice IDEs usually don't cut it for me, when I am supposed to be having fun.
Been doing that for years. I run Linux at home and use Windows at work.
I am much less of a fan of Xamarin, tried it, too clunky (for instance the default settings for the android emulator do not work out of the box) and slow.
And it’s a matter of taste. I don’t like dynamic languages as I’d rather have the compiler check my syntax for me rather than having to write a test, and static typing enables great refactorings. But other people will have other priorities.
https://blogs.msdn.microsoft.com/webdev/2018/04/17/library-m...
I made a freely movable and resizeable frame-less image viewer in C#/winforms for times when I want to view lots of pictures at once. (;
Can you elaborate on that? If you keep the work off your main thread, and don't create an enormous amount of controls, noticeable performance should not occur.
When you have long lists, or any large content inside scrolling panels, you’re technically creating an enormous amount of controls, and the performance degrades.
Possible to workaround, e.g. lists have ListView.VirtualMode property + associated events, for long web page-like content you can use an embedded browser, etc., but these workaround tend to be quite tricky to implement and debug. WPF too has a couple of issues with UI virtualization, but by comparison, it’s much simpler in WPF than in WinForms.
I tend to give every custom "singleton" window its own thread -you don't have to limit yourself to one main thread and I dislike modal interactions. Performance in that sense was great and taking care to correctly use Invoke/BeginInvoke made hassle free multithreading a breeze.
> and don't create an enormous amount of controls
That's exactly what I did. I created so many controls, the application rendered white boxes with a red strikethrough or outright crashed. WPF does not have that problem and additionally offers virtualization to speed up visual containers containing lots of complex controls/children. Yet WPF is a complex, overengineered mess with a steep learning curve.
It was my first big project to write a desktop application -I used winforms for it and everyone loved it. It was a tiny .exe file. I tried rewriting it in WPF three times but gave up every time...
I'm not sure what to think of the way it compiles to C and has its own garbage-collector.
But once you get going you're really fast at pumping native tools.
There is no easy way that I'm aware of. IIRC, early versions of this included the entire framework, so it's gotten a lot better.
Ah, yeah that makes sense, I'd not thought about it like that.
> IIRC, early versions of this included the entire framework, so it's gotten a lot better
Yeah, they're definitely improving things over time
I don't know if it's technically impossible or just hard to have 'tree-shaking' being done on it, so that you only get the functions/dependencies that are actually called?
See https://gitter.im/dotnet/corert?at=5b1af059178709146f21076f for some techniques to do this
Although I personally don't think it's a good idea to build HTML UI's with C#, which adds overhead + friction.
Also take a look at this project https://github.com/shtik/cli/tree/dev/src/slidey, AFAIK it's the project that inspired the video I embedded in the post