次の方法で共有


Fabulous Adventures In Coding

Eric Lippert's Erstwhile Blog

Never Say Never, Part One

Can you find a lambda expression that can be implicitly converted to Func<T> for any possible...

Author: Eric Lippert Date: 02/21/2011

Looking inside a double

Occasionally when I'm debugging the compiler or responding to a user question I'll need to quickly...

Author: Eric Lippert Date: 02/17/2011

What would Feynman do?

No one I know at Microsoft asks those godawful "lateral-thinking puzzle" interview questions...

Author: Eric Lippert Date: 02/14/2011

Optional arguments on both ends

Before we get into today's topic, a quick update on my posting from last year about Roslyn jobs. We...

Author: Eric Lippert Date: 02/10/2011

"Can a property or method really be marked as both abstract and override?" one of my coworkers just...

Author: Eric Lippert Date: 02/07/2011

Curiouser and curiouser

Here's a pattern you see all the time in C#: class Frob : IComparable<Frob> At first glance...

Author: Eric Lippert Date: 02/03/2011

Spot the defect: Bad comparisons, part four

One more easy one. I want to "sort" a list into a random, shuffled order. I can do that by simply...

Author: Eric Lippert Date: 01/31/2011

Spot the defect: Bad comparisons, part three

Did you notice how last time my length comparison on strings was unnecessarily verbose? I could have...

Author: Eric Lippert Date: 01/27/2011

Spot the defect: Bad comparisons, part two

Suppose I want to sort a bunch of strings into order first by length, and then, once they are sorted...

Author: Eric Lippert Date: 01/24/2011

Spot the defect: Bad comparisons, part one

The mutable List<T> class provides an in-place sort method which can take a comparison...

Author: Eric Lippert Date: 01/20/2011

Not as easy as it looks, Part Two

Holy goodness, did you guys ever find a lot of additional ways in which an "eliminate variable"...

Author: Eric Lippert Date: 01/17/2011

Not as easy as it looks

My colleague Kevin works on (among many other things) the refactoring engine in the C# IDE. He and I...

Author: Eric Lippert Date: 01/13/2011

Enormous Explosions

Welcome to 2011 everyone; I hope you all had as restful a time as I did over the winter break....

Author: Eric Lippert Date: 01/10/2011

Why are anonymous types generic?

Suppose you use an anonymous type in C#: var x = new { A = "hello", B = 123.456 }; Ever taken a look...

Author: Eric Lippert Date: 12/20/2010

All your base do not belong to you

People sometimes ask me why you can’t do this in C#: class GrandBase{ public virtual void M()...

Author: Eric Lippert Date: 12/13/2010

Asynchrony in C# 5, Part Seven: Exceptions

Resuming where we left off (ha ha ha!) after that brief interruption: exception handling in...

Author: Eric Lippert Date: 11/19/2010

Asynchrony in C# 5 Part Six: Whither async?

A number of people have asked me what motivates the design decision to require any method that...

Author: Eric Lippert Date: 11/11/2010

Asynchrony in C# 5 Part Five: Too many tasks

Suppose a city has a whole bunch of bank branches, each of which has a whole bunch of tellers and...

Author: Eric Lippert Date: 11/08/2010

Asynchrony in C# 5.0 part Four: It's not magic

Today I want to talk about asynchrony that does not involve any multithreading whatsoever. People...

Author: Eric Lippert Date: 11/04/2010

Asynchrony in C# 5, Part Three: Composition

I was walking to my bus the other morning at about 6:45 AM. Just as I was about to turn onto 45th...

Author: Eric Lippert Date: 11/01/2010

Asynchronous Programming in C# 5.0 part two: Whence await?

I want to start by being absolutely positively clear about two things, because our usability...

Author: Eric Lippert Date: 10/29/2010

Asynchrony in C# 5, Part One

The designers of C# 2.0 realized that writing iterator logic was painful. So they added iterator...

Author: Eric Lippert Date: 10/28/2010

Continuation Passing Style Revisited Part Five: CPS and Asynchrony

Today is when things are going to get really long and confusing. But we'll make it through somehow....

Author: Eric Lippert Date: 10/27/2010

Continuation Passing Style Revisited Part Three: Musings about coroutines

Last time I sketched briefly how one might implement interesting control flows like try-catch using...

Author: Eric Lippert Date: 10/25/2010

Continuation Passing Style Revisited Part Two: Handwaving about control flow

Last time on Fabulous Adventures: “But we can construct arbitrarily complex control flows by...

Author: Eric Lippert Date: 10/22/2010

Eric Lippert, from Microsoft?

No technology today, just an amusing story from a couple summers ago. Leah and I rent out a room in...

Author: Eric Lippert Date: 10/18/2010

Debunking another myth about value types

Here's another myth about value types that I sometimes hear: "Obviously, using the new operator on a...

Author: Eric Lippert Date: 10/11/2010

No backtracking, Part One

A number of the articles I’ve published over the years involve “backtracking”...

Author: Eric Lippert Date: 10/04/2010

The Truth About Value Types

As you know if you've read this blog for a while, I'm disturbed by the myth that "value types go on...

Author: Eric Lippert Date: 09/30/2010

Ambiguous Optional Parentheses, Part Three

(This is part three of a three-part series on C# language design issues involving elided...

Author: Eric Lippert Date: 09/27/2010

Is is as or is as is?

Today a question about the is and as operators: is the is operator implemented as a syntactic sugar...

Author: Eric Lippert Date: 09/16/2010

Teach Yourself C# In... how long?

Earlier this year I was the technical editor of "Teach Yourself Visual C# 2010 in 24 Hours" by Scott...

Author: Eric Lippert Date: 09/13/2010

Eric's solution for old school tree dumping

sealed class Dumper{ private StringBuilder sb; static public string Dump(Node root) { var dumper =...

Author: Eric Lippert Date: 09/09/2010

Old school tree display

I'm back from my various travels, refreshed and ready for more fabulous adventures in coding. A...

Author: Eric Lippert Date: 09/09/2010

Graph Colouring, Part Five

I said last time that I was interested in finding colourings for graphs that have lots of fully...

Author: Eric Lippert Date: 07/29/2010

Graph Colouring, Part Four

Let's give it a try. Can we colour South America with only four colours? Let's start by stating what...

Author: Eric Lippert Date: 07/26/2010

Graph Colouring with Simple Backtracking, Part Three

OK, we've got our basic data structures in place. Graph colouring is a very well-studied problem....

Author: Eric Lippert Date: 07/22/2010

Graph Colouring With Simple Backtracking, Part Two

Before I begin a quick note: congratulations and best wishes to David Johnson, currently the...

Author: Eric Lippert Date: 07/15/2010

Graph Colouring With Simple Backtracking, Part One

As regular readers know, I'm interested in learning how to change my C# programming style to...

Author: Eric Lippert Date: 07/12/2010

Spoiler Alert

The remaining video of the talk with Neal Gafter and me at NDC is up on the streaming content server...

Author: Eric Lippert Date: 07/08/2010

<Previous Next>