Define a primitive data type: Difference between revisions

m
→‎{{header|C sharp}}: Regularize header markup to recommended on category page
(→‎{{header|Wren}}: Simplified.)
m (→‎{{header|C sharp}}: Regularize header markup to recommended on category page)
Line 192:
As of February 2009 no open source libraries to do this task have been located.
 
=={{header|C sharp|C#}}==
Strictly speaking, this task is impossible in C# because a type that behaves like an integer (<code>int</code>, or <code>System.Int32</code>; <code>Integer</code> in VB.NET) must be a struct (in order to have value-type semantics), and, since C# does not allow the definition of a parameterless constructor for a struct (instead generating a default parameterless constructor that sets each of its fields to the default value for the type of the field), an instance of the struct with the forbidden value of zero can be created through that default constructor.
 
10,333

edits