Sign in Join

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

Mailing lists / fpc-devel / 2005-12

Revision 2037 gives problems with lazarus

6 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

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

Jonas Maebe
to Unknown author
As information: since r2037 lazarus problem wasn't fixed in 2040.

Fixed. I've reverted 2037. It doesn't work because "out" has braindead semantics for refcounted types imo: the caller side decreases the refcount and sets the parameter to nil before passing it to the caller. The stupid thing is that

a) in case of non-formal "out" parameters, the callee will decrease the refcount anyway before assigning something to the "out" parameter, so it's not necessary
b) in case of formal (i.e. typeless) "out" parameters, the callee will obviously not do that. But that seems to be completely normal to me and not something the compiler should do behind your back, since you have to take care of exactly the same thing with formal "var" parameters.

Jonas

Reply by email

Jonas Maebe
to Jonas Maebe
Jonas Maebe wrote 5 lines
> As information: since r2037 lazarus > problem wasn't > fixed in 2040. Fixed. I've reverted 2037.

And in case nightly lazarus snapshots failed because of ansi2wide/ wide2ansi parameter incompatibilities: I've reverted that change as well.

Jonas

Reply by email

Joost van der Sluis
to Jonas Maebe
Show quoted text 9 lines
>> As information: since r2037 lazarus >> problem wasn't >> fixed in 2040. > > Fixed. I've reverted 2037. And in case nightly lazarus snapshots failed because of ansi2wide/ wide2ansi parameter incompatibilities: I've reverted that change as well.

It wasn't mine intention to make the snapshot compile. I mean: 2.1.1 is development build, thus may have problems. As long as the developer knows them, and the problems are fixable in the foreseable future, I have no problems with them.

JoJo,
Joost.

Reply by email

Michael Van Canneyt
to Joost van der Sluis
Joost van der Sluis wrote 14 lines
> >> As information: since r2037 lazarus > >> problem wasn't > >> fixed in 2040. > > > > Fixed. I've reverted 2037. > > And in case nightly lazarus snapshots failed because of ansi2wide/ > wide2ansi parameter incompatibilities: I've reverted that change as > well. It wasn't mine intention to make the snapshot compile. I mean: 2.1.1 is development build, thus may have problems. As long as the developer knows them, and the problems are fixable in the foreseable future, I have no problems with them.

The rule for FPC is that committed code must compile. If it does not compile, don't commit.

Michael.

Reply by email

Jonas Maebe
to Michael Van Canneyt
Michael Van Canneyt wrote 8 lines
> It wasn't mine intention to make the snapshot compile. I mean: > 2.1.1 is > development build, thus may have problems. As long as the developer > knows them, and the problems are fixable in the foreseable future, I > have no problems with them. The rule for FPC is that committed code must compile. If it does not compile, don't commit.

The code did compile, it was lazarus which didn't compile/run anymore.

Jonas

Reply by email