Sign in Join

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

Mailing lists / fpc-devel / 2004-08

Objective-C objects

2 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

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

Olle Raab

04-08-16 00.16, skrev Dr. Rolf Jansen följande:

Show quoted text 6 lines
> I started to learn Cocoa with Objective-C. I prefer Cocoa over Carbon > but ObjectPascal over Objective-C. Do you think, that the Object models > of both languages might be compatible to a certain degree. Is it > possible to call Objective-C methods from ObjectPascal and vice versa? > In this case the greatest thing in the Pascal world would be to produce > PInterfaces for the Cocoa-Framework.

Afaik the architecture of fpc is such that several object models can coexist. E g there is support for the Delphi classes, old style Turbo objects, and even C++ objects (at least some work is going on). So I think it should be possible to implement yet another model, but perhaps some other guru can give a better answer.

IIRR Metrowerks did add some support for Objective-C classes to their Pascal.

Olle

Reply by email

Jonas Maebe
to Olle Raab
Olle Raab wrote 7 lines
Afaik the architecture of fpc is such that several object models can coexist. E g there is support for the Delphi classes, old style Turbo objects, and even C++ objects (at least some work is going on). So I think it should be possible to implement yet another model, but perhaps some other guru can give a better answer.

There is not support at all for C++ classes, and nobody is working on that. The only thing that is maybe planned for one day, is support for C++ name mangling, so you can call C++ object code from Pascal programs. Object models are not a plug&play feature of FPC.

Objective C is much more dynamic than either Object Pascal or C++, and I don't know whether it would be possible to map one to the other without creating some kind of Objective Pascal.

Jonas

Reply by email