[PATCH v3 05/11] vbscript: Store the necessary function and variable info in the script TypeInfo.

Jacek Caban jacek at codeweavers.com
Fri Nov 22 05:42:06 CST 2019


Hi Gabriel,

On 11/18/19 2:29 PM, Gabriel Ivăncescu wrote:
> +    UINT num_vars;
> +    UINT num_funcs;
> +    UINT *func_ids;


It would need a test to be sure, but I think that storing function IDs 
here is not right. The function may change if a new script adds a 
function of the same same. If it should indeed freeze the current state, 
then you'd want the old function to be exposed from ITypeInfo. Why not 
simply store an array of function_t pointers instead?


Also, you could just store a reference to each function via something 
like grab_vbscode(This->functions[i]->code_ctx) instead of introducing 
vbscode_ref_t.


Thanks,

Jacek




More information about the wine-devel mailing list