From 9b575f1c734c052b695ce921fb6412b22c18fdb4 Mon Sep 17 00:00:00 2001 From: Russell Yanofsky Date: Thu, 11 Nov 2021 09:54:21 -0500 Subject: Improve fs::PathToString documentation --- doc/developer-notes.md | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'doc/developer-notes.md') diff --git a/doc/developer-notes.md b/doc/developer-notes.md index 7ff1d36442..1888897856 100644 --- a/doc/developer-notes.md +++ b/doc/developer-notes.md @@ -1254,6 +1254,12 @@ A few guidelines for introducing and reviewing new RPC interfaces: - *Rationale*: User-facing consistency. +- Use `fs::path::u8string()` and `fs::u8path()` functions when converting path + to JSON strings, not `fs::PathToString` and `fs::PathFromString` + + - *Rationale*: JSON strings are Unicode strings, not byte strings, and + RFC8259 requires JSON to be encoded as UTF-8. + Internal interface guidelines ----------------------------- -- cgit v1.2.3