Live data from Hacker News

I found a bug in the .NET framework and fixed it by hand-altering the DLL

blog.nullspace.io

81–90 of 124 posts

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#81
post #52
post #34

Earlier quoted context omitted.

Apply some common sense, you think they let MS employees just commit to any codebase they like? And this is leaving aside all the annoying steps of locating their repository, figuring out how to build it, testing, finding out the right person to send the patch to, going through code review.

How is that any different than a central maintainer of Linux accepting patches and reviewing them before they go in? The only difference is that you can see the source and test on your own machine first. MS employees don't have to commit to any codebase they like, but they should be able to obtain the actual source, so that "with enough eyes, all bugs are shallow".

Actually anyone can obtain the source, it's publicly available.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#82
post #7

The real news here is that this is considered special. In most other languages, they'd have forked the source, fixed it, recompiled it for their own uses and submitted a pull request or patch. I'm a big .NET fan, but the fact that we have to jump through such hoops to find and fix a bug, and then still have near certainty that we're going to have to reapply the patch for many updates to come, well, that's just a bit…

I know what you mean, I like .NET too but there is a lot about working with it that feels very outdated these days.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#83
post #15

Earlier quoted context omitted.

Aren't you allowed to send a git (err tfs) pull request there at least within the company?

I've read several places that even Microsoft is not standardized on a source control management, some use tfs, some svn, some git, etc.

Don't think of MS as a single monolith. They're a hundred businesses of various sizes that just happen to share the same HR department.

> use tfs, some svn, some git, etc you can go onto MS's job board and find Rails, iOS, and Node positions. :-D

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#84

Sidebar: I haven't done deep C# in several years, since moving to F#. This code is getting to look butt-ugly. It is not a good thing if it continues like this. We already have C++. Don't need another one.

I do both C# and F#. But, at this point I think in ML no matter what which language I'm using. That said, though I'm delighted by F#, there are things that I really miss about C#: * Haskell's type classes are awesome, and neither F# nor C# have them. But, you can realize them with a really simple pattern in C# whereas in F# you have to resort to reflection or generic hacks[1] (but inline functions usually make such h…

"Of course, this begs the question that OO is better than functional. Having done both for a long time, I'm convinced that it is the case (though I do think learning functional programming is the fastest path to getting good at OO). Lamentably, I can't yet defend this point too vigorously because I've only just discovered the joy or Smalltalk."

Shoot me an email. Would love to chat some time. I've been doing OO for 20+ years and have become a big FP fan in the last 5.

I might would go OOP in a large commercial setting, but for small team startup-type work, pulling in all of that wiring and structure for delivering an MVP just looks crazy to me. Even for large greenfield projects, it makes more sense to me to start in the REPL, code the minimum amount necessary, and then "grow" your class structure as you start needing all that OOP goodness.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#86
post #75
post #25

Earlier quoted context omitted.

I've very rarely heard of shops running forked, re-compiled runtimes for languages like python or ruby. Normally if you find a bug in the core you might try to monkeypatch but many times that won't work so you have to suck it up and just work around it.

There's actually a bunch of shops running forked and recompiled runtimes for languages like python and ruby. I happen to work for a company who maintained such a fork (Ruby Enterprise Edition, by Phusion), and we weren't the only ones who had forks. Most famous were the MBARI patches, made by a guy who worked at MBARI and needed those for running ruby in a submarine or something :P The patches were actually very impr…

OK, but my point still stands since the vast majority of companies are not maintaining their own forks. In the rare situation where they need something special they'll rely on someone upstream, like your company, to fork it for them. Most companies that run into a bug in the core runtime will just workaround it.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#87

The fact that you can even do this without setting off a ton of alarmbells about failed checksums is what really scares me.

You can produce and consume signed libraries in .NET very easily. In practice it's becoming less common as .NET becomes more open.

As an aside, OP says he works with Bart De Smet and they're messing with expression trees. I bet that this is work related to Cortana and the expression trees are used for compiling standing Rx (Reactive Extensions) queries which Cortana uses extensively on the phone and in the cloud.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#88
post #74

Earlier quoted context omitted.

Hah. Or Tomas. Not sure. The S.L.E.Interpreter is after my time :)

It might be my fault... The DLR interpreter got rolled into .NET native so that ETs could be interpreted (hence the weird EETypeRva:0x01588388 error). I actually did the initial set of work on that having had experience w/ the DLR interpreter and handed that off to the .NET team. I probably did the expression quoter but I don't quite remember :( One thing I'll point out though, it's a Field on StrongBox for correctne…

Aha! Good call on the ByRef. Totally had forgot about that. Yeah, that was very important for correctness.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#89
post #34

Earlier quoted context omitted.

i'm glad someone who works at the company like you was able to enlighten us as to microsoft's internal practices oh wait

Apply some common sense, you think they let MS employees just commit to any codebase they like? And this is leaving aside all the annoying steps of locating their repository, figuring out how to build it, testing, finding out the right person to send the patch to, going through code review.

"you think they let MS employees just commit to any codebase they like?"

That's pretty much how it works at Google. The code owners have to review and approve your change (and can reject it), but it's common (even encouraged) to commit a bugfix or new feature to someone else's project.

Re: I found a bug in the .NET framework and fixed it by hand-altering the DLL

#90
post #9
post #7

The real news here is that this is considered special. In most other languages, they'd have forked the source, fixed it, recompiled it for their own uses and submitted a pull request or patch. I'm a big .NET fan, but the fact that we have to jump through such hoops to find and fix a bug, and then still have near certainty that we're going to have to reapply the patch for many updates to come, well, that's just a bit…

---Author here--- I should disclose that I actually work for Microsoft, and still chose the hard way. Fuck the police!

Off topic, but I really enjoyed your post about writing a Python lexer/parser in Haskell. Thanks for that!

http://blog.nullspace.io/obvious-python-parser.html

Post reply on HN