Add copy of .ttf font with .eot extension for testing
[wine-gecko.git] / xpcom / tests / SizeTest04.cpp
blobaad4ee68856bc924d218c0d22e14d08c2064f5f3
1 // Test04.cpp
3 #include "nsIDOMNode.h"
4 #include "nsCOMPtr.h"
6 #ifdef __MWERKS__
7 #pragma exceptions off
8 #endif
10 NS_DEF_PTR(nsIDOMNode);
13 Windows:
14 nsCOMPtr 13
15 raw 36
17 Macintosh:
18 nsCOMPtr 36 bytes (1.0000)
19 raw 120 (3.3333) i.e., 333.33% bigger than nsCOMPtr
22 class Test04_Raw
24 public:
25 Test04_Raw();
26 ~Test04_Raw();
28 void /*nsresult*/ SetNode( nsIDOMNode* newNode );
30 private:
31 nsIDOMNode* mNode;
34 Test04_Raw::Test04_Raw()
35 : mNode(0)
37 // nothing else to do here
40 Test04_Raw::~Test04_Raw()
42 NS_IF_RELEASE(mNode);
45 void // nsresult
46 Test04_Raw::SetNode( nsIDOMNode* newNode )
47 // m120, w36
49 NS_IF_ADDREF(newNode);
50 NS_IF_RELEASE(mNode);
51 mNode = newNode;
53 // return NS_OK;
58 class Test04_nsCOMPtr
60 public:
61 void /*nsresult*/ SetNode( nsIDOMNode* newNode );
63 private:
64 nsCOMPtr<nsIDOMNode> mNode;
67 void // nsresult
68 Test04_nsCOMPtr::SetNode( nsIDOMNode* newNode )
69 // m36, w13/13
71 mNode = newNode;