facebook-csharp-sdk / simple-json

JSON library for .NET 2.0+/SL4+/WP7/WindowsStore with optional support for dynamic and DataContract
MIT License
380 stars 143 forks source link

Consolidate compilation conditionals around types #35

Closed haacked closed 11 years ago

haacked commented 11 years ago

By writing a static method GetTypeInfo that just returns the passed in type when SIMPLE_JSON_TYPEINFO == false we can use the same code for both values of the conditional compilation constant SIMPLE_JSON_TYPEINFO.

Normally this would be done with an extension method but we can't use those in this project. :)