At the top of the source windows in VS 2017 is a toolbar with drop-downs for code browsing. I have discovered that using the following steps the toolbar disappears until the file is closed and re-opened.
If the context menu is used to “peek” a definition that is in the same file, when the peek window is closed the toolbar goes away.
Sorry, this is a known bug caused by the internals of the Peek Definition logic and fully resolving it would involve a fairly large change on the VisualGDB side. As a workaround please try reopening the source file after the bug is triggered.
Sorry, we may eventually fix this, however currently we are currently prioritizing other features over it as it requires a non-trivial backend change on our side.