Q:

casting in c can cause any compile error?

I know that in java I can't return double from a function that supose to return an int value without casting, but now when I learn c I see that I can compile something like (only warnings, no error):
int calc(double d, char c) {
   return d * c / 3;
}

so my question is, c compiler will always do for me auto casting when needed?
or this is specific working one because of char or something?

A:

C has a concept of implicit conversions, i.e. rules that define under which conditions and how values are converted to different types implicitly, without the need to explicitly cast them (see, for example, cppreference.com). So C is not "auto-casting" everything, but only under certain conditions.
Your return type is int, whereas the result of expression d * c / 3 is double. So the following (implicit) conversion applies:

Real floating-integer conversions
A finite value of any real floating
  type can be implicitly converted to any integer type. Except where
  covered by boolean conversion above, the rules are: The fractional
  part is discarded (truncated towards zero). If the resulting value can
  be represented by the target type, that value is used otherwise, the
  behavior is undefined

