First off, I've seen this question and understand why the following code doesn't work. That is not my question.
I have a constant, which is declared like;
//Constants.h
extern NSString * const MyConstant;
//Constants.m
NSString * const MyConstant = @"MyConstant";
However, in certain contexts, it's more useful to have this constant have a much more descriptive name, like MyReallySpecificConstant
. I was hoping to do:
//SpecificConstants.h
extern NSString * const MyReallySpecificConstant;
//SpecificConstants.m
#import "Constants.h"
NSString * const MyReallySpecificConstant = MyConstant;
Obviously I cannot do this (which is explained in the linked question above).
My question is:
How else (besides something like #define MyReallySpecificConstant MyConstant
) can I provide a single constant under multiple names?