help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: One more question about elisp


From: Francis Moreau
Subject: Re: One more question about elisp
Date: Sat, 7 Nov 2009 06:41:07 -0800 (PST)
User-agent: G2/1.0

On 7 nov, 02:40, LanX <lanx.p...@googlemail.com> wrote:
> On 6 Nov., 22:05, Francis Moreau <francis.m...@gmail.com> wrote:
>
> > It sounds strange to me (knowing C, python) to use hash tables to
> > structure data.
>
> You never used dicts in python for structured data???

No since python is known to be an object oriented language, if I want
to create an object, I'm defining a new class. I don't use a hash
table for that.

C allows to define new type. So I won't use a hash table to do that.

But I can understand that elisp has no way to create new types, and
hash tables can serve the purpose although I'm wondering how the code
will be readable (yes I already found elisp quite hard to read).

> IIRC an object instance  (like in your example) is actually just a
> dictionary and "dictionary" is just the python way to say hash table.

That's an implementation detail. The way you access fields of an
object through a hash table doesn't mean that an object is equivalent
to a hash table.

Thanks


reply via email to

[Prev in Thread] Current Thread [Next in Thread]