fslaborg / Deedle

Easy to use .NET library for data and time series manipulation and for scientific programming
http://fslab.org/Deedle/
BSD 2-Clause "Simplified" License
939 stars 197 forks source link

Should C# ReadCsv have skipTypeInference:true as default? #270

Closed adamklein closed 9 years ago

adamklein commented 10 years ago

I believe F# skips as default, but C# does not.

tpetricek commented 9 years ago

We have a bit odd design here, but the defaults are the same.

In C#, the parameter is skipTypeInference and the default is false. In F#, the parameter is inferTypes and the default is true. So, the parameters represent opposite things, but the defaults mean the same thing.

I think the reason is that skipTypeInference is an optional parameter and it will always default to false (so to make the default true, we had to invert the name of the parameter...). That said, we could use inferTypes of type Nullable<bool> and that would work equally well.

We can certainly change this - but it would be a breaking change (probably a good one for consistency though).

adamklein commented 9 years ago

Oh, I see ... the inconsistent API threw me off... my fault for not reading the parameter names closely. I'd be in favor of a breaking change here.

tpetricek commented 9 years ago

+1 for doing a breaking change