pub fn build_raw_program(
    project_config: &ProjectConfig,
    graphql_asts: &FnvHashMap<SourceSetName, GraphQLAsts>,
    schema: Arc<SDLSchema>,
    log_event: &impl PerfLogEvent,
    is_incremental_build: bool,
) -> Result<(Program, FnvHashSet<StringKey>, SourceHashes), BuildProjectError> {
    // Build a type aware IR.
    let BuildIRResult {
        ir,
        base_fragment_names,
        source_hashes,
    } = log_event.time("build_ir_time", || {
        build_ir::build_ir(project_config, &schema, graphql_asts, is_incremental_build)
            .map_err(|errors| BuildProjectError::ValidationErrors { errors })
    })?;

    // Turn the IR into a base Program.
    let program = log_event.time("build_program_time", || {
        Program::from_definitions(schema, ir)
    });

    Ok((program, base_fragment_names, source_hashes))
}
/// This program doesn't have IR transforms applied to it, so it's not optimized.
/// It's perfect for the LSP server: we have all the documents with
/// their locations to provide information to go_to_definition, hover, etc.
This program doesn't have IR transforms applied to it, so it's not optimized.
It's perfect for the LSP server: we have all the documents with
their locations to provide information to go_to_definition, hover, etc.
This program doesn ' t have IR transforms applied to it so it ' s not optimized . It ' s perfect for the LSP server : we have all the documents with their locations to provide information to go_to_definition hover etc .
pub fn build_raw_program(
    project_config: &ProjectConfig,
    graphql_asts: &FnvHashMap<SourceSetName, GraphQLAsts>,
    schema: Arc<SDLSchema>,
    log_event: &impl PerfLogEvent,
    is_incremental_build: bool,
) -> Result<(Program, FnvHashSet<StringKey>, SourceHashes), BuildProjectError> {
    // Build a type aware IR.
    let BuildIRResult {
        ir,
        base_fragment_names,
        source_hashes,
    } = log_event.time("build_ir_time", || {
        build_ir::build_ir(project_config, &schema, graphql_asts, is_incremental_build)
            .map_err(|errors| BuildProjectError::ValidationErrors { errors })
    })?;
    // Turn the IR into a base Program.
    let program = log_event.time("build_program_time", || {
        Program::from_definitions(schema, ir)
    });
    Ok((program, base_fragment_names, source_hashes))
}
pub fn build_raw_program ( project_config : & ProjectConfig , graphql_asts : & FnvHashMap < SourceSetName , GraphQLAsts > , schema : Arc < SDLSchema > , log_event : & impl PerfLogEvent , is_incremental_build : bool , ) -> Result < ( Program , FnvHashSet < StringKey > , SourceHashes ) , BuildProjectError > { // Build a type aware IR. let BuildIRResult { ir , base_fragment_names , source_hashes , } = log_event . time ( " " , | | { build_ir :: build_ir ( project_config , & schema , graphql_asts , is_incremental_build ) . map_err ( | errors | BuildProjectError :: ValidationErrors { errors } ) } ) ? ; // Turn the IR into a base Program. let program = log_event . time ( " " , | | { Program :: from_definitions ( schema , ir ) } ) ; Ok ( ( program , base_fragment_names , source_hashes ) ) }
This program doesn't have IR transforms applied to it, so it's not optimized.
This program doesn ' t have IR transforms applied to it so it ' s not optimized .
project_config
&ProjectConfig
graphql_asts
&FnvHashMap<SourceSetName, GraphQLAsts>
schema
Arc<SDLSchema>
log_event
&impl PerfLogEvent
is_incremental_build
bool
project_config
&ProjectConfig
graphql_asts
&FnvHashMap<SourceSetName, GraphQLAsts>
schema
Arc<SDLSchema>
log_event
&impl PerfLogEvent
is_incremental_build
bool