mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
22 lines
219 B
Plaintext
22 lines
219 B
Plaintext
module inlineme;
|
|
|
|
<*
|
|
@pure
|
|
*>
|
|
fn void test()
|
|
{
|
|
int x = 123;
|
|
int* y = &x;
|
|
}
|
|
|
|
int abc;
|
|
fn void test2()
|
|
{
|
|
abc = 1233;
|
|
}
|
|
|
|
<* @pure *>
|
|
fn void test3()
|
|
{
|
|
abc = 1233; // #error: '@pure' functions may not access globals
|
|
} |