News for hackers. Stuff that matters.
Re:Rust 1.17 by kbenson on Friday April 28, 2017 @02:59PM (#14222096)
Everything eventually gets represented by a string somewhere. Paths aren't inherently strings, but that's how they are often represented in code. You won't be defining your namespaces as a string in normal usage, but some things do need oto represent source, so why choose a character that makes their jobs harder. There are parallels. It's a downside of using backslash. It's not guaranteed to cause a problem, but the potential is there and waiting for anyone that needs to deal with representing it in language.
Re:Rust 1.17 by iopq on Friday April 28, 2017 @03:45PM (#14222468)
By string, I of course speak of string literals. The only place where this would be an issue is writing Rust compiler error messages. I don't consider that a strong argument for why the path analogy should be broken. Because the path analogy is broken, modules in Rust have strange rules. For example,

    use foo::bar;
doesn't actually use a relative "path" from the current module

you need to use

    use self::foo::bar;
I think this is a confusing default, and it would have never ended up this way if Rust used Windows-path-looking namespace syntax

if you're writing a parser and manipulating actual arrays of bytes, you don't have an issue with backslash, it's just another character to you