Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
epidemian
GitHub Repository: epidemian/gravity
Path: blob/master/test/class_static.gravity
1214 views
#unittest {
	name: "Test class static access.";
	error: NONE;
	result: 20;
};

class foo {
	static var a;
	static func p(p) {
		a = [0,10,20,30];
	}
}

func main() {
	foo.p(5);
	return foo.a[2];
}