[PATCH v5 3/9] jscript: Lookup the named item and keep a ref to it from the associated bytecode.
Jacek Caban
jacek at codeweavers.com
Fri Mar 6 10:04:02 CST 2020
On 06.03.2020 16:19, Gabriel Ivăncescu wrote:
> On 06/03/2020 16:40, Jacek Caban wrote:
>> Hi Gabriel,
>>
>> You could add named item as compile_script argument instead of
>> modifying result of each compile_script call. Also, what about
>> functions created by function constructor in function.c?
>>
>> Thanks,
>> Jacek
>
> Right. I will still have to pass the item, though (i.e. after looking
> it up), due to the compile_script in eval, and look it up in the
> respective two functions.
>
> For the function constructor in function.c, there's no named item, so
> I guess I'll just pass NULL. That's because it's only for native
> functions, if I understand correctly. And those are only in the global
> object.
>
> If my assumption is wrong, any idea how to retrieve the named item there?
No, an of it in JavaScript code is:
func = new Function("return 3;");
There are more examples in api.js.
Jacek
More information about the wine-devel
mailing list