diff options
| author | Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> | 2021-05-02 23:07:03 +0300 |
|---|---|---|
| committer | Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> | 2021-05-02 23:30:32 +0300 |
| commit | b8f8ffa967cf9078b9d369ed6408d2466e9644eb (patch) | |
| tree | 8ed11870d327a566fa4639d337205be8a603bb2e | |
| parent | d0d305b48f55a911333043d3edc26cf76468e26f (diff) | |
mu-sexp: make lists printable
And some typo fixes
| -rw-r--r-- | lib/utils/mu-sexp.hh | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/utils/mu-sexp.hh b/lib/utils/mu-sexp.hh index adc2cf3..43cf1f4 100644 --- a/lib/utils/mu-sexp.hh +++ b/lib/utils/mu-sexp.hh @@ -1,5 +1,5 @@ /* -** Copyright (C) 2020 Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> +** Copyright (C) 2021 Dirk-Jan C. Binnema <djcb@djcbsoftware.nl> ** ** This program is free software; you can redistribute it and/or modify it ** under the terms of the GNU General Public License as published by the @@ -207,7 +207,7 @@ struct Sexp { } /** - * Construct a properrty list sexp from a List + * Construct a property list sexp from a List * * @param name the property name; must start wtth ':' * @param sexp a Sexp @@ -352,6 +352,14 @@ operator<<(std::ostream& os, const Sexp& sexp) return os; } +static inline std::ostream& +operator<<(std::ostream& os, const Sexp::List& sexp) +{ + os << Sexp::make_list(Sexp::List(sexp)); + return os; +} + + } // Mu #endif /* MU_SEXP_HH__ */ |
