Web Inspector: support empty entries in source maps. Empty entries should be mapped to the compiled script.
Created attachment 162716 [details] Patch
Comment on attachment 162716 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=162716&action=review > Source/WebCore/inspector/front-end/CompilerScriptMapping.js:44 > + this._originalUISourceCodeForScriptId = {}; Can we reuse this._uiSourceCodeByURL ? > Source/WebCore/inspector/front-end/CompilerScriptMapping.js:87 > var result = []; uiSourceCodes() method is now used for tests only so I would get rid of it altogether. > LayoutTests/http/tests/inspector/compiler-script-mapping.html:142 > InspectorTest.checkUILocation(uiSourceCodeList[0], 4, 4, mapping.rawLocationToUILocation(WebInspector.debuggerModel.createRawLocation(script, 0, 81))); Shouldn't we do some checkUILocation/checkRawLocation for empty entries case?
Comment on attachment 162716 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=162716&action=review >> Source/WebCore/inspector/front-end/CompilerScriptMapping.js:44 >> + this._originalUISourceCodeForScriptId = {}; > > Can we reuse this._uiSourceCodeByURL ? That way inline and anonymous scripts won't be shown correctly. >> Source/WebCore/inspector/front-end/CompilerScriptMapping.js:87 >> var result = []; > > uiSourceCodes() method is now used for tests only so I would get rid of it altogether. done. >> LayoutTests/http/tests/inspector/compiler-script-mapping.html:142 >> InspectorTest.checkUILocation(uiSourceCodeList[0], 4, 4, mapping.rawLocationToUILocation(WebInspector.debuggerModel.createRawLocation(script, 0, 81))); > > Shouldn't we do some checkUILocation/checkRawLocation for empty entries case? Added a check for empty entry.
Committed r128061: <http://trac.webkit.org/changeset/128061>