[fpc-pascal] Windows Phone 8 + pascal

Sven Barth pascaldragon at googlemail.com
Mon Jun 25 12:29:17 CEST 2012


Am 25.06.2012 11:48 schrieb "Marco van de Voort" <marcov at stack.nl>:
>
> In our previous episode, Sven Barth said:
> > > says that WinRT is a COM-based API and uses a .NET-like metadata
format.
> > > So it is not native code after all then. I don't know why they
advertised
> > it as native. I guess it is faster than .NET code because it is not
> > managed. I thought that .NET allows non-managed code, too.
> >
> > Why does "COM-based + .NET-like metadata" imply that it's not native
code?
>
> It is ambiguous. Some COM forms can be queried for their methods etc, but
in
> some cases straight interface use is also possible.
>
> But my guess is that it is like DirectX, import the typelib, generate the
> interface units for it, and go.
>

More or less yes, but that what we currently extract from the typelib will
then be needed to be extracted from the metadata files.

> > The core libraries are written in either C or C++ and the metadata is
> > needed so that runtimes like .NET and languages like JavaScript can
> > interface with WinRT.
>
> Usually scripting and non scripting interfaces are separate. (since they
> derive from different base interfaces)

That's the point where WinRT tries to be strong: You only need the library
and the metadata to use it from within native or .NET languages or from
within JavaScript (which is provided by an engine that can make use if
WinRT kind and metadata)

> > We can also use this metadata to generate Object Pascal wrappers (it is
> > basically the successor of IDL which was used for interface definitions
in
> > the original COM)
>
> A typelib importer is already in svn.

Which won't be of much use for WinRT as this metadata is based on the
metadata that .NET assemblies already use and not on IDL.

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20120625/516fe920/attachment.html>


More information about the fpc-pascal mailing list