File tree Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Expand file tree Collapse file tree 1 file changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -351,6 +351,26 @@ fn map_lib_features(base_src_path: &Path,
351351 }
352352 }
353353 becoming_feature = None ;
354+ if line. contains ( "rustc_const_unstable(" ) {
355+ // const fn features are handled specially
356+ let feature_name = match find_attr_val ( line, "feature" ) {
357+ Some ( name) => name,
358+ None => err ! ( "malformed stability attribute" ) ,
359+ } ;
360+ let feature = Feature {
361+ level : Status :: Unstable ,
362+ since : "None" . to_owned ( ) ,
363+ has_gate_test : false ,
364+ // Whether there is a common tracking issue
365+ // for these feature gates remains an open question
366+ // https://github.com/rust-lang/rust/issues/24111#issuecomment-340283184
367+ // But we take 24111 otherwise they will be shown as
368+ // "internal to the compiler" which they are not.
369+ tracking_issue : Some ( 24111 ) ,
370+ } ;
371+ mf ( Ok ( ( feature_name, feature) ) , file, i + 1 ) ;
372+ continue ;
373+ }
354374 let level = if line. contains ( "[unstable(" ) {
355375 Status :: Unstable
356376 } else if line. contains ( "[stable(" ) {
You can’t perform that action at this time.
0 commit comments