gccrs: Document proc macro token tree indices
commit3a874d936b2fcbb1c77b146d8b1d651e52eb618f
authorPierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Mon, 23 Oct 2023 13:00:54 +0000 (23 15:00 +0200)
committerArthur Cohen <arthur.cohen@embecosm.com>
Tue, 16 Jan 2024 18:09:34 +0000 (16 19:09 +0100)
tree8fa93d8cb7094eb4b993d9c547ee052b1003bd57
parent0f04ac6eecd1214fe7403945874e125f92d58d9c
gccrs: Document proc macro token tree indices

Multiple references to procedural macro token trees were left as magic
number in the code. This commit introduces some constexpr for those along
some explanation for the selected value.

gcc/rust/ChangeLog:

* backend/rust-compile-base.cc (get_attributes): Add documentation for
indices 3 and 4.
(get_trait_name): Add documentation for index 1.

Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
gcc/rust/backend/rust-compile-base.cc