From 3c7eb1f2ea231c046367023576311fbc4b1270e3 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 19 Aug 2003 21:57:00 +0000 Subject: [PATCH] Make assertion message more helpful in a case that might happen... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7975 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/Support/CommandLine.h | 3 ++- include/llvm/Support/CommandLine.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include/Support/CommandLine.h b/include/Support/CommandLine.h index 410361797a5..dcd3b5ba511 100644 --- a/include/Support/CommandLine.h +++ b/include/Support/CommandLine.h @@ -642,7 +642,8 @@ class opt_storage { void check() { assert(Location != 0 && "cl::location(...) not specified for a command " - "line option with external storage!"); + "line option with external storage, " + "or cl::init specified before cl::location()!!"); } public: opt_storage() : Location(0) {} diff --git a/include/llvm/Support/CommandLine.h b/include/llvm/Support/CommandLine.h index 410361797a5..dcd3b5ba511 100644 --- a/include/llvm/Support/CommandLine.h +++ b/include/llvm/Support/CommandLine.h @@ -642,7 +642,8 @@ class opt_storage { void check() { assert(Location != 0 && "cl::location(...) not specified for a command " - "line option with external storage!"); + "line option with external storage, " + "or cl::init specified before cl::location()!!"); } public: opt_storage() : Location(0) {}