module volt.semantic.implicit

Code Map

module volt.semantic.implicit;


enum IgnoreConst;

//! Call checkAndDoConvert, but convert string literals into pointers, if
//! needed.
fn checkAndConvertStringLiterals(ctx: Context, type: ir.Type, exp: ir.Exp) { }
//! If exp will convert into type, call doConvert to do it, otherwise throw
//! an error, with the loc set to exp.loc.
fn checkAndDoConvert(ctx: Context, type: ir.Type, exp: ir.Exp) { }
//! Returns true if the given expression's type converts into type.
fn willConvert(ctx: Context, type: ir.Type, exp: ir.Exp, ignoreConst: bool) bool { }
//! Returns true if arg converts into param.
fn willConvert(ltype: ir.Type, rtype: ir.Type, ignoreConst: bool) bool { }
fn willConvertCallable(l: ir.Type, r: ir.Type, ignoreConst: bool) bool { }
fn willConvertInterface(l: ir.Type, rInterface: ir._Interface, ignoreConst: bool) bool { }
fn willConvertClassToInterface(lInterface: ir._Interface, rClass: ir.Class, ignoreConst: bool) bool { }
//! Change exp so its type is type. This function assumes that willConvert
//! returns true on the given expression.
fn doConvert(ctx: Context, type: ir.Type, exp: ir.Exp) { }
fn checkAndConvertStringLiterals(ctx: Context, type: ir.Type, exp: ir.Exp)

Call checkAndDoConvert, but convert string literals into pointers, if needed.

fn checkAndDoConvert(ctx: Context, type: ir.Type, exp: ir.Exp)

If exp will convert into type, call doConvert to do it, otherwise throw an error, with the loc set to exp.loc.

fn willConvert(ctx: Context, type: ir.Type, exp: ir.Exp, ignoreConst: bool) bool

Returns true if the given expression's type converts into type.

fn willConvert(ltype: ir.Type, rtype: ir.Type, ignoreConst: bool) bool

Returns true if arg converts into param.

fn doConvert(ctx: Context, type: ir.Type, exp: ir.Exp)

Change exp so its type is type. This function assumes that willConvert returns true on the given expression.