fix compilation for .net 4.0