Here is the code,
Code:
class A
{
public:
	A(int x) {}
	static void* operator new(size_t size){}
};

int main()
{
	void* rawMemory = operator new[](10*sizeof(A));

	A* pA = static_cast<A*>(rawMemory);

	for(int i=0;i<10;i++)
		new(&pA[i]) A(i);

	for(int j=9;j>=0;j--)
		pA[j].~A();

	operator delete[](rawMemory);
	return 0;
}
There is compiler error "error C2660: 'A:perator new' : function does not take 2 arguments". What does it mean? Also one more question here. What if overloaded operator new is not static? Is there any problem with operator new not being static or not being global? Thanks.