Menu

#19 Typing an opening brace unindents an indented line

v2.0
open
nobody
None
5
2011-06-07
2011-06-07
XP1
No

Typing an opening brace unindents an indented line

For example, within a block, typing a control structure, such as "while (true)", pressing Enter key to get a new indented line, and then typing the opening brace "{" will remove the indents on the current line.

I would imagine that the fix in pseudo-code logic would look like this:
if typed "{", look at previous line for number of indents, and if contains indents and number of indents > 0, do not trim indents;

D-IDE 2.0.4171

Discussion