Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-7601

Quick Fix "Add definition in ..." removes template arguments

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • Qt Creator 2.6.0-rc
    • Qt Creator 2.4.1
    • None
    • Linux Mint 13 (Ubuntu 12.04) 64-bit / QtSDK 1.2.1
    • 30b553466797ddf7e3252f1cab2d02d6ea0bee5a

    Description

      Hi!

      Consider the following code:

      /* header file */
      
      // includes
      
      template <class C>
      class Foo
      {
        public:
          void bar(std::vector<int> &vector);  
        private:
          C bah;
      };
      

      When I hit Alt+Enter on "void bar(...)" and then "Add definition in ..." the following code will be generated:

      /* source file */
      
      template <class C>
      void Foo::bar(std::vector &vector)
      {
      }
      

      The problem: Both template arguments are gone. It should be:

      /* source file */
      
      template <class C>
      void Foo<C>::bar(std::vector<int> &vector)
      {
      }
      

      Thanks!

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              leamelo Leandro T. C. Melo
              metaphysicalmarty Martin Clauß
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes