Explorar el Código

Modify padding and content of function

Etheram68 hace 5 años
padre
commit
7243b9414b
Se han modificado 3 ficheros con 6 adiciones y 6 borrados
  1. 1 1
      README.md
  2. 1 1
      package.json
  3. 4 4
      src/extension.ts

+ 1 - 1
README.md

@@ -28,5 +28,5 @@ To report a bug or ask for a feature, please open a [Github issue](https://githu
 
 ## Release Notes
 
-### 0.1.4
+### 0.1.5
 First Version of Auto Create canonical Class for the Cpp language

+ 1 - 1
package.json

@@ -2,7 +2,7 @@
 	"name": "canonicalclasscpp",
 	"displayName": "Canonical Class CPP",
 	"description": "This extension is to automatically create a canonical hpp and cpp file",
-	"version": "0.1.4",
+	"version": "0.1.5",
 	"publisher": "frfreyCanonicalClassCPP",
 	"icon": "42.png",
 	"repository": {

+ 4 - 4
src/extension.ts

@@ -43,9 +43,11 @@ export function activate(context: vscode.ExtensionContext) {
 							name + "::" + name + "() {}\n\n" +
 							name + "::" + name + "( const " + name + " & object ) {}\n\n" +
 							name + "::~" + name + "()\n{\n	std::cout << \"Destructor called\" << std::endl;\n}\n\n" +
-							name + " &		" + name + "::operator=( " + name + " const & rhs )\n{\n	return *this;\n}\n\n" +
+							name + " &		" + name + "::operator=( " + name + " const & rhs )\n{\n	//if ( this != &rhs )\n" +
+							"		//this->_value = rhs.getValue();\n" +
+							"	return *this;\n}\n\n" +
 							"std::ostream &		operator<<( std::ostream & o, " + name + " const & i )\n" +
-							"{\n	o << \"Value\" << i.get();\n	return o;\n}\n\n" +
+							"{\n	//o << \"Value = \" << i.getValue();\n	return o;\n}\n\n" +
 							"\n/* ************************************************************************** */";
 
 			let classhpp =	"#ifndef " + name.toUpperCase() + "_CLASS" + "_HPP\n" +
@@ -62,9 +64,7 @@ export function activate(context: vscode.ExtensionContext) {
 							"		" + name + " &		operator=( " + name + " const & rhs );"+
 							"\n\n" +
 							"	private:\n" +
-							"\n" +
 							"};\n\n" +
-							"\n" +
 							"std::ostream &		operator<<( std::ostream & o, " + name + " const & i );"+
 							"\n\n" +
 							"#endif /* *" + star + " " + name.toUpperCase() + "_CLASS_H */";