some love for std.string

many functions of std.string had no attributes like pure, safe etc.
additionally, many const arguments where not marked as const.
tabs -> whitespace
removed tail whitespace
Doc Examples to unittest docs
Yeah we shouldn't put `@trusted pure @nogc` on an uncontrained template. It will break user-defined type that are `@system` or impure or allocating. Let compiler inference do its job.