Problem with deleting a dynamic array

Hello!
First of all, please excuse me for my bad english!
Im having the following problem.

In some function, i return a dynamic array of int with some size. In the same function, in other part (is recursive) I get that array with a pointer but with no size specified. For example

int * t = function(...);

I know in that part what size my returned array is, but i dont declare it here. Then i use this pointer to do some operations, and finally, i want to delete the entire array, not only the t pointer... i don't know if im explaining very good.. :S

I dont know how to do this, in order to don't waste memory in every call... i think it's with pointer arimethic or something, but i dont know about that... can you help me?? Cause here i cant use the delete[] t instruction. Thanks in advance!!
I'm not sure what you mean. delete[] t; will free all of the memory allocated for t, but should only be used if you used new[].
Sorry, I couldn't follow you. Why you can't use the delete[] operator?
Could you post your code, please?
Im sorry!! I can use it, i just realize!! Hehe.. my fault!!!
Thank you!!
Topic archived. No new replies allowed.