forked from OSchip/llvm-project
[docs] Fix typo in YamlIO.rst
Patch by Mario Lang! llvm-svn: 259825
This commit is contained in:
parent
c2fab48145
commit
4de5cb8aef
|
@ -456,10 +456,11 @@ looks like:
|
||||||
|
|
||||||
template <>
|
template <>
|
||||||
struct ScalarTraits<MyCustomType> {
|
struct ScalarTraits<MyCustomType> {
|
||||||
static void output(const T &value, void*, llvm::raw_ostream &out) {
|
static void output(const MyCustomType &value, void*,
|
||||||
|
llvm::raw_ostream &out) {
|
||||||
out << value; // do custom formatting here
|
out << value; // do custom formatting here
|
||||||
}
|
}
|
||||||
static StringRef input(StringRef scalar, void*, T &value) {
|
static StringRef input(StringRef scalar, void*, MyCustomType &value) {
|
||||||
// do custom parsing here. Return the empty string on success,
|
// do custom parsing here. Return the empty string on success,
|
||||||
// or an error message on failure.
|
// or an error message on failure.
|
||||||
return StringRef();
|
return StringRef();
|
||||||
|
|
Loading…
Reference in New Issue