aBothe / Mono-D

D Add-In for MonoDevelop
http://wiki.dlang.org/Mono-D
Other
113 stars 26 forks source link

strange indentation bug when pasting code #567

Open extrawurst opened 9 years ago

extrawurst commented 9 years ago

let us cut out the marked code... image

and insert it above... image

..WAT

aBothe commented 9 years ago

and of course no sample code to try it on my own :wink: Just c&p'd some code and couldn't find any problems.

extrawurst commented 9 years ago

yeah guess what in contrast to most of my other issue reports there is no code attached cause it happens just in that file of a closed source project...

aBothe commented 9 years ago

I've attempted now several things with pasting

doThis("asd");

if(das)
{
    foo();
}
else if(1)
{
    fooz("");
}
else if(2)
{
    fooy();
}

from indented into other indented code parts..no luck. Can you reproduce this issue instead?

etcimon commented 9 years ago

Looks similar to the indentation issue I have been having, where the default indent goes way up at the bottom of files with 2000+ LOC mostly. Forces me to move code in separate files and use template mixins.

extrawurst commented 9 years ago

Like I said, I can reproduce it everytime in the case above, but I cannot supply the code to do so and simple repros like yours did not work for me either. one note though: there seems to be some indent counter that gets totally fucked up in those scopes. With every enter I press the indent gets increased. even if i delete the whole lines that got added this way the next enter jumps right to zillions indent to the right...