Re: [fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Ryan Joseph via fpc-pascal
> On Oct 5, 2020, at 5:08 PM, Jean SUZINEAU via fpc-pascal > wrote: > > In my own code I use BlockRead/BlockWrite, but I'm wondering if I've not seen > this somewhere in RTL. > > This looks good to me what about the concerns raised by Michael? I don't know enough about text formats but us

Re: [fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Winfried Bartnick via fpc-pascal
Am 06.10.20 um 01:08 schrieb Jean SUZINEAU via fpc-pascal: In my own code I use BlockRead/BlockWrite, but I'm wondering if I've not seen this somewhere in RTL. https://github.com/jsuzineau/pascal_o_r_mapping/blob/TjsDataContexte/pascal_o_r_mapping/02_Units/uuStrings.pas function String_from

Re: [fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Jean SUZINEAU via fpc-pascal
In my own code I use BlockRead/BlockWrite, but I'm wondering if I've not seen this somewhere in RTL. https://github.com/jsuzineau/pascal_o_r_mapping/blob/TjsDataContexte/pascal_o_r_mapping/02_Units/uuStrings.pas function String_from_File( _FileName: String): String;

Re: [fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Ryan Joseph via fpc-pascal
> On Oct 5, 2020, at 3:23 PM, Michael Van Canneyt via fpc-pascal > wrote: > > So I think you're looking at 6 or even 8 versions of this hypothetical > function... Ouch. :) I'm sure this code already exists in the RTL though, right? I assume it's part of some classes like TStringList and we

Re: [fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Michael Van Canneyt via fpc-pascal
On Mon, 5 Oct 2020, Ryan Joseph via fpc-pascal wrote: I often need to use a function which reads a file into a string, as is so common in so many scripting languages. Can it be considered to add something like this to the RTL? Since we have a refcounted Ansistring type it's natural for this

[fpc-pascal] Adding file to string to the RTL

2020-10-05 Thread Ryan Joseph via fpc-pascal
I often need to use a function which reads a file into a string, as is so common in so many scripting languages. Can it be considered to add something like this to the RTL? Since we have a refcounted Ansistring type it's natural for this to be a one-liner. Not saying we should use TStringList bu

Re: [fpc-pascal] Looking for testers for 3.2.0 release cross-compilers for NDS, GBA and WII targets

2020-10-05 Thread Schindler Karl-Michael via fpc-pascal
Hi > Am 04.10.2020 um 21:59 schrieb fpc-pascal-requ...@lists.freepascal.org: > > Message: 1 > Date: Sun, 4 Oct 2020 18:35:12 +0200 > From: Pierre Muller > To: fpc-pascal@lists.freepascal.org > Subject: [fpc-pascal] Looking for testers for 3.2.0 release cross-compilers > for NDS, GBA and WII tar