Skip to content

Commit 05b3ba4

Browse files
committed
Move enum idt to the single translation unit that actually requires it
1 parent c889412 commit 05b3ba4

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/util/irep_ids.cpp

+8
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,14 @@ const char *irep_ids_table[]=
2727

2828
#ifdef USE_DSTRING
2929

30+
enum class idt:unsigned
31+
{
32+
#define IREP_ID_ONE(the_id) id_##the_id,
33+
#define IREP_ID_TWO(the_id, str) id_##the_id,
34+
35+
#include "irep_ids.def"
36+
};
37+
3038
#define IREP_ID_ONE(the_id) \
3139
const dstringt ID_##the_id=dstringt::make_from_table_index( \
3240
static_cast<unsigned>(idt::id_##the_id));

src/util/irep_ids.h

-8
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,6 @@ Author: Reuben Thomas, [email protected]
3333
/// into a const extern irep_idt with the variable name `ID_param` and the
3434
/// string value `"contents"`.
3535

36-
enum class idt:unsigned
37-
{
38-
#define IREP_ID_ONE(the_id) id_##the_id,
39-
#define IREP_ID_TWO(the_id, str) id_##the_id,
40-
41-
#include "irep_ids.def"
42-
};
43-
4436
#ifdef USE_DSTRING
4537

4638
#define IREP_ID_ONE(the_id) extern const dstringt ID_##the_id;

0 commit comments

Comments
 (0)