From 1443298657156107704b5d9fcfa7356ee8fa8789 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Fri, 21 Aug 2020 03:29:53 +0100 Subject: style(tvix): Add missing braces in expressions The previous clang-tidy invocation missed some header files, which has now been rectified. Change-Id: I31547754fbf52f439dc7aeefb08ab90bd50c4156 Reviewed-on: https://cl.tvl.fyi/c/depot/+/1831 Reviewed-by: glittershark Tested-by: BuildkiteCI --- third_party/nix/src/libexpr/parser.hh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'third_party/nix/src/libexpr/parser.hh') diff --git a/third_party/nix/src/libexpr/parser.hh b/third_party/nix/src/libexpr/parser.hh index a79e2cad281f..70b5450b5aa8 100644 --- a/third_party/nix/src/libexpr/parser.hh +++ b/third_party/nix/src/libexpr/parser.hh @@ -79,16 +79,18 @@ static Expr* unescapeStr(SymbolTable& symbols, const char* s, size_t length) { t += '\r'; } else if (c == 't') { t += '\t'; - } else + } else { t += c; + } } else if (c == '\r') { /* Normalise CR and CR/LF into LF. */ t += '\n'; if (*s == '\n') { s++; } /* cr/lf */ - } else + } else { t += c; + } } return new ExprString(symbols.Create(t)); } -- cgit 1.4.1