2 Mar
2006
2 Mar
'06
6:15 p.m.
Hi!
I was wondering if there is a way to create a global function that could be shared by many public classes?
Here is an example: in X.ck --- // class public class X { fun static void foo() { <<< "foo!" >>>; } } // invoke X.foo() X.foo(); from Y.ck --- // invoke X.foo() X.foo(); --- The only trick, until we make better include/auto-loading, is to run X.ck before any shreds that needs X.foo(), like: > chuck X Y Also, we need to really fix the access modifiers 'public' and things, which is on the agenda. To share data globally, see: https://lists.cs.princeton.edu/pipermail/chuck-users/2005-November/000165.ht... Best, Ge!