Fsharp: VS automatic brace completion support

Created on 23 Jun 2017  Â·  5Comments  Â·  Source: dotnet/fsharp

I think, it should be clear what this is all about. Probably everybody knows and rememers that already.

For now there is no automatic closing of: () , [] , {} , "" , ''. And "Automatic brace completion" setting in "Options → Text Editor → F# → General" is not available to turn on/off.

Repro steps

  1. Type ( , [ , { , " or ' in VS F# text editor.

  2. See that there is no corresponding completion pair ) , ] , } , " or ' respectively.

Expected behavior

Get () , [] , {} , "" , '' typed with a cursor between braces/quotes by manual typing only ( , [ , { , " , ' respectively (however single quote ' is allowed in identifiers so, maybe, in such cases it should not be auto-paired). Perhaps it could be also good to have completion for <>, [<>], [||], but as I understand, these cases are more complex (e.g. < should be auto-paired only in case of generic, statically resolved types' and Type providers' parameters list) and used less often (so having these completions is less important, probably).

Actual behavior

No automatic completion of ) , ] , } , " , ' for ( , [ , { , " , ' respectively.

Known workarounds

Type both open and closing braces/quotes manually.

Related information

  • Visual Studio 2017 Community
  • Visual F# Tools (Nightly) v15.4.1.17062102
Area-IDE Language Service Feature Request

Most helpful comment

This is implemented.

All 5 comments

@cartermp shouldn't be too difficult to add right?

I am really missing it

Just found this issue, we are working on it: https://github.com/Microsoft/visualfsharp/pull/4049

This is implemented.

Best issue closure I've seen all week!

Was this page helpful?
0 / 5 - 0 ratings