Skip to content

Latest commit

 

History

History
22 lines (16 loc) · 990 Bytes

README.md

File metadata and controls

22 lines (16 loc) · 990 Bytes

Value Prototype

Wrapping arbitrary values without boxing of common types.

Build

Goals

  • Take any value, including null
  • Fit into 64bits of data and an object field (128bits total on x64)
  • Do not box any primitive types (int, float, etc.) [Except for Decimal]
  • Optimize performance for primitive type storage/retrieval
  • Expose Type of wrapped type (or null for null)
  • Allow retrieving as any type that is AssignableFrom
  • Support nullable intrinsics without boxing (int?, float?, etc.) [Except for Decimal]
  • Allow intrinsic to/from nullable intrinsic (except no value to intrinsic)

Additional special support

  • Support ArraySegment<T> without boxing
  • Support UTC DateTime and DateTimeOffset without boxing

As proposed in .NET