Method code for $dictionary.apply_to_keys()

[Turn on line numbering]
arg tdict, dict;
var x, newdict;

// Apply a t-dict to the keys of a dict
newdict = #[];
for x in (dict) {
    catch ~keynf
        x = x.replace(1, tdict[x[1]]);
    newdict = newdict.add(@x);
}
return newdict;

// Created 27-Mar-1995 as a part of ColdCore, see: @help Credit

Tlon