Skip to content

Instantly share code, notes, and snippets.

@cimnine
cimnine / Numeric.cs
Created June 25, 2012 16:35
A way to check if a type is numeric in C#
using System;
namespace ch.cimnine.Util
{
public sealed class Numeric
{
/// <summary>
/// Determines if a type is numeric. Nullable numeric types are considered numeric.
/// </summary>
/// <remarks>