[ClangImporter] Be more careful about stripping 'k' from enum constants.

This condition was wrong and could occasionally produce enum constant
names that started with digits.

rdar://problem/21820628

Swift SVN r30549
This commit is contained in:
Jordan Rose
2015-07-23 20:50:49 +00:00
parent dac6052cb2
commit bfd30db4c2
3 changed files with 20 additions and 4 deletions

View File

@@ -43,3 +43,12 @@ typedef CF_OPTIONS(UInt32, FakeAudioComponentFlags) {
kFakeAudioComponentFlag_LoadOutOfProcess = 1,
kFakeAudioComponentFlag_LoadInProcess = 2,
};
// From <AudioUnit/AudioUnitProperties.h>
// This enum has a digit immediately after the leading 'k'.
typedef CF_ENUM(UInt32, AU3DMixerAttenuationCurve) {
k3DMixerAttenuationCurve_Power = 0,
k3DMixerAttenuationCurve_Exponential = 1,
k3DMixerAttenuationCurve_Inverse = 2,
k3DMixerAttenuationCurve_Linear = 3
};