When you have a for loop and declare the index variable in it, it used to be instantiated for the entire function so you can use it in other for loops:
for (int i = 0; ...)
Now, it's instantiated only within the loop (more like C#), so if you want to declare it only once for your function, you have to pull it out of the loop declaration:
int i;
for (i = 0; ...)
If you have ON_WM_NCHITTEST() in any of your Windows subclassing code, you'll get this cryptic error:
cannot convert from 'UINT (__thiscall CMyControl::* )(CPoint)' to 'LRESULT (__thiscall CWnd::* )(CPoint)' Cast from base to derived requires dynamic_cast or static_cast
and to fix it, you have to change your head file and function declaration for
afx_msg UINT OnNcHitTest(CPoint point);
to:
afx_msg LRESULT OnNcHitTest(CPoint point);
If you reference a class' member functions by assigning them to pointer
pMyFunc = MyMemberFunction
you have to preface the function name with the class name and a reference symbol:
pMyFunct = &MyClass::MyMemberFunction
You can no longer let the compiler assume untyped variables are int. So these won't work:
const myconst = 10;
register i;
Instead, you have to do this:
const int myconst = 10;
register int i;
I think I like C# and Java much better now... ;-)
Su | Mo | Tu | We | Th | Fr | Sa |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 | ||||