Re: New map routines

new topic     » goto parent     » topic index » view thread      » older message » newer message

Aku wrote:
> 
> Jeremy Cowgar wrote:
> > Also, I wonder if we should make the type name lower case instead of mixed
> > as
> > to fit in with the other types, i.e. integer, atom, object not Integer Atom
> > or Object?
> 
> I forgot to reply about this.
> I want to know how the others think about this new object type,
> should it be Map or map?
> 
> Maybe if we use "map" we cannot have any variable called "map" again
> and will break so many codes?

We are defining a new API as we go on. I do not think we should define the new
API based on possible variable names. I think a set standard and language
consistency are much more important. Changing a variable name is easy.

With the new release, I think no matter how hard we try, we are going to break
some peoples code. I think at all costs we should keep the language consistent.
Also, when naming variables, a variable name of map is really not a good
programming practice. Just as I would not create a variable name Integer. No one
does that because of an existing type of integer. On the inverse, you shouldn't
create a variable name of map with a type of Map. We see this often in simple OO
programming examples. But, it's not a good name nor a good example.

When I read through code, and I see a variable name called "map" I would ask,
ok, it's a map, but of what?

Therefore, to further my side, I especially think we should not design the new
interface based on possible bad naming schemes of variable names. I firmly
believe that keeping language consistency is of much more importance.

Now, this is not to say we should ignore the fact that we may break programs.
With useless changes, that would be a problem, for instance, we shouldn't
introduce a function named "i" which returns the index of a value in an array.
That would just be silly.

But, with Map, I think it really needs to be map. We can wait for what others
think as well, but again, Euphoria is a simple language and if we starting making
it inconsistent, we are going to ruin it.

--
Jeremy Cowgar
http://jeremy.cowgar.com

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu