x
uploads/destructor.jpg

destructor n.1.〔英國〕垃圾焚化爐。2.破壞器;爆破裝置。

desudation

Enables the creation of hidden vtordisp constructor destructor displacement members 啟用創建隱藏vtordisp構造函數/析構函數置換成員。

When the destructor is called , the garbage collector is invoked to process the queue 調用析構函數時,將調用垃圾回收器來處理該隊列。

The memory manager calls the destructor just before it finally reclaims memory occupied by the 對象占用的內存之前先調用析構函數。

If the destructor is empty , this simply results in a needless loss of performance 如果析構函數為空,則只會導致不必要的性能丟失。

When a class contains a destructor , an entry is created in the finalize queue 如果類包含析構函數, finalize隊列中則會創建一個項。

Is necessary is when the only virtual function in your virtual base is a destructor 的情況是虛擬基中的唯一虛函數是析構函數。

Increases and after each pointer is deleted and the destructor is called , 的值會增加,而在刪除每個指針(并調用析構函數)后,

Object s destructor 正在使用的資源。

Managed code does not support anything similar to c destructor semantics 托管代碼不支持任何與c + +析構函數語義相似的語義。

Allows defining a destructor function that runs when an object is destroyed 允許定義一個析構函數當對象崩潰的時候運行。

In the second step , the compiler synthesizes a virtual destructor 在第二個步驟中,編譯器合成了一個虛擬析構函數。

Destructor may not immediately execute when an object loses scope 析構函數可能不會在對象失去范圍時立即執行即可。

At the end of the block , the associated destructor , transformed into 在塊的末尾,自動調用關聯的析構函數(被轉換為

When either a destructor is invoked explicitly under the new syntax , or when 在新語法下顯式調用析構函數時,或者將

However , the semantics of the class destructor have changed considerably 但是,類析構函數的語義發生了顯著變化。

This , recall , represents the user - supplied destructor for that class 回想一下,這代表該類的用戶提供的析構函數。

In the new syntax , as we ve seen , the destructor is synthesized into the 如前所述,在新語法中,析構函數合成到了

If the destructor is empty , this simply results in a loss of performance 如果析構函數為空,只會導致性能降低。

If a destructor is present , rewrite that to be the class finalizer 如果存在析構函數,則將其重寫為類終結器。