Re: [Mesa-dev] [PATCH] radeonsi: set indent_size in .editorconfig

2018-02-06 Thread Grazvydas Ignotas
On Tue, Feb 6, 2018 at 1:37 PM, Eric Engestrom
 wrote:
> On Sunday, 2018-02-04 00:19:33 +0200, Grazvydas Ignotas wrote:
>> At least with vim, this is needed to actually get tab instead of
>> 3 spaces after hitting the tab key.
>
> Are you sure?

For my copy of vim (7.4.1689) yes. Not sure what version of
editorconfig plugin I have, can't find a version anywhere.

I don't know about other editors, src/amd/ has the same settings and
nobody complained or changed them.

>
> The doc [1] says:
>
>> indent_size:
>> [...]
>> When set to tab, the value of tab_width (if specified) will be used.
>
>> tab_width:
>> a whole number defining the number of columns used to represent a tab
>> character. This defaults to the value of indent_size and doesn't
>> usually need to be specified.
>
> This sounds to me like `indent_size=tab` means that you want to indent
> with `tab_width` spaces?

That's not how I read it, to me it's the user's preferred tab width
that they configured outside of mesa.

GraÅžvydas
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH] radeonsi: set indent_size in .editorconfig

2018-02-06 Thread Eric Engestrom
On Sunday, 2018-02-04 00:19:33 +0200, Grazvydas Ignotas wrote:
> At least with vim, this is needed to actually get tab instead of
> 3 spaces after hitting the tab key.

Are you sure?

The doc [1] says:

> indent_size:
> [...]
> When set to tab, the value of tab_width (if specified) will be used.

> tab_width:
> a whole number defining the number of columns used to represent a tab
> character. This defaults to the value of indent_size and doesn't
> usually need to be specified.

This sounds to me like `indent_size=tab` means that you want to indent
with `tab_width` spaces?

[1] http://editorconfig.org/#supported-properties

> ---
>  src/gallium/drivers/radeonsi/.editorconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/src/gallium/drivers/radeonsi/.editorconfig 
> b/src/gallium/drivers/radeonsi/.editorconfig
> index cc8e11f..21a3c7d 100644
> --- a/src/gallium/drivers/radeonsi/.editorconfig
> +++ b/src/gallium/drivers/radeonsi/.editorconfig
> @@ -1,2 +1,3 @@
>  [*.{c,h}]
>  indent_style = tab
> +indent_size = tab
> -- 
> 2.7.4
> 
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev