macro interface NameBase,[Method]
{
common
local done
done equ
match Name:Base,NameBase \{ interface2 Name, Base, Method
done equ yes \}
match ,done \{ interface2 NameBase, ,Method \}
}
macro interface2 Name,Base,[Method]
{
common
macro Name#_vftable name_
\{
match any,Base \\{ ; line break must be here
Base#_vftable name_ \\}
forward
name_\#.#Method dd ?
common
\}
virtual at 0
Name#_vftable Name
end virtual
struc Name
\{
match any, fields@struct \\{ fields@struct equ fields@struct,.,Name, \\}
match , fields@struct
\\{
. dd ?
virtual at 0
Name#_vftable .
end virtual
\\}
\}
}
usage:
interface IUnknown,\
QueryInterface,\
AddRef,\
Release
interface ITaskBarList:IUnknown,\
HrInit,\
AddTab,\
DeleteTab,\
ActivateTab,\
SetActiveAlt