Closed
Description
I filed #6045 before I realized that you have to make useless traits to implement methods on primitives. However, we already use lang items to identify core::char
as the "canonical" char module, yes? Is it possible then to allow impls directly upon char
from within core::char
, since we know that it won't have anonymous impls anywhere else? This is what I'd like to be able to do:
impl char {
fn anything() { ... }
}
without having to make a useless trait first:
trait UselessCharTrait {
fn anything();
}
impl UselessCharTrait for char {
fn anything() { ... }
}
This is somewhat more pertinent now that #3048 is WONTFIX.