Type conversion error

hello: I used the latest go version but still had the following error:

github.com/syncthing/syncthing/lib/connections

lib\connections\quic_dial.go:97:34: cannot use &quicTlsConn literal (type *quicTlsConn) as type tlsConn in field value:

*quicTlsConn does not implement tlsConn (wrong type for ConnectionState method)

            have ConnectionState() handshake.ConnectionState
            want ConnectionState() tls.ConnectionState

lib\connections\quic_listen.go:159:39: cannot use &quicTlsConn literal (type *quicTlsConn) as type tlsConn in field value:

    *quicTlsConn does not implement tlsConn (wrong type for ConnectionState method)
            have ConnectionState() handshake.ConnectionState
            want ConnectionState() tls.ConnectionState

exit status 2
exit status 1

You need to make sure you use the vendored version of quic via go modules.

Or, to begin with, follow https://docs.syncthing.net/dev/building.html and describe precisely what you’re doing when it fails.

(Because it works for us, and others.)

Now is

lib\connections\quic_dial.go:86:39: not enough arguments in call to session.OpenStreamSync

    have ()
    want (context.Context)

lib\connections\quic_listen.go:118:34: not enough arguments in call to listener.Accept

    have ()
    want (context.Context)

lib\connections\quic_listen.go:151:38: not enough arguments in call to session.AcceptStream

    have ()
    want (context.Context)

And then to

session.OpenStreamSync(context.Background())

listener.Accept(context.Background())

session.AcceptStream(context.Background())

Seems to be ok.

The build instructions. See above.

Just above