Skip to content

Latest commit

 

History

History
45 lines (42 loc) · 1.51 KB

File metadata and controls

45 lines (42 loc) · 1.51 KB
title Function-Call Conversions | Microsoft Docs
ms.custom
ms.date 11/04/2016
ms.reviewer
ms.suite
ms.technology
cpp-language
ms.tgt_pltfrm
ms.topic article
dev_langs
C++
helpviewer_keywords
function calls, converting
function calls, argument type conversions
functions [C], argument conversions
ms.assetid 04ea0f81-509a-4913-8b12-0937a81babcf
caps.latest.revision 7
author mikeblome
ms.author mblome
manager ghogen
translation.priority.ht
cs-cz
de-de
es-es
fr-fr
it-it
ja-jp
ko-kr
pl-pl
pt-br
ru-ru
tr-tr
zh-cn
zh-tw

Function-Call Conversions

The type of conversion performed on the arguments in a function call depends on the presence of a function prototype (forward declaration) with declared argument types for the called function.

If a function prototype is present and includes declared argument types, the compiler performs type checking (see Functions).

If no function prototype is present, only the usual arithmetic conversions are performed on the arguments in the function call. These conversions are performed independently on each argument in the call. This means that a float value is converted to a double; a char or short value is converted to an int; and an unsigned char or unsigned short is converted to an unsigned int.

See Also

Type Conversions