On Tue, Mar 22, 2011 at 9:21 PM, Ben Kloosterman <[email protected]> wrote:
> > I feel that member functions for access control is one of the many ways > in > > which the concept of 'the object' has been conflated. It is simple, but > it > > doesn't compose... > > But don't type classes w "member methods" specifically allow this case ? > No. Type classes do not and cannot have member methods. I introduced a bad confusion about this a while back with an ill-considered statement. > > And yet, it *does* compose better than init-only fields. > Not really. Init-only fields should be viewed as an approximation to purity. The absence of the kind of composition you are considering where purity is concerned is actually quite important. Your region-based notion is quite different (and, in my view, quite interesting). > Alternatively, the concept of access could can be made more first-class, > which seems neater to me... We have toyed at the edge of this on this list somewhat. So far, all of the schemes that we have generated are pretty complex, which makes me uncomfortable. My gut is that we don't have the right underlying notions in the language yet to pull it off properly. > ... I find member functions [to be] Syntactic sugar with benefits... Ben, you occasionally say the most thought-provoking things. This had me briefly trying to picture exactly what sex between member functions might look like... shap
_______________________________________________ bitc-dev mailing list [email protected] http://www.coyotos.org/mailman/listinfo/bitc-dev
