Closed
Description
Example code:
#![feature(associated_consts, static_in_const)]
struct Test;
impl Test {
const CONST: &str = "Hello, world!";
}
Would default CONST
to &'static str
if this actually worked for associated constants. The original RFC decided to not do this, so, it makes sense to document the behaviour.
EDIT: the error message should be better, not the docs.