On 29 Jan 2010, at 14:40, Juha Manninen wrote:
There is no Modula2 mode. There is an Objective-Pascal mode, but no
Objective-C mode.
Sorry, yes. I knew it was Objective-Pascal, used in Mac, but I wrote
it wrong.
I remember reading about Modula2 mode but it must have been just an
idea.
Indeed.
Units compiled in different dialects can indeed be mixed in the
same
program.
That is cool! The same benefit Parrot or .NET have but with compiled
languages.
No, it is much more limited.
Ok... which way? They can mix and interact in the same program as
you told.
In case of FPC it's just a few handful of dialects that are supported
by a single compiler. A generic intermediate format can facilitate
easily combining the output of multiple completely different tools,
the creation/use of generic instrumentation/analysis/verification
tools that work on this format, the choice between static and dynamic
compilation (or a mix), annotations of the generated code in a
standardised way for use by tools that will process it later, ...
You can perfectly use a library compiled with gcc in a gpc-compiled
program. You just have to translate the headers
Right. That is the limitation.
As I said, the same limitation goes for FPC: if you want to use a
library written in Objective-C from Objective-Pascal, you also have to
translate the headers.
And the object oriented classes (in C++) you
can't really translate except for making them flat functions.
GPC also supports several different Pascal dialects (ISO Standard, ISO
Extended, Mac-style Pascal, Turbo Pascal, GPC-specific, ...), GCC
supports several different C standards (K&R, C89, C99, ...), G++
supports different C++ standards, ... And as far as I know, you can
also combine compiled source files written in different language
variants in the same final binary.
Jonas
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel