introducing abstract types to mc

Pavel Tsekov ptsekov at gmx.net
Sat Sep 25 20:17:04 UTC 2004


Hello,

On Sat, 25 Sep 2004, Roland Illig wrote:

> Pavel Tsekov wrote:
> > On Fri, 24 Sep 2004, Roland Illig wrote:
> >>I'd like to introduce more abstract types into mc. That is, to separate
> >>cleanly which files (or functions) _use_ a data type and which ones
> >>_implement_ the basic operation on variables of this type.
> >
> >
> > 'abstract' in what sense ? I looked at the patch and it seems to me that
> > the only changes there are changes to the infrastructure. I don't see
> > a relation between code organization into files and data type properties.
>
> The data type is what fileopctx.h provides (an uncomplete structure and
> some methods to manipulate it). The implementation details are hidden in
> fileopctx-impl.h.
>
> >>Using this approach we can quickly tell which functions operate directly
> >>on the type. Keeping the number of these functions minimal we have
> >>better control of keeping the internal state of these types valid. For
> >
> > Yep. And also defining a clean inteface for a given data type.
>
> That's exactly what I mean by "abstract".
>
> > It seems like you are suggesting to change the current interface to data
> > types to someting like the interface in glib and all related packages.
>
> Yes, that would be nice.

Rolland, i feel that such changes are going to be quite intrusive for
HEAD now as we are close to 4.6.1. I just thought that as a first step
you might want to create a new branch where you'll implement what you have
in mind. When the code is mature enough it could be merged in HEAD. I
guess the code will change a lot in the beggining until the concept is
clear - I think this will cause a lot of confusion. The branch will also
give, those people interested in the new code, full access to the modified
tree. This is much easier than spreading your changes through a set of patches.



More information about the mc-devel mailing list