MSHTML: THIS macros clean up

Dimi Paun dimi at lattica.com
Tue Jun 28 17:15:47 CDT 2005


----- Original Message ----- 
From: "Jacek Caban" <jack at itma.pwr.wroc.pl>
> @@ -78,29 +77,35 @@ static HRESULT WINAPI PersistMoniker_IsD
>  static HRESULT WINAPI PersistMoniker_Load(IPersistMoniker *iface, BOOL
fFullyAvailable,
>          IMoniker *pimkName, LPBC pibc, DWORD grfMode)
>  {
> -    FIXME("(%p)->(%x %p %p %08lx)\n", iface, fFullyAvailable, pimkName,
pibc, grfMode);
> +    PERSISTMON_THIS
> +    FIXME("(%p)->(%x %p %p %08lx)\n", This, fFullyAvailable, pimkName,
pibc, grfMode);
>      return S_OK;
>  }


This code looks weird. It should still look like C code,
even if we use a macro. I would suggest something like this:

static HRESULT WINAPI PersistMoniker_Load(IPersistMoniker *iface, BOOL
fFullyAvailable,
        IMoniker *pimkName, LPBC pibc, DWORD grfMode)
{
    HTMLDocument *This = PERSISTMON_THIS(iface);

    FIXME("(%p)->(%x %p %p %08lx)\n", This, fFullyAvailable, pimkName, pibc,
grfMode);
    return S_OK;
}

It's a bit more verbose, but a lot more readable.

-- 
Dimi Paun <dimi at lattica.com>
Lattica, Inc.




More information about the wine-devel mailing list