@@ -150,7 +150,8 @@ impl<B, C> ControlFlow<B, C> {
150150 /// ```
151151 #[ inline]
152152 #[ stable( feature = "control_flow_enum_is" , since = "1.59.0" ) ]
153- pub fn is_break ( & self ) -> bool {
153+ #[ rustc_const_unstable( feature = "const_control_flow" , issue = "none" ) ]
154+ pub const fn is_break ( & self ) -> bool {
154155 matches ! ( * self , ControlFlow :: Break ( _) )
155156 }
156157
@@ -166,7 +167,8 @@ impl<B, C> ControlFlow<B, C> {
166167 /// ```
167168 #[ inline]
168169 #[ stable( feature = "control_flow_enum_is" , since = "1.59.0" ) ]
169- pub fn is_continue ( & self ) -> bool {
170+ #[ rustc_const_unstable( feature = "const_control_flow" , issue = "none" ) ]
171+ pub const fn is_continue ( & self ) -> bool {
170172 matches ! ( * self , ControlFlow :: Continue ( _) )
171173 }
172174
@@ -257,7 +259,8 @@ impl<B, C> ControlFlow<B, C> {
257259 /// ```
258260 #[ inline]
259261 #[ unstable( feature = "control_flow_ok" , issue = "140266" ) ]
260- pub fn break_ok ( self ) -> Result < B , C > {
262+ #[ rustc_const_unstable( feature = "const_control_flow" , issue = "none" ) ]
263+ pub const fn break_ok ( self ) -> Result < B , C > {
261264 match self {
262265 ControlFlow :: Continue ( c) => Err ( c) ,
263266 ControlFlow :: Break ( b) => Ok ( b) ,
@@ -361,7 +364,8 @@ impl<B, C> ControlFlow<B, C> {
361364 /// ```
362365 #[ inline]
363366 #[ unstable( feature = "control_flow_ok" , issue = "140266" ) ]
364- pub fn continue_ok ( self ) -> Result < C , B > {
367+ #[ rustc_const_unstable( feature = "const_control_flow" , issue = "none" ) ]
368+ pub const fn continue_ok ( self ) -> Result < C , B > {
365369 match self {
366370 ControlFlow :: Continue ( c) => Ok ( c) ,
367371 ControlFlow :: Break ( b) => Err ( b) ,
0 commit comments