Copy compileTimeInitializer for const property descriptor

#KT-15802 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2017-02-06 17:27:57 +03:00
parent 81c3edfc00
commit 655cf82534
26 changed files with 115 additions and 33 deletions
@@ -1,5 +1,5 @@
/*
* Copyright 2010-2016 JetBrains s.r.o.
* Copyright 2010-2017 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -333,6 +333,10 @@ public class PropertyDescriptorImpl extends VariableDescriptorWithInitializerImp
substitutedDescriptor.setOverriddenDescriptors(overridden);
}
if (isConst() && compileTimeInitializer != null) {
substitutedDescriptor.setCompileTimeInitializer(compileTimeInitializer);
}
return substitutedDescriptor;
}