Skip to content

Commit

Permalink
Spec: Allow debug mode to be disabled arbitrarily by the user agent. (#…
Browse files Browse the repository at this point in the history
…90)

Adds logic that allows for debug mode to be disabled even if
enableDebugMode() is called. This addresses issue #57.

As a drive-by, adds an issue for an assert that is currently hit.
  • Loading branch information
alexmturner authored Sep 25, 2023
1 parent 4533e2a commit 2eb3d35
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spec.bs
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,10 @@ enableDebugMode(optional PADebugModeOptions options)</dfn> method steps are:
: [=debug details/key=]
:: |debugKey|

1. Optionally, set |debugDetails| to a new [=debug details=].

Note: This allows the user agent to make debug mode unavailable globally or
just for certain callers.
1. [=map/Set=] |debugScopeMap|[|debugScope|] to |debugDetails|.

Issue: Ensure errors are of an appropriate type, e.g. {{InvalidAccessError}} is
Expand Down Expand Up @@ -435,6 +439,8 @@ To <dfn algorithm export>get a debug details</dfn> given a [=debug scope=]
|debugScope|:
1. Let |debugScopeMap| be the [=debug scope map=].
1. [=Assert=]: |debugScopeMap|[|debugScope|] [=map/exists=].

Issue: This should return a default when the scope does not exist.
1. Return |debugScopeMap|[|debugScope|].

To <dfn algorithm export>mark a debug scope complete</dfn> given a [=debug
Expand Down

0 comments on commit 2eb3d35

Please sign in to comment.