Take the 2-minute tour ×  I want to make the int in
IDictionary<int, Driver> a little less obscure about its
meaning, so I thought maybe wrapping it would be a good idea.
The outcome would be something like IDictionary<finishPosition,
Driver>.  Preferably, finishPosition should be assignable like
this finishPosition = 1.  I do not know if this is possible and
how.  share|improve this question add comment  5 Answers  up
vote 4 down vote accepted  You could use a struct with an
implicit conversion.  public struct FinishPosition {     public
readonly int Position;      public FinishPosition(int position)
{         this.Position = position;      public static implicit
operator FinishPosition(int position) {         return new
FinishPosition(position);  // ...  Dictionary<FinishPosition,
Driver> dict = new Dictionary<FinishPosition, Driver>(); Driver
bob = new Driver();  // The following two lines are effectively
equivalent dict[new FinishPosition(7)] = bob; dict[7] = bob;  //
So are these two bob = dict[7]; bob =