@@ -816,9 +816,34 @@ ERROR(cannot_return_value_from_void_func,none,
816
816
NOTE(add_return_type_note,none,
817
817
" did you mean to add a return type?" , ())
818
818
819
- ERROR(expect_compile_time_const ,none,
819
+ ERROR(expect_compile_time_literal ,none,
820
820
" expect a compile-time constant literal" , ())
821
821
822
+ ERROR(const_unsupported_enum_associated_value,none,
823
+ " enums with associated values not supported in a '@const' expression" , ())
824
+ ERROR(const_unsupported_operator,none,
825
+ " unsupported operator in a '@const' expression" , ())
826
+ ERROR(const_unsupported_type,none,
827
+ " unsupported type in a '@const' expression" , ())
828
+ ERROR(const_unsupported_type_expr,none,
829
+ " type expressions not supported in a '@const' expression" , ())
830
+ ERROR(const_unsupported_closure,none,
831
+ " closures not supported in a '@const' expression" , ())
832
+ ERROR(const_unsupported_keypath,none,
833
+ " keypaths not supported in a '@const' expression" , ())
834
+ ERROR(const_opaque_decl_ref,none,
835
+ " unable to resolve variable reference in a '@const' expression" , ())
836
+ ERROR(const_opaque_func_decl_ref,none,
837
+ " unable to resolve function reference in a '@const' expression" , ())
838
+ ERROR(const_non_convention_c_conversion,none,
839
+ " only 'convention(c)' function values are supported in a '@const' expression" , ())
840
+ ERROR(const_opaque_callee,none,
841
+ " unable to resolve callee in a '@const' expression" , ())
842
+ ERROR(const_non_const_param,none,
843
+ " reference to a non-'@const' parameter in a '@const' expression" , ())
844
+ ERROR(const_unknown_default,none,
845
+ " not supported in a '@const' expression" , ())
846
+
822
847
// ------------------------------------------------------------------------------
823
848
// MARK: Import Resolution
824
849
// ------------------------------------------------------------------------------
0 commit comments