Commit b33a88d8 authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz
Browse files

escape_rfc4180: document relation with std::quote

* spot/misc/escape.hh: Here.
parent 1edb47ad
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2012, 2013, 2015 Laboratoire de Recherche et
// Copyright (C) 2011-2013, 2015, 2018 Laboratoire de Recherche et
// Developpement de l'Epita (LRDE).
// Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
......@@ -35,6 +35,15 @@ namespace spot
///
/// In CSV files, as defined by RFC4180, double-quoted string that
/// contain double-quotes should simply duplicate those quotes.
///
/// Note that in C++14,
/// ```
/// os << std::quoted(str, '"', '"');
/// ```
/// outputs the same result as
/// ```
/// escape_rfc4180(os << '"', str) << '"';
/// ```
SPOT_API std::ostream&
escape_rfc4180(std::ostream& os, const std::string& str);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment