On Sat, Aug 11, 2018 at 11:29:41AM +0200, Pablo Rodriguez wrote:
> I realize that the fault is mine, but with backwards compatibility I
> meant that the same operation (10 + "10") gives different results with
> different Lua versions.
It doesn’t, it returns 10 in both cases. The difference is
On 8/11/2018 11:33 AM, Pablo Rodriguez wrote:
On 08/09/2018 10:20 PM, Hans Åberg wrote:
On 9 Aug 2018, at 21:20, Pablo Rodriguez wrote:
[...]
My background is in humanities and I don’t understand the exponent for
being a float ("10²" contains an exponent
On Sat, 11 Aug 2018 11:29:41 +0200
Pablo Rodriguez wrote:
> On 08/09/2018 10:16 PM, Alan Braslau wrote:
> > On Thu, 9 Aug 2018 22:00:48 +0200
> > Pablo Rodriguez wrote:
> >
> >> I guess that backwards compatibility should be important here, but I
> >> hope there are stronger reasons for
> On 11 Aug 2018, at 11:33, Pablo Rodriguez wrote:
>
> On 08/09/2018 10:20 PM, Hans Åberg wrote:
>>> On 9 Aug 2018, at 21:20, Pablo Rodriguez wrote:
>>> [...]
>>> My background is in humanities and I don’t understand the exponent for
>>> being a float ("10²" contains an exponent
>>>
On 08/09/2018 10:25 PM, Hans Hagen wrote:
> In addition to what others already explained, you should not depend on
> features that are implementation dependent or might disappear.
Many thanks for your detailed explanation, Hans.
I had no idea that the automatic conversion from string to number
On 08/09/2018 10:20 PM, Hans Åberg wrote:
>> On 9 Aug 2018, at 21:20, Pablo Rodriguez wrote:
>> [...]
>> My background is in humanities and I don’t understand the exponent for
>> being a float ("10²" contains an exponent
>> [https://www.m-w.com/dictionary/exponent], but I would say is an integer
On 08/09/2018 10:16 PM, Alan Braslau wrote:
> On Thu, 9 Aug 2018 22:00:48 +0200
> Pablo Rodriguez wrote:
>
>> I guess that backwards compatibility should be important here, but I
>> hope there are stronger reasons for breaking it.
>
> tonumber() provides backwards compatibility. And the
On 8/9/2018 10:00 PM, Pablo Rodriguez wrote:
On 08/09/2018 09:34 PM, Alan Braslau wrote:
The lua manual also states that one should NOT rely on the implicit
conversion of a string to its numerical value, and suggests the
systematic use of tonumber().
Many thanks for your reply, Alan.
I guess
> On 9 Aug 2018, at 21:20, Pablo Rodriguez wrote:
>
> A numeric constant with a radix point or an exponent denotes a
> float; otherwise, if its value fits in an integer, it denotes an
> integer.
>
> Well, "10.0" contains the radix point, but with no arithmetical relevance.
>
> My
On Thu, 9 Aug 2018 22:00:48 +0200
Pablo Rodriguez wrote:
> I guess that backwards compatibility should be important here, but I
> hope there are stronger reasons for breaking it.
tonumber() provides backwards compatibility. And the recommendation to use it
was in the third edition (of the lua
On 08/09/2018 09:34 PM, Alan Braslau wrote:
> The lua manual also states that one should NOT rely on the implicit
> conversion of a string to its numerical value, and suggests the
> systematic use of tonumber().
Many thanks for your reply, Alan.
I guess that backwards compatibility should be
The lua manual also states that one should NOT rely on the implicit conversion
of a string to its numerical value, and suggests the systematic use of
tonumber().
Alan
On Thu, 9 Aug 2018 21:20:54 +0200
Pablo Rodriguez wrote:
> On 08/09/2018 08:12 PM, Wolfgang Schuster wrote:
> > Use
On 08/09/2018 08:12 PM, Wolfgang Schuster wrote:
> Use tonumber.
Many thanks for your reply, Wolfgang.
The issue is in Lua itself:
print(5+"5")
In versions prior to 5.3, result is "10".
From version 5.3, result is "10.0",
I would say this might be a bug. According to the “Lua 5.3 Reference
Use tonumber.
%%
\starttext
\cldcontext{\lastpage + 1}
\cldcontext{"\lastpage" + 1}
\cldcontext{tonumber("\lastpage") + 1}
\stoptext
%%
Wolfgang
Pablo Rodriguez schrieb am 09.08.18 um 20:02:
Dear list,
I have the following sample
\starttext
\startTEXpage[offset=1em]
Dear list,
I have the following sample
\starttext
\startTEXpage[offset=1em]
Pages: \ctxlua{context([[\lastpage]])}.
Next page: \ctxlua{context([[\lastpage]] + 1)}.
(Lua \luaversion)
\stopTEXpage
\stoptext
With Lua-5.2 (ConTeXt with JIT), I get the expected results.
Am 29.10.2011 um 18:27 schrieb Paul Menzel:
Dear ConTeXt folks,
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
⅛ ist $\frac18$.
½, ⅓, ¼, ⅕, ⅙, ⅛
\stoptext
I guess this is a font problem, but maybe fall
On Sun, Oct 30, 2011 at 9:44 AM, Wolfgang Schuster
schuster.wolfg...@googlemail.com wrote:
Am 29.10.2011 um 18:27 schrieb Paul Menzel:
Dear ConTeXt folks,
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
⅛ ist $\frac18$.
Am 30.10.2011 um 09:49 schrieb luigi scarso:
On Sun, Oct 30, 2011 at 9:44 AM, Wolfgang Schuster
schuster.wolfg...@googlemail.com wrote:
Am 29.10.2011 um 18:27 schrieb Paul Menzel:
Dear ConTeXt folks,
some fractions (input using Compose) are not displayed in the resulting
PDF files.
On 30-10-2011 09:44, Wolfgang Schuster wrote:
Am 29.10.2011 um 18:27 schrieb Paul Menzel:
Dear ConTeXt folks,
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
⅛ ist $\frac18$.
½, ⅓, ¼, ⅕, ⅙, ⅛
\stoptext
I guess
Dear ConTeXt folks,
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
⅛ ist $\frac18$.
½, ⅓, ¼, ⅕, ⅙, ⅛
\stoptext
I guess this is a font problem, but maybe fall backs could be added?
Thanks,
Paul
Dear ConTeXt folks,
Am Samstag, den 29.10.2011, 18:27 +0200 schrieb Paul Menzel:
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
⅛ ist $\frac18$.
½, ⅓, ¼, ⅕, ⅙, ⅛
\stoptext
I guess this is a font
Dear ConTeXt folks,
I forgot to append the links.
Am Samstag, den 29.10.2011, 23:12 +0200 schrieb Paul Menzel:
Am Samstag, den 29.10.2011, 18:27 +0200 schrieb Paul Menzel:
some fractions (input using Compose) are not displayed in the resulting
PDF files.
\starttext
22 matches
Mail list logo