Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Sven Barth via fpc-pascal
Am 10.01.2018 05:10 schrieb "Ryan Joseph" : > On Jan 10, 2018, at 6:37 AM, Graeme Geldenhuys < mailingli...@geldenhuys.co.uk> wrote: > > When using the Generics.Collections unit of Delphi I can define a list class that can hold Integer data types, by doing the

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Sven Barth via fpc-pascal
Am 10.01.2018 07:39 schrieb "Marco van de Voort" : In our previous episode, Sven Barth via fpc-pascal said: > Precisely these virtual methods are one point. They might not add much by > themselves, but if they're called for each Add or Remove operation they can > add quite a bit.

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Marco van de Voort
In our previous episode, Sven Barth via fpc-pascal said: > Precisely these virtual methods are one point. They might not add much by > themselves, but if they're called for each Add or Remove operation they can > add quite a bit. > Why do you think that the TFP(Object)List classes don't have

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Ryan Joseph
> On Jan 10, 2018, at 6:37 AM, Graeme Geldenhuys > wrote: > > When using the Generics.Collections unit of Delphi I can define a list class > that can hold Integer data types, by doing the following: > > var >IntList: TList; > begin >IntList :=

Re: [fpc-pascal] Problems with writing to console

2018-01-09 Thread James Richters
I suspect the output when writing to StdOut is moving the cursor to a location that is not known or kept track of by regular writeln in the CRT unit. If this is what's causing seemingly random positioning, You could possibly keep track of where the cursor is supposed to be yourself with the

Re: [fpc-pascal] Problems with writing to console

2018-01-09 Thread Michael Van Canneyt
On Tue, 9 Jan 2018, Darius Blaszyk wrote: Hi, I have been mixing "writeln(StdOut" and regular writeln in my application (actually a couple of applications working together) and found that the output on the console is mangled when I do that. Output is being overwritten and placed semi

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Graeme Geldenhuys
On 2018-01-09 01:29, Ryan Joseph wrote: What does this have to do with generics exactly? Everything I guess. ;-) That was the point of my reply. When using the Generics.Collections unit of Delphi I can define a list class that can hold Integer data types, by doing the following: var

Re: [fpc-pascal] Comp type

2018-01-09 Thread Darius Blaszyk
Comp is Int64 div 1. Thanks for the explanation Mathias! ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Comp type

2018-01-09 Thread Mattias Gaertner
On Tue, 09 Jan 2018 22:58:01 +0100 Darius Blaszyk wrote: > By accident I noticed the comp type for the first time. It's an Int64 > but is considered to be a real type. Just out of curiosity, what is the > use case of such a type, or is this just implemented for

[fpc-pascal] Problems with writing to console

2018-01-09 Thread Darius Blaszyk
Hi, I have been mixing "writeln(StdOut" and regular writeln in my application (actually a couple of applications working together) and found that the output on the console is mangled when I do that. Output is being overwritten and placed semi randomly on the console. What is the standard output

[fpc-pascal] Comp type

2018-01-09 Thread Darius Blaszyk
By accident I noticed the comp type for the first time. It's an Int64 but is considered to be a real type. Just out of curiosity, what is the use case of such a type, or is this just implemented for compatibility reasons? Rgds, Darius___ fpc-pascal

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Maciej Izak
2018-01-08 21:30 GMT+01:00 Graeme Geldenhuys : > Speaking of Generics and Benchmarks. Has anybody done some benchmarks on > FPC's Generics vs "old-school" TList and TObjectList. Recently I did a very > simple test with Delphi XE3 using TList and a stock TList.

Re: [fpc-pascal] Generics vs templates

2018-01-09 Thread Sven Barth via fpc-pascal
Am 09.01.2018 08:13 schrieb "Ryan Joseph" : > On Jan 9, 2018, at 2:04 PM, Sven Barth via fpc-pascal < fpc-pascal@lists.freepascal.org> wrote: > > But you need to program in a way that allows the usage of multiple, different types. That can more often than not lead to

Re: [fpc-pascal] re-engineering tool

2018-01-09 Thread Marc Santhoff
On Mon, 2018-01-08 at 15:21 +0200, Juha Manninen wrote: > On Sat, Jan 6, 2018 at 11:46 AM, Marc Santhoff > wrote: > > Since I'm confronted with the task of analyzing a pile of object > > pascal > > sources I'd like to know: > > > > Is there any tool that can help me? > > > >