File tree 1 file changed +8
-0
lines changed
src/PowerShellEditorServices/Language
1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 13
13
14
14
namespace Microsoft . PowerShell . EditorServices
15
15
{
16
+ using System . Diagnostics ;
16
17
using System . Management . Automation ;
17
18
using System . Management . Automation . Language ;
18
19
using System . Management . Automation . Runspaces ;
@@ -101,13 +102,20 @@ static public async Task<CommandCompletion> GetCompletions(
101
102
{
102
103
powerShell . Runspace = runspaceHandle . Runspace ;
103
104
105
+ Stopwatch stopwatch = new Stopwatch ( ) ;
106
+ stopwatch . Start ( ) ;
107
+
104
108
commandCompletion =
105
109
CommandCompletion . CompleteInput (
106
110
scriptAst ,
107
111
currentTokens ,
108
112
cursorPosition ,
109
113
null ,
110
114
powerShell ) ;
115
+
116
+ stopwatch . Stop ( ) ;
117
+
118
+ Logger . Write ( LogLevel . Verbose , $ "IntelliSense completed in { stopwatch . ElapsedMilliseconds } ms.") ;
111
119
}
112
120
}
113
121
You can’t perform that action at this time.
0 commit comments