Electronic Components Datasheet Search
  English  ▼

X  

78IV Datasheet(PDF) 67 Page - NEC

Part # 78IV
Description  CC78K4 Ver.2.30 or Later, C Compiler Language
PDF  523 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  NEC [NEC]
Direct Link  http://www.nec.com/
Logo NEC - NEC

78IV Datasheet(HTML) 67 Page - NEC

Back Button 78IV Datasheet HTML 63Page - NEC 78IV Datasheet HTML 64Page - NEC 78IV Datasheet HTML 65Page - NEC 78IV Datasheet HTML 66Page - NEC 78IV Datasheet HTML 67Page - NEC 78IV Datasheet HTML 68Page - NEC 78IV Datasheet HTML 69Page - NEC 78IV Datasheet HTML 70Page - NEC 78IV Datasheet HTML 71Page - NEC Next Button
Zoom Inzoom in Zoom Outzoom out
 67 / 523 page
background image
CHAPTER 4 TYPE CONVERSIONS
User’s Manual U15556EJ1V0UM
67
4.1 Arithmetic Operands
(1) Characters and integers (general integral promotion)
The data types of char, short int, and int bit fields (whether they are signed or unsigned) or of objects that have
an enumeration type will be converted to int types if their values are within the range that can be represented
with int types.
If not within the range, they will be converted to unsigned int types.
These implicit type
conversions are referred to as “general integral general promotion”.
All other arithmetic types will not be
changed by this general integral promotion.
In general integral promotion, the value of the original data type is retained, including its sign. char type data
without a type qualifier will normally be handled as signed char in this compiler.
If can also be handled as unsigned char by using an option.
(2) Signed integers and unsigned integers
When a value with an integer type is converted to another, the value will not be changed if the value can be
expressed by the integer type after conversion.
When a signed integer is converted to an unsigned integer of the same or larger size, the value is not changed
unless the value of the signed integer is negative. If the value of the signed integer is negative and the unsigned
integer has a size larger than that of the signed integer, the signed integer is expanded to the signed integer with
the same size as the unsigned integer, and then it is added to the value equal to the maximum number that can
be expressed with the unsigned integer plus 1, and the signed integer before conversion is converted to the
unsigned value.
When a value with an integer type is converted to an unsigned integer with a smaller size, the conversion result
is the non-negative remainder of the value divided with that value which 1 is added to the maximum number that
can be expressed with an unsigned integer after conversion. When a value with an integer type is converted to a
signed integer with smaller size or when an unsigned integer is converted to a signed integer with the same size,
the overflowed value is ignored if the value after conversion cannot be expressed. For the conversion pattern,
refer to Table 4-1. List of Conversions between Types.
Conversion operations from signed integral type to unsigned integral type are as listed in Table 4-2 below.
Table 4-2. Conversions from Signed Integral Type to Unsigned Integral Type
unsigned
Smaller in Value Range
Greater in Value Range
+/
signed
–
/+
: Type conversion will be performed properly.
+: The data will be converted to a positive integer.
/: The result of the conversion will be the remainder of the integer value, modulo the largest
possible value of the type to be converted plus 1.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com