lua-users home
lua-l archive

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


On Sun, Jan 17, 2016 at 6:57 AM, Dirk Laurie <dirk.laurie@gmail.com> wrote:
> Just about every post we get here about things like why
> 0.1+0.1+0.1 does not equal 0.3 comes from rank newbies, but
> just about every post we get about the vagaries of integer
> overflow comes from people that know very well what is going
> on and are just being contrary.


:( I remember asking many questions about floating point and big
integers and having a feeling of general anxiety that Lua wasn't
always going to give me sane answers.

"Any effectively generated theory capable of expressing elementary
arithmetic cannot be both consistent and complete." --Gödel's first
incompleteness theorem [1]

On something as limited as a binary computer, you're not going to even
be able to natively cover everything that is in basic integer math.
The solutions to representing concepts that go beyond the bounds of
basic types, such as 64 bit signed integers 1) are rarely needed 2)
have multiple solutions that are appropriate for only a subset of
problems.

>From the perspective of the non-trivial task that I'm trying to
complete, I understand that Lua is purposely incomplete. I have to
bring my own solutions to solve the hard problems in my application,
just like any other language.

At some point, you have to program.

-Andrew

[1] https://en.wikipedia.org/wiki/G%C3%B6del%27s_incompleteness_theorems