I use your step, the error is reduced,
Do you use CodeBlock 12.11, maybe you will find out the problems
Here is the error now:
||=== L1p18st90, Debug ===|
C:\GERMANY2012\OpenSourceSoftware2012\CodeBlockCPP\cpp_projekt\L1p18st90\main.cpp||In function 'int main()':|
C:\GERMANY2012\OpenSourceSoftware2012\CodeBlockCPP\cpp_projekt\L1p18st90\main.cpp|21|error: conflicting declaration 'auto p2'|
C:\GERMANY2012\OpenSourceSoftware2012\CodeBlockCPP\cpp_projekt\L1p18st90\main.cpp|18|error: 'p2' has a previous declaration as 'int p2'|
C:\GERMANY2012\OpenSourceSoftware2012\CodeBlockCPP\cpp_projekt\L1p18st90\main.cpp|22|error: request for member 'x' in 'p2', which is of non-class type 'int'|
C:\GERMANY2012\OpenSourceSoftware2012\CodeBlockCPP\cpp_projekt\L1p18st90\main.cpp|22|error: request for member 'y' in 'p2', which is of non-class type 'int'|
||=== Build finished: 4 errors, 0 warnings (0 minutes, 0 seconds) ===|
Also you don't need to include cstddef header for size_t in C++11.
You need to include a header that defines size_t, or define it yourself, before you can use it. Often standard headers include other headers so there is a big chance that if you include a standard header you will have size_t defined because it is such a commonly used type, but there is no guarantee and this can differ between different implementations and even between different version of the same implementation, so to be safe it is best to always include the headers that defines the things you are using.