示例#1
0
        public AssemblerMethod(Method method, AssemblerLine[] lines)
        {
            this.method = method;
            this.lines  = lines;
            addresses   = new ArrayList();

            ArrayList contents = new ArrayList();

            foreach (AssemblerLine line in lines)
            {
                if (line.Label != null)
                {
                    if (end_row > 0)
                    {
                        contents.Add("");
                        end_row++;
                    }
                    else
                    {
                        start_row++;
                    }
                    contents.Add(String.Format("{0}:", line.Label));
                    end_row++;
                }

                addresses.Add(new LineEntry(line.Address, 0, ++end_row));
                contents.Add(String.Format("  {0:x}   {1}", line.Address, line.Text));
            }

            string[] text = new string [contents.Count];
            contents.CopyTo(text);

            buffer = new SourceBuffer(method.Name, text);
        }
示例#2
0
 public SourceAddress(SourceFile file, SourceBuffer buffer, int row,
                      int line_offset, int line_range)
 {
     this.file        = file;
     this.buffer      = buffer;
     this.row         = row;
     this.line_offset = line_offset;
     this.line_range  = line_range;
 }
示例#3
0
        public SourceAddress(SourceFile file, SourceBuffer buffer, int row,
				      int line_offset, int line_range)
        {
            this.file = file;
            this.buffer = buffer;
            this.row = row;
            this.line_offset = line_offset;
            this.line_range = line_range;
        }
示例#4
0
        public AssemblerMethod(Method method, AssemblerLine[] lines)
        {
            this.method = method;
            this.lines = lines;
            addresses = new ArrayList ();

            ArrayList contents = new ArrayList ();
            foreach (AssemblerLine line in lines) {
                if (line.Label != null) {
                    if (end_row > 0) {
                        contents.Add ("");
                        end_row++;
                    } else
                        start_row++;
                    contents.Add (String.Format ("{0}:", line.Label));
                    end_row++;
                }

                addresses.Add (new LineEntry (line.Address, 0, ++end_row));
                contents.Add (String.Format ("  {0:x}   {1}", line.Address, line.Text));
            }

            string[] text = new string [contents.Count];
            contents.CopyTo (text);

            buffer = new SourceBuffer (method.Name, text);
        }
示例#5
0
 public SourceAddress(SourceFile file, SourceBuffer buffer, int row,
                      int line_offset, int line_range, SourceRange?source_range)
     : this(file, buffer, row, line_offset, line_range)
 {
     this.source_range = source_range;
 }
示例#6
0
            public WrapperMethodSource(WrapperMethod wrapper)
            {
                this.wrapper = wrapper;

                string[] cil_code = wrapper.Entry.CILCode.Split ('\n');
                buffer = new SourceBuffer (wrapper.Name, cil_code);
            }
示例#7
0
        public SourceAddress(SourceFile file, SourceBuffer buffer, int row,
				      int line_offset, int line_range, SourceRange? source_range)
            : this(file, buffer, row, line_offset, line_range)
        {
            this.source_range = source_range;
        }