Hi all,
how does one create a file stream in Pharo 7 that forces a specific line end convention ? For example, for forcing all end of lines to be Character lf. The old way, fileStream lineEndConvention: #'lf'. does not work anymore. Thanks, Thierry |
I think the idea is to use ZnCrPortableWriteStream for that.
> On 15 Mar 2018, at 14:58, Thierry Goubier <[hidden email]> wrote: > > Hi all, > > how does one create a file stream in Pharo 7 that forces a specific > line end convention ? For example, for forcing all end of lines to be > Character lf. > > The old way, > > fileStream lineEndConvention: #'lf'. > > does not work anymore. > > Thanks, > > Thierry > |
Hi, Yes, I'll provide a PR with that functionality soon. Probably in that case *ZnCrPortableWriteStream* is not the right name for that class. Sven, do you think renaming it now (before it has lots of users) would be acceptable towards backwards compatibility? Otherwise I would name it ZnNewLineConverterStream... Keep you updated, Guille On Thu, Mar 15, 2018 at 3:11 PM, Sven Van Caekenberghe <[hidden email]> wrote: I think the idea is to use ZnCrPortableWriteStream for that.
|
On Fri, Mar 16, 2018 at 11:29 AM, Guillermo Polito <[hidden email]> wrote:
|
In reply to this post by Guillermo Polito
> On 16 Mar 2018, at 11:29, Guillermo Polito <[hidden email]> wrote: > > Hi, > > Yes, I'll provide a PR with that functionality soon. Probably in that case *ZnCrPortableWriteStream* is not the right name for that class. Sven, do you think renaming it now (before it has lots of users) would be acceptable towards backwards compatibility? Otherwise I would name it ZnNewLineConverterStream... Renaming is OK/better, if it works (critical class in IO) Note #forPlatformLineEnding should do: OSPlatform current lineEnding > Keep you updated, > Guille > > On Thu, Mar 15, 2018 at 3:11 PM, Sven Van Caekenberghe <[hidden email]> wrote: > I think the idea is to use ZnCrPortableWriteStream for that. > > > On 15 Mar 2018, at 14:58, Thierry Goubier <[hidden email]> wrote: > > > > Hi all, > > > > how does one create a file stream in Pharo 7 that forces a specific > > line end convention ? For example, for forcing all end of lines to be > > Character lf. > > > > The old way, > > > > fileStream lineEndConvention: #'lf'. > > > > does not work anymore. > > > > Thanks, > > > > Thierry > > > > > > > > -- > > Guille Polito > Research Engineer > > Centre de Recherche en Informatique, Signal et Automatique de Lille > CRIStAL - UMR 9189 > French National Center for Scientific Research - http://www.cnrs.fr > > Web: http://guillep.github.io > Phone: +33 06 52 70 66 13 |
That should be fixed now. I proposed also the rename. I can revert it if needed. On Fri, Mar 16, 2018 at 1:04 PM, Sven Van Caekenberghe <[hidden email]> wrote:
|
2018-03-16 15:01 GMT+01:00 Guillermo Polito <[hidden email]>:
Thanks. I'll have a look later. Thierry
|
Free forum by Nabble | Edit this page |