New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use debug impl in rendering const eval result #15230
Conversation
@bors r+ |
Use debug impl in rendering const eval result fix #15188
💔 Test failed - checks-actions |
@bors r+ |
☀️ Test successful - checks-actions |
Fwiw, this fails on latest nightly in general. (And on stable my code that spawned this idea also fails on a specific debug impl, though I guess that is to be expected). |
That's bad. I tried to make it working. Will look at it.
I may be able to fix it if I know the problem. You can see why it fails by using the |
Clearly something is going very much wrong here. The problem manifest iwth the following debu impl impl fmt::Debug for TokenSet {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(f, "TokenSet(")?;
let mut first = true;
for kind in 0..SyntaxKind::LAST_TOKEN.to_raw().0 {
// let kind = SyntaxKind::from_raw(rowan::RawSyntaxKind(kind));
// if self.contains(kind) {
// if first {
// first = false;
// } else {
// f.write_str(" | ")?;
// }
// write!(f, "{:?}", kind)?;
// }
}
write!(f, ")")?;
Ok(())
}
} Commenting out the loop makes it pass. Seems like just havin a |
Ah, I'm using a patched std from 1.69, and this |
It seems the only problem was |
fix #15188