Create Static Slice from another Static Slice?
23:25 20 Feb 2022

I have two static slices that look something like this:

static ITEMS_1 : &'static [&str] = &[
    "abc",
    "def",
];

static ITEMS_2 : &'static [&str] = &[
    "abc",
    "def",
    "ghi"
];

The first two entries of ITEMS_2 should match those of ITEMS_1. So, I want to define ITEMS_2 as ITEMS_1 appended with another item (or more) to avoid duplication. Is there any sensible way of doing this?

rust