From 8609cc98bad6926d7ca94f10112b315d5d820ee0 Mon Sep 17 00:00:00 2001 From: Peter LaFosse Date: Mon, 4 Nov 2024 15:01:57 -0500 Subject: Fix opening/closing braces in PseudoRust --- lang/rust/pseudorust.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lang/rust') diff --git a/lang/rust/pseudorust.cpp b/lang/rust/pseudorust.cpp index d12b8e32..265d3688 100644 --- a/lang/rust/pseudorust.cpp +++ b/lang/rust/pseudorust.cpp @@ -37,6 +37,7 @@ void PseudoRustFunction::BeginLines(const HighLevelILInstruction& instr, HighLev if (instr.exprIndex == m_highLevelIL->GetRootExpr().exprIndex) { // At top level, add braces around the entire function + tokens.PrependCollapseIndicator(); tokens.AppendOpenBrace(); tokens.NewLine(); tokens.IncreaseIndent(); @@ -51,6 +52,7 @@ void PseudoRustFunction::EndLines(const HighLevelILInstruction& instr, HighLevel // At top level, add braces around the entire function tokens.NewLine(); tokens.DecreaseIndent(); + tokens.PrependCollapseIndicator(); tokens.AppendCloseBrace(); } } -- cgit v1.3.1