Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/mcs/ilasm
diff options
context:
space:
mode:
authorMarek Safar <marek.safar@gmail.com>2016-12-21 16:13:06 +0300
committerMarek Safar <marek.safar@gmail.com>2016-12-21 16:13:30 +0300
commitd82b6dbac5a7bcd46c5d27d5d4aeade6636ea750 (patch)
treeb0a46cee297cc42e113210830e6bc86d4c0e467b /mcs/ilasm
parent088ea9db6e032beb96f33584ab24a9f64681d148 (diff)
[ilasm] Clenup warnings
Diffstat (limited to 'mcs/ilasm')
-rw-r--r--mcs/ilasm/Driver.cs18
-rw-r--r--mcs/ilasm/Makefile2
-rw-r--r--mcs/ilasm/codegen/CodeGen.cs9
-rw-r--r--mcs/ilasm/codegen/FieldDef.cs4
-rw-r--r--mcs/ilasm/codegen/GenericTypeInst.cs2
-rw-r--r--mcs/ilasm/parser/ILParser.jay5
-rw-r--r--mcs/ilasm/scanner/InstrToken.cs3
7 files changed, 22 insertions, 21 deletions
diff --git a/mcs/ilasm/Driver.cs b/mcs/ilasm/Driver.cs
index 6f38e9d67be..c04622aeb1d 100644
--- a/mcs/ilasm/Driver.cs
+++ b/mcs/ilasm/Driver.cs
@@ -44,8 +44,8 @@ namespace Mono.ILASM {
private Target target = Target.Exe;
private string target_string = "exe";
private bool show_tokens = false;
- private bool show_method_def = false;
- private bool show_method_ref = false;
+// private bool show_method_def = false;
+// private bool show_method_ref = false;
private bool show_parser = false;
private bool scan_only = false;
private bool debugging_info = false;
@@ -189,7 +189,7 @@ namespace Mono.ILASM {
ie.FilePath = file_path;
ie.Location = scanner.Reader.Location;
throw;
- } catch (Exception e){
+ } catch (Exception){
Console.Write ("{0} ({1}, {2}): ",file_path, scanner.Reader.Location.line, scanner.Reader.Location.column);
throw;
} finally {
@@ -276,12 +276,12 @@ namespace Mono.ILASM {
case "show_tokens":
show_tokens = true;
break;
- case "show_method_def":
- show_method_def = true;
- break;
- case "show_method_ref":
- show_method_ref = true;
- break;
+// case "show_method_def":
+// show_method_def = true;
+// break;
+// case "show_method_ref":
+// show_method_ref = true;
+// break;
case "show_parser":
show_parser = true;
break;
diff --git a/mcs/ilasm/Makefile b/mcs/ilasm/Makefile
index 6b24d0d0536..090d1cc3231 100644
--- a/mcs/ilasm/Makefile
+++ b/mcs/ilasm/Makefile
@@ -4,7 +4,7 @@ include ../build/rules.make
PROGRAM = ilasm.exe
BUILT_SOURCES = ILParser.cs
-LOCAL_MCS_FLAGS = /lib:../class/lib/$(PROFILE) /r:../class/lib/$(PROFILE)/PEAPI.dll /r:Mono.CompilerServices.SymbolWriter.dll /r:Mono.Security.dll
+LIB_REFS = PEAPI Mono.CompilerServices.SymbolWriter Mono.Security
CLEAN_FILES = parser/y.output
diff --git a/mcs/ilasm/codegen/CodeGen.cs b/mcs/ilasm/codegen/CodeGen.cs
index b0b1803c180..6b9aadfc80e 100644
--- a/mcs/ilasm/codegen/CodeGen.cs
+++ b/mcs/ilasm/codegen/CodeGen.cs
@@ -29,7 +29,7 @@ namespace Mono.ILASM {
private PEFile pefile;
private ExternAssembly current_assemblyref;
- private ExternModule current_moduleref;
+// private ExternModule current_moduleref;
private string current_namespace;
private TypeDef current_typedef;
private MethodDef current_methoddef;
@@ -61,7 +61,6 @@ namespace Mono.ILASM {
private long stack_reserve;
private string output_file;
- private string debug_file;
private bool is_dll;
private bool entry_point;
@@ -119,9 +118,9 @@ namespace Mono.ILASM {
get { return current_assemblyref; }
}
- public ExternModule CurrentModuleRef {
- get { return current_moduleref; }
- }
+// public ExternModule CurrentModuleRef {
+// get { return current_moduleref; }
+// }
public ICustomAttrTarget CurrentCustomAttrTarget {
get { return current_customattrtarget; }
diff --git a/mcs/ilasm/codegen/FieldDef.cs b/mcs/ilasm/codegen/FieldDef.cs
index 19c23b9bfef..456b9a5ee23 100644
--- a/mcs/ilasm/codegen/FieldDef.cs
+++ b/mcs/ilasm/codegen/FieldDef.cs
@@ -23,7 +23,7 @@ namespace Mono.ILASM {
private PEAPI.NativeType native_type;
private bool offset_set;
- private bool datavalue_set;
+// private bool datavalue_set;
private bool value_set;
private bool is_resolved;
@@ -40,7 +40,7 @@ namespace Mono.ILASM {
this.type = type;
offset_set = false;
- datavalue_set = false;
+// datavalue_set = false;
value_set = false;
at_data_id = null;
diff --git a/mcs/ilasm/codegen/GenericTypeInst.cs b/mcs/ilasm/codegen/GenericTypeInst.cs
index 6634f418b63..5510500749b 100644
--- a/mcs/ilasm/codegen/GenericTypeInst.cs
+++ b/mcs/ilasm/codegen/GenericTypeInst.cs
@@ -19,7 +19,7 @@ namespace Mono.ILASM {
private BaseClassRef class_ref;
private PEAPI.GenericTypeInst p_gen_inst;
- private bool is_valuetypeinst;
+ const bool is_valuetypeinst = false;
private GenericArguments gen_args;
private bool is_added; /* Added to PEFile (to TypeSpec table) ? */
/* Note: Using static hashtable here as GenericTypeInsts is not cached */
diff --git a/mcs/ilasm/parser/ILParser.jay b/mcs/ilasm/parser/ILParser.jay
index a6b861903b6..56f37d06ea3 100644
--- a/mcs/ilasm/parser/ILParser.jay
+++ b/mcs/ilasm/parser/ILParser.jay
@@ -32,7 +32,7 @@ namespace Mono.ILASM {
private string pinvoke_meth;
private PEAPI.PInvokeAttr pinvoke_attr;
private ILTokenizer tokenizer;
- static int yacc_verbose_flag;
+ const int yacc_verbose_flag = 0;
KeyValuePair<string, TypeAttr> current_extern;
class NameValuePair {
@@ -59,13 +59,14 @@ namespace Mono.ILASM {
public bool CheckSecurityActionValidity (System.Security.Permissions.SecurityAction action, bool for_assembly)
{
+#pragma warning disable 618
if ((action == System.Security.Permissions.SecurityAction.RequestMinimum ||
action == System.Security.Permissions.SecurityAction.RequestOptional ||
action == System.Security.Permissions.SecurityAction.RequestRefuse) && !for_assembly) {
Report.Warning (String.Format ("System.Security.Permissions.SecurityAction '{0}' is not valid for this declaration", action));
return false;
}
-
+#pragma warning restore 618
return true;
}
diff --git a/mcs/ilasm/scanner/InstrToken.cs b/mcs/ilasm/scanner/InstrToken.cs
index bc78f97fd18..f4d996aeb10 100644
--- a/mcs/ilasm/scanner/InstrToken.cs
+++ b/mcs/ilasm/scanner/InstrToken.cs
@@ -56,10 +56,11 @@ namespace Mono.ILASM {
case OperandType.InlineNone:
token = Token.INSTR_NONE;
break;
-
+#pragma warning disable 618
case OperandType.InlinePhi:
token = Token.INSTR_PHI;
break;
+#pragma warning restore 618
case OperandType.InlineR:
case OperandType.ShortInlineR: