Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // All <Matium> keywords ar subject to change, this is half assed code that
- // isn't meant to compile.
- ///////////////////////////////////////////////////////////////////////////////
- // File: <Matium>Standards, what you DO NOT see.
- namespace <Matium> {
- namespace Standard {
- namespace Unsigned {
- using Integer8 = unsigned char; // This is also a single byte.
- using Integer16 = unsigned short; // This is an unsigned integer of 16 bytes.
- using Integer32 = unsigned int; // This is an unsigned integer of 32 bytes.
- using Integer64 = unsigned long; // This is an unsigned integer of 64 bytes.
- Integer8 Integer8(Integer8 Value) { return Value; }
- Integer16 Integer16(Integer16 Value) { return Value; }
- Integer32 Integer32(Integer32 Value) { return Value; }
- Integer64 Integer64(Integer64 Value) { return Value; }
- }
- using Integer16 = short; // This is an integer of 16 bytes.
- using Integer32 = int; // This is an integer of 32 bytes.
- using Integer64 = long; // This is an integer of 64 bytes (biggest ones).
- Integer16 Integer16(Integer16 Value) { return Value; }
- Integer32 Integer32(Integer32 Value) { return Value; }
- Integer64 Integer64(Integer64 Value) { return Value; }
- using Byte = unsigned char; // This is one byte.
- using Character = char; // I really think saying "Character" is clearer.
- Byte Byte(Byte Value) { return Value; }
- Character Character(Character Value) { return Value; }
- using Variable = auto;
- }
- }
- ///////////////////////////////////////////////////////////////////////////////
- // How to use it, what you see:
- <Matium>::Standard::Variable Red = <Matium>::Standard::Byte(0xFF);
- <Matium>::Standard::Variable A = <Matium>::Standard::Character("A");
- <Matium>::Standard::Variable Number3 = <Matium>::Standard::Unsigned::Integer16(3);
- <Matium>::Standard::Variable Number8 = <Matium>::Standard::Unsigned::Integer8(8);
- <Matium>::Standard::Variable BigNumber = <Matium>::Standard::Integer64(1000232123);
- <Matium>::Standard::Integer32 Status = 0; // The classic way with the equals.
- using namespace Matium;
- Standard::Integer32 Thing = 0; // Or you can be a dickhead and not see my namespace again :^)
- Standard::Integer32 Ting = Standard::Integer32(1); // Messy, ain't it? That's why I have "Variable".
- // Or you can keep going.
- using namespace Matium::Standard;
- Iteger32 Statusion = 1;
- Variable M8 = Integer32(8/8); // And play around with calculations, of course.
Advertisement
Add Comment
Please, Sign In to add comment