From 0344e23236c8e28b80ce1b14a3a4394918953f2e Mon Sep 17 00:00:00 2001 From: Pierre-Emmanuel Patry Date: Wed, 8 Nov 2023 10:50:00 +0100 Subject: gccrs: Add new keyword utility class Much like attributes values, keywords are known beforehand and never change. Instead of relying on handcrafted string we could centralize everything in one place. We may require to check whether a word is a keyword, which can now be done easily thanks to the keyword set. gcc/rust/ChangeLog: * Make-lang.in: Add rust-keyword-values.cc to the list. * util/rust-keyword-values.cc: New file. * util/rust-keyword-values.h: New file. Signed-off-by: Pierre-Emmanuel Patry --- gcc/rust/Make-lang.in | 1 + 1 file changed, 1 insertion(+) (limited to 'gcc/rust/Make-lang.in') diff --git a/gcc/rust/Make-lang.in b/gcc/rust/Make-lang.in index 1ff179f..f2cadd5 100644 --- a/gcc/rust/Make-lang.in +++ b/gcc/rust/Make-lang.in @@ -100,6 +100,7 @@ GRS_OBJS = \ rust/rust-hir.o \ rust/rust-hir-map.o \ rust/rust-attributes.o \ + rust/rust-keyword-values.o \ rust/rust-abi.o \ rust/rust-token-converter.o \ rust/rust-macro.o \ -- cgit v1.1