Compiler explorer (godbolt.org) is broken again

For support with specific websites

Moderator: trava90

Forum rules
Please always mention the name/domain of the website in question in your topic title.
Please one website per topic thread (to help keep things organized). While behavior on different sites might at first glance seem similar, they are not necessarily caused by the same.

Please try to include any relevant output from the Toolkit Error Console or the Developer Tools Web Console using the following procedure:
  1. Clear any current output
  2. Navigate or refresh the page in question
  3. Copy and paste Errors or seemingly relevant Warnings into a single [ code ] block.
dinosaur
Fanatic
Fanatic
Posts: 165
Joined: 2014-06-03, 09:26
Location: France

Compiler explorer (godbolt.org) is broken again

Unread post by dinosaur » 2024-01-17, 19:23

Greetings,

Compiler explorer is broken and displays a blank page; it did work for a while, after a first breakage and thanks to PM's JS engine updates, but broke again a couple months ago.

The error reported in the Developer Tools Web Console is:

Code: Select all

Error: ReferenceError: WeakRef is not defined
Source File: https://static.ce-cdn.net/vendor.v42.7b1dac2b8162df8eff66.js
Line: 2

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35651
Joined: 2011-08-28, 17:27
Location: Motala, SE

Re: Compiler explorer (godbolt.org) is broken again

Unread post by Moonchild » 2024-01-17, 20:36

Yeah they keep breaking it every time we fix it.

As for WeakRef - it's a strongly discouraged spec; nobody should use it. We do have an open issue to put in a stub for it so these kinds of sites stop breaking on it, but we haven't gotten around to that yet.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakRef wrote:Avoid where possible

Correct use of WeakRef takes careful thought, and it's best avoided if possible. It's also important to avoid relying on any specific behaviors not guaranteed by the specification. When, how, and whether garbage collection occurs is down to the implementation of any given JavaScript engine. Any behavior you observe in one engine may be different in another engine, in another version of the same engine, or even in a slightly different situation with the same version of the same engine. Garbage collection is a hard problem that JavaScript engine implementers are constantly refining and improving their solutions to.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite