summaryrefslogtreecommitdiffstats
path: root/llvm/lib/TableGen
diff options
context:
space:
mode:
authorDavid Greene <greened@obbligato.org>2011-10-19 13:02:45 +0000
committerDavid Greene <greened@obbligato.org>2011-10-19 13:02:45 +0000
commitb77fc0d9065e860070b0f65c2270123f2cfb5ace (patch)
treeb2b9187cb7506dadfa56a9f4b1600fc71d9996ff /llvm/lib/TableGen
parentdb10e691385b507e09aa92db2bb1eb5a4138e991 (diff)
downloadbcm5719-llvm-b77fc0d9065e860070b0f65c2270123f2cfb5ace.tar.gz
bcm5719-llvm-b77fc0d9065e860070b0f65c2270123f2cfb5ace.zip
Add Record Init
Add an init function to be shared among Record constructors. llvm-svn: 142501
Diffstat (limited to 'llvm/lib/TableGen')
-rw-r--r--llvm/lib/TableGen/Record.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/TableGen/Record.cpp b/llvm/lib/TableGen/Record.cpp
index b12589b7e8d..4f38e144d94 100644
--- a/llvm/lib/TableGen/Record.cpp
+++ b/llvm/lib/TableGen/Record.cpp
@@ -1684,6 +1684,10 @@ void RecordVal::print(raw_ostream &OS, bool PrintSem) const {
unsigned Record::LastID = 0;
+void Record::init() {
+ checkName();
+}
+
void Record::checkName() {
// Ensure the record name has string type.
const TypedInit *TypedName = dynamic_cast<const TypedInit *>(Name);
OpenPOWER on IntegriCloud