Define a primitive data type: Difference between revisions

Content added Content deleted
(→‎[[Defining Primitive Data Types#ALGOL 68]]: check that multiplication is possible for big integers.)
m (→‎{{header|Java}}: Incorrect use of incorrect template)
Line 331:
The closest you can get to defining a primitive type in Java is making a new wrapper class for yourself with methods for math operations. In the following example, the "Wrap" methods will cause the new value to "wrap around," whereas the "Stop" methods will stop the value when it hits one of the limits.
 
{{incorrect|langJava|This doesn't actually create a primitive in Java. Also, many of the methods and constructors are the bound checks.}}
 
public class TinyInt{