    #include <iostream>
    #include <vector>
    using namespace std;
     
    template<typename T>
    struct Params : public std::vector<T>
    {
        template<typename V> // avoids fallback to language-defined behavior
        inline Params<T>& operator,(const V& value)
        {
            this->push_back(value);
            return *this;
        }
    };
     
    void printParams(const Params<int>& params = Params<int>())
    {
        cout << "[";
     
        for (size_t i = 0; i < params.size(); ++i)
        {
            cout << (i == 0 ? "" : ", ");
            cout << params[i];
        }
     
        cout << "]" << endl;
    }
     
    int main()
    {
        // No params
        printParams(); // []
     
        // No params with explicit empty params
        printParams(Params<int>()); // []
     
        // Some params
        printParams((Params<int>(), 1, 2, 3)); // [1, 2, 3]
     
        // compile-time error: invalid conversion from `const char[4]` to `int`
        // printParams((Params<int>(), 1, 2, 3, "error"));
    }