-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
315 additions
and
127 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"label": "ethdebug/format/info", | ||
"position": 7, | ||
"link": null | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
sidebar_position: 2 | ||
--- | ||
|
||
import SchemaViewer from "@site/src/components/SchemaViewer"; | ||
|
||
# Schema | ||
|
||
<SchemaViewer | ||
schema={{ id: "schema:ethdebug/format/info" }} | ||
/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
--- | ||
sidebar_position: 1 | ||
--- | ||
|
||
import SchemaViewer from "@site/src/components/SchemaViewer"; | ||
|
||
# Overview | ||
|
||
:::tip[Summary] | ||
|
||
Objects in the **ethdebug/format/info** schema organize debugging data | ||
associated with a particular compilation. This includes lookup tables of | ||
types and pointers by their unique name identifiers, as well as optionally may | ||
include additional information such as complete program listings and compiled | ||
source contents. | ||
|
||
::: | ||
|
||
This schema serves as a root schema, in that it (a) aggregates | ||
all other schemas in this format (either directly or indirectly), and (b) in | ||
that no other schema aggregates it. | ||
|
||
This schema serves as a suitable target for | ||
[JSON Schema bundling](https://json-schema.org/understanding-json-schema/structuring#bundling), | ||
e.g., for implementations that want to reduce complexity around validating | ||
**ethdebug/format** records and don't want to handle reference resolution | ||
across schema YAML files. | ||
|
||
:::warning | ||
|
||
**Note**, however, that "root schema" does not imply "objects in the schema | ||
always contain all relevant debugging data". Due to widespread practice among | ||
EVM language compilers to produce their own structured JSON output, objects in | ||
this schema are not necessarily complete records of debug information. | ||
|
||
Compilers may choose to divide **distinct portions of debugging data** into | ||
**distinct sections of compiler JSON output**. For instance, it likely makes | ||
sense for a compiler to produce debugging data about a particular contract's | ||
bytecode alongside that contract bytecode's other output information. | ||
|
||
At least until tooling accommodates this concern, debugging implementers | ||
**must** be aware that they will likely need to aggregate debugging data from | ||
multiple sections of each supported compiler's own output format. | ||
|
||
::: | ||
|
||
**However**, this schema _is suitable_ for representing a complete and | ||
standalone debugging data record for a particular compilation, but | ||
note the optionality of fields such as `compilation` and `programs`. | ||
Implementations looking to produce such self-contained debugging data objects | ||
should study the structure of these (and any other optional fields) and ensure | ||
that such fields are fully populated. |
2 changes: 1 addition & 1 deletion
2
packages/web/spec/bytecode/_category_.json → packages/web/spec/program/_category_.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"label": "Program contexts", | ||
"position": 6, | ||
"link": null | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
$schema: "https://json-schema.org/draft/2020-12/schema" | ||
$id: "schema:ethdebug/format/info" | ||
|
||
title: ethdebug/format/info | ||
description: | | ||
Objects in this schema organize debugging data relating to a particular | ||
compilation, including **ethdebug/format/type** and | ||
**ethdebug/format/pointer** records by name identifiers. | ||
Objects in this schema **may** contain debugging information about individual | ||
sources, contracts, and compiled bytecodes, to accommodate use cases that | ||
benefit from debugging data being collected together in a single JSON object. | ||
type: object | ||
properties: | ||
types: | ||
title: Types by name | ||
description: | | ||
A collection of types by name identifier. | ||
type: object | ||
additionalProperties: | ||
$ref: "schema:ethdebug/format/type" | ||
|
||
pointers: | ||
title: Pointer templates by name | ||
description: | | ||
A collection of pointer templates by name identifier. | ||
type: object | ||
additionalProperties: | ||
$ref: "schema:ethdebug/format/pointer/template" | ||
|
||
compilation: | ||
$ref: "schema:ethdebug/format/materials/compilation" | ||
|
||
programs: | ||
type: array | ||
items: | ||
$ref: "schema:ethdebug/format/program" | ||
|
||
required: | ||
- types | ||
- pointers | ||
|
||
examples: | ||
- types: {} | ||
pointers: {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -95,5 +95,4 @@ examples: | |
} | ||
} | ||
language: | ||
Solidity | ||
language: Solidity |
Oops, something went wrong.