News for hackers. Stuff that matters.
Re:It’s strange what people put up with in C# by goto11 on Saturday August 15, 2020 @06:57AM (#24167954)
The compiler does warn when you discard a value, but I assume a C# notebook is something like Jupyter? It is probably a special case in that environment.

There is Comparer.Create convenience method which creates an IComparer instance from a lambda. But yeah it is a workaround.

Re:It’s strange what people put up with in C# by np_tedious on Saturday August 15, 2020 @07:15AM (#24168031)
Sounds fine to me. Unused valuable will get you some squiggle warnings in the editor, but not in a notebook.

As far as "language gotcha" articles go this is pretty weak IMO

Re:It’s strange what people put up with in C# by dcanelhas on Saturday August 15, 2020 @07:19AM (#24168056)
The semicolon at the end of a statement is possibly matlab-inspired.
Re:It’s strange what people put up with in C# by siwatanejo on Sunday August 16, 2020 @01:36AM (#24175480)
> The compiler does warn when you discard a value

The C# compiler doesn't; the F# compiler does.

Re:It’s strange what people put up with in C# by McNerdius on Sunday August 16, 2020 @04:27AM (#24176186)
While not a warning by default, it does inform (IDE0058) in the editor. placing dotnet_diagnostic.IDE0058.severity = warning in your .editorconfig will promote it.
Re:It’s strange what people put up with in C# by merb on Sunday August 16, 2020 @01:49PM (#24179687)
and with warnings as error its also forbidden.