You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
#29335 causes regression in property name lookup #29428
#29335 adds a oops-wrong-path redirect to getTypeofVariableOrParameterOrProperty that switches to getTypeOfFuncClassEnumModule. This new redirect breaks property resolution in chrome-devtools-frontend:
node_modules/chrome-devtools-frontend/front_end/ui/ContextMenu.js(355,22): error TS2339: Property '_useSoftMenu' does not exist on type 'typeof ContextMenu'.
Here's the associated code:
staticinitialize(){InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.Events.SetUseSoftMenu,setUseSoftMenu);/** * @param {!Common.Event} event */functionsetUseSoftMenu(event){UI.ContextMenu._useSoftMenu=/** @type {boolean} */(event.data);// this line}}```
Ithinkthisisbecausethereare*some*symbolsthathaveValueModuleset,butshouldstillberesolvedwithgetTypeofVariableOrParameterOrProperty.It's a matter of separating those from the ones that #29335 cares about.
Per my commment in the user suite test - the new error is correct. The property access was allowed before because UI.ContextMenu acquired an any type from circular referencing, however now it (correctly) resolves to the namespace side of the type instead and the assignment fails (there is no top level assignment for that property, so it should never have worked).
Activity
weswigham commentedon Jan 17, 2019
Per my commment in the
usersuite test - the new error is correct. The property access was allowed before becauseUI.ContextMenuacquired ananytype from circular referencing, however now it (correctly) resolves to the namespace side of the type instead and the assignment fails (there is no top level assignment for that property, so it should never have worked).