This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
ide-diagnostics/src/handlers Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ pub(crate) fn unresolved_proc_macro(
3232 let severity = if config_enabled { Severity :: Error } else { Severity :: WeakWarning } ;
3333 let def_map = ctx. sema . db . crate_def_map ( d. krate ) ;
3434 let message = if config_enabled {
35- def_map. proc_macro_loading_error ( ) . unwrap_or ( "proc macro not found in the built dylib " )
35+ def_map. proc_macro_loading_error ( ) . unwrap_or ( "internal error " )
3636 } else {
3737 match d. kind {
3838 hir:: MacroKind :: Attr if proc_macros_enabled => "attribute macro expansion is disabled" ,
Original file line number Diff line number Diff line change @@ -528,10 +528,16 @@ impl GlobalState {
528528 ( crate_graph, proc_macros, crate_graph_file_dependencies)
529529 } ;
530530
531+ let mut change = Change :: new ( ) ;
531532 if self . config . expand_proc_macros ( ) {
533+ change. set_proc_macros (
534+ crate_graph
535+ . iter ( )
536+ . map ( |id| ( id, Err ( "Proc-macros have not been built yet" . to_owned ( ) ) ) )
537+ . collect ( ) ,
538+ ) ;
532539 self . fetch_proc_macros_queue . request_op ( cause, proc_macro_paths) ;
533540 }
534- let mut change = Change :: new ( ) ;
535541 change. set_crate_graph ( crate_graph) ;
536542 self . analysis_host . apply_change ( change) ;
537543 self . crate_graph_file_dependencies = crate_graph_file_dependencies;
You can’t perform that action at this time.
0 commit comments