tgjones / HlslTools

A Visual Studio extension that provides enhanced support for editing High Level Shading Language (HLSL) files
http://timjones.io/blog/archive/2016/04/25/hlsl-tools-for-visual-studio-v1.0-released
Other
562 stars 97 forks source link

= symbol not reconized by the auto-indentation #76

Closed Melcx closed 5 years ago

Melcx commented 7 years ago

Hi,

First, thanks for this fantastic plugin !

Then here is my (little) problem : the '=' symbol seem to not be recognized by the auto-indentation as a binary operator. I would like to auto-indent this (look at the spaces) : int a =10* b; into this : int a=10*b; (no spaces) But by disabling the spaces between binary operators in the HLSL Tool's options, it gives me this : int a = 10*b; (spaces around '=')

Thanks for advance !

tgjones commented 7 years ago

Thanks for reporting this - I'll aim to fix it in the next version.

tgjones commented 5 years ago

Actually C# is the same as HLSL Tools - it doesn't apply binary operator formatting rules to =. This isn't a common request, so I'm going to close it, but I'd accept a PR that adds an additional formatting option for "Ignore spaces in declaration statements", to match C#'s rule of the same name.