I've following code:

#include <iostream>
using namespace std;

class Child1
{
    int i;
};

class Child2 : public Child1
{
    int j;
};

class Base1
{

public:

    virtual Child1& getChildren()
    {
        cout << "Children1" << endl;
        return children;
    }

private:

    Child1 children;
};

class Base2 : public Base1
{

public:

    virtual Child2& getChildren()
    {
        cout << "Children2" << endl;
        return children;
    }

private:

    Child2 children;
};

This code compiles fine however when I alter the return kind of getChildren() from reference type to object key in either or both Base1 and Base2 (e.g. virtual Child2 getChildren(), I recieve the next error on Visual Studio 2010:

error C2555: 'Base2::getChildren': overriding virtual function return type differs and is not covariant from 'Base1::getChildren'

I wish to know why shall we be held not getting this error when utilizing reference and setting it up otherwise. Is this can be a bug in VS2010? Since the C++ standard (based on this page on Microsoft's website) states something similar to: The return kind of an overriding function will be either just like the return kind of the overridden function or covariant using the classes from the functions. And the course within the return kind of B::f is identical class because the class within the return kind of D::f or, is definitely an unambiguous direct or indirect base class from the class within the return kind of D::f and it is available in D.

P.S. I actually do not need the conventional right now so can't verify the above mentioned quote.

You skipped another part they cited: "If your function D::f overrides a function B::f, the return kinds of the functions are covariant when they fulfill the following criteria: (1) both of them are pointers to classes or references to classes"

They need to be references or pointers, not concrete classes. That needs could live quite happily within the "convariant with" agreement inside your MS quote. The 2nd part talks about "the course within the return type" - note the concern that they have prevented "the course came back" precisely since it is the course element of the pointer- or reference-to-class return type.

Consider what covariance is perfect for: you are returning an item plus some existing code written for that base class might be wanting to deal with that but through virtual dispatch finish up getting your objects. If they may be different in dimensions how is the objects be saved? This mess is sidestepped through the indirection... you are able to decide where they're (some buffer, shared mem, heap) and also the covariant return type may be the pointer or reference thereto.