winebuild & (name, heap, init)

Alexandre Julliard julliard at
Wed Sep 11 11:06:28 CDT 2002

"Dimitrie O. Paun" <dpaun at> writes:

> Even better -- encode it in the typeinfo.
> /* M = modifiable */
> typedef LPSTR LPMSTR;
> Use LPM{,W}STR instead of LP{,W}STR where the parameter is an IO one.
> The type are equivalent, so no one will notice a difference except
> our parsing tool.

This way lies madness. The parser shouldn't require any modification
to the source, and should work on any Windows source, not only the
Wine ones. This means there are basically two approaches:

1. write a full C compiler
2. use Patrik's Perl stuff to generate the initial info as best as we
   can and then update it by hand.

IMO #2 is the way to go, because no matter how clever a parser you
write it won't be able to extract semantics information; and that
would be the main advantage of doing a better relay debugger. Imagine
dumping structure contents, flags, following list pointers, etc.  We
shouldn't limit ourselves to what can be extracted automatically from
the source.

Of course having an imperfect parser also means we cannot use it for
the export info, because unlike relay debugging it needs to be 100%
correct. So we either need compiler declspec support, or we need a
specialized tool to extract the declspec info in a way that is
guaranteed to not miss anything.

Alexandre Julliard
julliard at

More information about the wine-devel mailing list