Skip to content

Commit

Permalink
fixed pezy#17
Browse files Browse the repository at this point in the history
  • Loading branch information
pezy committed Feb 25, 2015
1 parent 3d6a5b9 commit 3933d6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ch04/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ char cval; int ival; unsigned int ui; float fval; double dval;
identify the implicit type conversions, if any, taking place:
```cpp
cval = 'a' + 3; // 'a' promoted to int, then the result of ('a' + 3)(int) converted to char.
fval = ui - ival * 1.0; // ival promoted to double, ui also promoted to double. then that double converted to float.
fval = ui - ival * 1.0; // ival converted to double , ui also converted to double. then that double converted(by truncation) to float.
dval = ui * fval; // ui promoted to float. then that float converted to double.
cval = ival + fval + dval; // ival converted to float, then that float and fval converted to double. At last, that double converted to char(by truncation).
```
Expand Down

0 comments on commit 3933d6b

Please sign in to comment.