Visual Studio 2010 warnings


#1

(Yes I know that's an old compiler but I think those warnings are legit)

I just compiled the latest Introjucer from GIT, and I got a few warnings.

1>c:\juce\extras\introjucer\source\project saving\jucer_ProjectExport_XCode.h(1420): warning C4510: 'XCodeProjectExporter::ImageType' : default constructor could not be generated
1>          c:\juce\extras\introjucer\source\project saving\jucer_ProjectExport_XCode.h(1411) : see declaration of 'XCodeProjectExporter::ImageType'
1>c:\juce\extras\introjucer\source\project saving\jucer_ProjectExport_XCode.h(1420): warning C4512: 'XCodeProjectExporter::ImageType' : assignment operator could not be generated
1>          c:\juce\extras\introjucer\source\project saving\jucer_ProjectExport_XCode.h(1411) : see declaration of 'XCodeProjectExporter::ImageType'
1>c:\juce\extras\introjucer\source\project saving\jucer_ProjectExport_XCode.h(1420): warning C4610: struct 'XCodeProjectExporter::ImageType' can never be instantiated - user defined constructor required

These are due to the struct having const int members:

    struct ImageType
    {
        const char* orientation;
        const char* idiom;
        const char* subtype;
        const char* extent;
        const char* scale;
        const char* filename;
        const int   width;
        const int   height;
    };

I don't know if the compiler actually generates any wrong code because of this. But it's probably better to have width and height con-const.

--
Roeland


#2

(Yes I know that's an old compiler but I think those warnings are legit)

:)


#3

Could have sworn that I already fixed that one, but obviously not! Thanks, will tidy it up!