@@ -25,7 +25,8 @@ type internal CsvProviderArgs =
2525 Culture : string
2626 Encoding : string
2727 ResolutionFolder : string
28- EmbeddedResource : string }
28+ EmbeddedResource : string
29+ PreferDateOnly : bool }
2930
3031type internal XmlProviderArgs =
3132 { Sample : string
@@ -37,7 +38,8 @@ type internal XmlProviderArgs =
3738 EmbeddedResource : string
3839 InferTypesFromValues : bool
3940 Schema : string
40- InferenceMode: InferenceMode }
41+ InferenceMode: InferenceMode
42+ PreferDateOnly : bool }
4143
4244type internal JsonProviderArgs =
4345 { Sample : string
@@ -50,7 +52,8 @@ type internal JsonProviderArgs =
5052 InferTypesFromValues : bool
5153 PreferDictionaries : bool
5254 InferenceMode: InferenceMode
53- Schema: string }
55+ Schema: string
56+ PreferDateOnly : bool }
5457
5558type internal HtmlProviderArgs =
5659 { Sample : string
@@ -60,7 +63,8 @@ type internal HtmlProviderArgs =
6063 Culture : string
6164 Encoding : string
6265 ResolutionFolder : string
63- EmbeddedResource : string }
66+ EmbeddedResource : string
67+ PreferDateOnly : bool }
6468
6569type internal WorldBankProviderArgs =
6670 { Sources : string
@@ -93,7 +97,8 @@ type internal TypeProviderInstantiation =
9397 box x.Culture
9498 box x.Encoding
9599 box x.ResolutionFolder
96- box x.EmbeddedResource |]
100+ box x.EmbeddedResource
101+ box x.PreferDateOnly |]
97102 | Xml x ->
98103 ( fun cfg -> new XmlProvider( cfg) :> TypeProviderForNamespaces),
99104 [| box x.Sample
@@ -105,7 +110,8 @@ type internal TypeProviderInstantiation =
105110 box x.EmbeddedResource
106111 box x.InferTypesFromValues
107112 box x.Schema
108- box x.InferenceMode |]
113+ box x.InferenceMode
114+ box x.PreferDateOnly |]
109115 | Json x ->
110116 ( fun cfg -> new JsonProvider( cfg) :> TypeProviderForNamespaces),
111117 [| box x.Sample
@@ -118,7 +124,8 @@ type internal TypeProviderInstantiation =
118124 box x.InferTypesFromValues
119125 box x.PreferDictionaries
120126 box x.InferenceMode
121- box x.Schema |]
127+ box x.Schema
128+ box x.PreferDateOnly |]
122129 | Html x ->
123130 ( fun cfg -> new HtmlProvider( cfg) :> TypeProviderForNamespaces),
124131 [| box x.Sample
@@ -128,7 +135,8 @@ type internal TypeProviderInstantiation =
128135 box x.Culture
129136 box x.Encoding
130137 box x.ResolutionFolder
131- box x.EmbeddedResource |]
138+ box x.EmbeddedResource
139+ box x.PreferDateOnly |]
132140 | WorldBank x ->
133141 ( fun cfg -> new WorldBankProvider( cfg) :> TypeProviderForNamespaces),
134142 [| box x.Sources
@@ -223,7 +231,8 @@ type internal TypeProviderInstantiation =
223231 Encoding = args.[ 9 ]
224232 CacheRows = false
225233 ResolutionFolder = " "
226- EmbeddedResource = " " }
234+ EmbeddedResource = " "
235+ PreferDateOnly = false }
227236 | " Xml" ->
228237 Xml { Sample = args.[ 1 ]
229238 SampleIsList = args.[ 2 ] |> bool.Parse
@@ -234,7 +243,8 @@ type internal TypeProviderInstantiation =
234243 EmbeddedResource = " "
235244 InferTypesFromValues = args.[ 5 ] |> bool.Parse
236245 Schema = args.[ 6 ]
237- InferenceMode = args.[ 7 ] |> InferenceMode.Parse }
246+ InferenceMode = args.[ 7 ] |> InferenceMode.Parse
247+ PreferDateOnly = false }
238248 | " Json" ->
239249 // Handle special case for Schema.json tests where some fields might be empty
240250 if args.Length > 5 && not ( String.IsNullOrEmpty( args.[ 5 ])) then
@@ -248,7 +258,8 @@ type internal TypeProviderInstantiation =
248258 InferTypesFromValues = args.[ 5 ] |> bool.Parse
249259 PreferDictionaries = args.[ 6 ] |> bool.Parse
250260 InferenceMode = args.[ 7 ] |> InferenceMode.Parse
251- Schema = if args.Length > 8 then args.[ 8 ] else " " }
261+ Schema = if args.Length > 8 then args.[ 8 ] else " "
262+ PreferDateOnly = false }
252263 else
253264 // This is for schema-based tests in the format "Json,,,,,true,false,BackwardCompatible,SimpleSchema.json"
254265 Json { Sample = args.[ 1 ]
@@ -261,7 +272,8 @@ type internal TypeProviderInstantiation =
261272 InferTypesFromValues = true
262273 PreferDictionaries = false
263274 InferenceMode = InferenceMode.Parse " BackwardCompatible"
264- Schema = if args.Length > 8 then args.[ 8 ] else " " }
275+ Schema = if args.Length > 8 then args.[ 8 ] else " "
276+ PreferDateOnly = false }
265277 | " Html" ->
266278 Html { Sample = args.[ 1 ]
267279 PreferOptionals = args.[ 2 ] |> bool.Parse
@@ -270,7 +282,8 @@ type internal TypeProviderInstantiation =
270282 Culture = args.[ 4 ]
271283 Encoding = " "
272284 ResolutionFolder = " "
273- EmbeddedResource = " " }
285+ EmbeddedResource = " "
286+ PreferDateOnly = false }
274287 | " WorldBank" ->
275288 WorldBank { Sources = args.[ 1 ]
276289 Asynchronous = args.[ 2 ] |> bool.Parse }
0 commit comments