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

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

bug#21934: 24.5; find-tag: reading TAGS file incorrectly


From: Andreas Matthias
Subject: bug#21934: 24.5; find-tag: reading TAGS file incorrectly
Date: Sun, 22 Nov 2015 15:08:07 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Dmitry Gutov wrote:

> That is, of course, if "." always goes after the name of the class/module/etc
> that "getPos" is defined in, and it can't follow a variable name. I'm not
> familiar with Lua's syntax.

In the example given Rectangle is a data structure called table and a
table is an associative array. In Lua you can put variables and
functions into a table. So Rectangle.getPos() is the function getPos()
of table Rectangle. Though Lua does not know the concept of classes, it
is easy to model object-oriented behavior by means of tables.

In addition to the dot-operator there's also a colon-operator in Lua which
acts like the dot-operator but hides the self/this parameter of OOP.





reply via email to

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