mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-11 14:14:36 +08:00
The `SourceMapNamesResolver.js` was written before async-await became a thing and the callback heavy code is fairly difficult to read and maintain. So as part of removing unnecessary calls to `Promise.resolve()` we also asyncified the whole file, and streamlined the implementations of the various functions. In particular the following changes were performed: - Asyncify `scopeIdentifiers()`. - Asyncify `resolveScope()`. - Merge `resolveExpressionAsync()` into `resolveExpression()` and asyncify the latter. - Asyncify `allVariablesInCallFrame()`. - Asyncify `resolveThisObject()`. Along the way we also migrated to modern syntax were possible and feasible. Bug: chromium:1161501 Change-Id: I00d986e512ce3e73cbb1fb7e33c5716ff4288e11 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2607286 Auto-Submit: Benedikt Meurer <bmeurer@chromium.org> Commit-Queue: Yang Guo <yangguo@chromium.org> Reviewed-by: Yang Guo <yangguo@chromium.org>