You've already forked linux-packaging-mono
Imported Upstream version 5.8.0.22
Former-commit-id: df344e34b07851d296efb3e6604c8db42b6f7aa3
This commit is contained in:
parent
5f4a27cc8a
commit
7d05485754
@@ -53,6 +53,7 @@ namespace Mono.ILASM {
|
||||
private bool keycontainer = false;
|
||||
private string keyname;
|
||||
private StrongName sn;
|
||||
bool noautoinherit;
|
||||
|
||||
public DriverMain (string[] args)
|
||||
{
|
||||
@@ -67,7 +68,7 @@ namespace Mono.ILASM {
|
||||
if (output_file == null)
|
||||
output_file = CreateOutputFilename ();
|
||||
try {
|
||||
codegen = new CodeGen (output_file, target == Target.Dll, debugging_info);
|
||||
codegen = new CodeGen (output_file, target == Target.Dll, debugging_info, noautoinherit);
|
||||
foreach (string file_path in il_file_list) {
|
||||
Report.FilePath = file_path;
|
||||
ProcessFile (file_path);
|
||||
@@ -270,6 +271,9 @@ namespace Mono.ILASM {
|
||||
else
|
||||
keyname = command_arg;
|
||||
break;
|
||||
case "noautoinherit":
|
||||
noautoinherit = true;
|
||||
break;
|
||||
case "scan_only":
|
||||
scan_only = true;
|
||||
break;
|
||||
@@ -336,16 +340,17 @@ namespace Mono.ILASM {
|
||||
|
||||
private void Usage ()
|
||||
{
|
||||
Console.WriteLine ("Mono ILasm compiler\n" +
|
||||
Console.WriteLine ("Mono IL assembler compiler\n" +
|
||||
"ilasm [options] source-files\n" +
|
||||
" --about About the Mono ILasm compiler\n" +
|
||||
" --version Print the version number of the Mono ILasm compiler\n" +
|
||||
" --about About the Mono IL assembler compiler\n" +
|
||||
" --version Print the version number of the compiler\n" +
|
||||
" /output:file_name Specifies output file.\n" +
|
||||
" /exe Compile to executable.\n" +
|
||||
" /dll Compile to library.\n" +
|
||||
" /debug Include debug information.\n" +
|
||||
" /key:keyfile Strongname using the specified key file\n" +
|
||||
" /key:@container Strongname using the specified key container\n" +
|
||||
" /noautoinherit Disable inheriting from System.Object by default\n" +
|
||||
"Options can be of the form -option or /option\n");
|
||||
Environment.Exit (1);
|
||||
}
|
||||
@@ -361,7 +366,7 @@ namespace Mono.ILASM {
|
||||
private void Version ()
|
||||
{
|
||||
string version = System.Reflection.Assembly.GetExecutingAssembly ().GetName ().Version.ToString ();
|
||||
Console.WriteLine ("Mono ILasm compiler version {0}", version);
|
||||
Console.WriteLine ("Mono IL assembler compiler version {0}", version);
|
||||
Environment.Exit (0);
|
||||
}
|
||||
|
||||
|
||||
@@ -63,14 +63,16 @@ namespace Mono.ILASM {
|
||||
private string output_file;
|
||||
private bool is_dll;
|
||||
private bool entry_point;
|
||||
bool noautoinherit;
|
||||
|
||||
private Module this_module;
|
||||
|
||||
public CodeGen (string output_file, bool is_dll, bool debugging_info)
|
||||
public CodeGen (string output_file, bool is_dll, bool debugging_info, bool noautoinherit)
|
||||
{
|
||||
this.output_file = output_file;
|
||||
this.is_dll = is_dll;
|
||||
|
||||
this.noautoinherit = noautoinherit;
|
||||
|
||||
if (debugging_info)
|
||||
symwriter = new SymbolWriter (output_file);
|
||||
|
||||
@@ -313,7 +315,7 @@ namespace Mono.ILASM {
|
||||
|
||||
typedef = new TypeDef (attr, current_namespace,
|
||||
name, parent, impl_list, location, gen_params, outer);
|
||||
|
||||
typedef.NoAutoInherit = noautoinherit && parent == null;
|
||||
type_manager[cache_name] = typedef;
|
||||
current_customattrtarget = current_typedef = typedef;
|
||||
current_declsectarget = typedef;
|
||||
|
||||
@@ -93,6 +93,8 @@ namespace Mono.ILASM {
|
||||
this.attr |= PEAPI.TypeAttr.Abstract;
|
||||
}
|
||||
|
||||
public bool NoAutoInherit { get; set; }
|
||||
|
||||
public string Name {
|
||||
get { return name; }
|
||||
}
|
||||
@@ -389,7 +391,7 @@ namespace Mono.ILASM {
|
||||
name_space, name);
|
||||
}
|
||||
}
|
||||
if (FullName == "System.Object")
|
||||
if (FullName == "System.Object" || NoAutoInherit)
|
||||
classdef.SpecialNoSuper ();
|
||||
}
|
||||
|
||||
|
||||
@@ -1 +1 @@
|
||||
c12eeaf978be47f106f6620198cbd223988e3ab2
|
||||
b564427b568fa5956bc83bf9fee47d3c78750b79
|
||||
@@ -321,6 +321,7 @@ namespace Mono.ILASM {
|
||||
keywords ["legacy"] = new ILToken (Token.K_LEGACY, "legacy");
|
||||
keywords ["library"] = new ILToken (Token.K_LIBRARY, "library");
|
||||
keywords ["auto"] = new ILToken (Token.K_AUTO, "auto");
|
||||
keywords ["aggressiveinlining"] = new ILToken (Token.K_AGGRESSIVEINLINING, "aggressiveinlining");
|
||||
|
||||
return keywords;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user