|
2 | 2 | title: "IDebugExpressionEvaluator2::Terminate | Microsoft Docs"
|
3 | 3 | ms.date: "11/04/2016"
|
4 | 4 | ms.topic: "conceptual"
|
5 |
| -helpviewer_keywords: |
| 5 | +helpviewer_keywords: |
6 | 6 | - "Terminate"
|
7 | 7 | - "IDebugExpressionEvaluator2::Terminate"
|
8 | 8 | ms.assetid: 38265100-4d80-4902-833a-07bb569f9ba8
|
9 | 9 | author: "gregvanl"
|
10 | 10 | ms.author: "gregvanl"
|
11 | 11 | manager: jillfra
|
12 |
| -ms.workload: |
| 12 | +ms.workload: |
13 | 13 | - "vssdk"
|
14 | 14 | ---
|
15 | 15 | # IDebugExpressionEvaluator2::Terminate
|
16 |
| -Stops and cleans up the expression evaluator. |
17 |
| - |
18 |
| -## Syntax |
19 |
| - |
20 |
| -```cpp |
21 |
| -HRESULT Terminate ( |
22 |
| - void |
23 |
| -); |
24 |
| -``` |
25 |
| - |
26 |
| -```csharp |
27 |
| -int Terminate (); |
28 |
| -``` |
29 |
| - |
30 |
| -## Return Value |
31 |
| - If successful, returns `S_OK`; otherwise, returns an error code. |
32 |
| - |
33 |
| -## Remarks |
34 |
| - Tells the expression evaluator when it is being cleaned up. |
35 |
| - |
36 |
| -## Example |
37 |
| - The following example shows how to implement this method for a **ExpressionEvaluatorPackage** object that exposes the [IDebugExpressionEvaluator2](../../../extensibility/debugger/reference/idebugexpressionevaluator2.md) interface. |
38 |
| - |
39 |
| -```cpp |
40 |
| -STDMETHODIMP ExpressionEvaluatorPackage::Terminate(void) |
41 |
| -{ |
42 |
| - // scan the namespaces contained and delete |
43 |
| - EEExtensionMethodCache **ppChild = NULL; |
44 |
| - m_HashExtensionMethodCache.ResetHashIterator(); |
45 |
| - while (ppChild = m_HashExtensionMethodCache.IterateHash()) |
46 |
| - { |
47 |
| - delete *ppChild; |
48 |
| - } |
49 |
| - return VBEEImplicitVariables::Terminate(); |
50 |
| -} |
51 |
| -``` |
52 |
| - |
53 |
| -## See Also |
54 |
| - [IDebugExpressionEvaluator2](../../../extensibility/debugger/reference/idebugexpressionevaluator2.md) |
| 16 | +Stops and cleans up the expression evaluator. |
| 17 | + |
| 18 | +## Syntax |
| 19 | + |
| 20 | +```cpp |
| 21 | +HRESULT Terminate ( |
| 22 | + void |
| 23 | +); |
| 24 | +``` |
| 25 | + |
| 26 | +```csharp |
| 27 | +int Terminate (); |
| 28 | +``` |
| 29 | + |
| 30 | +## Return Value |
| 31 | +If successful, returns `S_OK`; otherwise, returns an error code. |
| 32 | + |
| 33 | +## Remarks |
| 34 | +Tells the expression evaluator when it is being cleaned up. |
| 35 | + |
| 36 | +## Example |
| 37 | +The following example shows how to implement this method for a **ExpressionEvaluatorPackage** object that exposes the [IDebugExpressionEvaluator2](../../../extensibility/debugger/reference/idebugexpressionevaluator2.md) interface. |
| 38 | + |
| 39 | +```cpp |
| 40 | +STDMETHODIMP ExpressionEvaluatorPackage::Terminate(void) |
| 41 | +{ |
| 42 | + // scan the namespaces contained and delete |
| 43 | + EEExtensionMethodCache **ppChild = NULL; |
| 44 | + m_HashExtensionMethodCache.ResetHashIterator(); |
| 45 | + while (ppChild = m_HashExtensionMethodCache.IterateHash()) |
| 46 | + { |
| 47 | + delete *ppChild; |
| 48 | + } |
| 49 | + return VBEEImplicitVariables::Terminate(); |
| 50 | +} |
| 51 | +``` |
| 52 | +
|
| 53 | +## See Also |
| 54 | +[IDebugExpressionEvaluator2](../../../extensibility/debugger/reference/idebugexpressionevaluator2.md) |
0 commit comments