Remove unecessary using declarations.

This commit is contained in:
Mikaël Capelle
2020-05-18 21:49:51 +02:00
parent b02537d709
commit b28abccc2f
3 changed files with 4 additions and 20 deletions
+2
View File
@@ -101,6 +101,8 @@ namespace CSharp {
namespace CSharp {
using namespace System::IO;
bool isFomodEntry(std::shared_ptr<const FileTreeEntry> entry) {
return entry->pathFrom(g.SourceTree).compare("fomod", Qt::CaseInsensitive) == 0;
}
-10
View File
@@ -20,7 +20,6 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
#using <System.dll>
#using <System.Drawing.dll>
#using <System.Security.dll>
#using <System.Windows.Forms.dll>
/**
@@ -30,17 +29,8 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
namespace CSharp {
using namespace System;
using namespace System::CodeDom;
using namespace System::CodeDom::Compiler;
using namespace System::Collections;
using namespace System::ComponentModel;
using namespace System::Diagnostics;
using namespace System::Drawing;
using namespace System::IO;
using namespace System::Windows::Forms;
using namespace Microsoft::CSharp;
using namespace Microsoft::VisualBasic;
using namespace System::Security::Permissions;
/// <summary>
/// Describes the options to display in a select form.
+2 -10
View File
@@ -9,8 +9,6 @@
#include "csharp_utils.h"
#include "base_script.h"
#using <System.Windows.Forms.dll>
#using <System.Drawing.dll>
#using <System.dll>
using namespace MOBase;
@@ -44,12 +42,6 @@ IPluginInstaller::EInstallResult executeScript(System::String^ script) {
using namespace System::CodeDom;
using namespace System::CodeDom::Compiler;
using namespace System::Collections::Generic;
using namespace System::Collections;
using namespace System::Diagnostics;
using namespace System::Drawing;
using namespace System::IO;
using namespace System::Windows::Forms;
using namespace Microsoft::CSharp;
AppDomain^ currentDomain = AppDomain::CurrentDomain;
currentDomain->AssemblyResolve += gcnew ResolveEventHandler(currentDomain_AssemblyResolve);
@@ -79,8 +71,8 @@ IPluginInstaller::EInstallResult executeScript(System::String^ script) {
auto result = provider->CompileAssemblyFromSource(cp, script);
int errorCount = 0;
for (int i = 0; i < result->Errors->Count; ++i) {
CompilerError^ error = result->Errors[i];
CompilerErrorCollection^ errors = result->Errors;
for each (CompilerError^ error in result->Errors) {
if (error->IsWarning) {
log::error("C# [{}]: {}", error->Line, CSharp::to_string(error->ErrorText));
}