In <1c6b604c-cb47-4c76-b4ca-> Chad <> writes:
> Let's say I'm working on a programming project that uses multiple
> languages. And now let's say that the only (apparent) way I can get C
> to cooperate with the other programming languages is to cast the
> return value from malloc(). How would you get around avoiding casting
> the return from malloc()?
If you're calling malloc() from within a module written in another
language, then you should use whatever mechanism that language provides
for coercing the return value of malloc() into a compatible representation.
But this isn't C casting, so this example is irrelevant.
If you're calling malloc() from within C code, the presence elsewhere in
your program of modules written in other languages is irrelevant.
In short, I don't see how other languages are relevant to this discussion.
--
John Gordon A is for Amy, who fell down the stairs
B is for Basil, assaulted by bears
-- Edward Gorey, "The Gashlycrumb Tinies"