title: The type 'Company.Model.User' and the type 'Company.Core.Model.User' both have the same simple name of 'User' and so cannot be used in the same model
body: <p>I have a base entity class <code>MyCompany.Core.Model.User</code> which is to be used for common properties of a <code>User</code> entity:</p>
  
  <pre><code>public class User
  {
      public string Username { get; set; }
      public string Usercode { get; set; }
  }
  </code></pre>
  
  <p>I also have a base mapping class <code>MyCompany.Core.Model.UserMap</code> to setup the code first mappings for the base <code>User</code> class:</p>
  
  <pre><code>public class UserMap&lt;TUser&gt; : EntityMapBase&lt;TUser&gt;
      where TUser : User
  {
      public UserMap()
      {
          // Primary Key
          this.HasKey(t =&gt; t.Usercode);
  
          // Table &amp; Column Mappings
          this.ToTable("Users");
          this.Property(t =&gt; t.Username).HasColumnName("Username");
          this.Property(t =&gt; t.Usercode).HasColumnName("UserCode");
      }
  }
  </code></pre>
  
  <p>In a separate assembly I have a derived class <code>MyCompany.Model.User</code> that inherits from the base <code>User</code> class and extends it with some additional properties:</p>
  
  <pre><code>public class User : Core.User
  {
      public string Surname { get; set; }
  } 
  </code></pre>
  
  <p>In addition I have a derived mapping class <code>MyCompany.Model.UserMap</code> to provide the additional configuration for the additional properties:</p>
  
  <pre><code>public class UserMap : Core.UserMap&lt;User&gt;
  {
      public UserMap()
      {
          this.Property(t =&gt; t.Surname).HasColumnName("Surname");
      }
  }
  </code></pre>
  
  <p>However when adding <code>MyCompany.Model.User</code> to the context and registering the <code>MyCompany.Model.UserMap</code> I'm getting the following error:</p>
  
  <p><em>The type 'MyCompany.Model.User' and the type 'MyCompany.Core.Model.User' both have the same simple name of 'User' and so cannot be used in the same model. All types in a given model must have unique simple names. Use 'NotMappedAttribute' or call Ignore in the Code First fluent API to explicitly exclude a property or type from the model.</em></p>
  
  <p>This <a href="http://blog.oneunicorn.com/2013/03/11/ef6-nested-types-and-more-for-code-first/" rel="noreferrer">link</a> indicates that you can't have the same "simple name" in the model twice.</p>
  
  <p><strong>Why is the base class "simple name" being registered in the model, and is there a way around it in order to implement this sort of entity inheritance?</strong>  </p>
  
  <p>I suspect the simple solution would be to rename the derived class; however I would prefer to avoid this as there may be many derivations in multiple contexts.</p>
  
  <p><em>Note: Using Entity Framework 6.0.0-rc1 (prerelease)</em></p>