cprover
cpp_typecheck_resolvet Class Reference

#include <cpp_typecheck_resolve.h>

Collaboration diagram for cpp_typecheck_resolvet:
[legend]

Classes

struct  matcht
 

Public Types

enum  wantt { wantt::VAR, wantt::TYPE, wantt::BOTH }
 

Public Member Functions

 cpp_typecheck_resolvet (class cpp_typecheckt &_cpp_typecheck)
 
exprt resolve (const cpp_namet &cpp_name, const wantt want, const cpp_typecheck_fargst &fargs, bool fail_with_exception=true)
 
cpp_scopetresolve_scope (const cpp_namet &cpp_name, irep_idt &base_name, cpp_template_args_non_tct &template_args)
 
cpp_scopetresolve_namespace (const cpp_namet &cpp_name)
 

Protected Types

typedef std::vector< exprtresolve_identifierst
 

Protected Member Functions

void convert_identifiers (const cpp_scopest::id_sett &id_set, const wantt want, const cpp_typecheck_fargst &fargs, resolve_identifierst &identifiers)
 
exprt convert_template_parameter (const cpp_idt &id)
 
exprt convert_identifier (const cpp_idt &id, const wantt want, const cpp_typecheck_fargst &fargs)
 
void disambiguate_functions (resolve_identifierst &identifiers, const cpp_typecheck_fargst &fargs)
 
void exact_match_functions (resolve_identifierst &identifiers, const cpp_typecheck_fargst &fargs)
 
void filter (resolve_identifierst &identifiers, const wantt want)
 
symbol_typet disambiguate_template_classes (const irep_idt &base_name, const cpp_scopest::id_sett &id_set, const cpp_template_args_non_tct &template_args)
 disambiguate partial specialization More...
 
void make_constructors (resolve_identifierst &identifiers)
 
void apply_template_args (resolve_identifierst &identifiers, const cpp_template_args_non_tct &template_args, const cpp_typecheck_fargst &fargs)
 
void apply_template_args (exprt &expr, const cpp_template_args_non_tct &template_args, const cpp_typecheck_fargst &fargs)
 
void guess_function_template_args (resolve_identifierst &identifiers, const cpp_typecheck_fargst &fargs)
 guess arguments of function templates More...
 
void remove_templates (resolve_identifierst &identifiers)
 
void remove_duplicates (resolve_identifierst &identifiers)
 
exprt guess_function_template_args (const exprt &expr, const cpp_typecheck_fargst &fargs)
 Guess template arguments for function templates. More...
 
void guess_template_args (const typet &template_parameter, const typet &desired_type)
 
void guess_template_args (const exprt &template_parameter, const exprt &desired_expr)
 
bool disambiguate_functions (const exprt &expr, unsigned &args_distance, const cpp_typecheck_fargst &fargs)
 
exprt do_builtin (const irep_idt &base_name, const cpp_template_args_non_tct &template_args)
 
void show_identifiers (const irep_idt &base_name, const resolve_identifierst &identifiers, std::ostream &out)
 
void resolve_with_arguments (cpp_scopest::id_sett &id_set, const irep_idt &base_name, const cpp_typecheck_fargst &fargs)
 
void filter_for_named_scopes (cpp_scopest::id_sett &id_set)
 
void filter_for_namespaces (cpp_scopest::id_sett &id_set)
 

Protected Attributes

cpp_typechecktcpp_typecheck
 
source_locationt source_location
 
cpp_scopetoriginal_scope
 

Detailed Description

Definition at line 20 of file cpp_typecheck_resolve.h.

Member Typedef Documentation

◆ resolve_identifierst

typedef std::vector<exprt> cpp_typecheck_resolvet::resolve_identifierst
protected

Definition at line 48 of file cpp_typecheck_resolve.h.

Member Enumeration Documentation

◆ wantt

Enumerator
VAR 
TYPE 
BOTH 

Definition at line 26 of file cpp_typecheck_resolve.h.

Constructor & Destructor Documentation

◆ cpp_typecheck_resolvet()

cpp_typecheck_resolvet::cpp_typecheck_resolvet ( class cpp_typecheckt _cpp_typecheck)

Definition at line 32 of file cpp_typecheck_resolve.cpp.

Member Function Documentation

◆ apply_template_args() [1/2]

void cpp_typecheck_resolvet::apply_template_args ( resolve_identifierst identifiers,
const cpp_template_args_non_tct template_args,
const cpp_typecheck_fargst fargs 
)
protected

Definition at line 61 of file cpp_typecheck_resolve.cpp.

References irept::id(), irept::is_not_nil(), and exprt::type().

Referenced by resolve().

◆ apply_template_args() [2/2]

◆ convert_identifier()

◆ convert_identifiers()

void cpp_typecheck_resolvet::convert_identifiers ( const cpp_scopest::id_sett id_set,
const wantt  want,
const cpp_typecheck_fargst fargs,
resolve_identifierst identifiers 
)
protected

Definition at line 37 of file cpp_typecheck_resolve.cpp.

References convert_identifier(), irept::id(), id_set, irept::is_not_nil(), and exprt::type().

Referenced by resolve().

◆ convert_template_parameter()

◆ disambiguate_functions() [1/2]

◆ disambiguate_functions() [2/2]

◆ disambiguate_template_classes()

◆ do_builtin()

◆ exact_match_functions()

void cpp_typecheck_resolvet::exact_match_functions ( resolve_identifierst identifiers,
const cpp_typecheck_fargst fargs 
)
protected

Definition at line 415 of file cpp_typecheck_resolve.cpp.

References disambiguate_functions(), and cpp_typecheck_fargst::in_use.

Referenced by resolve().

◆ filter()

void cpp_typecheck_resolvet::filter ( resolve_identifierst identifiers,
const wantt  want 
)
protected

Definition at line 378 of file cpp_typecheck_resolve.cpp.

References BOTH, TYPE, and VAR.

Referenced by resolve().

◆ filter_for_named_scopes()

◆ filter_for_namespaces()

void cpp_typecheck_resolvet::filter_for_namespaces ( cpp_scopest::id_sett id_set)
protected

Definition at line 2342 of file cpp_typecheck_resolve.cpp.

References id_set.

Referenced by resolve_namespace().

◆ guess_function_template_args() [1/2]

void cpp_typecheck_resolvet::guess_function_template_args ( resolve_identifierst identifiers,
const cpp_typecheck_fargst fargs 
)
protected

◆ guess_function_template_args() [2/2]

◆ guess_template_args() [1/2]

◆ guess_template_args() [2/2]

◆ make_constructors()

◆ remove_duplicates()

void cpp_typecheck_resolvet::remove_duplicates ( resolve_identifierst identifiers)
protected

Definition at line 155 of file cpp_typecheck_resolve.cpp.

Referenced by resolve().

◆ remove_templates()

void cpp_typecheck_resolvet::remove_templates ( resolve_identifierst identifiers)
protected

Definition at line 139 of file cpp_typecheck_resolve.cpp.

References cpp_typecheck, and namespace_baset::follow().

Referenced by resolve().

◆ resolve()

exprt cpp_typecheck_resolvet::resolve ( const cpp_namet cpp_name,
const wantt  want,
const cpp_typecheck_fargst fargs,
bool  fail_with_exception = true 
)

◆ resolve_namespace()

◆ resolve_scope()

◆ resolve_with_arguments()

void cpp_typecheck_resolvet::resolve_with_arguments ( cpp_scopest::id_sett id_set,
const irep_idt base_name,
const cpp_typecheck_fargst fargs 
)
protected

◆ show_identifiers()

void cpp_typecheck_resolvet::show_identifiers ( const irep_idt base_name,
const resolve_identifierst identifiers,
std::ostream &  out 
)
protected

Member Data Documentation

◆ cpp_typecheck

◆ original_scope

cpp_scopet* cpp_typecheck_resolvet::original_scope
protected

◆ source_location


The documentation for this class was generated from the following files: