Basic types
#164
-
According to https://github.com/c3lang/c3docs/blob/master/docs/types.md#basic-types //import std::cinterop; (types.c3:1) Error: No module named 'std::cinterop' could be found, did you type the name right?
func int main()
{
bool b;
char c;
// byte b2; (types.c3:8) Error: Expected ';'.
short s;
ushort u;
int i;
uint ui;
long l;
ulong ul;
iptr ip;
uptr up;
iptrdiff ipd;
uptrdiff upd;
isize is;
usize us;
// half h; Error: Expected ';'.
float f;
double d;
// quad q; Error: Expected ';'.
// f16 f_16; Error: Expected ';'.
// f32 f_32; Error: Expected ';'.
// f64 f_64; Error: Expected ';'.
return 0;
} |
Beta Was this translation helpful? Give feedback.
Answered by
lerno
Jun 10, 2021
Replies: 1 comment 1 reply
-
quad and half support isn't complete yet. I am not sure whether I'll support the type aliases (e.g. f16 etc) as aliases. $switch (CINTSIZE):
$case 8:
define CInt = ichar;
$case 16:
define CInt = short;
$case 32:
define CInt = int;
$case 64:
define CInt = long;
$endswitch .. in that file. So that's why it's delayed. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
data-man
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
quad and half support isn't complete yet. I am not sure whether I'll support the type aliases (e.g. f16 etc) as aliases.
byte
/char
now ischar
andichar
respectively. I'll fix the docs for that. I'll create the cinterop package when I have the $switch working 100%, because the source code will look something like:.. in that file. So that's why it's delayed.