vote up
0
vote down

Challenge: Robust enumeration over external code

Here is an interesting little problem: public class Program { private static void Main() { foreach (int i in RobustEnumerating(Enumerable.Range(0, 10), FaultyFunc)) { Console.WriteLine(i); } } public static IEnumerable<T>
 
Ayende Rahien
tags: c#
Mar 04 2010 07:35 AM
vote up
0
vote down

Suggestions for a new laptop?

Okay, the previous time I asked this question, I decided that buying a big desktop machine would be preferable, but I am currently traveling and I am pained at the speed of my current laptop. Therefore, I am going to need a new one. I am the happy owner
 
Ayende Rahien
Feb 13 2010 05:34 AM
vote up
0
vote down

Documenting Standards in IE

This post discusses some of the work we’re doing on the IE team to fulfill our commitment to document our support of web standards. A good starting point is Microsoft’s interoperability principles, something we’ve written about here on this blog before,
 
ieblog
Feb 25 2010 04:33 AM
vote up
0
vote down

In which hints become facts: XNA Game Studio 4.0

Today we announced what I've been hinting at this past few weeks: XNA Game Studio 4.0 is coming soon* to a phone near you! Quick summary: New platform Windows Phone 7 Series New features Integrates with Visual Studio 2010 Dynamic audio output Microphone
 
ShawnHargreaves
Mar 10 2010 05:32 AM
vote up
0
vote down

Voicemail security, even stronger than bank security

Microsoft's telephone department takes security very seriously. Your voicemail password must be at least eight digits long. By comparison, the password for my ATM card is only four digits long. Because voicemail is that important, I guess. (Yes, I know
 
oldnewthing
Mar 03 2010 09:01 PM
vote up
0
vote down

Slaying relational dragons

I recently had a fascinating support call, talking about how to optimize a very big model and an access pattern that basically required to have the entire model in memory for performing certain operations. A pleasant surprise was that it wasn’t horrible
 
Ayende Rahien
Feb 22 2010 01:46 PM
vote up
0
vote down

Working with the HTML5 Community

We’re always excited to engage with members of the W3C including the developers of other browsers as well as the broader web development community to help shape the direction of emerging Web standards, particularly HTML5.  This includes
 
ieblog
tags: w3c
Mar 10 2010 06:51 AM
vote up
0
vote down

Advocating the overthrow of the government of the United States by force or subversion

It has been widely reported that South Carolina now requires "subversive groups" to register with the Secretary of State (and pay a $5 filing fee). Curiously, the list of organizations which must register include "an organization subject to
 
oldnewthing
Feb 15 2010 11:48 PM
vote up
0
vote down

It rather involved being on the other side of this airtight hatchway: Dubious escalation

Consider this type of dubious security vulnerability: There is a buffer overflow bug in kernel driver&nbsp;X. To exploit it, call this function with these strange parameters. The exploit works only if you are logged on as administrator, because
 
oldnewthing
tags: other
Feb 16 2010 08:30 PM
vote up
0
vote down

How IE8 Determines Document Mode

This post describes how IE8 determines what Document Mode such as Quirks or Standards Modes to use for rendering websites. This topic is important for site developers and consumers. It’s related to the Compatibility View List that we recently
 
ieblog
Mar 03 2010 01:52 AM
vote up
0
vote down

Tab Isolation

Tab isolation has recently become a more popular topic. This post is a quick survey of what tab isolation is, how it works, and what it provides. What is it? Tab isolation is a way to improve a browser’s reliability by containing the impact of a crash.
 
ieblog
Mar 05 2010 06:36 AM
vote up
0
vote down

Profiler Subscription?

One repeated request for the profiler is to have a personal version (which a price to match). I am not really happy with the idea, for several reasons. One of the major ones is that I have enough variability in the product already, and adding a new
 
Ayende Rahien
tags: uberprof
Feb 24 2010 07:30 AM
vote up
0
vote down

How many servings are there in a single-serve cup? The answer might surprise you

I was in the grocery store, and there was a sign advertising a new product. Delight in a cup Your favorite XYZ Ice Cream Now in convenient single-serve cups. I took a look at the cup. Seemed kind of big for a single serving. I picked one up to read the
 
oldnewthing
Feb 20 2010 02:33 AM
vote up
0
vote down

Food products that are offenses against nature: Bagel-fuls

Wow, it's been a long time since my last rant against food products that are offenses against nature. Today's rant is against Bagel-fuls, a product which Kraft launched in April 2008. Bagel-fuls (note the hyphen and the lowercase "f") are a dense, doughy
 
oldnewthing
Feb 26 2010 01:29 AM
vote up
0
vote down

Why is the fine for a basic traffic infraction in the state of Washington such a random-looking number?

Willy-Peter Schaub was puzzled by a sign reminding drivers that the fine for obstructing an intersection is $101 and wonders what the extra $1 is for. The laws of the State of Washington defer the monetary value of traffic fines to the Infraction Rules
 
oldnewthing
Mar 09 2010 09:45 PM
vote up
0
vote down

Le Chatelier's principle in action: Announcements

As I noted some time ago, one of the most important lessons I learned from Systemantics is Le Chatelier's Principle for complex systems which states, "Every complex system resists its proper functioning." At Microsoft, there are processes galore. For
 
oldnewthing
tags: other
Feb 23 2010 11:41 PM
vote up
0
vote down

TechNet 2.0 – Episode 6 – Wiki

Each of you has likely used one of the world’s most popular Wiki’s known as http://wikipedia.org. The English section of that site has 3.2 million articles and there are many more supported languages. An excerpt from the mission of the site is “to
 
Keith Combs
tags: tn20
Feb 23 2010 09:43 PM
vote up
0
vote down

Rhino Divan DB reboot idea

Divan DB is my pet database. I created it to scratch an itch [Nitpickers: please note this!], to see if I can create Couch DB like system in .NET. You can read all about it in the following series of posts. It stalled for a while, mostly because I run
 
Ayende Rahien
tags: databases
Feb 25 2010 03:45 PM
vote up
0
vote down

The ethics of aggregating other peoples' content

Content theft Most of the recent - what I'll call - "discussions" about content aggregators have revolved around content theft. I'm not going to flip-flop on that topic: when you use someone else's work, you ask first, and if given the okay, you
 
AaronBertrand
Mar 11 2010 06:45 AM
vote up
0
vote down
vote up
0
vote down

Sometimes I have code blinders on

This is a piece of code that I am using in RDB, at some point, it threw a null reference exception: I am ashamed to admit that I started doing some really deep debugging to understand the bug (this happen only under very strange circumstances). When I
 
Ayende Rahien
Mar 05 2010 05:07 PM
vote up
0
vote down

Everyday is Grammer Day

March fourth is not just a pun on march forth, but it's also National Grammar Day, sponsored by the Society for the Promotion of Good Grammar.
 
oldnewthing
Mar 04 2010 10:16 PM
vote up
0
vote down

On the Internet, everybody wants to know if you're a dog

On Slate, Michael Agger expounds on increasing pressure for people to provide pictures of themselves online. I've managed to resist so far. That article also tipped me off to a phenomenon I didn't even know had a name: MySpace angles.
 
oldnewthing
Feb 22 2010 08:57 PM
vote up
0
vote down

Put Missing Kids on your 404 Page - Entirely Client-Side Solution with YQL, jQuery, and MSAjax

I noticed a post over at a blog called "The other side of the moon" where the author suggests that we put pictures and details of missing children on on 404 pages. It's a simple and brilliant idea. Millions of 404s are delivered every day. We
Feb 25 2010 07:56 PM
vote up
1
vote down

Getting code ready for production

I am currently doing the production-ready pass through the Rhino DivanDB code base, and I thought that this change was interesting enough to post about: public void Execute() { while(context.DoWork) { bool foundWork = false;
 
Ayende Rahien
Mar 06 2010 04:24 PM
vote up
0
vote down

Don't forget to double-null-terminate those strings you pass to SHFileOperation

About once every two months for the past six months (I stopped checking further back), somebody reports a problem with the SHFileOperation function. Often, they don't include very much information at all. They just say, "I call the function and it
 
oldnewthing
tags: code
Feb 19 2010 12:36 AM
vote up
0
vote down

Why doesn't double-right-click bring up the Properties dialog?

kip asks why double-right-click isn't a shortcut for Properties. Recall the logical consequences of the way Windows converts single-clicks into double-clicks. The double-click action is an extension of the single-click action. In the case of context
 
oldnewthing
tags: other
Mar 08 2010 08:30 PM
vote up
0
vote down

A decidedly Canadian response to the shambles that was the running portion of the modern pentathlon in Beijing

Living so close to the United States-Canada border means that there's a lot of friendly teasing of the many Canadians in our midst. It's a good thing Canadians as a whole seem to have a pretty good sense of humor about it. (Well, except the Quebecers.
 
oldnewthing
Feb 13 2010 05:34 AM
vote up
0
vote down

Rhino DivanDB – A full coding sample – Embedded

Rhino Divan DB is going to come in at least two forms, embedded, and remote. The following is a full example of starting DivanDB, defining a view, adding some documents and then querying the database. Note that here we want to ensure that we get the most
 
Ayende Rahien
Mar 02 2010 03:41 PM
vote up
0
vote down

New Offers for Visual Studio 2010

Last October, we announced a new packaging lineup and licensing options for Visual Studio 2010 to provide customers with simplified ways to purchase and license Visual Studio.  The new lineup includes three main versions of Visual Studio with
 
Somasegar
Mar 02 2010 02:44 PM
vote up
0
vote down

German language tip: Matratzen = mattresses, Matrosen = sailors

Be careful not to confuse the two. Since we're sharing: During a conversation in German, I talked about seeing Unfall (accident) instead of Abfall (garbage) on the street. To my credit, I immediately corrected my error. To my discredit, the error was
 
oldnewthing
Feb 25 2010 12:48 AM
vote up
0
vote down

My new laptop &ndash; 2010 edition

Well, it arrived two days ago, but I only just finished doing the bare bones installation. My new laptop is a Lenovo Thinkpad W510 (4319-29G, if anyone really cares). I have been a happy Thinkpad user for a long time, so it seems to be a natural choice.
 
Ayende Rahien
Feb 17 2010 09:33 AM
vote up
0
vote down

The fundamental rule of rocket science

The rocket scientist who taught me that most rocket science isn't rocket science also taught me the fundamental rule of rocket science: Pointy end up.
 
oldnewthing
Feb 17 2010 02:17 AM
vote up
0
vote down

Back to Basics: C# 4 method overloading and dynamic types

C# 3.0 introduced the implicit type "var". I've explained var as saying: "I'm too lazy to tell you the type of this variable, so you figure it out, compiler." However, it's more useful than just promoting terseness or laziness: var i
Feb 13 2010 05:02 AM
vote up
0
vote down

We moved your ASP.NET website cheese, in a good way

We've just pushed live an update to the http://www.asp.net site. This is the first of a series of updates to the site we'll be making this year. The home page for the site was getting bogged down with info and was too visually busy. It was too complex
tags: msdn
Mar 11 2010 06:43 AM
vote up
0
vote down

Is Opera 10.5 the Best Browser Ever?

Could this be the fastest, best-looking, and most configurable browser available? Craig reviews the newly-released Opera 10.5. Related posts:Can Opera Ever Become Popular? Opera is one of the fastest and most innovative browsers....What’s New in
 
Craig Buckler
Mar 09 2010 06:11 PM
vote up
0
vote down

Application compatibility layers are there for the customer, not for the program

Some time ago, a customer asked this curious question (paraphrased, as always): Hi, we have a program that was originally designed for Windows XP and Windows Server 2003, but we found that it runs into difficulties on Windows Vista. We've
 
oldnewthing
tags: other
Mar 11 2010 11:20 PM
vote up
0
vote down

The Problem With Opera

Few people have a bad word to say about Opera. But that's possibly because so few people use the browser. Craig pinpoints some of its problems and suggests a number of ways Opera could attract a higher audience. Related posts:Can Opera Ever Become
 
Craig Buckler
Mar 10 2010 03:36 PM
vote up
0
vote down

A Trip Down Memory Lane - Presentations over 10 years old

I've been presenting for a long time. It's great fun, mostly it's stand-up comedy with code and PowerPoint. I also keep everything, always, so earlier today when I was asked by a friend to find some ten year old code, I found a few 10 year old
Mar 09 2010 07:09 AM
vote up
0
vote down

SQL SERVER – Rollback TRUNCATE Command in Transaction

This is very common concept that truncate can not be rolled back. I always hear conversation between developer if truncate can be rolled back or not. If you use TRANSACTIONS in your code, TRUNCATE can be rolled back. If there is no transaction is used
Mar 04 2010 07:37 AM