rdanbrook/nestopia — pull request #95 by lioncash (2014-08-30 18:22:28+00:00)
Title: Core: Fix the use of uninitialized class members being used within the initialization lists.

I noticed that in some cases currently uninitialized variables are used to initialize some things in the initializer lists. The reason for this is the standard dictates that class members are initialized in the order they are declared within the class (specifically this is section 12.6.2, point 10)

Here's a list of where this happens for documentation sake.

- [NstMachine.cpp](https://github.com/rdanbrook/nestopia/blob/master/source/core/NstMachine.cpp#L48)
cpu is used in extPort and expPort's initializations.

- [NstPpu.cpp (line 86)](https://github.com/rdanbrook/nestopia/blob/master/source/core/NstPpu.cpp#L86)
buffer would not actually be initialized in this case.

- [NstPpu.cpp (line 105)](https://github.com/rdanbrook/nestopia/blob/master/source/core/NstPpu.cpp#L105)
screen would not be initialized at this point due to it being further down in the class member declarations.