test/shared/support.rad 419 B raw
1
//! Shared dependency with private writable state.
2
3
/// Value read by dependent packages.
4
export static value: i32 = 7;
5
6
/// Large private allocation before the final zero-initialized scalar.
7
static padding: [u8; 8192] = [0; 8192];
8
/// Zero-initialized value at a large package offset.
9
static tail: i32 = 0;
10
11
/// Read this domain's value.
12
export fn read() -> i32 {
13
    set padding[8191] = 0;
14
    return value + tail;
15
}