[Freeciv-Dev] Re: [CMA 2.3] A few comments
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
On Tue, 9 Oct 2001, hawk@xxxxxxxxxxxxxxxxxxxxxxx wrote:
>> > MAX_CMAS is an internal constant. Code from outside has to use
>> > cmafc_predefined_num to get the number of predefined parameters.
>> >
>>
>> Why not just import header files? Is this for other languages like
>> python etc?
>
> Encapsulation. Data hiding.
Could you give us a real explanation, rather than just OO buzzwords?
As nearly as I can tell, MAX_CMAS is just a constant with a name. A
define or an enum is the usual way to do this in C. Using a function
instead is generally only useful if you wish to change the constant
while preserving binary compatibility; I don't think this is the case
here, so cmafc_predefined_num() is just bloat.
--
Big Gaute http://www.srcf.ucam.org/~gs234/
.. here I am in 53 B.C. and all I want is a dill pickle!!
[Freeciv-Dev] Re: [CMA 2.3] A few comments, Tony Stuckey, 2001/10/09
[Freeciv-Dev] Re: [CMA 2.3] A few comments, Daniel L Speyer, 2001/10/09
[Freeciv-Dev] Re: [CMA 2.3] A few comments, Raimar Falke, 2001/10/10
|
|