Browse by Tags
All Tags »
DesignByContract (
RSS)
It’s been a busy couple of months! The SELA Developer Practice, SELA’s annual conference for .NET developers, has taken place on March 13-16 in SELA’s offices and the Crowne Plaza hotel in Tel-Aviv. Dear conference attendees: thanks for being there! I personally appreciate your coming to the sessions, mingling with the speakers, telling us your pain points and participating in active discussions. I hope to see you again next year, and if there’s any feedback you have or tips for us to improve the...
Code Contracts are a mechanism coming out of incubation at Microsoft Research for expressing design intent when implementing an API. The idea is to specify assertions that are verified at runtime to ensure that callers provide proper information to your methods. There are ways to specify contractual information on methods – Contract.Requires and Contract.Ensures , and there are also interface contracts (for any implementation of the interface) and object invariants. Finally, there are automatic tools...
In part 1 we looked at CLR side-by-side support for multiple versions, at interoperability-related features and at DLR-related changes in the CLR. There have been various complaints about performance aspects of the CLR that are sometimes neglected - the installation experience, the startup experience and the GC latency experience for high-performance applications. This feedback will be addressed in CLR 4.0: The .NET installer can be branded and customized, and begins with a 200K bootstrapper. Downloading...
One of the first things I do as part of the .NET Performance course is demonstrating some of the ways we have for measuring the performance of individual applications and of the system as a whole. As part of that quest, we encounter tools that require no ad-hoc participation on our part: Fire them up, give them an executable or a process to do their magic, and analyze the results. Some other tools need more love and care on our part to produce anything remotely useful. A profiler can tell you that...
A Design-By-Contract programming paradigm specifies that classes and methods in the language specify pre- and post-conditions which must hold when entering and leaving the class code. For example, the following Eiffel snippet is a counter class which can be incremented, decremented and reset to 0. Note the ensure , require and invariant clauses sprinkled across the definition: class TINY COUNTER feature item: INT feature increment is do item = item + 1 ensure item = old item + 1 end decrement is...