Skip to content

Fix code block formatting in README and question - #19

Closed
brettz9 wants to merge 1 commit into
dawn-gpu:mainfrom
brettz9:patch-1
Closed

brettz9 wants to merge 1 commit into
dawn-gpu:mainfrom
brettz9:patch-1

Conversation

@brettz9

@brettz9 brettz9 commented Sep 25, 2026

Copy link
Copy Markdown

Updated code block formatting in README for clarity.

My real purpose is to ask if you could add Symbol.toStringTag for each of the globals, e.g., GPUCompilationInfo and GPUCompilationMessage, e.g.,

  Object.defineProperty(
      globals.GPUCompilationMessage.prototype, Symbol.toStringTag, {
          get () {
              return 'GPUCompilationMessage';
          }
      }
  );
  Object.defineProperty(
      globals.GPUCompilationInfo.prototype, Symbol.toStringTag, {
          get () {
              return 'GPUCompilationInfo';
          }
      }
  );

For some reason, the string tag is defined only on the constructor, e.g., globals.GPUCompilationMessage, not on its prototype, so objects don't get that.

I don't know if this is something that can be fixed in C source, or whether symbols need to be added in JavaScript.

My interest is to allow structured cloning of these objects, and that requires detection of their type.

Thanks!

Updated code block formatting in README for clarity.
@dj2

dj2 commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

The code change doesn't seem to do anything when viewing the rendered page, so I don't think we need to submit it.

For the second part, please submit a feature request at https://crbug.com/dawn

@dj2 dj2 closed this Sep 30, 2026
@brettz9

brettz9 commented Oct 2, 2026

Copy link
Copy Markdown
Author

With the issue now fixed (per https://issues.chromium.org/issues/567785960 ), can I ask when your next update might be that would include the fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants