Using generics possible to limit supplied types to Built-In?
<p>I would like to limit the data types my method accepts using generics to built in types:</p>

<p>Built in types: <a href="http://msdn.microsoft.com/en-us/library/ya5y69ds(v=vs.80).aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/ya5y69ds(v=vs.80).aspx</a></p>

<p>The list differs from value / reference types. And I would like to only support built in, not all value types, and ofc also string, which is a reference type. </p>

<p>Is this possible?</p>

<p>EDIT:</p>

<p>Using constraints you can restrict to value types like this:</p>

<pre><code>T GetObject&lt;T&gt; where T: struct;
</code></pre>

<p>This would not permit strings to pass through though. </p>
