Give a nice error message on Kaleidoscope.use() when compiling with V2 API only

In preparation for the sunset of the V1 API, when using the V2 API only, give a
nice error message on `Kaleidoscope.use()`, instead of simply not defining it.
This makes the upgrade path a little easier.

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/345/head
Gergely Nagy 6 years ago
parent d945cba325
commit 051ec97186

@ -140,6 +140,11 @@ class Kaleidoscope_ {
use(plugins...);
#pragma GCC diagnostic pop
}
#else
// NOTE: Do **NOT** remove this when sunsetting the V1 API!
inline void use(...) {
static_assert(false, _DEPRECATE(_DEPRECATED_MESSAGE_USE));
}
#endif
// ---- hooks ----

Loading…
Cancel
Save