OLD | NEW |
1 //===- NaClObjDumpStream.h --------------------------------------*- C++ -*-===// | 1 //===- NaClObjDumpStream.h --------------------------------------*- C++ -*-===// |
2 // Models an objdump stream (bitcode records/assembly code). | 2 // Models an objdump stream (bitcode records/assembly code). |
3 // | 3 // |
4 // The LLVM Compiler Infrastructure | 4 // The LLVM Compiler Infrastructure |
5 // | 5 // |
6 // This file is distributed under the University of Illinois Open Source | 6 // This file is distributed under the University of Illinois Open Source |
7 // License. See LICENSE.TXT for details. | 7 // License. See LICENSE.TXT for details. |
8 // | 8 // |
9 //===----------------------------------------------------------------------===// | 9 //===----------------------------------------------------------------------===// |
10 | 10 |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 /// Base class for all directives. The basic functionality is that it | 233 /// Base class for all directives. The basic functionality is that it |
234 /// has a reference to the text formatter, and is applied by calling | 234 /// has a reference to the text formatter, and is applied by calling |
235 /// method apply. This method apply is encorporated into the | 235 /// method apply. This method apply is encorporated into the |
236 /// stream operator<<, so that they can be used as part of the | 236 /// stream operator<<, so that they can be used as part of the |
237 /// streamed output. | 237 /// streamed output. |
238 /// | 238 /// |
239 /// Method apply extracts any tokens in the text stream. Moves them | 239 /// Method apply extracts any tokens in the text stream. Moves them |
240 /// into the base stream. Finally, it calls virtual method MyApply | 240 /// into the base stream. Finally, it calls virtual method MyApply |
241 /// to do the actions of the directive. | 241 /// to do the actions of the directive. |
242 class Directive { | 242 class Directive { |
243 Directive(const Directive&) LLVM_DELETED_FUNCTION; | 243 Directive(const Directive&) = delete; |
244 void operator=(const Directive&) LLVM_DELETED_FUNCTION; | 244 void operator=(const Directive&) = delete; |
245 public: | 245 public: |
246 /// Creates a directive for the given stream. | 246 /// Creates a directive for the given stream. |
247 explicit Directive(TextFormatter *Formatter) | 247 explicit Directive(TextFormatter *Formatter) |
248 : Formatter(Formatter) {} | 248 : Formatter(Formatter) {} |
249 | 249 |
250 virtual ~Directive() {} | 250 virtual ~Directive() {} |
251 | 251 |
252 /// Returns the formatter associated with the directive. | 252 /// Returns the formatter associated with the directive. |
253 TextFormatter &GetFormatter() const { | 253 TextFormatter &GetFormatter() const { |
254 return *Formatter; | 254 return *Formatter; |
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
752 /// automatically insert the newline for you, if you did not add | 752 /// automatically insert the newline for you, if you did not add |
753 /// it. If multiple lines are to be buffered into the assembly stream, | 753 /// it. If multiple lines are to be buffered into the assembly stream, |
754 /// each line must be separated with a newline character. It is | 754 /// each line must be separated with a newline character. It is |
755 /// always safe to end all assembly lines with a newline character. | 755 /// always safe to end all assembly lines with a newline character. |
756 /// | 756 /// |
757 /// Also note that this class takes care of formatting records to fit | 757 /// Also note that this class takes care of formatting records to fit |
758 /// into a calculated record width (based on value set to | 758 /// into a calculated record width (based on value set to |
759 /// RecordWidth). On the other hand, we assume that the assembly is | 759 /// RecordWidth). On the other hand, we assume that the assembly is |
760 /// formatted by the caller (i.e. owner of this object). | 760 /// formatted by the caller (i.e. owner of this object). |
761 class ObjDumpStream { | 761 class ObjDumpStream { |
762 ObjDumpStream(const ObjDumpStream&) LLVM_DELETED_FUNCTION; | 762 ObjDumpStream(const ObjDumpStream&) = delete; |
763 void operator=(const ObjDumpStream&) LLVM_DELETED_FUNCTION; | 763 void operator=(const ObjDumpStream&) = delete; |
764 public: | 764 public: |
765 /// The default number of error messages that will be printed before | 765 /// The default number of error messages that will be printed before |
766 /// execution is stopped due to too many errors. | 766 /// execution is stopped due to too many errors. |
767 static unsigned DefaultMaxErrors; | 767 static unsigned DefaultMaxErrors; |
768 | 768 |
769 /// The default value for the column that separates records and | 769 /// The default value for the column that separates records and |
770 /// assembly, when DumpRecords and DumpAssembly is true. | 770 /// assembly, when DumpRecords and DumpAssembly is true. |
771 static unsigned ComboObjDumpSeparatorColumn; | 771 static unsigned ComboObjDumpSeparatorColumn; |
772 | 772 |
773 /// The default value for line width when DumpRecords is true, | 773 /// The default value for line width when DumpRecords is true, |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
958 RecordBuffer.clear(); | 958 RecordBuffer.clear(); |
959 AssemblyBuffer.clear(); | 959 AssemblyBuffer.clear(); |
960 MessageBuffer.clear(); | 960 MessageBuffer.clear(); |
961 } | 961 } |
962 }; | 962 }; |
963 | 963 |
964 } | 964 } |
965 } | 965 } |
966 | 966 |
967 #endif | 967 #endif |
OLD | NEW |