Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-22 Thread Peter Vreman
The behaviour you are counting on is a side effect of an optimisation, not a behaviour by design. Oh, btw: fpc 2.2.2rc1 behaves with -O2 like delphi :) Without -O2 like 2.2.0 :) Add: I just realized that Peter implemented this some time ago in a in most cases (!) delphi compatible

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-22 Thread Peter Vreman
Boian Mitov wrote: I mean -O2 probably affects number of optimizations. I just hope there will be switches for turning off specific optimizations selectively. Please use a separate thread for new questions. See the -O switch help in 'fpc -h' how to turn on/off optimizations. Peter

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-22 Thread Boian Mitov
Vreman [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Sunday, June 22, 2008 1:43 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 It is good that it works for you now, but like Jonas already wrote. It is just pure luck and you rely

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-22 Thread Jonas Maebe
On 22 Jun 2008, at 23:30, Boian Mitov wrote: I mean it was not working when the optimization was on. They did not have option to turn the optimization off. No, it can only work when the optimization is on in FPC. To recap: a) in both FPC and Delphi, temps (regardless of their type) are

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-22 Thread Boian Mitov
] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Sunday, June 22, 2008 2:52 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 No, it can only work when the optimization is on in FPC. To recap: ___ fpc-devel maillist - fpc

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-20 Thread Peter Vreman
The behaviour you are counting on is a side effect of an optimisation, not a behaviour by design. Oh, btw: fpc 2.2.2rc1 behaves with -O2 like delphi :) Without -O2 like 2.2.0 :) Add: I just realized that Peter implemented this some time ago in a in most cases (!) delphi compatible

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-20 Thread Boian Mitov
- Original Message - From: Peter Vreman [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Friday, June 20, 2008 2:42 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-20 Thread Boian Mitov
- Original Message - From: Boian Mitov [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Friday, June 20, 2008 2:58 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Hi Peter

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-20 Thread Boian Mitov
://www.mitov.com - Original Message - From: Boian Mitov [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Friday, June 20, 2008 2:58 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503

[fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
Hi folks, It appears that this bug has been fixed. Where I can get a patch for this? This is a very high priority bug for us, and we are glad that it has already been addressed :-) . I am very eager to test the fix. With best regards, Boian Mitov

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 13:10, Boian Mitov wrote: It appears that this bug has been fixed. Where I can get a patch for this? This is a very high priority bug for us, and we are glad that it has already been addressed :-) . I am very eager to test the fix. Please read the comments to

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
: Jonas Maebe [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 4:15 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On 19 Jun 2008, at 13:10, Boian Mitov wrote: It appears that this bug has been fixed. Where I can get

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 13:21, Boian Mitov wrote: Thank you! I don't understand. 0011503 is a major failure. Is it in the compiler or in some library? Please read the comments to http://bugs.freepascal.org/view.php? id=9472. The whole issue is discussed there in great detail. This is a huge

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
: Thursday, June 19, 2008 4:39 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On 19 Jun 2008, at 13:21, Boian Mitov wrote: Thank you! I don't understand. 0011503 is a major failure. Is it in the compiler or in some library? Please read the comments to http

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Jonas, This functionality works in all versions of Delphi 5-2007. We support them all, and we have done so for years. We have no problems to compile with such optimizations turned off. We need proper reference counting. We have over 300

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Michael Van Canneyt [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:00 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 It should IMHO not be too hard to make a switch

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Boian Mitov schrieb: I have downloaded the source, and I will see if we can tweak it and add some compiler option to support this somehow. If it would be that easy, we would have done it. It's simply a matter of the design of compiler/rtl how ref. counting is done. We must draw a border

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Michael Van Canneyt [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:00 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 If you

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 13:53, Boian Mitov wrote: This functionality works in all versions of Delphi 5-2007. We support them all, and we have done so for years. We have no problems to compile with such optimizations turned off. One final time: please read the comments to

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Boian Mitov schrieb: PS: It will help me a lot if you guys can at least pint me to what files I should be looking for to change the behavior of the temp ;-) . See my other mail, this requires not only a simple change in a few files. ___ fpc-devel

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:10 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 If it would be that easy, we would have done

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:14 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb: PS: It will help me

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Michael, Thank you! I will be looking into the code, and see if I can add the functionality with some switch. We may redo the code, however it will probably take well over a year for fully rewriting it all, and it may not be necessarily a

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Jonas Maebe schrieb: On 19 Jun 2008, at 13:53, Boian Mitov wrote: This functionality works in all versions of Delphi 5-2007. We support them all, and we have done so for years. We have no problems to compile with such optimizations turned off. One final time: please read the comments to

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:16 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Michael, Thank you! I will be looking into the code, and see if I can add

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Marco van de Voort
Gee... Isn't it the reason we all love C++ ;-) . There all those things are standardized by the ANSI, and return variable temp must be alive only for the duration of the statement if you want to call your compiler ANSI ;-) . Then again, don't we all hate the lack of support for singletons

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:29 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Do you have pg numbers in Strousstrup? (I've 2nd ed) I'd be interested to read how standards describes such things

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Vincent Snijders
Michael Van Canneyt schreef: On Thu, 19 Jun 2008, Boian Mitov wrote: Here is a code sniped that sows just one example of the problem: This is a very simple example of how important the order really is: We have even more crucial problems related with this. This is just a simple one:

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Boian Mitov [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:37 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 I will dig for it. With best

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Marco van de Voort
I will see to ping somebody on the ANSI comity for this one. It takes forever to dig it out ;-) . I will let you know. Thanks. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
@lists.freepascal.org Sent: Thursday, June 19, 2008 5:16 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Michael, Thank you! I will be looking into the code, and see if I can add the functionality with some switch. We may redo the code

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 14:36, Michael Van Canneyt wrote: On Thu, 19 Jun 2008, Boian Mitov wrote: Here is a code sniped that sows just one example of the problem: This is a very simple example of how important the order really is: We have even more crucial problems related with this. This is

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:16 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Michael, Thank you! I will be looking into the code, and see if I can add the functionality with some switch

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Jonas Maebe [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:55 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
On Thu, 19 Jun 2008, Boian Mitov wrote: This is not very precise. You are referring to garbage collection in general. Reference counting as it used to be defined in the original COM specification for DLL and statically linked objects specifically states that the object will be destroyed as

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Boian Mitov schrieb: Hi Florian, FLock is not interface. There is no error with the FLock. To which instance is WriteLock an interface? FLock? WriteLock is interface, and I have to destroy it before I destroy the FLock. The order of destruction is obviously crucial. The error is the

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
patch for bugs : 0011503 / 0009472 The Delphi help warns explicitly against this. (see Using reference counting) Michael. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
Voort [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 5:54 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 I will see to ping somebody on the ANSI comity for this one. It takes forever to dig it out ;-) . I will let you know

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
- Original Message - From: Michael Van Canneyt [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:14 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 The Delphi help warns explicitly against this. (see Using

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:27 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:16 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
@lists.freepascal.org Sent: Thursday, June 19, 2008 6:31 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Page 244 Item 3 describes the lifespan of a temporary object in expression (rvalue life span): Ah, but this is a compiler generated object as result value. I'm still surprised

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Boian Mitov schrieb: Hi Marco, You are wrong. They mean expression not block! This path of the discussion is useless. As soon as you make WriteLock a global/static var, delphi behaves the same as fpc: it creates a temp. ref. which is only cleaned at procedure exit.

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:42 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb: Hi Marco, You are wrong

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 15:20, Boian Mitov wrote: never call Free() on interfaced object. I surely know that if I have used interfaces for the last 10 years or so ;-) . What I need is a way to make sure that all the references are gone. This is the first non garbage collected compiler that has

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:42 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb: Hi Marco, You

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Florian Klaempfl schrieb: Jonas Maebe schrieb: The behaviour you are counting on is a side effect of an optimisation, not a behaviour by design. Oh, btw: fpc 2.2.2rc1 behaves with -O2 like delphi :) Without -O2 like 2.2.0 :) Add: I just realized that Peter implemented this some time ago in

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Jonas Maebe [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 6:51 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Delphi doesn't, look at this example

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Jonas Maebe
On 19 Jun 2008, at 16:06, Florian Klaempfl wrote: Florian Klaempfl schrieb: Jonas Maebe schrieb: The behaviour you are counting on is a side effect of an optimisation, not a behaviour by design. Oh, btw: fpc 2.2.2rc1 behaves with -O2 like delphi :) Without -O2 like 2.2.0 :) Add: I just

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Florian Klaempfl
Boian Mitov schrieb: Thank you! I will see to get the 2.2.2rc1 and compile with the switch :-) . I will validate if it behaves the same way and will let you know :-) . I am very excited that there could be a ready solution :-) . I still recommend that you think about changing your design,

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 7:06 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Florian Klaempfl schrieb: Jonas Maebe schrieb

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Florian Klaempfl [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 7:09 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb: Thank you! I will see to get

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
, June 19, 2008 7:09 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Boian Mitov schrieb: Thank you! I will see to get the 2.2.2rc1 and compile with the switch :-) . I will validate if it behaves the same way and will let you know -) :. I am very excited

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On Thu, 19 Jun 2008, Boian Mitov wrote: Hmm... Florian, I seem to be finding only downloads for 2.2.0 . Where I can get 2.2.2rc1 ? See download link on www.freepascal.org main page, first (english) news item. Michael. With best

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
On Thu, 19 Jun 2008, Boian Mitov wrote: The FTP server seems really slow to respond. Do you want me to setup an FTP account for you guys on one of my servers, so you can upload in the future Beta stuff there for easier access for everybody? There are many mirrors; The main site just points

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
- Original Message - From: Michael Van Canneyt [EMAIL PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 8:16 AM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 On Thu, 19 Jun 2008, Boian Mitov

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Michael Van Canneyt
On Thu, 19 Jun 2008, Boian Mitov wrote: Hi Michael, Finally the server responded. This file is not on the mirrors :-( . It is only on the FTP. Strange, I would think that the FTP mirrors picked it up by now ? Michael. ___ fpc-devel maillist

Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472

2008-06-19 Thread Boian Mitov
PROTECTED] To: FPC developers' list fpc-devel@lists.freepascal.org Sent: Thursday, June 19, 2008 12:41 PM Subject: Re: [fpc-devel] Need patch for bugs : 0011503 / 0009472 Strange, I would think that the FTP mirrors picked it up by now ? ___ fpc-devel