Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
neonsunset
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
10 ms
·
61.
▲
by
neonsunset
1y ago
> The code generator was just better in C++. I suspect the main reason is .NET JIT compiler doesn’t have time for expensive optimisations. Yeah, there are heavy constraints on how many phases there are and how much work each phase can do
62.
▲
by
neonsunset
1y ago
> LTO On some workloads (think calls not possible to inline within a hot loop), I found LTO to be a requirement for C code to match C# performance, not the other way around. We've come a long way! (if you ask if there are any ca
63.
▲
by
neonsunset
1y ago
Funnily enough, the combination of .NET and PL/SQL already exists today, albeit in a literal sense: https://pldotnet.brickabode.com/cms/uploads/pldotnet_v0_99_b...
64.
▲
by
neonsunset
1y ago
Only if you go out of your way to author a method with (Guid someGuid = default) argument. I've never seen it happen with Guids, if someone gives you default(Guid) - they did it on purpose, it's no different to explicitly setting
65.
▲
by
neonsunset
1y ago
> The main motivation to use unsafe is p/invoke. This is opposite to the way unsafe (either syntax or known unsafe APIs) is used today.
66.
▲
by
neonsunset
1y ago
No, that's just the memory model of CLI and the choice made by C#. By default, it emits localsinit flag for methods which indicates that all local variables must be zero-initialized first. On top of that, you can't really access u
67.
▲
by
neonsunset
1y ago
The competition is too strong. At a team or organization level, where neither uses Flutter, why would you use Dart when C# and Kotlin exist? Both have better performance, better UX for doing common application tasks and vastly bigger ecosys
68.
▲
by
neonsunset
1y ago
> C# strings and arrays were also almost a carbon copy of Java You'd be surprised but .NET and Java strings have a lot of differences. In Java, String is a class which wraps byte[], in .NET - string is a "FieldSeq" object
69.
▲
by
neonsunset
1y ago
It doesn't usually happen (on Windows but realistically elsewhere too) unless you publish an application as self-contained. To be specific, .NET install is version-aware and would manage those side by side, unless the destination folde
70.
▲
by
neonsunset
1y ago
I was going to complain how Avalonia still has issues with large binaries even with NAOT but I just tested it on https://github.com/sourcegit-scm/sourcegit on Windows, and the resulting size of the folder without symbo
71.
▲
by
neonsunset
1y ago
Wait what? AvaloniaUI is not WPF, neither is WinUI3 which is new and maybe something you'd consider if you only target Windows (I presume it's better than using it through Uno, otherwise you'd probably choose Avalonia to supp
72.
▲
by
neonsunset
1y ago
For JIT binaries it’s best to apply /p:PublishTrimmed=true which (sometimes massively) reduces their size. Applications written in AvaloniaUI or, nowadays, WinUI 3 can be compiled with NativeAOT which reduces the size and memory usage
73.
▲
by
neonsunset
1y ago
Using gRPC in Go is really inconvenient in comparison to some other languages.
74.
▲
by
neonsunset
1y ago
To be fair I think Rust has very healthy selection of options for both, with Serde and Reqwest/Hyper being de-facto standard. Rust has other challenges it needs to overcome but this isn't one. I'd put Go behind both C#/F
75.
▲
by
neonsunset
1y ago
Kind of? :) https://github.com/royalapplications/beyondnet
76.
▲
by
neonsunset
1y ago
If you already have C# and mobile app dev experience, the most productive choice will probably be using AvaloniaUI (or perhaps Uno Platform?).
77.
▲
by
neonsunset
1y ago
This has nothing to do with null analysis. It simply lets you replace an assignment behind an if with an inline expression.
78.
▲
by
neonsunset
1y ago
AVX512 is not just about width. It ships with a lot of very useful instructions available for narrower vectors with AVX512VL. It also improves throughput per instruction. You're not hand-writing intrinsified code usually yet compilers,
79.
▲
by
neonsunset
1y ago
AVX2 vs AVX512 in this case may be somewhat misleading. In .NET, even if you use 256bit-wide vectors, it will still take advantage of AVX512VL whenever available to fuse chained operations into masked, vpternlogd's, etc.[0] (plus stand
80.
▲
by
neonsunset
1y ago
> Related features like TS Partial<> are missing, and that means that expressing concepts like POCOs that are in the process of being initialized but aren't yet is a real pain; most code that does that in the wild is not types
81.
▲
by
neonsunset
1y ago
Yes. It will complain if you assign one to something that isn't T?. For the best experience you may want to add `<WarningsAsErrors>nullable</WarningsAsErrors>` to .csproj file.
82.
▲
by
neonsunset
1y ago
If it's any consolation, Sep will happily use AVX-512 whenever available, without having to opt into that explicitly, including the server parts, as it will most likely run under a JIT runtime (although it's NAOT-compatible). So y
83.
▲
by
neonsunset
1y ago
> even feel slightly bad a about using generics. Hey, struct generics are the go-to tool for zero-cost abstractions in .NET! No need to feel bad about them :)
84.
▲
by
neonsunset
1y ago
Last time I checked the base web template (the one which uses minimal API) was around 10-12 MB (which is pretty good for something with a full web server, GC, async runtime and more). I’ll message you in private to see what’s going on. But
85.
▲
by
neonsunset
1y ago
Omnisharp is what the base C# extension used previously. It has been replaced by Roslyn LS (although can be switched to back still). You are talking about something you have no up-to-date knowledge of.
86.
▲
by
neonsunset
1y ago
C# language server, being Roslyn Language Server, is plugin agnostic, it's MIT licensed and is essentially a part of the compiler: https://github.com/dotnet/roslyn/tree/main/src/LanguageServe...
87.
▲
by
neonsunset
1y ago
> I think we lost something with static linking when going from C to Dotnet. (And I guess Java.) Many C (and C++, especially "header only") libraries when statically linked are pretty good at filtering out unused code. This is
88.
▲
by
neonsunset
1y ago
> Thanks. In my experience the CoreWCF team are fairly active, but I didn't want to bother them until I can understand if this is a problem with CoreWCF. It may not be necessarily a problem but, ideally, the less users have to care
89.
▲
by
neonsunset
1y ago
if anything, in C#, you can import the entire class as `using static MyFunctions;` and make such functions top-level. Well, usually you write an extension method instead since most functions act on some form of data but you get the idea. (c
90.
▲
by
neonsunset
1y ago
If the author reads HN comments - findings like these are probably better to be submitted at https://github.com/CoreWCF/CoreWCF instead (although I have no idea how active CoreWCF owners are w.r.t this)
More ›