Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2014-08

For Stocki. Regarding interfaces.

7 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Unknown author

Stocki,

Since your report was closed and I didn't fully (the closing) agree with that without research, here's a part of my research:

I found this reply by Danny Thorpe on stackoverflow: http://stackoverflow.com/questions/7759081/is-the-compiler-treatment-of-implicit-interface-variables-documented/19914385#19914385

To quote:
"I recall there have been a few bugs in this area over the years. Long ago (D3? D4?), the compiler didn't reference count the intermediate worked most of the time, but got into trouble in
parameter alias situations. Once that was addressed there was a follow up regarding const params, I believe./*There was always a desire to move disposal of the intermediate value interface up to as soon as possible after the statement in which it was needed, but I don't think that ever got implemented in the Win32 optimizer because the compiler just wasn't set up for handling disposal at statement or block granularity*/."

As you will see, the original intention by the Delphi architects was to release an interface as soon as possible.
The problem was**and is** that their compiler infrastructure doesn't allow that.
So the discussion on the buglist should be read in that context.

Even the designer of Delphi's interface implementation wished they were able to have a better implementation.
CUDO's to the Freepascal compiler guys for more or less achieving that ;)

You have to read it very carefully. It is not about the question, but about the *last part of the answer by Danny.**
*
I hope this sheds some new light on the matter that bothers you so much.

Regards,

Thaddy

Reply by email

Sven Barth
to Unknown author
Show quoted text 5 lines
Stocki, Since your report was closed and I didn't fully (the closing) agree with that without research, here's a part of my research:

[...]

I hope this sheds some new light on the matter that bothers you so much.

Addendum:
http://wiert.me/2014/08/06/delphi-using-iinterface-to-restore-cursor-at-end-of-mehod-prelude-to-a-memento-that-executes-any-code-at-end-of-method/ (look at the comments by me)

And unless we have it somewhere black on white in the official documentation we won't change anything there. And even then we'd likely only do it for mode Delphi...

Note: It would have been nice if you mentioned the issue which you are refering to. Not everyone has an eye on the bug tracker...

Regards,
Sven

Reply by email

Unknown author
to Sven Barth

Sven,
I made some mistakes here as well. About 20 years ago I knew what was going on.
I am sorry I didn't put the mail in the proper context.

Regards,

Thaddy

Sven Barth wrote 25 lines
On 26.08.2014 17:27, wrote: > Stocki, > > Since your report was closed and I didn't fully (the closing) agree with > that without research, here's a part of my research: > [...] > I hope this sheds some new light on the matter that bothers you so much. Addendum: http://wiert.me/2014/08/06/delphi-using-iinterface-to-restore-cursor-at-end-of-mehod-prelude-to-a-memento-that-executes-any-code-at-end-of-method/ (look at the comments by me) And unless we have it somewhere black on white in the official documentation we won't change anything there. And even then we'd likely only do it for mode Delphi... Note: It would have been nice if you mentioned the issue which you are refering to. Not everyone has an eye on the bug tracker... Regards, Sven _______________________________________________ fpc-devel maillist - http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply by email

Unknown author
to Marco van de Voort

Mm,

Marco, since you were the first one to put me right (and I was referring to block rsolution, which was false) I do not think - in the light of Danny's writings - that a {$modeswitch delphibugs} is appropriate. ;)

Anyway, I hope that this reconciles Stocki's thinking about the subject.

Delphi got it wrong FPC got it better (maybe not right, but close and better than delphi) conceptually.

Marco van de Voort wrote 9 lines
In our previous episode, Sven Barth said: > And unless we have it somewhere black on white in the official > documentation we won't change anything there. And even then we'd likely > only do it for mode Delphi... Make it a modeswitch then :-) _______________________________________________ fpc-devel maillist - http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply by email