Re: [Pharo-dev] Confused about FileReference read/write streams

2018-09-18 Thread Guillermo Polito
Hi Sven, On Mon, Sep 17, 2018 at 4:14 PM Sven Van Caekenberghe wrote: > Hi, > > Since ever (or as far as I can remember), FileReference made a distinction > between read and write streams, see #readStream[Do:] and #writeStream[Do:] > - these return a ZnCharacterReadStream and

Re: [Pharo-dev] Confused about FileReference read/write streams

2018-09-18 Thread Guillermo Polito
I've opened an issue https://pharo.fogbugz.com/f/cases/22466/Add-readWriteStream-and-readWriteStreamDo-in-FileSystem On Tue, Sep 18, 2018 at 10:14 AM Guillermo Polito wrote: > Hi Sven, > > On Mon, Sep 17, 2018 at 4:14 PM Sven Van Caekenberghe > wrote: > >> Hi, >> >> Since ever (or as far as I

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Henrik Sperre Johansen
Guillermo Polito wrote > On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant > akgrant0710@ > > wrote: > > >> Would it be useful for future FFI work to have primitives available >> which convert file names to and from the various platform specific >> formats? (Linux is basically a no-op, and

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Guillermo Polito
On Tue, Sep 18, 2018 at 10:43 AM Henrik Sperre Johansen < henrik.s.johan...@veloxit.no> wrote: > Guillermo Polito wrote > > On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant > > > akgrant0710@ > > > > > wrote: > > > >> Hi Esteban, Guille and Everyone, > >> > >> I haven't looked at using FFI much,

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Guillermo Polito
On Tue, Sep 18, 2018 at 11:06 AM Julien wrote: > Hello, > > I realised that it is possible to create an interval of floats. > > I think this is bad because, since intervals are computed by successively > adding a number, it might result in precision errors. > > (0.0 to: 1.0 by: 0.1) asArray >>>

[Pharo-dev] [Pharo 7.0-dev] Build #1253: 22456 dynamic left to right columns layout generates an additional unneeded row with null presenters

2018-09-18 Thread ci-pharo-ci-jenkins2
There is a new Pharo build available! The status of the build #1253 was: SUCCESS. The Pull Request #1803 was integrated: "22456 dynamic left to right columns layout generates an additional unneeded row with null presenters" Pull request url:

[Pharo-dev] [Pharo 7.0-dev] Build #1254: 22463 Tag ManifestTextCore and classes in package Text-Core-Manifest

2018-09-18 Thread ci-pharo-ci-jenkins2
There is a new Pharo build available! The status of the build #1254 was: SUCCESS. The Pull Request #1811 was integrated: "22463 Tag ManifestTextCore and classes in package Text-Core-Manifest" Pull request url: https://github.com/pharo-project/pharo/pull/1811 Issue Url:

Re: [Pharo-dev] UndefinedClasses as first class entities for P7

2018-09-18 Thread Guillermo Polito
On Thu, Sep 13, 2018 at 11:07 PM Tim Mackinnon wrote: > Kind of related - we did get the ability to save methods with undefined > classes and undeclared variables (vs having to correct this to save). So at > least a nod to that? > Yes, I was following your progress there :) And since you have

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Esteban Lorenzano
> On 18 Sep 2018, at 10:42, Henrik Sperre Johansen > wrote: > > Guillermo Polito wrote >> On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant > >> akgrant0710@ > >> >> wrote: >> >>> Hi Esteban, Guille and Everyone, >>> >>> I haven't looked at using FFI much, however it is easy to imagine

[Pharo-dev] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Julien
Hello, I realised that it is possible to create an interval of floats. I think this is bad because, since intervals are computed by successively adding a number, it might result in precision errors. (0.0 to: 1.0 by: 0.1) asArray >>> #(0.0 0.1 0.2 0.30004 0.4 0.5 0.6001

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Esteban Lorenzano
> On 18 Sep 2018, at 11:13, Guillermo Polito wrote: > > > > On Tue, Sep 18, 2018 at 11:06 AM Julien > wrote: > Hello, > > I realised that it is possible to create an interval of floats. > > I think this is bad because, since intervals are computed by

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Guillaume Larcheveque
Maybe #to:by: should convert its parameters in Fraction to avoid Floats problems (not sure, just an idea) 2018-09-18 11:25 GMT+02:00 Esteban Lorenzano : > > > On 18 Sep 2018, at 11:13, Guillermo Polito > wrote: > > > > On Tue, Sep 18, 2018 at 11:06 AM Julien > wrote: > >> Hello, >> >> I

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Guillermo Polito
On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant wrote: > Hi Esteban, Guille and Everyone, > > I haven't looked at using FFI much, however it is easy to imagine that > different file encoding rules on different platforms will make writing > FFI calls more difficult, Well not really (from my

[Pharo-dev] Fraction and ScaledDecimal should be not be serialized as Float in STON format

2018-09-18 Thread Julien
Hello, I realised that in the current implementation, when a number is serialised by STON it is either as an integer literal or as a float literal. There is a risk to loose precision, especially if what you serialise is a ScaledDecimal or a fraction. I propose a simple change to fix this: 1.

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Henrik Sperre Johansen
Guillermo Polito wrote > On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant > akgrant0710@ > > wrote: > >> Hi Esteban, Guille and Everyone, >> >> I haven't looked at using FFI much, however it is easy to imagine that >> different file encoding rules on different platforms will make writing >> FFI

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Esteban Lorenzano
> On 18 Sep 2018, at 11:04, Guillermo Polito wrote: > > > > On Tue, Sep 18, 2018 at 10:43 AM Henrik Sperre Johansen > mailto:henrik.s.johan...@veloxit.no>> wrote: > Guillermo Polito wrote > > On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant > > > akgrant0710@ > > > > > wrote: > > > >> Hi

[Pharo-dev] Roassal2 crashing when drawing TRLabelShape

2018-09-18 Thread Oleksandr Zaytsev
Hello, Roassal2 has recently been crashing on my image on every example that includes text. Peter Uhnak helped me discover that it crashes when drawing a TRLabelShape and maybe Cairo doesn't like the new FT plugin. Some experiments: 1. Inspecting an empty view (RTView new inspect) doesn't

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Nicolas Cellier
Hi Julien, You are right, Float intervals are not to be encouraged! But if a knowledgeable person wants to use it, why forbid it? Why not forbid Float alltogether then? In the same vein, I saw C compiler warning me about using Float = (== in C). Great! Now I cannot use -Wall -Werror, though I

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Eliot Miranda
> On Sep 18, 2018, at 2:52 AM, Guillaume Larcheveque > wrote: > > Maybe #to:by: should convert its parameters in Fraction to avoid Floats > problems (not sure, just an idea) There is no need to convert. One can simply write 0 to: 1 by: 1/10 The issue with 0 to: 1 by: 0.1 is a problem

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Nicolas Cellier
Le mar. 18 sept. 2018 à 11:53, Guillaume Larcheveque < guillaume.larcheve...@gmail.com> a écrit : > Maybe #to:by: should convert its parameters in Fraction to avoid Floats > problems (not sure, just an idea) > > Hi Guillaume, Yes possibly... But if the author explicitely requested a loop on

[Pharo-dev] Pharo Downloads are sluggish

2018-09-18 Thread Esteban Maringolo
Is there a reason why the latest version of the builds linked from the website are not hosted in some CDN, Amazon S3 or similar? Maybe in Europe the speed is fast, but where I am (Argentina) it is really slow, the screenshot shows 3.5KB/s, it averages 10KB/s, with peaks of 40KB/s. This is an

Re: [Pharo-dev] [rmod] Float should not implement #to:, #to:by:, etc...

2018-09-18 Thread Nicolas Cellier
Le mar. 18 sept. 2018 à 22:40, Nicolas Cellier < nicolas.cellier.aka.n...@gmail.com> a écrit : > > > Le mar. 18 sept. 2018 à 11:53, Guillaume Larcheveque < > guillaume.larcheve...@gmail.com> a écrit : > >> Maybe #to:by: should convert its parameters in Fraction to avoid Floats >> problems (not

Re: [Pharo-dev] Pharo Downloads are sluggish

2018-09-18 Thread Esteban Maringolo
After sending the previous email I checked the progress and it was aborted due to a network error. [image: pharo-cancelled.PNG] I retried and apparently the speed got to a more reasonable one, with peaks of 300KB/sec. [image: pharo-retry.png] My guess is that the bottleneck is at where the

Re: [Pharo-dev] Platform file encoding for FFI

2018-09-18 Thread Alistair Grant
Hi Guille, Esteban and Henry, Thanks for your replies. On Tue, Sep 18, 2018 at 10:09:02AM +0200, Guillermo Polito wrote: > > > On Mon, Sep 17, 2018 at 6:52 PM Alistair Grant wrote: > > Hi Esteban, Guille and Everyone, > > I haven't looked at using FFI much, however it is easy to

Re: [Pharo-dev] Fraction and ScaledDecimal should be not be serialized as Float in STON format

2018-09-18 Thread Sven Van Caekenberghe
Hi Julien, Good and interesting point. Your summary is correct: STON, inheriting from JSON so to speak, only knowns about integer and float numbers. All other Smalltalk numbers get converted, which results in a loss of type and precision. That might not be a perfect situation, but nobody