Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Dennis Poon
Martin Schreiber wrote: On Friday 12 February 2016 03:17:57 Dennis wrote: Is there any sample codes to copy published properties (via RTTI) ? e.g. psuedo code below for i := 0 to properties.count -1 do begin case properties[i].type of vtInteger : properties[i].AsInteger

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Martin Schreiber
On Friday 12 February 2016 03:17:57 Dennis wrote: > > Is there any sample codes to copy published properties (via RTTI) ? > e.g. psuedo code below > >for i := 0 to properties.count -1 do begin > case properties[i].type of > vtInteger : properties[i].AsInteger := > Source.Propert

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Dennis
Martin Schreiber wrote: On Thursday 11 February 2016 17:17:32 Graeme Geldenhuys wrote: Now the other thing that surprised be, I thought TPersistent.Assign() automatically handles protected properties (via RTTI) - thinking that descendants automatically get such functionality for free. But revi

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Mattias Gaertner
On Wed, 10 Feb 2016 05:10:55 -0500 Anthony Walter wrote: >[...] > Additionally, and in a different scenario, when the identifier IS defined > and several units are in the uses clause the goto declaration can jump to > an include file without any information pertaining to which of the units is > i

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread wkitty42
On 02/11/2016 06:51 AM, Michael Van Canneyt wrote: On Thu, 11 Feb 2016, Mattias Gaertner wrote: Michael Van Canneyt hat am 11. Februar 2016 um 04:27 geschrieben: [...] Lazarus IDE shows a tooltip when you hover over an identifier with the mouse. I suspect it will take one on the team less than

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Martin Schreiber
On Thursday 11 February 2016 17:17:32 Graeme Geldenhuys wrote: > > Now the other thing that surprised be, I thought TPersistent.Assign() > automatically handles protected properties (via RTTI) - thinking that > descendants automatically get such functionality for free. But reviewing > the RTL code,

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Graeme Geldenhuys
On 2016-02-11 15:55, Martin Schreiber wrote: > It depends on what knows to handle what. Sometimes both have to be overridden. Thanks Martin and Andreas. So it's more about which direction you want to go. Now the other thing that surprised be, I thought TPersistent.Assign() automatically handles p

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Martin Schreiber
On Thursday 11 February 2016 16:13:22 Graeme Geldenhuys wrote: > Hi, > > In TPersistent, we have two virtual methods. Assign() which calls > AssignTo(). > > 1) Why are they both virtual? It seems like Assign() is what I call a > template method, farming its work out to other helper methods - in thi

Re: [fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Andreas Schneider
Am 2016-02-11 16:13, schrieb Graeme Geldenhuys: Hi, In TPersistent, we have two virtual methods. Assign() which calls AssignTo(). 1) Why are they both virtual? It seems like Assign() is what I call a template method, farming its work out to other helper methods - in this case, AssignTo(). Norma

[fpc-pascal] Assign() vs AssignTo()

2016-02-11 Thread Graeme Geldenhuys
Hi, In TPersistent, we have two virtual methods. Assign() which calls AssignTo(). 1) Why are they both virtual? It seems like Assign() is what I call a template method, farming its work out to other helper methods - in this case, AssignTo(). Normally template methods are not virtual, but their he

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-11 Thread Luca Olivetti
El 11/02/16 a les 04:12, Martin ha escrit: info symbol 0x54320 and it prints what is at that address. Do that for each address in the trace. That should be "info line *0x54320". Bye -- Luca ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Sven Barth
Am 11.02.2016 11:41 schrieb "Anthony Walter" : > > > This won't be changed. Period. > > Sven, not to be argumentative, but you do get that for a long time programmers have learned how to write code and use libraries by examining them? My goal is simply to make it easier for the people who would wan

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-11 Thread Luiz Americo Pereira Camara
2016-02-11 0:12 GMT-03:00 Martin : > > Lazarus has "Leaks and Traces" in the view menu. Paste the trace, and then > use the Button "Resolve" to load the exe with symbols. That should do. > > It uses a copy of the code found in infodwrf and "whatever the name of the > unit reading stabs". Both of t

Re: [fpc-pascal] Recovering info from a backtrace with an external debug file

2016-02-11 Thread Luiz Americo Pereira Camara
2016-02-11 0:06 GMT-03:00 Luiz Americo Pereira Camara < luizameri...@gmail.com>: > > > 2016-02-10 23:59 GMT-03:00 : > >> On 02/10/2016 09:47 PM, Luiz Americo Pereira Camara wrote: >> >>> >>> How to get the line number, method names of the backtrace using the >>> external >>> debug file? >>> >> >>

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Graeme Geldenhuys
On 2016-02-11 11:51, Michael Van Canneyt wrote: > It's a coder... It's a hacker... it's SuperMattias ! :-D LOL G. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Michael Van Canneyt
On Thu, 11 Feb 2016, Mattias Gaertner wrote: Michael Van Canneyt hat am 11. Februar 2016 um 04:27 geschrieben: [...] Lazarus IDE shows a tooltip when you hover over an identifier with the mouse. I suspect it will take one on the team less than 10-minutes to add the unit name to the tooltip, i

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Mattias Gaertner
> Michael Van Canneyt hat am 11. Februar 2016 um 04:27 > geschrieben: >[...] > Lazarus IDE shows a tooltip when you hover over an identifier with the mouse. > I suspect it will take one on the team less than 10-minutes to add the unit > name to the tooltip, in addition to the package and source fi

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Michael Van Canneyt
On Thu, 11 Feb 2016, Anthony Walter wrote: This won't be changed. Period. Sven, not to be argumentative, Funny. You _are_ argumentative, considering the answers you got and number of posts :-) (no offense intended) but you do get that for a long time programmers have learned how to writ

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Michael Van Canneyt
On Thu, 11 Feb 2016, Anthony Walter wrote: Michael, a question: How much of the interface section of units differ per platform? Is it 1% of the code? Is it 5% of the code? With the xml2 unit it's 0%, yet all of the declarations are nested in several layers of include files: Numbers are irre

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Anthony Walter
> This won't be changed. Period. Sven, not to be argumentative, but you do get that for a long time programmers have learned how to write code and use libraries by examining them? My goal is simply to make it easier for the people who would want to pick up and start using Lazarus. Organizing thing

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Adriaan van Os
Michael Van Canneyt wrote: he fact that you're the first to complain in 20 years (at least I cannot remember any others, and I've been around for a while) gives you an indication of the relative importance of your problem. I do share Anthony's (strong) dislike of include files (but I am not

Re: [fpc-pascal] Please someone explain this to me

2016-02-11 Thread Sven Barth
Am 11.02.2016 00:23 schrieb "Anthony Walter" : > > For those who didn't understand what I meant by using regions in the interface section rather than include files, here is an image of what is essentially in SysUtils currently: > > http://cache.getlazarus.org/images/sysutils-include.gif > > Notice