-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: LINQ
-
None
-
None
-
Dotnet Drivers
-
None
-
None
-
None
-
None
-
None
-
None
While working on a LINQ ticket I discovered that we have extension methods for Type scattered across three files:
Serialization\TypeExtensions.cs
Misc\TypeExtensions.cs
ReflectionExtensions.cs
The first file is in the Bson project, and the other two are in the Driver project. Since these classes are internal nothing can be done to consolidate the Bson and Driver extension methods. Fortunately the Bson project only has 3 Type extension methods.
The two driver files could be consolidated into a single file: Misc\TypeExtensions.
This consolidation not only improves understanding the code base by centralizing all Type extension methods in one place, but will also eliminate some duplications across the two files.