zhongliangyu / protobuf-net

Automatically exported from code.google.com/p/protobuf-net
0 stars 0 forks source link

Serializing DateTime from a list or array loses Kind information #288

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

var dt = DateTime.UtcNow;
var kind1 = Serializer.DeepClone(dt).Kind;
var kind2 = Serializer.DeepClone(new DateTime[] { dt } )[0].Kind;

What is the expected output? What do you see instead?

Both kind1 and kind2 should be Utc, but kind2 is Unspecified.

What version of the product are you using? On what operating system?

2.0.0.480, Windows XP 64 bit, .NET 4.0.

Original issue reported on code.google.com by m...@jamesthurley.com on 27 Apr 2012 at 5:37