I'm constantly thinking melodies. Now, to add interest to those melodies, obviously you have to know what things can be superimposed over a chord, and I will think of extended arpeggios and the upper estensions. If I'm playing very vertically, I will invariably start to include certaing passing notes which imply certain scales — like a melodic minor scale against a C minor chord, or diminished scales, something like that. But I'm not thinking of a scale at that specific moment. I'm thinking of the notes as surrounding that chord — because I know how each of the twelve notes in music sound against a C minor seventh, for instance.
Denyer, Ralph (2002). The Guitar Handbook. p. 114. ISBN 0-679-74275-1.