• Cyrus' Blather

    Defining Equals on an interface

    • 17 Comments
    I was wondering today if ICollection should declare an Equals method on it and state what the semantics of it would be. This came around because I currently have 3 implementations of ICollection: ArrayCollection (an ICollection backed by an array...
  • Cyrus' Blather

    Internal and External Iterators

    • 10 Comments
    I've updated ICollection<A> in the following manner: public interface ICollection <A> : IEnumerable <A> { /// Previous stuff /// <summary> /// Iterates over the members in this collection applying 'p' to each...
  • Cyrus' Blather

    Theo schools me on OO over functional programming

    • 3 Comments
    I just got back from dinner with another friend ( The-oy ) who schooled me on the OO mistakes I made in the lazy loader . The problem stemmed from the fact that I was trying to conver the following functional type into an OO one. # type 'a optional...
  • Cyrus' Blather

    Is it possible to get java's '==' semantics in C#?

    • 16 Comments
    Prelude: Here's what my current array based implementation of ICollection looks like. It builds upon a lot of suggestions as to the tradeoffs of perf vs. memory and uses delegates to place control in the person who creates the collection for how certain...
  • Cyrus' Blather

    ATHF

    • 8 Comments
    Sorry for the poor quality (formatting wise) of the post last night. I was enjoying writing it but then Aqua Team Hunger Force came on on Adult Swim and totally sucked me in. I didn't even both to see what it looked like after I hit “post”...
  • Cyrus' Blather

    Untying unnatural bonds

    • 2 Comments
    Didn't get to work on any of the Unit-testing/Collections work today. Instead I worked on redesigning a design pattern (which i have no name for) into something reasonable. It's hard to describe but it involves several objects (lets say 3 for example...
  • Cyrus' Blather

    Issues posting from my mac

    • 3 Comments
    Kinda frustrated trying to blog from home. Firefox tends to get caught in infinite loops and Safari crashes. Luckily safari has a good system where crashes get sent back to apple. So i am confident that these will get fixed. However, i'm not sure how...
  • Cyrus' Blather

    Jay mentioned me

    • 3 Comments
    Jay linked to me from his blog and had some nice things to say. Unfortunately, I'm new to this blogging stuff and already I'm running into issues balancing the needs of work versus the desire to communicate and discuss. Note: this is a problem even...
  • Cyrus' Blather

    Mike chews me out for including optional operations on an interface

    • 17 Comments
    Mike, another dev on the C# took issue (aka slapped me around) with the way my current interface is being built. He doesn't approve of an Add method that can possibly fail. He thinks that if the interface declares it then it's something that should be...
  • Cyrus' Blather

    Where extensible formatting breaks down

    • 10 Comments
    Imagine the following bit of code: public void ImFeelingStandardToday( int i, int j, int k) { } public void ImFeelingWhimsicalToday ( int i, int j, int l, int k ) { } The first is the method as formatted by the standard...
  • Cyrus' Blather

    Extensible formatting model

    • 2 Comments
    One of the issues with our formatting engine is that it isn't really extensible. This is because we've done the following: We've gone through and marked all the places where you have a formatting choice and we've defined a (unmodifiable) set of...
  • Cyrus' Blather

    Formatting intro

    • 9 Comments
    Anson and i were discussing formatting last night (at around 1 am). He'd received some feedback from some customers about the new formatting engine Kevin has written for Whidbey. The issue that the feature (like many others added in whidbey) tends to...
  • Cyrus' Blather

    First stab at the basic ICollection interface done.

    • 7 Comments
    Ended up with the following for my ICollection interface: namespace Testing.Collections { public interface ICollection <A> { /// <summary> /// Attempts to add an element into this collection /// </summary> ...
  • Cyrus' Blather

    New language innovation from MS research

    • 3 Comments
    Anson and I chatted last night about the very interesting work done my MS research to advance langauge theory and incorporate recent innovations into our process of designing software. These include the ASML project and Polyphonic C# (most likely iwth...
  • Cyrus' Blather

    A fun algorithmic problem

    • 4 Comments
    Gunnar posted a very interesting problem . I gave it two mental stabs before running into walls. So I'm going to break out a good pad of paper and see if I can get it.
  • Cyrus' Blather

    What can/should Pre/Post conditions do?

    • 15 Comments
    In the last post i dicussed the issue of interface invariants. I'm currently enforcing interface invariants by writing them up in code and then running the concrete implementations of that interface against those tests. However, that seems somewhat clunky...
  • Cyrus' Blather

    Should an interface declare invariants that it can't enforce

    • 10 Comments
    I was thinking about the clear method on my ICollection interface. i.e: /// <summary> /// Removes all the elements contained in this collection. /// </summary> void Clear(); Now, it's interesting that that method takes no...
  • Cyrus' Blather

    New core delgate added

    • 1 Comments
    Just added the following delgate: delegate bool Authenticator <A>(A a1, A a2); It's purpose is to take two obejcts of type A and return if they are equal or not. Of course, this is equivalent to: Function <A, Function <A, bool >>...
  • Cyrus' Blather

    Object oriented programming and binary functions

    • 6 Comments
    Ran into an interesting problem while trying to implement the latest function on my ICollection interface: /// <summary> /// /// </summary> /// <param name= "element" ></param> /// <returns></returns>...
  • Cyrus' Blather

    Writing the simplest code (Part2)

    • 3 Comments
    Turns out there was an even simpler way to write a concrete implementation of ICollection: namespace Testing.Collections { public class EmptyCollection <A> : ICollection <A> { public EmptyCollection () { } #region...
  • Cyrus' Blather

    Collections and threadsafety (with some perf implications)

    • 5 Comments
    I've already made the design decision that my collections will not be inherently threadsafe. If you want to use them you will need to provide your own locking mechanism to ensure that multiple threads don't cause a problem. However, i do believe that...
  • Cyrus' Blather

    Writing the simplest code to make your test pass

    • 2 Comments
    I realized with my last bit of coding/post that i was following one of the rules that jay had told me about: “Once you've written the tests, provide the simplest implementation that makes them pass”. However, when writing a library it's a...
  • Cyrus' Blather

    Poor mans bootstrapping unit testing

    • 1 Comments
    I wrote in a pervious post about my inability to use NUnit, and my want to avoid my own unit testing engine. I felt caught between a rock and a hard place. I want to test, but i don't have to the testing tools available. I mentioned that i would need...
  • Cyrus' Blather

    First ICollection implementation: Array Collection

    • 3 Comments
    Wrote my first concrete implementation of my ArrayCollection class: namespace Testing.Collections { using System; public class ArrayCollection <A> : ICollection <A> { private A[] array; private int count; public...
  • Cyrus' Blather

    Importance of shipping with the platform (=> NUnit+BadImageFormatException)

    • 2 Comments
    Anson and i had a pretty interesting argument about the need to ship working versions of the tools with the platform we're releasing. His take on it was that when a new platform shipped we had to provide tools that worked with it at that moment. i.e....
Page 14 of 15 (366 items) «1112131415