@yuebai008/cli
Version:
Command line interface for rapid qg-minigame development
1 lines • 20.1 kB
JavaScript
import*as Common from"../../core/common/common.js";import*as Host from"../../core/host/host.js";import*as Platform from"../../core/platform/platform.js";import*as Root from"../../core/root/root.js";import*as SDK from"../../core/sdk/sdk.js";import*as Bindings from"../bindings/bindings.js";import*as Formatter from"../formatter/formatter.js";import*as Workspace from"../workspace/workspace.js";import*as SourceMapScopes from"../source_map_scopes/source_map_scopes.js";import{assertNotNullOrUndefined}from"../../core/platform/platform.js";let breakpointManagerInstance;const INITIAL_RESTORE_BREAKPOINT_COUNT=100;export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper{storage=new Storage;#e;targetManager;debuggerWorkspaceBinding;#t=new Map;#o=new Map;#r=new Map;#i=[];constructor(e,t,o,r){super(),this.#e=t,this.targetManager=e,this.debuggerWorkspaceBinding=o,Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.SET_ALL_BREAKPOINTS_EAGERLY)&&(this.storage.mute(),this.#s(r??100),this.storage.unmute()),this.#e.addEventListener(Workspace.Workspace.Events.UISourceCodeAdded,this.uiSourceCodeAdded,this),this.#e.addEventListener(Workspace.Workspace.Events.UISourceCodeRemoved,this.uiSourceCodeRemoved,this),this.#e.addEventListener(Workspace.Workspace.Events.ProjectRemoved,this.projectRemoved,this),this.targetManager.observeModels(SDK.DebuggerModel.DebuggerModel,this)}#s(e){let t=this.storage.breakpoints.size-e;for(const e of this.storage.breakpoints.values()){if(t>0){t--;continue}const o=Storage.computeId(e),r=new Breakpoint(this,null,e,"RESTORED");this.#r.set(o,r)}}static instance(e={forceNew:null,targetManager:null,workspace:null,debuggerWorkspaceBinding:null}){const{forceNew:t,targetManager:o,workspace:r,debuggerWorkspaceBinding:i,restoreInitialBreakpointCount:s}=e;if(!breakpointManagerInstance||t){if(!o||!r||!i)throw new Error(`Unable to create settings: targetManager, workspace, and debuggerWorkspaceBinding must be provided: ${(new Error).stack}`);breakpointManagerInstance=new BreakpointManager(o,r,i,s)}return breakpointManagerInstance}modelAdded(e){Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.INSTRUMENTATION_BREAKPOINTS)&&e.setSynchronizeBreakpointsCallback(this.restoreBreakpointsForScript.bind(this))}modelRemoved(e){e.setSynchronizeBreakpointsCallback(null)}addUpdateBindingsCallback(e){this.#i.push(e)}async copyBreakpoints(e,t){const o=t.project().uiSourceCodeForURL(t.url())!==t||this.#e.project(t.project().id())!==t.project(),r=this.storage.breakpointItems(e.url(),e.contentType().name());for(const e of r)o?this.storage.updateBreakpoint({...e,url:t.url(),resourceTypeName:t.contentType().name()}):await this.setBreakpoint(t,e.lineNumber,e.columnNumber,e.condition,e.enabled,e.isLogpoint,"RESTORED")}async restoreBreakpointsForScript(e){if(!Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.INSTRUMENTATION_BREAKPOINTS))return;if(!e.sourceURL)return;const t=await this.getUISourceCodeWithUpdatedBreakpointInfo(e);this.#n(e.sourceURL)&&await this.#a(t);const o=e.debuggerModel,r=await o.sourceMapManager().sourceMapForClientPromise(e);if(r)for(const t of r.sourceURLs())if(this.#n(t)){const r=await this.debuggerWorkspaceBinding.uiSourceCodeForSourceMapSourceURLPromise(o,t,e.isContentScript());await this.#a(r)}const{pluginManager:i}=this.debuggerWorkspaceBinding;if(i){const t=await i.getSourcesForScript(e);if(Array.isArray(t))for(const e of t)if(this.#n(e)){const t=await this.debuggerWorkspaceBinding.uiSourceCodeForDebuggerLanguagePluginSourceURLPromise(o,e);assertNotNullOrUndefined(t),await this.#a(t)}}}async getUISourceCodeWithUpdatedBreakpointInfo(e){const t=this.debuggerWorkspaceBinding.uiSourceCodeForScript(e);return assertNotNullOrUndefined(t),await this.#u(t),t}async#u(e){if(this.#i.length>0){const t=[];for(const o of this.#i)t.push(o(e));await Promise.all(t)}}async#a(e){this.restoreBreakpoints(e);const t=this.#r.values(),o=Array.from(t).filter((t=>t.uiSourceCodes.has(e)));await Promise.all(o.map((e=>e.updateBreakpoint())))}#n(e){return this.storage.breakpointItems(e).length>0}static getScriptForInlineUiSourceCode(e){const t=Bindings.DefaultScriptMapping.DefaultScriptMapping.scriptForUISourceCode(e);return t&&t.isInlineScript()&&!t.hasSourceURL?t:null}static breakpointLocationFromUiLocation(e){const t=e.uiSourceCode,o=BreakpointManager.getScriptForInlineUiSourceCode(t),{lineNumber:r,columnNumber:i}=o?o.relativeLocationToRawLocation(e):e;return{lineNumber:r,columnNumber:i}}static uiLocationFromBreakpointLocation(e,t,o){const r=BreakpointManager.getScriptForInlineUiSourceCode(e);return r&&({lineNumber:t,columnNumber:o}=r.rawLocationToRelativeLocation({lineNumber:t,columnNumber:o})),e.uiLocation(t,o)}static isValidPositionInScript(e,t,o){return!o||!(e<o.lineOffset||e>o.endLine)&&(!(e===o.lineOffset&&t&&t<o.columnOffset)&&!(e===o.endLine&&(!t||t>=o.endColumn)))}restoreBreakpoints(e){const t=BreakpointManager.getScriptForInlineUiSourceCode(e),o=t?.sourceURL??e.url();if(!o)return;const r=e.contentType();this.storage.mute();const i=this.storage.breakpointItems(o,r.name());for(const o of i){const{lineNumber:r,columnNumber:i}=o;BreakpointManager.isValidPositionInScript(r,i,t)&&this.innerSetBreakpoint(e,r,i,o.condition,o.enabled,o.isLogpoint,"RESTORED")}this.storage.unmute()}uiSourceCodeAdded(e){const t=e.data;this.restoreBreakpoints(t)}uiSourceCodeRemoved(e){const t=e.data;this.removeUISourceCode(t)}projectRemoved(e){const t=e.data;for(const e of t.uiSourceCodes())this.removeUISourceCode(e)}removeUISourceCode(e){this.#d(e).forEach((t=>t.removeUISourceCode(e)))}async setBreakpoint(e,t,o,r,i,s,n){const a=this.#e.findCompatibleUISourceCodes(e);let u;for(const d of a){const a=new Workspace.UISourceCode.UILocation(d,t,o),c=await this.debuggerWorkspaceBinding.normalizeUILocation(a),l=BreakpointManager.breakpointLocationFromUiLocation(c),p=this.innerSetBreakpoint(c.uiSourceCode,l.lineNumber,l.columnNumber,r,i,s,n);e===d&&(c.id()!==a.id()&&Common.Revealer.reveal(c),u=p)}return console.assert(void 0!==u,"The passed uiSourceCode is expected to be a valid uiSourceCode"),u}innerSetBreakpoint(e,t,o,r,i,s,n){const a={url:BreakpointManager.getScriptForInlineUiSourceCode(e)?.sourceURL??e.url(),resourceTypeName:e.contentType().name(),lineNumber:t,columnNumber:o,condition:r,enabled:i,isLogpoint:s},u=Storage.computeId(a);let d=this.#r.get(u);return d?(d.updateState(a),d.addUISourceCode(e),d.updateBreakpoint(),d):(d=new Breakpoint(this,e,a,n),this.#r.set(u,d),d)}findBreakpoint(e){const t=this.#o.get(e.uiSourceCode);return t&&t.get(e.id())||null}addHomeUISourceCode(e,t){let o=this.#t.get(e);o||(o=new Set,this.#t.set(e,o)),o.add(t)}removeHomeUISourceCode(e,t){const o=this.#t.get(e);o&&(o.delete(t),0===o.size&&this.#t.delete(e))}async possibleBreakpoints(e,t){const o=await this.debuggerWorkspaceBinding.uiLocationRangeToRawLocationRanges(e,t),r=(await Promise.all(o.map((({start:e,end:t})=>e.debuggerModel.getPossibleBreakpoints(e,t,!1))))).flat(),i=new Map;return await Promise.all(r.map((async o=>{const r=await this.debuggerWorkspaceBinding.rawLocationToUILocation(o);null!==r&&r.uiSourceCode===e&&t.containsLocation(r.lineNumber,r.columnNumber??0)&&i.set(r.id(),r)}))),[...i.values()]}breakpointLocationsForUISourceCode(e){const t=this.#o.get(e);return t?Array.from(t.values()):[]}#d(e){return this.breakpointLocationsForUISourceCode(e).map((e=>e.breakpoint)).concat(Array.from(this.#t.get(e)??[]))}allBreakpointLocations(){const e=[];for(const t of this.#o.values())e.push(...t.values());return e}removeBreakpoint(e,t){const o=e.breakpointStorageId();t&&this.storage.removeBreakpoint(o),this.#r.delete(o)}uiLocationAdded(e,t){let o=this.#o.get(t.uiSourceCode);o||(o=new Map,this.#o.set(t.uiSourceCode,o));const r=new BreakpointLocation(e,t);o.set(t.id(),r),this.dispatchEventToListeners(Events.BreakpointAdded,r)}uiLocationRemoved(e,t){const o=this.#o.get(t.uiSourceCode);if(!o)return;const r=o.get(t.id())||null;r&&(o.delete(t.id()),0===o.size&&this.#o.delete(t.uiSourceCode),this.dispatchEventToListeners(Events.BreakpointRemoved,r))}supportsConditionalBreakpoints(e){return this.debuggerWorkspaceBinding.supportsConditionalBreakpoints(e)}}export var Events;!function(e){e.BreakpointAdded="breakpoint-added",e.BreakpointRemoved="breakpoint-removed"}(Events||(Events={}));export class Breakpoint{breakpointManager;#c=new Set;uiSourceCodes=new Set;#l;#p;isRemoved=!1;#g=null;#h=new Map;constructor(e,t,o,r){this.breakpointManager=e,this.#p=r,this.updateState(o),t?(console.assert(t.contentType().name()===o.resourceTypeName),this.addUISourceCode(t)):this.#m(o),this.breakpointManager.targetManager.observeModels(SDK.DebuggerModel.DebuggerModel,this)}#m(e){e.resolvedState?this.#g=e.resolvedState.map((e=>({...e,scriptHash:""}))):e.resourceTypeName===Common.ResourceType.resourceTypes.Script.name()&&(this.#g=[{url:e.url,lineNumber:e.lineNumber,columnNumber:e.columnNumber,scriptHash:"",condition:this.backendCondition()}])}getLastResolvedState(){return this.#g}updateLastResolvedState(e){if(this.#g=e,!Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.SET_ALL_BREAKPOINTS_EAGERLY))return;let t;e&&(t=e.map((e=>({url:e.url,lineNumber:e.lineNumber,columnNumber:e.columnNumber,condition:e.condition})))),resolvedStateEqual(this.#l.resolvedState,t)||(this.#l={...this.#l,resolvedState:t},this.breakpointManager.storage.updateBreakpoint(this.#l))}get origin(){return this.#p}async refreshInDebugger(){if(!this.isRemoved){const e=Array.from(this.#h.values());await Promise.all(e.map((async e=>(await e.resetBreakpoint(),this.#b(e)))))}}modelAdded(e){const t=this.breakpointManager.debuggerWorkspaceBinding,o=new ModelBreakpoint(e,this,t);this.#h.set(e,o),this.#b(o),e.addEventListener(SDK.DebuggerModel.Events.DebuggerWasEnabled,this.#k,this),e.addEventListener(SDK.DebuggerModel.Events.DebuggerWasDisabled,this.#S,this),e.addEventListener(SDK.DebuggerModel.Events.ScriptSourceWasEdited,this.#f,this)}modelRemoved(e){const t=this.#h.get(e);t?.cleanUpAfterDebuggerIsGone(),this.#h.delete(e),this.#v(e)}#v(e){e.removeEventListener(SDK.DebuggerModel.Events.DebuggerWasEnabled,this.#k,this),e.removeEventListener(SDK.DebuggerModel.Events.DebuggerWasDisabled,this.#S,this),e.removeEventListener(SDK.DebuggerModel.Events.ScriptSourceWasEdited,this.#f,this)}#k(e){const t=e.data,o=this.#h.get(t);o&&this.#b(o)}#S(e){const t=e.data,o=this.#h.get(t);o?.cleanUpAfterDebuggerIsGone()}async#f(e){const{source:t,data:{script:o,status:r}}=e;if("Ok"!==r)return;console.assert(t instanceof SDK.DebuggerModel.DebuggerModel);const i=this.#h.get(t);i?.wasSetIn(o.scriptId)&&(await i.resetBreakpoint(),this.#b(i))}modelBreakpoint(e){return this.#h.get(e)}addUISourceCode(e){this.uiSourceCodes.has(e)||(this.uiSourceCodes.add(e),this.breakpointManager.addHomeUISourceCode(e,this),this.bound()||this.breakpointManager.uiLocationAdded(this,this.defaultUILocation(e)))}clearUISourceCodes(){this.bound()||this.removeAllUnboundLocations();for(const e of this.uiSourceCodes)this.removeUISourceCode(e)}removeUISourceCode(e){if(this.uiSourceCodes.has(e)&&(this.uiSourceCodes.delete(e),this.breakpointManager.removeHomeUISourceCode(e,this),this.bound()||this.breakpointManager.uiLocationRemoved(this,this.defaultUILocation(e))),this.bound()){for(const t of this.#c)t.uiSourceCode===e&&(this.#c.delete(t),this.breakpointManager.uiLocationRemoved(this,t));this.bound()||this.isRemoved||this.addAllUnboundLocations()}}url(){return this.#l.url}lineNumber(){return this.#l.lineNumber}columnNumber(){return this.#l.columnNumber}uiLocationAdded(e){this.isRemoved||(this.bound()||this.removeAllUnboundLocations(),this.#c.add(e),this.breakpointManager.uiLocationAdded(this,e))}uiLocationRemoved(e){this.#c.has(e)&&(this.#c.delete(e),this.breakpointManager.uiLocationRemoved(this,e),this.bound()||this.isRemoved||this.addAllUnboundLocations())}enabled(){return this.#l.enabled}bound(){return 0!==this.#c.size}hasBoundScript(){for(const e of this.uiSourceCodes)if(e.project().type()===Workspace.Workspace.projectTypes.Network)return!0;return!1}setEnabled(e){this.updateState({...this.#l,enabled:e})}condition(){return this.#l.condition}backendCondition(e){const t=this.condition();if(""===t)return"";const o=e=>{let t=SDK.DebuggerModel.COND_BREAKPOINT_SOURCE_URL;return this.isLogpoint()&&(e=`${LOGPOINT_PREFIX}${e}${LOGPOINT_SUFFIX}`,t=SDK.DebuggerModel.LOGPOINT_SOURCE_URL),`${e}\n\n//# sourceURL=${t}`};return Root.Runtime.experiments.isEnabled("evaluateExpressionsWithSourceMaps")&&e?SourceMapScopes.NamesResolver.allVariablesAtPosition(e).then((e=>Formatter.FormatterWorkerPool.formatterWorkerPool().javaScriptSubstitute(t,e))).then((e=>o(e)),(()=>o(t))):o(t)}setCondition(e,t){this.updateState({...this.#l,condition:e,isLogpoint:t})}isLogpoint(){return this.#l.isLogpoint}get storageState(){return this.#l}updateState(e){Platform.DCHECK((()=>!this.#l||this.#l.url===e.url&&this.#l.lineNumber===e.lineNumber&&this.#l.columnNumber===e.columnNumber)),this.#l?.enabled===e.enabled&&this.#l?.condition===e.condition&&this.#l?.isLogpoint===e.isLogpoint||(this.#l=e,this.breakpointManager.storage.updateBreakpoint(this.#l),this.updateBreakpoint())}async updateBreakpoint(){return this.bound()||(this.removeAllUnboundLocations(),this.isRemoved||this.addAllUnboundLocations()),this.#I()}async remove(e){if(this.getIsRemoved())return;this.isRemoved=!0;const t=!e;for(const e of this.#h.keys())this.#v(e);await this.#I(),this.breakpointManager.removeBreakpoint(this,t),this.breakpointManager.targetManager.unobserveModels(SDK.DebuggerModel.DebuggerModel,this),this.clearUISourceCodes()}breakpointStorageId(){return Storage.computeId(this.#l)}defaultUILocation(e){return BreakpointManager.uiLocationFromBreakpointLocation(e,this.#l.lineNumber,this.#l.columnNumber)}removeAllUnboundLocations(){for(const e of this.uiSourceCodes)this.breakpointManager.uiLocationRemoved(this,this.defaultUILocation(e))}addAllUnboundLocations(){for(const e of this.uiSourceCodes)this.breakpointManager.uiLocationAdded(this,this.defaultUILocation(e))}getUiSourceCodes(){return this.uiSourceCodes}getIsRemoved(){return this.isRemoved}async#I(){await Promise.all(Array.from(this.#h.values()).map((e=>this.#b(e))))}async#b(e){const t=await e.scheduleUpdateInDebugger();"ERROR_BACKEND"===t?await this.remove(!0):"ERROR_BREAKPOINT_CLASH"===t&&await this.remove(!1)}}export class ModelBreakpoint{#L;#B;#R;#N=new Bindings.LiveLocation.LiveLocationPool;#c=new Map;#C=new Common.Mutex.Mutex;#M=!1;#U=null;#E=[];#w=new Set;constructor(e,t,o){this.#L=e,this.#B=t,this.#R=o}get currentState(){return this.#U}resetLocations(){for(const e of this.#c.values())this.#B.uiLocationRemoved(e);this.#c.clear(),this.#N.disposeAll(),this.#w.clear()}async scheduleUpdateInDebugger(){if(!this.#L.debuggerEnabled())return"OK";const e=await this.#C.acquire();let t="PENDING";for(;"PENDING"===t;)t=await this.#D();return e(),t}scriptDiverged(){for(const e of this.#B.getUiSourceCodes()){const t=this.#R.scriptFile(e,this.#L);if(t&&t.hasDivergedFromVM())return!0}return!1}async#D(){if(this.#L.target().isDisposed())return this.cleanUpAfterDebuggerIsGone(),"OK";const e=this.#B.lineNumber(),t=this.#B.columnNumber(),o=this.#B.backendCondition();let r=null;if(!this.#B.getIsRemoved()&&this.#B.enabled()&&!this.scriptDiverged()){let i=[];for(const o of this.#B.getUiSourceCodes()){const{lineNumber:r,columnNumber:s}=BreakpointManager.uiLocationFromBreakpointLocation(o,e,t);if(i=(await Bindings.DebuggerWorkspaceBinding.DebuggerWorkspaceBinding.instance().uiLocationToRawLocations(o,r,s)).filter((e=>e.debuggerModel===this.#L)),i.length)break}if(i.length&&i.every((e=>e.script()))){const e=await Promise.all(i.map((async e=>{const t=e.script(),o=await this.#B.backendCondition(e);return{url:t.sourceURL,scriptHash:t.hash,lineNumber:e.lineNumber,columnNumber:e.columnNumber,condition:o}})));r=e.slice(0)}else if(!Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.INSTRUMENTATION_BREAKPOINTS)){const i=this.#B.getLastResolvedState();if(i)r=i.map((e=>({...e,condition:o})));else{r=[{url:this.#B.url(),scriptHash:"",lineNumber:e,columnNumber:t,condition:o}]}}}const i=this.#E.length;if(i&&Breakpoint.State.equals(r,this.#U))return"OK";if(this.#B.updateLastResolvedState(r),i)return await this.resetBreakpoint(),"PENDING";if(!r)return"OK";const{breakpointIds:s,locations:n,serverError:a}=await this.#O(r),u=a&&this.#L.debuggerEnabled()&&!this.#L.isReadyToPause();if(!s.length&&u)return"PENDING";if(this.#U=r,this.#M)return this.#M=!1,"OK";if(!s.length)return"ERROR_BACKEND";this.#E=s,this.#E.forEach((e=>this.#L.addBreakpointListener(e,this.breakpointResolved,this)));return(await Promise.all(n.map((e=>this.addResolvedLocation(e))))).includes("ERROR")?"ERROR_BREAKPOINT_CLASH":"OK"}async#O(e){const t=await Promise.all(e.map((e=>e.url?this.#L.setBreakpointByURL(e.url,e.lineNumber,e.columnNumber,e.condition):this.#L.setBreakpointInAnonymousScript(e.scriptHash,e.lineNumber,e.columnNumber,e.condition)))),o=[];let r=[],i=!1;for(const e of t)e.breakpointId?(o.push(e.breakpointId),r=r.concat(e.locations)):i=!0;return{breakpointIds:o,locations:r,serverError:i}}async resetBreakpoint(){this.#E.length&&(this.resetLocations(),await Promise.all(this.#E.map((e=>this.#L.removeBreakpoint(e)))),this.didRemoveFromDebugger(),this.#U=null)}didRemoveFromDebugger(){this.#M?this.#M=!1:(this.resetLocations(),this.#E.forEach((e=>this.#L.removeBreakpointListener(e,this.breakpointResolved,this))),this.#E=[])}async breakpointResolved({data:e}){"ERROR"===await this.addResolvedLocation(e)&&await this.#B.remove(!1)}async locationUpdated(e){const t=this.#c.get(e),o=await e.uiLocation();t&&this.#B.uiLocationRemoved(t),o?(this.#c.set(e,o),this.#B.uiLocationAdded(o)):this.#c.delete(e)}async addResolvedLocation(e){this.#w.add(e.scriptId);const t=await this.#R.rawLocationToUILocation(e);if(!t)return"OK";const o=this.#B.breakpointManager.findBreakpoint(t);return o&&o.breakpoint!==this.#B?"ERROR":(await this.#R.createLiveLocation(e,this.locationUpdated.bind(this),this.#N),"OK")}cleanUpAfterDebuggerIsGone(){this.#M=!0,this.resetLocations(),this.#U=null,this.#E.length&&this.didRemoveFromDebugger()}wasSetIn(e){return this.#w.has(e)}}!function(e){let t;!function(e){e.equals=function(e,t){if(e===t)return!0;if(!e||!t)return!1;if(e.length!==t.length)return!1;for(let o=0;o<e.length;o++){const r=e[o],i=t[o];if(r.url!==i.url)return!1;if(r.scriptHash!==i.scriptHash)return!1;if(r.lineNumber!==i.lineNumber)return!1;if(r.columnNumber!==i.columnNumber)return!1;if(r.condition!==i.condition)return!1}return!0}}(t=e.State||(e.State={}))}(Breakpoint||(Breakpoint={}));class Storage{setting;breakpoints;#F;constructor(){this.setting=Common.Settings.Settings.instance().createLocalSetting("breakpoints",[]),this.breakpoints=new Map,this.#F=!1;for(const e of this.setting.get())this.breakpoints.set(Storage.computeId(e),e);Host.userMetrics.breakpointsRestoredFromStorage(this.breakpoints.size)}mute(){this.#F=!0}unmute(){this.#F=!1}breakpointItems(e,t){const o=[];for(const r of this.breakpoints.values())r.url===e&&(r.resourceTypeName!==t&&void 0!==t||o.push(r));return o}updateBreakpoint(e){if(this.#F)return;const t=Storage.computeId(e);t&&(this.breakpoints.delete(t),this.breakpoints.set(t,e),this.save())}removeBreakpoint(e){this.#F||(this.breakpoints.delete(e),this.save())}save(){this.setting.set(Array.from(this.breakpoints.values()))}static computeId({url:e,resourceTypeName:t,lineNumber:o,columnNumber:r}){if(!e)return"";let i=`${e}:${t}:${o}`;return void 0!==r&&(i+=`:${r}`),i}}function resolvedStateEqual(e,t){if(e===t)return!0;if(!e||!t||e.length!==t.length)return!1;for(let o=0;o<e.length;o++){const r=e[o],i=t[o];if(r.url!==i.url||r.lineNumber!==i.lineNumber||r.columnNumber!==i.columnNumber||r.condition!==i.condition)return!1}return!0}export const EMPTY_BREAKPOINT_CONDITION="";export const NEVER_PAUSE_HERE_CONDITION="false";export class BreakpointLocation{breakpoint;uiLocation;constructor(e,t){this.breakpoint=e,this.uiLocation=t}}const LOGPOINT_PREFIX="/** DEVTOOLS_LOGPOINT */ console.log(",LOGPOINT_SUFFIX=")";