Since .NET arrays are covariant, the following works in C#:
var strArray = new string[0];
object[] objArray = strArray;
In F#, given an array, 'T[], what would be the best way to convert it to obj[], without re-creating the array (e.g., Array.map box)? I’m using (box >> unbox), but it feels sloppy.
seems like a good idea; O(1), and does the job, apparently.
Consider also not using this CLR mis-feature. 😉