Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!rpi!uupsi!sunic!news.funet.fi!hydra!cc.helsinki.fi!teittinen From: teittinen@cc.helsinki.fi Newsgroups: comp.lang.c++ Subject: Question of new and realloc() Message-ID: <1991Jan24.131035.4634@cc.helsinki.fi> Date: 24 Jan 91 13:10:35 GMT Organization: University of Helsinki Lines: 12 Can I use realloc() to handle pointers created by new-operator? Can this cause any troubles? I'd like to use new-operator to minimize pointer type casts and because it does arrays right without sizeof-calculations. Why is there no resize-operator that would make the same thing as realloc(), but would return the right pointer type? That way I could get rid of some pointer type casts (void* -> MyType*). -- E-Mail: teittinen@finuh.bitnet ! "Studying is the only way teittinen@cc.helsinki.fi ! to do nothing without Marko Teittinen, student of computer science ! anyone blaming you" -me