You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is important to notice that the file does end with a newline:
$ od -c demo.swift
0000000 i m p o r t F o u n d a t i o
0000020 n \n\n s t r u c t D e m o {
0000040 \n i n i t ( ) { \n
0000060 / / B l a \n
0000100 } \n } \n
0000105
As you can see swiftformat is fine with this demo struct.
The next step is then to run this within VSCode. I have configured the exact same config file and would expect the same output. It is not, it removes the last line.
When I save it I get the following content with od:
$ od -c demo.swift
0000000 i m p o r t F o u n d a t i o
0000020 n \n\n s t r u c t D e m o {
0000040 \n i n i t ( ) { \n
0000060 / / B l a \n
0000100 } \n }
0000104
That new line should not be removed.
The text was updated successfully, but these errors were encountered:
I have a simple example file
demo.swift
:It is important to notice that the file does end with a newline:
When I run
swiftformat
using the command line:As you can see
swiftformat
is fine with this demo struct.The next step is then to run this within
VSCode
. I have configured the exact same config file and would expect the same output. It is not, it removes the last line.When I save it I get the following content with
od
:That new line should not be removed.
The text was updated successfully, but these errors were encountered: