Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 "Create Impl." on meth. w/o ";" copies whole class

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
drzoom Posted - Jul 04 2006 : 07:14:22 AM
I use:
VA_X.dll file version 10.3.1526.0 built 2006.06.28

In this situation:

Slot.h:

#pragma once
#ifndef FITTING_ENVIRONMENTMANAGER_SLOT_H
#define FITTING_ENVIRONMENTMANAGER_SLOT_H

template<class T>
class FitSideData
{
};

namespace fitting {
namespace environmentmanager {

namespace alscombination {
  class Info {};
}

/**
 * Represents a simple slot for two sides.
 */
class Slot : public FitSideData<alscombination::Info>
{
public:
  /**
   * ctor
   */
  Slot();

  /**
   * ctor
   */
  Slot( const alscombination::Info& rightALS,
    const alscombination::Info& leftALS);

  /**
   * dtor
   */
  virtual ~Slot();

public:
  /**
   * Check if both ALS combinations ids are equal.
   *
   * \\return true If both sides have the same ALS combination id.
   */
  bool IsALSCombinationIdConsistent() const
};


}
}


#endif


and...


#include "StdAfx.h"
#include "Slot.h"

namespace fitting {
namespace environmentmanager {

Slot::Slot()
  : FitSideData<alscombination::Info>()
{
}

Slot::Slot( const alscombination::Info& rightALSInfo,
  const alscombination::Info& leftALSInfo )
: FitSideData<alscombination::Info>( leftALSInfo, rightALSInfo )
{
}

Slot::~Slot()
{
}

}
}





1. If I use the refactor method "Create Implementation" on the new method IsALSCombinationIdConsistent, I get this code in the implementation File:


class Slot :  FitSideData<alscombination::Info> { : /**  * ctor  */
 fitting::environmentmanager::Slot::IsALSCombinationIdConsistent()
 /**  * ctor  */ Slot( const alscombination::Info& rightALS,
const alscombination::Info& leftALS)
{

}


Note the missing semicolon at the end of the new method declaration.




2. If I add the semicolon and call "Create Implementation" I get a correct implementation:


bool fitting::environmentmanager::Slot::IsALSCombinationIdConsistent() const
{

}


But outside of the namespace brackets.

Feature Request: An option to choose between placing implementation methods in namespace brackets or as standalone implementation blocks.

Possible you can look, if there already other implemented method and place the new method in the same namespace bracket. If no implemented method in a namespace bracket exists, create a new one and place the method in it.

best regards
Tobias


1   L A T E S T    R E P L I E S    (Newest First)
jpizzi Posted - Jul 04 2006 : 11:40:23 PM
Confirmed. Thanks for the detailed reproducible example.

case=1567

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000