home *** CD-ROM | disk | FTP | other *** search
/ Power GUI Programming with VisualAge C++ / powergui.iso / trialva / ibmcppw / help / cppprog.inf (.txt) < prev    next >
Encoding:
OS/2 Help File  |  1996-02-22  |  624.7 KB  |  21,471 lines

Text Truncated. Only the first 1MB is shown below. Download the file for the complete contents.
  1.  
  2. ΓòÉΓòÉΓòÉ 1. About this Book ΓòÉΓòÉΓòÉ
  3.  
  4. This book describes coding techniques such as multithreading, creating DLLs, 
  5. using templates, signal and exception handling, and managing memory. The book 
  6. focuses mostly on the C and C++ techniques involved, rather than the lower 
  7. level Windows techniques. This book is written for application and systems 
  8. programmers who want to use IBM VisualAge for C++ for Windows, Version 3.5 to 
  9. develop and run C or C++ programming applications. You should have a working 
  10. knowledge of the C or C++ programming language, the Windows operating system, 
  11. and other products described in Welcome to VisualAge for C++. 
  12.  
  13. For an overview and tour of VisualAge for C++, see the Welcome to VisualAge for 
  14. C++. For introductory information on how to use the VisualAge for C++ compiler 
  15. and tools to compile, link, debug, browse, and trace your program, see the 
  16. User's Guide. For reference information on the more technical aspects of the 
  17. compiler and advanced programming techniques, use this book. 
  18.  
  19.  
  20. ΓòÉΓòÉΓòÉ 1.1. Notices ΓòÉΓòÉΓòÉ
  21.  
  22. Copyright International Business Machines Corporation, 1992, 1996. All rights 
  23. reserved. 
  24.  
  25. Note to U.S. Government Users - Documentation related to restricted rights - 
  26. Use, duplication, or disclosure is subject to restrictions set forth in GSA ADP 
  27. Schedule Contract with IBM Corp. 
  28.  
  29. First Edition. 
  30.  
  31. This edition applies to Version 3.5 of IBM VisualAge for C++ for Windows 
  32. (33H4979, 33H4980) and to all subsequent releases and modifications until 
  33. otherwise indicated in new editions.  Make sure you are using the correct 
  34. edition for the level of the product. 
  35.  
  36. This publication could include technical inaccuracies or typographical errors. 
  37. Changes are periodically made to the information herein; any such changes will 
  38. be reported in subsequent revisions. 
  39.  
  40. Requests for publications and for technical information about IBM products 
  41. should be made to your IBM Authorized Dealer or your IBM Marketing 
  42. Representative. 
  43.  
  44. When you send information to IBM, you grant IBM a nonexclusive right to use or 
  45. distribute the information in any way it believes appropriate without incurring 
  46. any obligation to you. 
  47.  
  48. Any reference to an IBM licensed program in this publication is not intended to 
  49. state or imply that only IBM's licensed program may be used. Any functionally 
  50. equivalent product, program, or service that does not infringe any of IBM's 
  51. intellectual property rights may be used instead of the IBM product, program, 
  52. or service. Evaluation and verification of operation in conjunction with other 
  53. products, except  those expressly designated by IBM, is the user's 
  54. responsibility. 
  55.  
  56. IBM may have patents or pending patent applications covering subject matter in 
  57. this document.  The furnishing of this document does not give you any license 
  58. to these patents.  You can send license inquiries, in writing, to the IBM 
  59. Director of Licensing, IBM Corporation, 500 Columbus Avenue, Thornwood, NY, 
  60. 10594, USA. 
  61.  
  62. Licensees of this program who wish to have information about it for the purpose 
  63. of enabling: (i) the exchange of information between independent created 
  64. programs and other programs (including this one) and (ii) the mutual use of the 
  65. information which has been exchanged, should contact IBM Canada Ltd., 
  66. Department 071, 1150 Eglinton Avenue East, North York, Ontario M3C 1H7, Canada. 
  67. Such information may be available, subject to appropriate terms and conditions, 
  68. including in some cases payment of a fee. 
  69.  
  70.  
  71. ΓòÉΓòÉΓòÉ 1.2. Trademarks and Service Marks ΓòÉΓòÉΓòÉ
  72.  
  73. The following terms are trademarks of International Business Machines 
  74. Corporation in the United States or other countries or both : 
  75.  
  76.       IBM 
  77.       IBMLink 
  78.       Open Class 
  79.       Personal System/2 
  80.       PS/2 
  81.       Project Smarts 
  82.       VisualAge 
  83.       WorkFrame 
  84.       System Object Model 
  85.       SOM 
  86.  
  87.  Windows and Windows NT are trademarks of the Microsoft Corporation. 
  88.  
  89.  Other company, product, and service names, which may be denoted by a double 
  90.  asterisk(**), may be trademarks or service marks of others. 
  91.  
  92.  Before you begin to use this information, it would be helpful to understand 
  93.  how to navigate through it. You can use the Table of Contents and Index 
  94.  facility to locate topics and the Search facility to search the text of this 
  95.  document. You can use hypertext links to acquire related information on the 
  96.  current topic. Hypertext links appear in a different color. For example, here 
  97.  is a link to another panel: Communicating Your Comments to IBM. By 
  98.  double-clicking on the text of the link or by pressing Enter on a highlighted 
  99.  link, you will open a panel of related information. When you open a panel, the 
  100.  first link has the focus; to shift the focus to other links, use the Tab key. 
  101.  
  102.  You should also understand: 
  103.  
  104.      How to Use the Contents 
  105.      How to Obtain Additional Information 
  106.      How to Use Action Bar Choices 
  107.      How to Cut and Paste Examples 
  108.  
  109.  
  110. ΓòÉΓòÉΓòÉ 1.3. How to Use the Contents ΓòÉΓòÉΓòÉ
  111.  
  112. When the Contents window first appears, some topics have a plus (+) sign beside 
  113. them. The plus sign indicates that additional topics are available. 
  114.  
  115. To expand the Contents if you are using a mouse, click on the plus sign.  If 
  116. you are using the keyboard, use the Up or Down Arrow key to highlight the 
  117. topic, and press the plus (+) key. For example, How to Use the Contents has a 
  118. plus sign beside it.  To see additional topics for that heading, click on the 
  119. plus sign or highlight that topic and press the plus (+) key. 
  120.  
  121. To view a topic, double-click on the topic (or press the Up or Down Arrow key 
  122. to highlight the topic, and then press the Enter key). 
  123.  
  124.  
  125. ΓòÉΓòÉΓòÉ 1.4. How to Obtain Additional Information ΓòÉΓòÉΓòÉ
  126.  
  127. After you select a topic, the information for that topic appears in a window. 
  128. Highlighted words or phrases indicate that additional information is available. 
  129. Certain words and phrases are highlighted in a different color from the 
  130. surrounding text. These are called hypertext terms. 
  131.  
  132. If you are using a mouse, double-click on the highlighted word.  If you are 
  133. using a keyboard, press the Tab key to move to the highlighted word, and then 
  134. press the Enter key.  Additional information then appears in a window. 
  135.  
  136.  
  137. ΓòÉΓòÉΓòÉ 1.5. How to Use Action Bar Choices ΓòÉΓòÉΓòÉ
  138.  
  139. Several choices are available for managing the information presented in this 
  140. document. There are three menus on the action bar:  the Services menu, the 
  141. Options menu, and the Help menu. 
  142.  
  143. The actions that are selectable from the Services menu operate on the active 
  144. window currently displayed on the screen. These actions include the following: 
  145.  
  146.  Placing Bookmarks 
  147.    You can set a placeholder so you can retrieve information of interest to 
  148.    you. 
  149.  
  150.  Searching for Information 
  151.    You can find occurrences of a word or phrase in the current topic, selected 
  152.    topics, or all topics. 
  153.  
  154.  Printing Information 
  155.    You can print one or more topics. You can also print a set of topics by 
  156.    first marking the topics in the Contents list. 
  157.  
  158.  Copying Information to a File 
  159.    You can copy a topic that you are viewing to the System Clipboard or to a 
  160.    file that you can edit. This method is particularly useful for copying 
  161.    syntax definitions and program samples into the application that you are 
  162.    developing. 
  163.  
  164.  Using the actions that are selectable from the Options menu, you can change 
  165.  the way your Contents list is displayed. To expand the Contents and show all 
  166.  levels for all topics, choose Expand all from the Options pull-down. You can 
  167.  also press the Ctrl, Shift, and * keys together. 
  168.  
  169.  The actions that are selectable from the Help menu allow you to select 
  170.  different types of help information. 
  171.  
  172.  For information about any of the menu choices, highlight the choice in the 
  173.  menu and press F1. 
  174.  
  175.  
  176. ΓòÉΓòÉΓòÉ 1.5.1. Placing Bookmarks ΓòÉΓòÉΓòÉ
  177.  
  178. When you place a bookmark on a topic, it is added to a list of bookmarks you 
  179. have previously set.  You can view the list, and you can remove one or all 
  180. bookmarks from the list.  If you have not set any bookmarks, the list is empty. 
  181.  
  182. To set a bookmark, do the following: 
  183.  
  184.    1. Select a topic from the Contents. 
  185.    2. When that topic appears, select the Bookmark option from the Services 
  186.       menu. 
  187.    3. If you want to change the name used for the bookmark, type the new name 
  188.       in the field. 
  189.    4. Click on the Place radio button (or press the Up or Down Arrow key to 
  190.       select it). 
  191.    5. Click on OK (or select it and press Enter). The bookmark is then added to 
  192.       the bookmark list. 
  193.  
  194.  
  195. ΓòÉΓòÉΓòÉ 1.5.2. Searching for Information ΓòÉΓòÉΓòÉ
  196.  
  197. You can specify a word or phrase to be searched.  You can also limit the search 
  198. to a set of topics by first marking the topics in the Contents list. 
  199.  
  200. To search for a word or phrase in all topics, do the following: 
  201.  
  202.    1. Select the Search option from the Services menu. 
  203.    2. Type the word or words to be searched for. 
  204.    3. Click on All sections (or press the Up or Down Arrow keys to select it). 
  205.    4. Click on Search (or select it and press Enter) to begin the search. 
  206.    5. The list of topics where the word or phrase appears is displayed. 
  207.  
  208.  
  209. ΓòÉΓòÉΓòÉ 1.5.3. Printing Information ΓòÉΓòÉΓòÉ
  210.  
  211. You can print one or more topics, the index, or the table of contents.  Make 
  212. sure that your printer is connected to the serial port, configured correctly, 
  213. and ready for input. To print: 
  214.  
  215.    1. Select Print from the Services pull-down. 
  216.    2. Select what you want to print. Note that the This section and Marked 
  217.       sections choices are only available if you are viewing a topic or if you 
  218.       have marked topics, respectively.  To mark topics in the table of 
  219.       contents, press the Ctrl key and click on the topics, or use the arrow 
  220.       keys. 
  221.    3. Select Print to print what you've chosen on your printer. 
  222.  
  223.  
  224. ΓòÉΓòÉΓòÉ 1.5.4. Copying Information to a File ΓòÉΓòÉΓòÉ
  225.  
  226. You can copy a topic that you are viewing in two ways: 
  227.  
  228.      Copy copies the topic that you are viewing into the System Clipboard. 
  229.  
  230.      Copy to file copies the topic that you are viewing into a temporary file 
  231.       named TEXT.TMP.  You can later edit that file by using any editor. 
  232.       TEXT.TMP is placed in the directory where your viewable document resides. 
  233.  
  234.  To copy a topic, do the following: 
  235.  
  236.    1. Expand the Contents list and select a topic. 
  237.    2. When the topic appears, select Copy to file from the Services menu. 
  238.    3. The system puts the text pertaining to that topic into the temporary file 
  239.       TEXT.TMP. 
  240.  
  241.  
  242. ΓòÉΓòÉΓòÉ 1.6. How to Cut and Paste Examples ΓòÉΓòÉΓòÉ
  243.  
  244. You can copy examples (or information) from this reference/guide/book to 
  245. compile, link, and run them, or to paste them into your own code. 
  246.  
  247. To copy an example or information: 
  248.  
  249.    1. Make the topic you want to copy the active window. 
  250.  
  251.    2. From the Services menu, select Copy to file. The text in that topic is 
  252.       placed in the temporary file TEXT.TMP, in the same directory as this 
  253.       reference. 
  254.  
  255.    3. You can then modify or use TEXT.TMP as you want. 
  256.  
  257.  Note:  Because the system copies the entire contents of the topic to the file, 
  258.  you may need to edit it to remove additional text. Most examples in this 
  259.  reference are ready to compile, link, and run as they appear, and do not 
  260.  require any editing. 
  261.  
  262.  
  263. ΓòÉΓòÉΓòÉ 1.7. Other Information You Might Find Helpful ΓòÉΓòÉΓòÉ
  264.  
  265. This product provides a number of online guides and references that we hope 
  266. you'll find helpful as you develop applications. This information includes 
  267. User's Guides, References, and How Do I help that gives you specific 
  268. instructions for performing common tasks. You can get to this online 
  269. information from the Information folder inside the main product folder.  You 
  270. can also get to it from the Help menu in any of the components of the product. 
  271.  
  272.  
  273. ΓòÉΓòÉΓòÉ 1.8. Communicating Your Comments to IBM ΓòÉΓòÉΓòÉ
  274.  
  275. If there is something you like, or dislike, about this book, please let us 
  276. know.  You can use one of the methods listed below to send your comments to 
  277. IBM.  Please be sure to include the complete title of the publication that you 
  278. are commenting on. 
  279.  
  280. The comments you send should only pertain to the information in this document 
  281. and its presentation.  To request additional publications or to ask questions 
  282. or make comments about the functions of IBM products or systems, you should 
  283. talk to your IBM representative or your authorized IBM remarketer. 
  284.  
  285. When you send comments to IBM, you grant IBM a nonexclusive right to use or 
  286. distribute your comments in any way it believes appropriate without incurring 
  287. any obligation to you. 
  288.  
  289. You can send your comments to IBM in the following ways: 
  290.  
  291.      By mail to the following address: 
  292.  
  293.             IBM Canada Ltd. Laboratory
  294.             Information Development
  295.             2G/345/1150/TOR
  296.             1150 EGLINTON AVENUE EAST
  297.             NORTH YORK, ONTARIO
  298.             CANADA M3C 1H7
  299.  
  300.      By FAX to the following number: 
  301.  
  302.         -  United States and Canada: (416) 448-6161 
  303.         -  Other countries (+1) 416-448-6161 
  304.  
  305.      By electronic mail to one of the following IDs.  Be sure to include your 
  306.       entire network address if you wish to get a reply. 
  307.  
  308.         -  Internet: torrcf@vnet.ibm.com 
  309.         -  IBMLink: toribm(torrcf) 
  310.         -  IBM/PROFS: torolab4(torrcf) 
  311.         -  IBMMAIL: ibmmail(caibmwt9) 
  312.  
  313.  
  314. ΓòÉΓòÉΓòÉ 2. Setting Runtime Environment Variables ΓòÉΓòÉΓòÉ
  315.  
  316. This chapter discusses environment variables which compose the runtime of the 
  317. applications you build.  You need to be aware of them when you build the 
  318. application as they can affect the behaviour of your application and can lead 
  319. to unexpected results if not taken into account. 
  320.  
  321. This chapter discusses: 
  322.  
  323.      Application Environment Variables, and 
  324.  
  325.      How to Set Environment Variables. 
  326.  
  327.  
  328. ΓòÉΓòÉΓòÉ 2.1. How to Set Environment Variables ΓòÉΓòÉΓòÉ
  329.  
  330. You can set the runtime environment for your application by using Windows 
  331. environment variables. You can set most of them from the Program Manager by 
  332. clicking on Control Panel and then double-clicking the System icon, from the 
  333. command line or in a command file using the set command, or from within your 
  334. program using the SetEnvironmentVariable function. 
  335.  
  336. Note:  Programs linked to the subsystem library do not have an environment to 
  337. set. 
  338.  
  339. Some of the variables discussed in this chapter are also used at compile time. 
  340. The compiler environment variables are described in the User's Guide. 
  341.  
  342.  
  343. ΓòÉΓòÉΓòÉ 2.2. Application Environment Variables ΓòÉΓòÉΓòÉ
  344.  
  345. The following environment variables determine where your application will look 
  346. to locate files necessary to the execution of its tasks.  Files for such things 
  347. as command interpretation, runtime messages, and locale settings will all be 
  348. needed. If you do not make sure that the environment variables are correctly 
  349. set, your application may fail to find a file, or worse yet, find and use an 
  350. unintended file. 
  351.  
  352. The following environment variables are discussed: 
  353.  
  354.      COMSPEC 
  355.      LANG 
  356.      LC Environment Variables 
  357.      LOCPATH 
  358.      PATH 
  359.      TEMPMEM 
  360.      TMP 
  361.      TZ 
  362.  
  363.  
  364. ΓòÉΓòÉΓòÉ 2.2.1. COMSPEC ΓòÉΓòÉΓòÉ
  365.  
  366. The system function uses this variable to locate the command interpreter. When 
  367. the Windows operating system is installed, the installation program sets the 
  368. COMSPEC variable to the name and path of the command interpreter. To change the 
  369. COMSPEC variable, click on the Program Manager then the Control Panel and then 
  370. double-click on System. 
  371.  
  372.  
  373. ΓòÉΓòÉΓòÉ 2.2.2. LANG ΓòÉΓòÉΓòÉ
  374.  
  375. The LANG environment variable specifies the default locale name for the locale 
  376. categories, when the LC_ALL environment variable is not defined and the locale 
  377. categories environment variable is not defined. 
  378.  
  379.  
  380. ΓòÉΓòÉΓòÉ 2.2.3. LC Environment Variables ΓòÉΓòÉΓòÉ
  381.  
  382. The following environment variables are used to specify the names of locale 
  383. categories: 
  384.  
  385.      LC_ALL 
  386.      LC_COLLATE 
  387.      LC_CTYPE 
  388.      LC_MESSAGES 
  389.      LC_MONETARY 
  390.      LC_NUMERIC 
  391.      LC_TIME 
  392.      LC_TOD 
  393.      LC_SYNTAX 
  394.  
  395.  Section Locale Source Files describes the locale categories that correspond to 
  396.  these environment variables. Section Customizing a Locale tells you how to use 
  397.  these environment variables to customize a locale. 
  398.  
  399.  
  400. ΓòÉΓòÉΓòÉ 2.2.4. LOCPATH ΓòÉΓòÉΓòÉ
  401.  
  402. The setlocale function uses this environment variable at run time to search for 
  403. locale information not in the current directory. 
  404.  
  405.  
  406. ΓòÉΓòÉΓòÉ 2.2.5. PATH ΓòÉΓòÉΓòÉ
  407.  
  408. The system, exec, and _spawn functions use this environment variable to search 
  409. for EXE and CMD files not in the current directory. Also, when you run an 
  410. executable program, the runtime messages are in DLL which must be either in 
  411. your current directory or in one of the directories specified by the PATH 
  412. variable. For example, 
  413.  
  414.   SET PATH=c:\IBMCPPW\BIN;c:\IBMCPPW\HELP; e:\ian;d:\steve
  415.  
  416. You can specify one or more directories with this variable. Given the above 
  417. example, the path searched would be the current directory and then the 
  418. directories c:\IBMCPPW\BIN, c:\IBMCPPW\HELP, e:\ian, and d:\steve. 
  419.  
  420. For further information on the functions that use PATH, refer to the C Library 
  421. Reference. 
  422.  
  423.  
  424. ΓòÉΓòÉΓòÉ 2.2.6. TEMPMEM ΓòÉΓòÉΓòÉ
  425.  
  426. Use this variable to control whether temporary files are created as memory 
  427. files or as disk files. You can establish the value using the set command 
  428. either in a command file or on the command line. For example: 
  429.  
  430.   SET TEMPMEM=on
  431.  
  432. If the value specified is on (in upper-, lower-, or mixed case), and you 
  433. compile with the /Sv+ option, the temporary files will be created as memory 
  434. files. If TEMPMEM is set to any other value, the temporary files will be disk 
  435. files. If you do not compile with /Sv+, memory file support is not available 
  436. and your program will end with an error when it tries to open a memory file. 
  437.  
  438. If TEMPMEM will be used by a program, you must set its value in the environment 
  439. before the program starts.  You cannot set it from within the program. 
  440.  
  441.  
  442. ΓòÉΓòÉΓòÉ 2.2.7. TMP ΓòÉΓòÉΓòÉ
  443.  
  444. The directory specified by this variable holds temporary files, such as those 
  445. created using the tmpfile function. (tmpfile is described in the C Library 
  446. Reference.) You must set the TMP variable to use the VisualAge for C++ 
  447. compiler. 
  448.  
  449. Assign a path to the TMP variable with the set command, either in a command 
  450. file or on the command line. For example: 
  451.  
  452.   SET TMP=c:\IBMCPPW\TMP
  453.  
  454. You can specify only one directory using the TMP variable. 
  455.  
  456. Note:  The TMP environment variable may be set by applications other than 
  457. VisualAge for C++.  If another application changes TMP to specify a different 
  458. directory, this directory will be used by VisualAge for C++ to hold temporary 
  459. files. 
  460.  
  461.  
  462. ΓòÉΓòÉΓòÉ 2.2.8. TZ ΓòÉΓòÉΓòÉ
  463.  
  464. This variable is used to describe the timezone information that the locale will 
  465. use.  To set TZ, use the set which has the following format: 
  466.  
  467. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  468. Γöé                                 Γöé
  469. Γöé >>ΓöÇΓöÇSETΓöÇΓöÇTZΓöÇΓöÇ=ΓöÇΓöÇSSSΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  470. Γöé            ΓööΓöÇΓö¼ΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇhΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÿ      Γöé
  471. Γöé             Γö£ΓöÇ+ΓöÇΓöñ   ΓööΓöÇ:ΓöÇΓöÇmΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÿ       Γöé
  472. Γöé             ΓööΓöÇΓö┤ΓöÇΓöÿ       ΓööΓöÇ:ΓöÇΓöÇsΓöÇΓöÿ        Γöé
  473. Γöé                                 Γöé
  474. Γöé >ΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  475. Γöé   ΓööΓöÇDDDΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÿ         Γöé
  476. Γöé      ΓööΓöÇ,sm,sw,sd,st,em,ew,ed,et,shiftΓöÇΓöÿ          Γöé
  477. Γöé                                 Γöé
  478. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  479.  
  480. The values for the TZ variable are defined below. The default values given are 
  481. for the built-in "C" locale defined by the ANSI C standard. 
  482.  
  483. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  484. Γöé Table 1. TZ Environment Variable Parameters           Γöé
  485. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  486. Γöé VARIABLE   Γöé DESCRIPTION            Γöé DEFAULT   Γöé
  487. Γöé        Γöé                  Γöé VALUE    Γöé
  488. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  489. Γöé SSS      Γöé Standard-timezone identifier.  It Γöé EST     Γöé
  490. Γöé        Γöé must be three characters, must   Γöé       Γöé
  491. Γöé        Γöé begin with a letter, and can    Γöé       Γöé
  492. Γöé        Γöé contain spaces.          Γöé       Γöé
  493. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  494. Γöé h, m, s    Γöé The variable h specifies the dif- Γöé 5      Γöé
  495. Γöé        Γöé ference (in hours) between the   Γöé       Γöé
  496. Γöé        Γöé standard time zone and coordi-   Γöé       Γöé
  497. Γöé        Γöé nated universal time (CUT), for-  Γöé       Γöé
  498. Γöé        Γöé merly Greenwich mean time (GMT).  Γöé       Γöé
  499. Γöé        Γöé You can optionally use m to    Γöé       Γöé
  500. Γöé        Γöé specify minutes after the hour,  Γöé       Γöé
  501. Γöé        Γöé and s to specify seconds after   Γöé       Γöé
  502. Γöé        Γöé the minute.  A positive number   Γöé       Γöé
  503. Γöé        Γöé denotes time zones west of the   Γöé       Γöé
  504. Γöé        Γöé Greenwich meridian; a negative   Γöé       Γöé
  505. Γöé        Γöé number denotes time zones east of Γöé       Γöé
  506. Γöé        Γöé the Greenwich meridian.  The    Γöé       Γöé
  507. Γöé        Γöé number must be an integer value.  Γöé       Γöé
  508. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  509. Γöé DDD      Γöé Daylight saving time (DST) zone  Γöé EDT     Γöé
  510. Γöé        Γöé identifier.  It must be three   Γöé       Γöé
  511. Γöé        Γöé characters, must begin with a   Γöé       Γöé
  512. Γöé        Γöé letter, and can contain spaces.  Γöé       Γöé
  513. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  514. Γöé sm      Γöé Starting month (1 to 12) of DST.  Γöé 4      Γöé
  515. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  516. Γöé sw      Γöé Starting week (-4 to 4) of DST.  Γöé 1      Γöé
  517. Γöé        Γöé Use negative numbers to count   Γöé       Γöé
  518. Γöé        Γöé back from the last week of the   Γöé       Γöé
  519. Γöé        Γöé month (-1) and positive numbers  Γöé       Γöé
  520. Γöé        Γöé to count from the first week (1). Γöé       Γöé
  521. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  522. Γöé sd      Γöé Starting day of DST.        Γöé 0      Γöé
  523. Γöé        Γöé 0 to 6 if sw != 0         Γöé       Γöé
  524. Γöé        Γöé 1 to 31 if sw = 0         Γöé       Γöé
  525. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  526. Γöé st      Γöé Starting time (in seconds) of   Γöé 3600     Γöé
  527. Γöé        Γöé DST.                Γöé       Γöé
  528. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  529. Γöé em      Γöé Ending month (1 to 12) of DST.   Γöé 10      Γöé
  530. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  531. Γöé ew      Γöé Ending week (-4 to 4) of DST.   Γöé -1      Γöé
  532. Γöé        Γöé Use negative numbers to count   Γöé       Γöé
  533. Γöé        Γöé back from the last week of the   Γöé       Γöé
  534. Γöé        Γöé month (-1) and positive numbers  Γöé       Γöé
  535. Γöé        Γöé to count from the first week (1). Γöé       Γöé
  536. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  537. Γöé ed      Γöé Ending day of DST.         Γöé 0      Γöé
  538. Γöé        Γöé 0 to 6 if ew != 0         Γöé       Γöé
  539. Γöé        Γöé 1 to 31 if ew = 0         Γöé       Γöé
  540. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  541. Γöé et      Γöé Ending time of DST (in seconds).  Γöé 7200     Γöé
  542. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  543. Γöé shift     Γöé Amount of time change (in     Γöé 3600     Γöé
  544. Γöé        Γöé seconds).             Γöé       Γöé
  545. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  546.  
  547. For example: 
  548.  
  549.   SET TZ=CST6CDT
  550.  
  551. sets the standard time zone to CST, the daylight saving time zone to CDT, and 
  552. sets a difference of 6 hours between CST and CUT. It does not set any values 
  553. for the start and end date of daylight saving time or the time shifted. 
  554.  
  555. When TZ is not present, the default is EST5EDT, the "C" locale value. When only 
  556. the standard time zone is specified, the default value of n (difference in 
  557. hours from GMT) is 0 instead of 5. 
  558.  
  559. If you give values for any of sm, sw, sd, st, em, ew, ed, et, or shift, you 
  560. must give values for all of them. the entire statement is considered not valid, 
  561. and the time zone information is not changed. 
  562.  
  563. The value of TZ can be accessed and changed by the tzset function. For more 
  564. information on tzset, see the C Library Reference. 
  565.  
  566.  
  567. ΓòÉΓòÉΓòÉ 3. Running Your Program ΓòÉΓòÉΓòÉ
  568.  
  569. This chapter describes common tasks associated with the running of your 
  570. application. These include: 
  571.  
  572.      Declaring Arguments to main 
  573.      Passing Data to a Program 
  574.      Returning Values from main 
  575.      Expanding Global File-Name Arguments, and 
  576.      Redirecting Standard Streams. 
  577.  
  578.  
  579. ΓòÉΓòÉΓòÉ 3.1. Choice of User Interfaces for Running an Application ΓòÉΓòÉΓòÉ
  580.  
  581. You can run an an executable unit through any one of three user interfaces: 
  582.  
  583.      using the WorkFrame environment to create a project, 
  584.      using the Program Manager interface to create an program object, or 
  585.       simply, 
  586.      using the command line to create an executable file. 
  587.  
  588.  Note:  Applications created in the Win32s environment can be run only from the 
  589.  File Manager or Program Manager. This is because, in the Win32s environment, 
  590.  the DOS command interpreter which is automatically invoked when the command 
  591.  line is used does not recognize Win32-based files as valid executables. 
  592.  
  593.  Directions on how to create and run these elements through the various 
  594.  interfaces is discussed in the User's Guide. 
  595.  
  596.  
  597. ΓòÉΓòÉΓòÉ 3.1.1. Locating Executable Files ΓòÉΓòÉΓòÉ
  598.  
  599. The operating system will search for the executable file in the following 
  600. order: 
  601.  
  602.      In only the directory specified, if a fully qualified path name is given, 
  603.       otherwise 
  604.      In your current working directory, then 
  605.      In each of the the directories specified by the PATH environment 
  606.       variable. 
  607.  
  608.       If more than one of the directories of the PATH variable contains an 
  609.       executable file of the requested name, the first executable file that is 
  610.       found on the path is run. 
  611.  
  612.  The run time messages files (CPPWRTM.DLL and CPPWRERR.DLL for the C run time) 
  613.  must also be either in your current working directory or in one of the 
  614.  directories specified by the PATH environment variable. 
  615.  
  616.  You can use the system function in the VisualAge for C++ runtime library to 
  617.  run other programs and commands from within a program. See the C Library 
  618.  Reference for more information on the system function. 
  619.  
  620.  
  621. ΓòÉΓòÉΓòÉ 3.2. Declaring Arguments to main ΓòÉΓòÉΓòÉ
  622.  
  623. To set up your program to receive data from the command line, the project 
  624. parameter page, or through object conversations, declare arguments to main as: 
  625.  
  626.   int main(int argc, char **argv, char **envp)
  627.  
  628. In extended mode, C also allows a return type of void for main. 
  629.  
  630. VisualAge for C++ supports this definition as well as the following 
  631. ANSI-conforming definitions. 
  632.  
  633.   int main(int argc, char **argv) { ... }
  634.  
  635. and 
  636.  
  637.   int main(void) { ... }
  638.  
  639. By declaring these variables as arguments to main, you make them available as 
  640. local variables. You need not declare all three arguments, but if you do, they 
  641. must be in the order shown. To use the envp argument, you must declare argc and 
  642. argv, even if you do not use them. 
  643.  
  644. Each Windows command-line argument, regardless of its data type, is stored as a 
  645. null-terminated string in an array of strings. The command is passed to the 
  646. program as the argv array of strings. The number of arguments appearing at the 
  647. command prompt is passed as the integer variable argc. 
  648.  
  649. The first argument of any command is the name of the program to run. The 
  650. program name is the first string stored at argv[0]. Because you must always 
  651. give a program name, the value of argc is at least 1. 
  652.  
  653. Note:  On Windows 95, argv[0]. is the program name with full path 
  654. qualification. This is because the Windows 95 API always adds the full path 
  655. qualification before it returns the program name to the user. 
  656.  
  657. The runtime initialization code stores the first argument after the program 
  658. name at argv[1], the second at argv[2], and so on through the end of the 
  659. arguments. The total number of arguments, including the program name, is stored 
  660. in argc. The argv[argc] is set to a NULL pointer. 
  661.  
  662. You can also access the values of the individual arguments from within the 
  663. program using argv.  For example, to access the value of the last argument, use 
  664. the expression argv[argc-1]. 
  665.  
  666. The third argument passed to main, envp, is a pointer to the environment table. 
  667. You can use this pointer to access the value of the environment settings. (Note 
  668. that the getenv function accomplishes the same task and is easier to use.) The 
  669. envp argument is not available when you use the subsystem libraries. 
  670.  
  671. The putenv routine may change the location of the environment table in storage, 
  672. depending on storage requirements; because of this, the value given to envp 
  673. when you start to run your program might not be correct throughout the running 
  674. of the program. The putenv and getenv functions access the environment table 
  675. correctly, even when its location changes. For more information about putenv 
  676. and getenv, see the C Library Reference. 
  677.  
  678.  
  679. ΓòÉΓòÉΓòÉ 3.3. Passing Data to a Program ΓòÉΓòÉΓòÉ
  680.  
  681. To pass data to your program by way of the command line, give one or more 
  682. arguments after the program name. Each argument must be separated from other 
  683. arguments by one or more spaces or tab characters. You must enclose in double 
  684. quotation marks any arguments that include spaces, tab characters, double 
  685. quotation marks, or redirection characters. For example: 
  686.  
  687.   hello 42 "de f" 16
  688.  
  689. This command runs the program named hello.exe and passes three arguments: 42, 
  690. de f, and 16. The combined length of all arguments in the command (including 
  691. the program name) cannot exceed the Windows maximum length for a command. 
  692.  
  693. You can also use escape sequences within arguments. For example, to represent 
  694. double quotation marks, precede the double quotation character with a 
  695. backslash. To represent a backslash, use two backslashes in a row. For example, 
  696. when you invoke the hello.exe program from the preceding example with this 
  697. command: 
  698.  
  699.   hello "ABC\"" \"HELLO\\
  700.  
  701. the arguments passed to the program are ABC" and "HELLO\. 
  702.  
  703.  
  704. ΓòÉΓòÉΓòÉ 3.4. Returning Values from main ΓòÉΓòÉΓòÉ
  705.  
  706. The function main, like any other C or C++ function, returns a value. Its 
  707. return value is an int value that is passed to the operating system as the 
  708. return code of the program that has been run. 
  709.  
  710. You can check this return code with the IF ErrorLevel command in Windows batch 
  711. files. For more information on the IF ErrorLevel command, check the command 
  712. reference accompanying your operating system. 
  713.  
  714. To cause main to return a specific value to the operating system, use the 
  715. return statement or the exit function to specify the value to be returned. The 
  716. statement 
  717.  
  718.   return 6;
  719.  
  720. returns the value 6. 
  721.  
  722. If you do not use either method, the return code is undefined. 
  723.  
  724. For more information about main, see the Language Reference. 
  725.  
  726.  
  727. ΓòÉΓòÉΓòÉ 3.5. Expanding Global File-Name Arguments ΓòÉΓòÉΓòÉ
  728.  
  729. You can expand global file-name arguments from the Windows command line using 
  730. the Windows global file-name characters (or wildcard characters), the question 
  731. mark (?), and asterisk (*), to specify the file-name and path-name arguments at 
  732. the command prompt. To use them, you must link your program with the special 
  733. routine contained in SETARGV.OBJ. This object file is included with the 
  734. libraries in the LIB directory under the main VisualAge for C++ directory. If 
  735. you do not link your program with SETARGV.OBJ, the compiler treats the 
  736. characters literally. SETARGV.OBJ expands the global file-name characters in 
  737. the same manner that the Windows operating system does. For example, when you 
  738. link hello.obj with SETARGV.OBJ: 
  739.  
  740.   ILINK -out:hello.exe /NOE hello SETARGV
  741.  
  742. and run the resulting executable module hello.exe with this command: 
  743.  
  744.   hello *.INC ABC? "XYZ?"
  745.  
  746. the SETARGV function expands the global file-name characters and causes all 
  747. file names with the extension .INC in the current working directory to be 
  748. passed as arguments to the hello program.  Similarly, all file names beginning 
  749. with ABC followed by any one character are passed as arguments. The file names 
  750. are sorted in lexical order. 
  751.  
  752. If the SETARGV function finds no matches for the global file-name arguments, 
  753. for example, if no files have the extension .INC, the argument is passed 
  754. literally. 
  755.  
  756. Because the "XYZ?" argument is enclosed in quotation marks, the expansion of 
  757. the global file-name character is suppressed, and the argument is passed 
  758. literally as XYZ?. 
  759.  
  760. Alternatively, if you use access your executables through the project interface 
  761. and you frequently use global file-name expansion, you can place the 
  762. SETARGV.OBJ routine in the standard libraries you use.  Then the routine is 
  763. automatically linked with your program. 
  764.  
  765. Use the ILIB utility to delete the module named SETUPARG from the library (the 
  766. module name is the same in all VisualAge for C++ libraries), and  add the 
  767. SETARGV.OBJ module. When you replace SETUPARG with SETARGV, global file-name 
  768. expansions are performed automatically on command-line arguments. 
  769.  
  770. For more information on the ILIB utility, see the User's Guide. 
  771.  
  772.  
  773. ΓòÉΓòÉΓòÉ 3.6. Redirecting Standard Streams ΓòÉΓòÉΓòÉ
  774.  
  775. A C or C++ program has standard streams associated with it. You need not open 
  776. them; they are automatically set up by the runtime environment when you include 
  777. <stdio.h>. The three standard streams are: 
  778.  
  779.  stdin   The input device from which your program normally retrieves its data. 
  780.          For example, the library function getchar uses stdin. 
  781.  
  782.  stdout  The output device to which your program normally directs its output. 
  783.          For example, the library function printf uses stdout. 
  784.  
  785.  stderr  The output device to which your program directs its diagnostic 
  786.          messages. 
  787.  
  788.  On input and output operations requiring a file pointer, you can use stdin, 
  789.  stdout, or stderr in the same manner as you would a regular file pointer. 
  790.  
  791.  When a C++ program uses the I/O Stream classes, the following predefined 
  792.  streams are also provided in addition to the standard streams: 
  793.  
  794.  cin     The standard input stream. 
  795.  
  796.  cout    The standard output stream. 
  797.  
  798.  cerr    The standard error stream. Output to this stream is unit-buffered. 
  799.          Characters sent to this stream are flushed after each insertion 
  800.          operation. 
  801.  
  802.  clog    Also the standard error stream. Output to this stream is fully 
  803.          buffered. 
  804.  
  805.  The cin stream is an istream_withassign object, and the other three streams 
  806.  are ostream_withassign objects. These streams and the classes they belong to 
  807.  are described in detail in the Open Class Library Reference. 
  808.  
  809.  There may be times when you want to redirect a standard stream to a file.  The 
  810.  following sections describe methods you can use for C and C++ programs. 
  811.  
  812.  Redirection from within a Program 
  813.  
  814.  To redirect C standard streams to a file from within your program, use the 
  815.  freopen library function.  For example, to redirect your output to a file 
  816.  called pia.out instead of stdout, code the following statement in your 
  817.  program: 
  818.  
  819.     freopen("pia.out", "w", stdout);
  820.  
  821.  For more information on freopen, refer to the C Library Reference. 
  822.  
  823.  You can reassign a C++ standard stream to another istream (cin only) or 
  824.  ostream object, or to a streambuf object, using the operator=.  For example, 
  825.  to redirect your output to a file called michael.out, create michael.out as an 
  826.  ostream object, and assign cout to it: 
  827.  
  828.     #include <fstream.h>
  829.  
  830.     int main(void)
  831.     {
  832.      cout << "This is going to the standard output stream" << endl;
  833.  
  834.      ofstream outfile("michael.out");
  835.      cout = outfile;
  836.      cout << "This is going to michael.out file" << endl;
  837.  
  838.      return 0;
  839.     }
  840.  
  841.  You can also assign cout to outfile.rdbuf() to perform the same redirection. 
  842.  
  843.  For more information on using C++ standard streams, see the Open Class Library 
  844.  Reference. 
  845.  
  846.  Redirection from the Command Line 
  847.  
  848.  To redirect a C or C++ standard stream to a file from the command line, use 
  849.  the standard Windows redirection symbols. 
  850.  
  851.  For example, to run the program bill.exe, which has two required parameters 
  852.  XYZ and 123, and redirect the output from stdout to a file called bill.out, 
  853.  you would use the following command: 
  854.  
  855.     bill XYZ 123 > bill.out
  856.  
  857.  You can also use the Windows file handles to redirect one standard stream to 
  858.  another.  For example, to redirect stderr to stdout, you would use the 
  859.  command: 
  860.  
  861.     2 > &1
  862.  
  863.  Note: 
  864.  
  865.    1. You cannot use redirection from the command line for memory files. 
  866.  
  867.    2. On Windows 95, you cannot use redirection from the command line for 
  868.       exceptions.  stderr always goes to the screen. 
  869.  
  870.  Redirection under Win32s 
  871.  
  872.  There is no concept of console on Win32s (no command line). Programs are 
  873.  usually started by double-clicking on the program icon. The alternative method 
  874.  is to start the program from File Manager (using the run option under the File 
  875.  menu). While it allows a user to pass arguments to the application, 
  876.  redirection symbols  that a user might enter there are ignored by the 
  877.  operating system and passed to the application as normal arguments. The same 
  878.  thing also happens on Windows NT when you start a program from File Manager, 
  879.  or put redirection signs under quotes when starting it from the command line. 
  880.  
  881.  To allow a user to redirect input, output and error handles in this 
  882.  environment, VisualAge for C++ provides a special object -- redirect.obj.  (It 
  883.  is in the same directory as SETARGV.OBJ.) It needs to be linked in explicitly 
  884.  using the /NOE linker option. This object contains a function that will parse 
  885.  redirection symbols and assign stdin, stdout, and stderr to the specified 
  886.  files. You will need to link with this object if you plan to make your 
  887.  application support redirection under Win32s. Note that once you do it, you 
  888.  will not be able to pass redirection signs as arguments to your program. 
  889.  
  890.  Note:  Redirection using redirect.obj object is not supported for subsystems. 
  891.  
  892.  
  893. ΓòÉΓòÉΓòÉ 4. Performing I/O Using Standard Streams ΓòÉΓòÉΓòÉ
  894.  
  895. This chapter describes input and output methods for the VisualAge for C++ 
  896. compiler: 
  897.  
  898.      Using Standard Streams 
  899.      Stream Processing 
  900.      Memory File Input/Output 
  901.      Buffering 
  902.      Opening Streams Using Data Definition Names 
  903.      Precedence of File Characteristics 
  904.      Closing Files 
  905.      Input/Output Restrictions 
  906.  
  907.  Note that record level I/O is not supported. 
  908.  
  909.  
  910. ΓòÉΓòÉΓòÉ 4.1. Using Standard Streams ΓòÉΓòÉΓòÉ
  911.  
  912. Three standard streams are associated with the C language, stdin, stdout, and 
  913. stderr. In C++, when you use the I/O Stream Library, there are four additional 
  914. C++ standard streams, cin, cout, cerr, and clog. All of the standard streams 
  915. are described in Redirecting Standard Streams. 
  916.  
  917. The operating system associates a file handle with each of the streams as 
  918. follows: 
  919.  
  920. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  921. Γöé FILE    Γöé C STREAM    Γöé C++ STREAM   Γöé
  922. Γöé HANDLE   Γöé        Γöé        Γöé
  923. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  924. Γöé 0      Γöé stdin     Γöé cin      Γöé
  925. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  926. Γöé 1      Γöé stdout     Γöé cout      Γöé
  927. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  928. Γöé 2      Γöé stderr     Γöé cerr, clog   Γöé
  929. Γöé       Γöé        Γöé        Γöé
  930. Γöé       Γöé        Γöé NOTE:  Both  Γöé
  931. Γöé       Γöé        Γöé cerr and clog Γöé
  932. Γöé       Γöé        Γöé are standard  Γöé
  933. Γöé       Γöé        Γöé error     Γöé
  934. Γöé       Γöé        Γöé streams; cerr Γöé
  935. Γöé       Γöé        Γöé is unit buf-  Γöé
  936. Γöé       Γöé        Γöé fered and   Γöé
  937. Γöé       Γöé        Γöé clog is fully Γöé
  938. Γöé       Γöé        Γöé buffered.   Γöé
  939. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  940.  
  941. The file handle and stream are not equivalent. There may situations where a 
  942. file handle is associated with a different stream, for example, where file 
  943. handle 2 is associated with a stream other than stderr, cerr, or clog. Do not 
  944. code your program in so that it is dependent on the association between the 
  945. stream and the file handle. 
  946.  
  947. The standard streams are not available when you are using the subsystem 
  948. libraries. 
  949.  
  950. Note: 
  951.  
  952.    1. The C++ streams do not support the use of data definition names 
  953.       (ddnames). 
  954.  
  955.    2. Record level I/O is not supported. 
  956.  
  957.  See the Open Class Library Reference for more information about the C++ 
  958.  streams. 
  959.  
  960.  
  961. ΓòÉΓòÉΓòÉ 4.2. Stream Processing ΓòÉΓòÉΓòÉ
  962.  
  963. Input and output are mapped into logical data streams, either text or binary. 
  964. Streams present a consistent view of file contents, independent of the 
  965. underlying file system. 
  966.  
  967.  
  968. ΓòÉΓòÉΓòÉ 4.2.1. Text Streams ΓòÉΓòÉΓòÉ
  969.  
  970. Text streams contain printable characters and control characters organized into 
  971. lines. Each line consists of zero or more characters and ends with a new-line 
  972. character (\n). A new-line character is not automatically appended to the end 
  973. of the file. 
  974.  
  975. The VisualAge for C++ compiler may add, alter, or ignore some new-line 
  976. characters during input or output so that they conform to the conventions for 
  977. representing text in the Windows environment. Thus, there may not be a 
  978. one-to-one correspondence between the characters in a stream and those in the 
  979. external representation. See page Differences between Storing Data as a Text or 
  980. Binary Stream for an example of the difference in representations. 
  981.  
  982. Data read from a text stream is equal to the data that was written if it 
  983. consists only of printable characters and the horizontal tab, new-line, 
  984. vertical tab, and form-feed control characters. 
  985.  
  986. On output, each new-line character is translated to a carriage-return 
  987. character, followed by a line-feed character. On input, a carriage-return 
  988. character followed by a line-feed character, or a line-feed character alone is 
  989. converted to a new-line character. 
  990.  
  991. If the last operation on the stream is a read operation, fflush discards the 
  992. unread portion of the buffer. If the last operation on the stream is a write 
  993. operation, fflush writes out the contents of the buffer. In either case, fflush 
  994. clears the buffer. 
  995.  
  996. The ftell, fseek, fgetpos, fsetpos, and rewind functions cannot be used to get 
  997. or change the file position within character devices or Windows pipes. 
  998.  
  999. The C standard streams are always in text mode at the start of your program. 
  1000. You can change the mode of a standard stream from text to binary, without 
  1001. redirecting the stream, by using the freopen function with no file name 
  1002. specified. For example: 
  1003.  
  1004.   fp = freopen("", "rb", stdin);
  1005.  
  1006. You can use the same method to change the mode from binary back to text. You 
  1007. cannot change the mode of a stream to anything other than text or binary, nor 
  1008. can you change the file type to something other than disk. No other parameters 
  1009. are allowed. Note that this method is included in the SAA C definition, but not 
  1010. in the ANSI C standard. 
  1011.  
  1012.  
  1013. ΓòÉΓòÉΓòÉ 4.2.1.1. Control-Z Character in Text Streams ΓòÉΓòÉΓòÉ
  1014.  
  1015. When a text stream is connected to a character device, such as the keyboard or 
  1016. an operating system pipe, the Ctrl-Z (\x1a) character is treated as an 
  1017. end-of-file indicator, regardless of where it appears in the stream. 
  1018.  
  1019. If Ctrl-Z is the last character in a file, it is discarded when read. 
  1020. Similarly, when a file ending with a Ctrl-Z character is opened in append or 
  1021. update mode, the Ctrl-Z is discarded. Programs compiled by the VisualAge for 
  1022. C++ compiler do not automatically have a Ctrl-Z character appended to the end 
  1023. of the file when the file is closed. If you require a Ctrl-Z character at the 
  1024. end of your text files, you must write it out yourself. 
  1025.  
  1026. This treatment of the Ctrl-Z character applies to text streams only.  In binary 
  1027. streams, it is treated like any other character. 
  1028.  
  1029.  
  1030. ΓòÉΓòÉΓòÉ 4.2.2. Binary Streams ΓòÉΓòÉΓòÉ
  1031.  
  1032. A binary stream is a sequence of characters or data. The data is not altered on 
  1033. input or output, so the data read from a binary stream is equal to the data 
  1034. that was written. 
  1035.  
  1036. If the last operation on the stream is a read operation, fflush discards the 
  1037. unread portion of the buffer. If the last operation on the stream is a write 
  1038. operation, fflush writes out the contents of the buffer. In either case, fflush 
  1039. clears the buffer. 
  1040.  
  1041.  
  1042. ΓòÉΓòÉΓòÉ 4.2.3. Differences between Storing Data as a Text or Binary Stream ΓòÉΓòÉΓòÉ
  1043.  
  1044. If two streams are opened, one as a binary stream and the other as a text 
  1045. stream, and the same information is written to both, the contents of the 
  1046. streams may differ. The following example shows two streams of different types 
  1047. and the hexadecimal values of the resulting files.  The values show that the 
  1048. data is stored differently for each file. 
  1049.  
  1050.  
  1051. Differences between Binary and Text Streams
  1052.  
  1053. #include <stdio.h>
  1054.  
  1055. int main(void)
  1056. {
  1057.   FILE *fp1, *fp2;
  1058.   char lineBin[15], lineTxt[15];
  1059.   int x;
  1060.  
  1061.   fp1 = fopen("script.bin","wb");
  1062.   fprintf(fp1,"hello world\n");
  1063.  
  1064.   fp2 = fopen("script.txt","w");
  1065.   fprintf(fp2,"hello world\n");
  1066.  
  1067.   fclose(fp1);
  1068.   fclose(fp2);
  1069.  
  1070.   fp1 = fopen("script.bin","rb");
  1071.  
  1072.   /* opening the text file as binary to suppress
  1073.   the conversion of internal data  */
  1074.   fp2 = fopen("script.txt","rb");
  1075.  
  1076.   fgets(lineBin, 15, fp1);
  1077.   fgets(lineTxt, 15, fp2);
  1078.  
  1079.   printf("Hex value of binary file = ");
  1080.   for (x=0; lineBin[x]; x++)
  1081.     printf("%.2x", (int)(lineBin[x]) );
  1082.  
  1083.   printf("\nHex value of text file  = ");
  1084.   for (x=0; lineTxt[x]; x++)
  1085.     printf("%.2x", (int)(lineTxt[x]) );
  1086.  
  1087.   printf("\n");
  1088.  
  1089.   fclose(fp1);
  1090.   fclose(fp2);
  1091.  
  1092.   /* The expected output is:
  1093.  
  1094.     Hex value of binary file = 68656c6c6f20776f726c640a
  1095.     Hex value of text file  = 68656c6c6f20776f726c640d0a  */
  1096. }
  1097.  
  1098. As the hexadecimal values of the file contents show in the binary stream 
  1099. (script.bin), the new-line character is converted to a line feed (\0a), while 
  1100. in the text stream (script.txt), the new line is converted to a carriage-return 
  1101. line feed (\0d0a). 
  1102.  
  1103.  
  1104. ΓòÉΓòÉΓòÉ 4.3. Memory File Input/Output ΓòÉΓòÉΓòÉ
  1105.  
  1106. When you compile with the /Sv+ option, VisualAge for C++ compiler supports 
  1107. files known as memory files. They differ from the other file types only in that 
  1108. they are temporary files that reside in memory. You can write to and read from 
  1109. a memory file just as you do with a disk file. 
  1110.  
  1111. Using memory files can speed up the execution of your program because, under 
  1112. normal circumstances, there is no disk I/O when your program accesses these 
  1113. files. However, if your program is running in an environment where the 
  1114. operating system is paging, you might not get faster execution when using 
  1115. memory files. This loss of speed is most likely to occur if your memory files 
  1116. are large. 
  1117.  
  1118. You can create a memory file in two ways: 
  1119.  
  1120.      By specifying type=memory directly in your source code. For example 
  1121.  
  1122.               stream = fopen("memfile.txt", "w, type=memory");
  1123.  
  1124.      By using the ddname in the fopen call and the set command to specify the 
  1125.       file you want your program to open. 
  1126.  
  1127.               stream=fopen("DD:MEMFILE", "w");
  1128.  
  1129.       Before you run your program, use the set command: 
  1130.  
  1131.               SET DD:MEMFILE=memfile.txt, memory(y)
  1132.  
  1133.       The SET DD: statement specifies MEMFILE as a data definition name 
  1134.       (ddname). 
  1135.  
  1136.       Note: 
  1137.         1. You must specify the /Sh+ compiler option to use ddnames. 
  1138.  
  1139.         2. ddnames are not supported for use with C++ standard streams. 
  1140.  
  1141.  Once a memory file has been created, it can be accessed by the module that 
  1142.  created it as well as by any other function within the same process. The 
  1143.  memory file remains accessible until the file is removed by the remove 
  1144.  function or until the program has terminated. 
  1145.  
  1146.  A call to fopen that tries to open a file with the same name as an existing 
  1147.  memory file accesses the memory file, even if you do not specify type=memory 
  1148.  in the fopen call. 
  1149.  
  1150.  When using fopen to open a memory file in write or append mode, you must 
  1151.  ensure that the file is not already open. 
  1152.  
  1153.  
  1154. ΓòÉΓòÉΓòÉ 4.3.1. Memory File Restrictions and Considerations ΓòÉΓòÉΓòÉ
  1155.  
  1156.      You must specify the /Sv+ option to use memory files. 
  1157.  
  1158.      Memory files are private to the process that created them. Redirection to 
  1159.       memory files from the command line is not supported, and they cannot be 
  1160.       shared with any other process, including child processes. Also, memory 
  1161.       files cannot be shared through the system function. 
  1162.  
  1163.      Memory files do not undergo any conversion of the new-line character. 
  1164.       Data is not altered on input or output. 
  1165.  
  1166.      Memory files are unbuffered, and the blksize attribute is ignored. No 
  1167.       validation is performed for the path or file name used. 
  1168.  
  1169.      Memory file names are case sensitive. For example, the file a.a is not 
  1170.       the same memory file as A.A: 
  1171.  
  1172.               fopen("A.A","w,type=memory");
  1173.               remove("a.a");
  1174.  
  1175.       The above call to remove will not remove memory file A.A because the file 
  1176.       name is in uppercase. Because memory files are always checked first, the 
  1177.       function will look for memory file a.a, and if that file does not exist, 
  1178.       it will remove the disk file a.a (or A.A, because disk files are not case 
  1179.       sensitive). 
  1180.  
  1181.      You can request that the temporary files created by the tmpfile function 
  1182.       be either disk files or memory files. By default, tmpfile creates disk 
  1183.       files.  To have temporary files created as memory files, set the TEMPMEM 
  1184.       environment variable to ON: 
  1185.  
  1186.               SET TEMPMEM=on
  1187.  
  1188.       The word on can be in any case. You must still specify the /Sv+ compiler 
  1189.       option. For more information about TEMPMEM, see Setting Runtime 
  1190.       Environment Variables. 
  1191.  
  1192.  
  1193. ΓòÉΓòÉΓòÉ 4.4. Buffering ΓòÉΓòÉΓòÉ
  1194.  
  1195. VisualAge for C++ compiler uses buffers to increase the efficiency of 
  1196. system-level I/O. The following buffering modes are used: 
  1197.  
  1198.  Unbuffered     Characters are transmitted as soon as possible. This mode is 
  1199.                 also called unit buffered. 
  1200.  
  1201.  Line buffered  Characters are transmitted as a block when a new-line character 
  1202.                 is encountered or when the buffer is filled. 
  1203.  
  1204.  Fully buffered Characters are transmitted as a block when the buffer is 
  1205.                 filled. 
  1206.  
  1207.  The buffering mode specifies the manner in which the buffer is flushed, if a 
  1208.  buffer exists. 
  1209.  
  1210.  You can use the blksize parameter with the fopen function to indicate the 
  1211.  initial size of the buffer you want to allocate for the stream. Note that you 
  1212.  must specify the /Sh+ compiler option to use ddnames. 
  1213.  
  1214.  If you do not specify a buffer size, the default size is 4096. Either the 
  1215.  setvbuf or setbuf function can be used to control buffering. One of these 
  1216.  functions may be specified for a stream. You cannot change the buffering mode 
  1217.  after any operation on the file has occurred. 
  1218.  
  1219.  Fully buffered mode is the default unless the stream is connected to a 
  1220.  character device, in which case it is line buffered. 
  1221.  
  1222.  To ensure data is transmitted to external storage as soon as possible, use the 
  1223.  setbuf or setvbuf function to set the buffering mode to unbuffered. 
  1224.  
  1225.  
  1226. ΓòÉΓòÉΓòÉ 4.5. Opening Streams Using Data Definition Names ΓòÉΓòÉΓòÉ
  1227.  
  1228. When you specify the /Sh+ compiler option, you can use the Windows set command 
  1229. with a data definition name (ddname) as a parameter to specify the name of the 
  1230. file to be opened by your program. You can also use the set command to specify 
  1231. other file characteristics. 
  1232.  
  1233. When you use the set command with ddnames, you can change the files that are 
  1234. accessed by each run of your program without having to alter and recompile your 
  1235. source code. 
  1236.  
  1237. Note: 
  1238.  
  1239.    1. You cannot use ddnames with the C++ standard streams. 
  1240.  
  1241.    2. The maximum number of files that can be open at any time changes with the 
  1242.       amount of memory available. 
  1243.  
  1244.  
  1245. ΓòÉΓòÉΓòÉ 4.5.1. Specifying a ddname with the SET Command ΓòÉΓòÉΓòÉ
  1246.  
  1247. To specify a ddname, the set command has the following syntax: 
  1248.  
  1249.   SET DD:DDNAME=filename[,option, option...]
  1250.  
  1251. where: 
  1252.  
  1253.  DDNAME     Is the ddname as specified in the source code.  The ddname must be 
  1254.             in uppercase. 
  1255.  
  1256.  filename   Is the name of the file that will be opened by fopen. 
  1257.  No white-space characters are allowed between the DD and the equal sign. 
  1258.  
  1259.  For example, you could open the file sample.txt in two ways: 
  1260.  
  1261.      By putting the name of the file directly into your source code: 
  1262.  
  1263.               FILE *stream;
  1264.               stream=fopen("sample.txt", "r");
  1265.  
  1266.      By using a ddname in the fopen call and the set command to specify the 
  1267.       file you want your program to open: 
  1268.  
  1269.               FILE *stream;
  1270.               stream=fopen("DD:DATAFILE", "r");
  1271.  
  1272.       Before you run your program, use the set command: 
  1273.  
  1274.               SET DD:DATAFILE=c:\sample.txt
  1275.  
  1276.       When the program runs, it will open the file c:\sample.txt. If you want 
  1277.       the same program to use the file c:\test.txt the next time it runs, use 
  1278.       the following set command: 
  1279.  
  1280.               SET DD:DATAFILE=c:\test.txt
  1281.  
  1282.  The set command can be issued before your program is executed: from the 
  1283.  Program Manager by clicking on Control Panel and then double-clicking the 
  1284.  System icon, from the command line or in a command file, or from within your 
  1285.  program using the SetEnvironmentVariable function. 
  1286.  
  1287.  You can also use the putenv function from within the program to set the 
  1288.  ddname. For example: 
  1289.  
  1290.     _putenv("DD:DATAFILE=sample.txt, writethru(y)");
  1291.  
  1292.  For a description of putenv, see the C Library Reference. 
  1293.  
  1294.  
  1295. ΓòÉΓòÉΓòÉ 4.5.2. Describing File Characteristics Using Data Definition Names ΓòÉΓòÉΓòÉ
  1296.  
  1297. When you are defining ddnames, use the options to specify the characteristics 
  1298. of the file your program opens. You can specify the options in any order and in 
  1299. upper- or lowercase. If you specify an option more than once, only the last one 
  1300. takes effect. If an option is not valid, fopen fails and errno is set 
  1301. accordingly. 
  1302.  
  1303. You can use the following options when specifying a ddname. 
  1304.  
  1305. Note:  The options blksize, lrecl, and recfm are meant to be used with record 
  1306. level I/O. Because record level I/O is not supported, these options are 
  1307. accepted but ignored. 
  1308.  
  1309.  blksize( n ) 
  1310.       The size in bytes of the block of data moved between the disk and the 
  1311.       program. The maximum size is 32760 for fixed block files and 32756 for 
  1312.       variable block files. Larger values can improve the efficiency of disk 
  1313.       access by lowering the number of times the disk must be accessed. 
  1314.       Typically, values below 512 increase I/O time, and values above 8KB do 
  1315.       not show improvement. 
  1316.  
  1317.  lrecl( n ) 
  1318.       The size in bytes of one record (logical record length). If the value 
  1319.       specified is larger than the value of blksize, the lrecl value is 
  1320.       ignored. 
  1321.  
  1322.  recfm(f | v | fb | vb ) [The default values for these options are underlined] 
  1323.       Specifies whether the record length is fixed or variable, and whether the 
  1324.       records are stored in blocks. 
  1325.  
  1326.       f           The record size is fixed (i.e. all records are the same 
  1327.                   length) and the size of each record is specified by the lrecl 
  1328.                   option. 
  1329.  
  1330.       v           The record size is variable and the maximum record size is 
  1331.                   specified by the lrecl option. 
  1332.  
  1333.       fb          The record size is fixed and the records are stored in 
  1334.                   blocks. The record size is specified by the lrecl option, and 
  1335.                   the block size is specified by the blksize option. The block 
  1336.                   size must be an integral multiple of lrecl. 
  1337.  
  1338.       vb          The record size is variable and the records are stored in 
  1339.                   blocks. The maximum record size is specified by the lrecl 
  1340.                   option, and the block size is specified by the blksize 
  1341.                   option. 
  1342.  
  1343.  share (read | none | all ) 
  1344.       Specifies the file sharing. 
  1345.  
  1346.       read        The file can be shared for read access. Other processes can 
  1347.                   read from the file, but not write to it. 
  1348.  
  1349.       none        The file cannot be shared. No other process can get access to 
  1350.                   the file (exclusive access). 
  1351.  
  1352.       all         Allows the file to be shared for both read and write access. 
  1353.                   Other processes can both read from and write to the file. 
  1354.  
  1355.  writethru( n | y ) 
  1356.       Determines whether to force the writing of Windows buffers. 
  1357.  
  1358.       n              Turns off forced writes to the file. The system is not 
  1359.                      forced to write the internal buffer to permanent storage 
  1360.                      before control is returned to the application. 
  1361.  
  1362.       y              Forces the system to write to permanent storage before 
  1363.                      control is returned to the application. The directory is 
  1364.                      updated after every write operation. 
  1365.  
  1366.                      Use writethru(y) if data must be written to the disk 
  1367.                      before your program continues. This can help make data 
  1368.                      recovery easier should a program interruption occur. 
  1369.  
  1370.       Note:  When writethru(y) is specified, file output will be noticeably 
  1371.       slower. 
  1372.  
  1373.  memory( n | y ) 
  1374.       Specifies whether a file will exist in permanent storage or in memory. 
  1375.  
  1376.       n           Specifies that the file will exist in permanent storage. 
  1377.  
  1378.       y           Specifies that the file will exist only in memory. The system 
  1379.                   uses only the Windows file name. All other parameters, such 
  1380.                   as a path, are ignored. You must specify the /Sv+ option to 
  1381.                   enable memory files. 
  1382.  
  1383.  
  1384. ΓòÉΓòÉΓòÉ 4.5.3. fopen Defaults ΓòÉΓòÉΓòÉ
  1385.  
  1386. A call to fopen has the following defaults: 
  1387.  
  1388.  share(read)     The file can be shared for read access. Other processes can 
  1389.                  read from the file, but not write to it. 
  1390.  
  1391.  writethru(n)    The file is opened with no forced writes to permanent storage. 
  1392.  
  1393.  Full buffering is used unless the stream is connected to a character device, 
  1394.  then it it is line buffered. 
  1395.  
  1396.  For more information on fopen, refer to the C Library Reference. 
  1397.  
  1398.  
  1399. ΓòÉΓòÉΓòÉ 4.6. Precedence of File Characteristics ΓòÉΓòÉΓòÉ
  1400.  
  1401. You can describe your data both within the program, by fopen, and outside it, 
  1402. by ddname, but you do not always need to do so. There are advantages to 
  1403. describing the characteristics of your data in only one place. 
  1404.  
  1405. Opening a file by ddname may require the merging of the information internal 
  1406. and external to the program. In the case of a conflict, the characteristics 
  1407. described by using fopen override those described using a ddname. For example, 
  1408. given the following ddname statement and fopen command: 
  1409.  
  1410.   SET DD:ROGER=danny.c, memory(n)
  1411.   stream = fopen("DD:ROGER", "w, type=memory")
  1412.  
  1413. the file danny.c will be opened as a memory file. 
  1414.  
  1415.  
  1416. ΓòÉΓòÉΓòÉ 4.7. Closing Files ΓòÉΓòÉΓòÉ
  1417.  
  1418. The fclose function is used to close a file. On normal program termination, the 
  1419. compiler library routines automatically close all files and flush all buffers. 
  1420. When a program ends abnormally, all files are closed but the buffers are not 
  1421. flushed. 
  1422.  
  1423.  
  1424. ΓòÉΓòÉΓòÉ 4.8. Input/Output Restrictions ΓòÉΓòÉΓòÉ
  1425.  
  1426. The following restrictions apply to input/output operations: 
  1427.  
  1428.      Seeking within character devices and Windows piped files is not allowed. 
  1429.  
  1430.      Seeking past the end of the file is not allowed for text files. For 
  1431.       binary files that are opened using any of w, w+, wb+, w+b, or wb, a seek 
  1432.       past the end of the file will result in a new end-of-file position and 
  1433.       nulls will be written between the old end-of-file position and the new 
  1434.       one. 
  1435.  
  1436.  Note:  When you open a file in append mode, the file pointer is positioned at 
  1437.  the end of the file. 
  1438.  
  1439.  
  1440. ΓòÉΓòÉΓòÉ 5. Optimizing Your Program ΓòÉΓòÉΓòÉ
  1441.  
  1442. Two aspects of your program can be affected by optimization - the size of your 
  1443. program and your program's execution performance. 
  1444.  
  1445. This chapter discusses: 
  1446.  
  1447.      Standard Optimization Considerations and 
  1448.      Fine-tuning Techniques for Optimizing Code 
  1449.  
  1450.  In general, optimizing your code will result in faster and smaller programs. 
  1451.  However, in some cases, optimizing for size may result in a slower program, 
  1452.  and optimizing for speed may result in a larger program. In addition, when you 
  1453.  optimize your code you may uncover bugs in your code that had not been evident 
  1454.  before. 
  1455.  
  1456.  This chapter provides guidelines only. To obtain the best results for either 
  1457.  performance or module size, experiment with the techniques suggested. 
  1458.  
  1459.  
  1460. ΓòÉΓòÉΓòÉ 5.1. Standard Optimization Considerations ΓòÉΓòÉΓòÉ
  1461.  
  1462. It is assumed you have already implemented the obvious program changes which 
  1463. typically yield the initial, dramatic, performance improvements. Program 
  1464. changes you should already have considered include: choosing efficient 
  1465. algorithms with small memory footprints; avoiding duplicate copies of data; and 
  1466. passing atomic types (like int and short) by value versus passing by reference, 
  1467. wherever possible. While not a technical pre-requisite to the fine-tuning 
  1468. methods discussed here, if you have not already examined your program for these 
  1469. types of improvements, we recommend you do so before continuing with this 
  1470. chapter. 
  1471.  
  1472. For help on determining the execution profile of your program, see the 
  1473. discussion of the Performance Analyzer in the User's Guide. The benefits to 
  1474. your program will vary depending on your code and on the opportunities for 
  1475. optimization available to the compiler. 
  1476.  
  1477.  
  1478. ΓòÉΓòÉΓòÉ 5.2. Fine-tuning Techniques for Optimizing Code ΓòÉΓòÉΓòÉ
  1479.  
  1480. This chapter describes fine-tuning techniques which have the potential to 
  1481. squeeze that final percentage point or two of performance improvement out of 
  1482. your program, for those situations and applications where peak efficiency is 
  1483. required. Because the size of your program affects both the load time and the 
  1484. runtime characteristics of your application, it is best to do size tuning 
  1485. before performance tuning.  We have presented the topics in that order. 
  1486.  
  1487.      Reducing Program Size 
  1488.      Improving Program Performance 
  1489.  
  1490.  
  1491. ΓòÉΓòÉΓòÉ 5.2.1. Reducing Program Size ΓòÉΓòÉΓòÉ
  1492.  
  1493. This section lists the methods you can use to decrease the size of your 
  1494. executable module. 
  1495.  
  1496.      Coding Techniques 
  1497.      Using Libraries and Library Functions 
  1498.      Choosing Compiler Options 
  1499.  
  1500.  
  1501. ΓòÉΓòÉΓòÉ 5.2.1.1. Coding Techniques ΓòÉΓòÉΓòÉ
  1502.  
  1503. The following list describes relatively quick and simple ways you can make your 
  1504. modules smaller: 
  1505.  
  1506.      When you declare or define structures or C++ classes, take into account 
  1507.       the alignment of data types.  Declare the largest members first to reduce 
  1508.       wasted space between members. 
  1509.  
  1510.      If you do not use the intermediate code linker, arrange your own external 
  1511.       data to minimize gaps in alignment. 
  1512.  
  1513.      Avoid assigning structures if your structures are large or if you use 
  1514.       #include <string.h>. Instead, use memcpy to copy the structure. 
  1515.  
  1516.      If you do not use the argc and argv arguments to main, create a dummy 
  1517.       _setuparg function that contains no code. 
  1518.  
  1519.  
  1520. ΓòÉΓòÉΓòÉ 5.2.1.2. Using Libraries and Library Functions ΓòÉΓòÉΓòÉ
  1521.  
  1522. Your choice of libraries and of library functions affects the size of your 
  1523. code. The guidelines below can add up to a greater reduction in size than those 
  1524. listed above, but they can also require more effort on your part.  In some 
  1525. cases, they require you to write your own code for such things as buffering or 
  1526. exception handling. 
  1527.  
  1528.      Use the subsystem library whenever possible.  This library has no runtime 
  1529.       environment, so the initialization, termination, and exception handling 
  1530.       code is not included.  It also includes fewer library functions than the 
  1531.       standard library. 
  1532.  
  1533.      Use the low-level I/O functions.  Note that you must provide your own 
  1534.       buffering for these functions. 
  1535.  
  1536.      Disable the inlining of intrinsic C functions. 
  1537.  
  1538.       Certain string manipulation, floating-point, and trigonometric functions 
  1539.       are inlined by default. (See C Library Reference for a list of these 
  1540.       functions.) To selectively disable the inlining, parenthesize the 
  1541.       function call, for example: 
  1542.  
  1543.               (strlen)(x);
  1544.  
  1545.       For most of the floating-point built-in functions, this recommendation 
  1546.       does not apply because the inlined code is probably smaller than a 
  1547.       generated call instruction. 
  1548.  
  1549.       The /Oc switch disables expansion of intrinsic fuctions whenever the 
  1550.       function call is smaller than the inlined function. You must specify /O 
  1551.       whenever you wish to use the /Oc switch. 
  1552.  
  1553.  
  1554. ΓòÉΓòÉΓòÉ 5.2.1.3. Choosing Compiler Options ΓòÉΓòÉΓòÉ
  1555.  
  1556. The following list names the compiler options to use to make your executable 
  1557. module smaller. Unless noted, these options are not set by default. 
  1558.  
  1559.  /Gd+    Links dynamically to the runtime library.  If you link statically, 
  1560.          code for all the runtime functions you call is included in your 
  1561.          executable module. 
  1562.  
  1563.  /Gh-    Does not generate execution trace and analyzer hooks which would 
  1564.          increase module size. This is the default. 
  1565.  
  1566.  /Gi+    Generates code for fast integer execution and eliminates certain 
  1567.          conversions. 
  1568.  
  1569.  /Gw-    Does not generate an FWAIT instruction after each floating-point load 
  1570.          instruction.  This is the default. 
  1571.  
  1572.  /Gx+    For C++ programs only, suppresses generation of exception handling 
  1573.          code. 
  1574.  
  1575.  /G3|/qtune=386 Optimizes for the 386 processor. Optimizing for other 
  1576.          processors generates extra code. Code compiled with /G3 runs on a 486, 
  1577.          Pentium, or Pentium Pro processor. 
  1578.  
  1579.  /O+     Turns on optimization. 
  1580.  
  1581.  /Oc+    Turns on optimization for size. You must also specify /O. 
  1582.  
  1583.  /Oi-    Does not inline user functions. Inlining reduces overhead but 
  1584.          increases module size. When /O- is specified, this is the default. 
  1585.          When /O+ is specified, /Oi+ becomes the default. 
  1586.  
  1587.  /Ol+    Passes code through the intermediate code linker.  The intermediate 
  1588.          linker removes unused variables and sorts external data to provide 
  1589.          maximal packing.  For best results, use the /Gu+ option to specify 
  1590.          that defined data is not used by external functions.  See the User's 
  1591.          Guide for more information about the intermediate linker. 
  1592.  
  1593.  /Sh-    Does not include ddname support.  This is the default. 
  1594.  
  1595.  /Sv-    Does not include memory file support in the library. This is the 
  1596.          default. 
  1597.  
  1598.  /Ti-    Does not generate debug or Performance Analyzer information, which 
  1599.          would increase module size. This is the default. 
  1600.  
  1601.  /Tx-    Provides only the exception message and address when an exception 
  1602.          occurs instead of a complete machine-state dump. This is the default. 
  1603.  
  1604.  
  1605. ΓòÉΓòÉΓòÉ 5.2.2. Improving Program Performance ΓòÉΓòÉΓòÉ
  1606.  
  1607. This section lists the methods you can use to improve the speed of your 
  1608. program. 
  1609.  
  1610.      Choosing Libraries 
  1611.      Allocating and Managing Memory 
  1612.      Using Strings and String Manipulation Functions 
  1613.      Performing Input and Output 
  1614.      Designing and Calling Functions 
  1615.      Other Coding Techniques 
  1616.      C++-Specific Considerations 
  1617.      Choosing Compiler Options 
  1618.      Specifying Linker Options 
  1619.  
  1620.  
  1621. ΓòÉΓòÉΓòÉ 5.2.2.1. Choosing Libraries ΓòÉΓòÉΓòÉ
  1622.  
  1623. Your choice of runtime libraries can affect the performance of your code: 
  1624.  
  1625.      Use the subsystem library whenever possible.  Because there is no runtime 
  1626.       environment for this library, its load and initialization times are 
  1627.       faster than for the other libraries. 
  1628.  
  1629.      Use the single-thread library for single-thread programs.  The 
  1630.       multithread library involves extra overhead. 
  1631.  
  1632.      If your application has multiple executable modules and DLLs, create and 
  1633.       use a common version of a runtime library DLL. See Creating Your Own 
  1634.       Runtime Library DLLs  for more information. 
  1635.  
  1636.  
  1637. ΓòÉΓòÉΓòÉ 5.2.2.2. Allocating and Managing Memory ΓòÉΓòÉΓòÉ
  1638.  
  1639. The following list describes ways to improve performance through better memory 
  1640. allocation and management: 
  1641.  
  1642.      If you allocate a lot of dynamic storage for a specific function, use the 
  1643.       _alloca function. Because _alloca allocates from the stack instead of the 
  1644.       heap, the storage is automatically freed when the function ends. In some 
  1645.       cases however, using _alloca can detract from performance. It causes the 
  1646.       function that calls it to chain the EBP register, which creates more code 
  1647.       in the function prolog and also eliminates EBP from use as a 
  1648.       general-purpose register. If you are not allocating much dynamic storage, 
  1649.       this overhead can outweigh the benefits of using _alloca. For this 
  1650.       reason, if your function does not allocate a lot of dynamic storage, use 
  1651.       other memory allocation functions. 
  1652.  
  1653.      You can use malloc, HeapAlloc, or if programming in C++, new to allocate 
  1654.       storage. In general, HeapAlloc is faster, but you must do your own heap 
  1655.       management and you cannot use realloc to reallocate the memory. Also, 
  1656.       HeapAlloc can only allocate at the granularity of a page. However, malloc 
  1657.       manages the heap for you and the storage it returns can be reallocated 
  1658.       with realloc. In addition, malloc is portable, while HeapAlloc is not. 
  1659.       When programming in C++, use new. new calls the constructor for the class 
  1660.       object being created and provides additional type checking not available 
  1661.       when using malloc or HeapAlloc. 
  1662.  
  1663.      When you use malloc, the amount of storage allocated is actually the 
  1664.       amount you specify plus a minimal overhead that is used internally by the 
  1665.       memory allocation functions. 
  1666.  
  1667.      When you copy data into storage allocated by calloc, malloc, or realloc, 
  1668.       copy it to the same boundaries on which the compiler would align them. In 
  1669.       particular, aligning double precision floating-point variables and arrays 
  1670.       on 8-byte boundaries can greatly improve performance on the 486, Pentium, 
  1671.       and Pentium Pro microprocessors. For more information about the mapping 
  1672.       of data, see Data Mapping. 
  1673.  
  1674.      When you declare or define structures or C++ classes, take into account 
  1675.       the alignment of data types.  Declare the largest members first to reduce 
  1676.       wasted space between members and to reduce the number of boundaries the 
  1677.       compiler must cross. The alignment is especially important if you pack 
  1678.       your structure or class. 
  1679.  
  1680.      After freeing or reallocating storage, periodically call _heapmin to 
  1681.       release the unused storage to the operating system and reduce the working 
  1682.       set of your program. A reduced working set causes less swapping of memory 
  1683.       to disk, resulting in better performance. Experiment to determine how 
  1684.       often you should call _heapmin. 
  1685.  
  1686.  
  1687. ΓòÉΓòÉΓòÉ 5.2.2.3. Using Strings and String Manipulation Functions ΓòÉΓòÉΓòÉ
  1688.  
  1689. The handling of string operations can affect the performance of your program: 
  1690.  
  1691.      When you store strings into storage allocated by malloc, align the start 
  1692.       of the string on a doubleword, or 4-byte, boundary. This alignment allows 
  1693.       the best performance of the string functions.  The compiler performs this 
  1694.       alignment for all strings it allocates. 
  1695.  
  1696.      Keep track of the length of your strings.  If you know the length of your 
  1697.       string, you can use memcpy instead of strcpy. The memcpy function is 
  1698.       faster because it does not have to search for the end of the string. 
  1699.  
  1700.      Avoid using strtok.  Because this function is very general, you can 
  1701.       probably write a function more specific to your application and get 
  1702.       better performance. 
  1703.  
  1704.  In C and C++, strings are read-only by default. Placing strings into read-only 
  1705.  memory allows for certain types of optimizations and also causes the compiler 
  1706.  to put out only one copy of strings that are used in more than one place. If 
  1707.  you use the intrinsic string functions, the compiler can better optimize them 
  1708.  if it knows that any string literals it is operating on will not be changed. 
  1709.  
  1710.  Note:  You can explicitly set strings to read-only by using #pragma strings 
  1711.  (readonly) in your source files or /qro to avoid changing your source files. 
  1712.  
  1713.  
  1714. ΓòÉΓòÉΓòÉ 5.2.2.4. Performing Input and Output ΓòÉΓòÉΓòÉ
  1715.  
  1716. There are a number of ways to improve your program's performance of input and 
  1717. output: 
  1718.  
  1719.      Use binary streams instead of text streams.  In binary streams, data is 
  1720.       not changed on input or output. 
  1721.  
  1722.      Use the low-level I/O functions, such as open and close. These functions 
  1723.       are faster and more specific to the application than the stream I/O 
  1724.       functions like fopen and fclose. You must provide your own buffering for 
  1725.       the low-level functions. 
  1726.  
  1727.      If you do your own I/O buffering, make the buffer a multiple of 4K, which 
  1728.       is the size of a page. Because malloc uses extra storage as overhead, 
  1729.       allocating storage in a multiple of the page size actually results in 
  1730.       more pages being allocated than required. Instead, you may want to 
  1731.       investigate one of the Win32 mechanisms for managing memory (i.e. virtual 
  1732.       memory, memory mapped files, or heaps). 
  1733.  
  1734.      If you know you have to process an entire file, the following technique 
  1735.       has the advantage of reducing disk I/O, provided the file is not so big 
  1736.       that excessive swapping will occur. Determine the size of the data to be 
  1737.       read in, allocate a single buffer to read it to, read the whole file into 
  1738.       that buffer at once using ReadFile, and then process the data in the 
  1739.       buffer. 
  1740.  
  1741.      If you perform frequent read or write operations on your temporary files, 
  1742.       create them as memory files. I/O operations can be performed more quickly 
  1743.       on memory files than on disk files. To use memory files, you must specify 
  1744.       the /Sv+ option. 
  1745.  
  1746.      Instead of scanf and fscanf, use fgets to read in a string, and then use 
  1747.       one of atoi, atol, atof, or _atold to convert it to the appropriate 
  1748.       format. 
  1749.  
  1750.      Use sprintf only for complex formatting. For simpler formatting, such as 
  1751.       string concatenation, use a more specific string function. 
  1752.  
  1753.      When reading input, read in a whole line at once rather than one 
  1754.       character at a time. 
  1755.  
  1756.  
  1757. ΓòÉΓòÉΓòÉ 5.2.2.5. Designing and Calling Functions ΓòÉΓòÉΓòÉ
  1758.  
  1759. Whether you are writing a function or calling a library function, there are a 
  1760. few things you should keep in mind: 
  1761.  
  1762.      Fully prototype all functions. A full prototype gives the compiler and 
  1763.       optimizer complete information about the types of the parameters. As a 
  1764.       result, promotions from unwidened types to widened types are not required 
  1765.       and the compiler never needs to emit eyecatcher instructions for the 
  1766.       function (see Eyecatchers). 
  1767.  
  1768.      When designing a function, place the most used parameters in the left 
  1769.       most position in the function prototype.  The left most parameters have a 
  1770.       better chance of being stored in a register. 
  1771.  
  1772.      Avoid passing structures or unions as function parameters or returning a 
  1773.       structure or a union. Passing such aggregates requires the compiler to 
  1774.       copy and store many values. This is worse in C++ programs in which class 
  1775.       objects are passed by value, a constructor and destructor are called when 
  1776.       the function is called. Instead, pass or return a pointer to the 
  1777.       structure or union. 
  1778.  
  1779.      If you call another function near the end of your function and pass it 
  1780.       the same parameters that were passed to your function, put the parameters 
  1781.       in the same order in the function prototypes. The compiler can then reuse 
  1782.       the storage that the parameters are in and does not have to generate code 
  1783.       to reorder them. 
  1784.  
  1785.      Use the intrinsic and built-in functions, which include string 
  1786.       manipulation, floating-point, and trigonometric functions. Intrinsic 
  1787.       functions require less overhead and are faster than a function call, and 
  1788.       often allow the compiler to perform better optimization. Your functions 
  1789.       are automatically mapped to intrinsic functions if you include the 
  1790.       VisualAge for C++ header file, however, in C only, this mapping is 
  1791.       overridden if you #undef the macro name. 
  1792.  
  1793.      Be careful when using intrinsic functions in loops. Many intrinsic 
  1794.       functions use multiple registers.  Some of the registers are specific and 
  1795.       cannot be changed.  In the loop, the number of values to be placed in 
  1796.       registers increases while the number of registers is limited.  As a 
  1797.       result, temporary values such as loop induction variables and results of 
  1798.       intermediate calculations often cannot be stored in registers, thus 
  1799.       slowing your program performance. 
  1800.  
  1801.       In general, you will encounter this problem with the intrinsic string 
  1802.       functions rather than the floating-point functions, and in inner loops or 
  1803.       when tuning for a 386 using /G3 or /qtune=386. 
  1804.  
  1805.      Use recursion only where necessary. Because recursion involves building a 
  1806.       stack frame, an iterative solution is always faster than a recursive one. 
  1807.  
  1808.  
  1809. ΓòÉΓòÉΓòÉ 5.2.2.6. Other Coding Techniques ΓòÉΓòÉΓòÉ
  1810.  
  1811. The following list describes other techniques you can use to improve 
  1812. performance: 
  1813.  
  1814.      Use the _Import keyword to identify data and function imports from a DLL, 
  1815.       this generates the most efficient code. Avoid using the /qautomimported 
  1816.       switch unless you really need to generate objects without DLL 
  1817.       considerations. 
  1818.  
  1819.      Use one or more of the /qalias=typ|allp|addr|ansi options. The ability to 
  1820.       make less conservative aliasing assumptions results in better code. 
  1821.  
  1822.      Minimize the use of external (extern) variables to reduce aliasing and so 
  1823.       improve optimization. 
  1824.  
  1825.      Avoid taking the address of local variables. If you use a local variable 
  1826.       as a temporary variable and must take its address, avoid reusing the 
  1827.       temporary variable. Taking the address of a local variable inhibits 
  1828.       optimizations that would otherwise be done on calculations involving that 
  1829.       variable. 
  1830.  
  1831.      Avoid using short int values, except in aggregates. Because all integer 
  1832.       arithmetic is done on long values, using short values causes extra 
  1833.       conversions to be performed. 
  1834.  
  1835.      Avoid using long long int types, except where absolutely necessary. 
  1836.       Similarly, avoid using float (use double float instead wherever 
  1837.       possible). Extra instructions must be generated to perform operations on 
  1838.       such data types. 
  1839.  
  1840.      If you do division or modulo arithmetic by a divisor that is a power of 
  1841.       2, if possible, make the dividend unsigned to produce better code. 
  1842.  
  1843.      Use #pragma alloc_text and #pragma data_seg to group code and data 
  1844.       respectively, to improve the locality of reference. Using #pragma 
  1845.       alloc_text causes functions that are used at the same time to be stored 
  1846.       together. They might then fit on a single page that can be used and then 
  1847.       discarded. You can use Performance Analyzer to determine which functions 
  1848.       to group together. #pragma data_seg works in a similar manner for 
  1849.       grouping data. 
  1850.  
  1851.      Use constants where possible. The optimizer will be able to do a better 
  1852.       job reducing runtime calculations by doing them at compile-time instead. 
  1853.       For instance, if a loop body has a constant number of iterations, use 
  1854.       constants in the loop condition to improve optimization. In the following 
  1855.       statement, for (i=0; i<4; i++) can be better optimized than for (i=0; 
  1856.       i<x; i++). 
  1857.  
  1858.      Avoid goto statements that jump into the middle of loops. Such statements 
  1859.       inhibit certain optimizations. 
  1860.  
  1861.      Use the intermediate code linker to improve optimization. See the User's 
  1862.       Guide for information about the intermediate linker. 
  1863.  
  1864.      Inline your functions selectively. Inlined functions require less 
  1865.       overhead and are generally faster than a function call. The best 
  1866.       candidates for inlining are small functions that are called frequently 
  1867.       from a few places. Large functions and functions that are called rarely 
  1868.       may not be good candidates for inlining. 
  1869.  
  1870.       For best results, use the Performance Analyzer to decide which functions 
  1871.       you should inline and qualify the _Inline keyword (or inline for C++ 
  1872.       files). For a discussion of using Performance Analyzer in this manner, 
  1873.       see the User's Guide. (Using automatic inlining, specifying /Oi with a 
  1874.       value, is not as effective.) Using the intermediate code linker with user 
  1875.       inlining can improve your program performance even more. 
  1876.  
  1877.  Some coding practices, although often necessary, will slow down program 
  1878.  performance: 
  1879.  
  1880.      Using the setjmp and longjmp functions. These functions involve storing 
  1881.       and restoring the state of the thread. 
  1882.  
  1883.      Using #pragma handler. This #pragma causes code to be generated to 
  1884.       register and deregister an exception handler for a function. 
  1885.  
  1886.  
  1887. ΓòÉΓòÉΓòÉ 5.2.2.7. C++-Specific Considerations ΓòÉΓòÉΓòÉ
  1888.  
  1889. The following performance hints apply only to C++ programs: 
  1890.  
  1891.      Because C++ objects are often allocated from the heap and have a limited 
  1892.       scope, memory usage in C++ programs affects performance more than in C 
  1893.       programs.  To improve memory usage and performance: 
  1894.  
  1895.         -  Tailor your own new and delete operators. 
  1896.         -  Allocate memory for a class before it is required. 
  1897.         -  Ensure that objects that are no longer needed are freed or otherwise 
  1898.            made available for reuse. One way to do this is to use an object 
  1899.            manager. Each time you create an instance of an object, you pass the 
  1900.            pointer to that object to the object manager. The object manager 
  1901.            maintains a list of these pointers. To access an object, you can 
  1902.            call an object manager member function to return the information to 
  1903.            you. The object manager can then manage memory usage and object 
  1904.            reuse. 
  1905.         -  Avoid copying large complex objects. 
  1906.  
  1907.      When you use the Collection classes from the Open Class Library to create 
  1908.       classes, use a high level of abstraction. After you establish the type of 
  1909.       access to your class, you can create more specific implementations.  This 
  1910.       can result in improved performance with minimal code change. 
  1911.  
  1912.      Use virtual functions only when they are necessary. They are usually 
  1913.       compiled to be indirect calls, which are slower than direct calls. 
  1914.  
  1915.      Use try blocks for exception handling only when necessary because they 
  1916.       can inhibit optimization. Use the /Gx+ option to suppress the generation 
  1917.       of exception handling code in programs where it is not needed. Unless you 
  1918.       specify this option, some exception handling code is generated even for 
  1919.       programs that do not use catch or try blocks. 
  1920.  
  1921.      Avoid using overloaded operators to perform arithmetic operations on 
  1922.       user-defined types. The compiler cannot perform the same optimizations 
  1923.       for objects as it can for simple types. 
  1924.  
  1925.      Avoid performing a deep copy if a shallow copy is all you require. For an 
  1926.       object that contains pointers to other objects, a shallow copy copies 
  1927.       only the pointers and not the objects to which they point. The result is 
  1928.       two objects that point to the same contained object. A deep copy, 
  1929.       however, copies the pointers and the objects they point to, as well as 
  1930.       any pointers or objects contained within that object, and so on. A simple 
  1931.       assignment using an overloaded operator can generate many lines of code. 
  1932.  
  1933.      When you define structures or data members within a class, define the 
  1934.       largest data types first to align them on the doubleword boundary. 
  1935.  
  1936.      Usually, you should not declare virtual functions inline. If all virtual 
  1937.       functions in a class are inline, the virtual function table of that class 
  1938.       and all the virtual function bodies will be replicated in each 
  1939.       compilation unit that uses the class. 
  1940.  
  1941.  
  1942. ΓòÉΓòÉΓòÉ 5.2.2.8. Choosing Compiler Options ΓòÉΓòÉΓòÉ
  1943.  
  1944. The following list names the compiler options that can improve performance and 
  1945. describes the action of each option. 
  1946.  
  1947. Note:  Of these options, only /Om- and /Gf+ are defaults. 
  1948.  
  1949.  Option  Effect 
  1950.  
  1951.  /Gf+    Generates code for fast floating-point operations. 
  1952.  
  1953.  /Gi+    Generates code for fast integer operations. 
  1954.  
  1955.  /Gx+    For C++ programs only, suppresses generation of exception handling 
  1956.          code. 
  1957.  
  1958.  /G[3|4|5] Optimize for the 386 (/G3), 486 (/G4), or Pentium (/G5) 
  1959.          microprocessor. Use the appropriate option for the processor you are 
  1960.          using or plan to use. If you do not know what processor your 
  1961.          application will run on, use the /qtune=blend option (see below). The 
  1962.          blend option tries to optimize for all the 32-bit X86 processors. 
  1963.  
  1964.  /qtune[386|486|pentium|pentiumpro|blend] Optimize for the 386, 486, Pentium, 
  1965.          or Pentium Pro microprocessor. Use the appropriate option for the 
  1966.          processor you are using or plan to use. If you do not know what 
  1967.          processor your application will run on, use the -qtune=blend option 
  1968.          (this is the default). The blend option tries to optimize for all the 
  1969.          32-bit X86 processors. 
  1970.  
  1971.          If your application is floating-point intensive and you know that the 
  1972.          application will be running on a Pentium or PentiumPro processor, use 
  1973.          pentium or pentiumpro qtune values instead of blend. Such generated 
  1974.          code will run faster on these processors, but could run slower on 386 
  1975.          or 486 processors. 
  1976.  
  1977.  /O+     Turns on optimization for speed. Specifying /O+ also causes /Op+ 
  1978.          (enable optimizations involving the stack pointer), /Os+ (invoke the 
  1979.          instruction scheduler), and /Oi+ (inline user functions) to be 
  1980.          specified. 
  1981.  
  1982.  /Oi+    Inlines user functions. 
  1983.  
  1984.  /Ol+    Passes code through the intermediate code linker.  Using the 
  1985.          intermediate linker can result in better optimized code.  For best 
  1986.          results, use the /Gu+ option also to specify that data that is defined 
  1987.          in the .DLL or .EXE being built is not used by external functions. See 
  1988.          the User's Guide for more information about the intermediate linker. 
  1989.  
  1990.  /Om-    Does not limit the working set size of the compiler so that the 
  1991.          compiler can inline more user code. 
  1992.  
  1993.  /qalias=<opt1>:<opt2>:...:<optN> Specifies the aliasing assertion to be 
  1994.          applied to your compilation unit. The available options are: 
  1995.  
  1996.          typ            Pointers to different types are never aliased. 
  1997.  
  1998.          allp           Pointers are never aliased. 
  1999.  
  2000.          addr           Variables are disjoint from pointers unless the address 
  2001.                         is taken. 
  2002.  
  2003.          ansi           Use type-based aliasing during optimization. 
  2004.  
  2005.  #pragma disjoint The directive informs the compiler that none of the 
  2006.          identifiers listed share the same physical storage.  This provides 
  2007.          more opportunity for optimization.  Valid for C programs only. 
  2008.  
  2009.  #pragma isolated_call Marking a function as isolated indicates to the 
  2010.          optimizer that external and static variables cannot be changed by the 
  2011.          called function and that references to storage can be deleted from the 
  2012.          calling function where appropriate. Instructions can be reordered with 
  2013.          more freedom, resulting in fewer pipeline delays and faster execution 
  2014.          in the processor. 
  2015.  
  2016.  The following options improve the performance of your code by preventing the 
  2017.  generation of objects or information that can degrade performance. Note that 
  2018.  these are set by default: 
  2019.  
  2020.  Option  Effect 
  2021.  /Gh-    Prevents the generation of execution trace and analyzer hooks. 
  2022.  /Gw-    Prevents the generation of FWAIT instruction after each floating-point 
  2023.          load instruction. 
  2024.  /qnoautoimported Generates code assuming that all data to be imported from a 
  2025.          DLL has been explicitly marked with the _Import keyword or the 
  2026.          __declspec(dllimport) modifier. 
  2027.  /Ti-    Does not generate debug information. 
  2028.  
  2029.  
  2030. ΓòÉΓòÉΓòÉ 5.2.2.9. Specifying Linker Options ΓòÉΓòÉΓòÉ
  2031.  
  2032. Using the following linker options can lead to improved performance. 
  2033.  
  2034.  /BASE:n     /BASE can be used to position the DLLs you require at 
  2035.              non-overlapping address ranges. This will normally speed up 
  2036.              loading because it is less likely that a DLL will have to be 
  2037.              relocated to some other address. 
  2038.  
  2039.  /Gl+        Enable smart linking. (Default is /Gl-.) 
  2040.  
  2041.  /ALIGNFILE:n Use this linker option to set the file alignment for sections in 
  2042.              the output file. Setting n to larger factors reduces the load time 
  2043.              for the executable. (By default, the alignment is set to 512.) 
  2044.  
  2045.  
  2046. ΓòÉΓòÉΓòÉ 6. Creating Multithread Programs ΓòÉΓòÉΓòÉ
  2047.  
  2048. This chapter describes how to use the VisualAge for C++ compiler to create 
  2049. multithread programs and discusses restrictions of the multithread environment. 
  2050. It also describes the sample multithread program that you may have installed 
  2051. which is included with the VisualAge for C++ product. For instructions on how 
  2052. to compile and run the sample program, see Sample Multithread Program. 
  2053.  
  2054. Multithread programming is a feature of the Windows operating system and is 
  2055. supported by the VisualAge for C++ compiler with: 
  2056.  
  2057.      Code generation and linking options. 
  2058.  
  2059.       (See Compiling and Linking Multithread Programs for more information.) 
  2060.  
  2061.      Multithread libraries. 
  2062.  
  2063.       (See Using the Multithread Libraries for more information.) 
  2064.  
  2065.  No multithread support is available in the subsystem libraries or in 
  2066.  applications run in the Win32s environment. You can use Thread Local Storage 
  2067.  (TLS) in Win32s. Even though threads are not supported there, a version of TLS 
  2068.  provides a per-process data facility in Win32s. For more information on TLS 
  2069.  and the Win32s environment, see Understanding Multithreaded Variables. 
  2070.  
  2071.  
  2072. ΓòÉΓòÉΓòÉ 6.1. What Is a Multithread Program? ΓòÉΓòÉΓòÉ
  2073.  
  2074. A multithread program is one whose functions are divided among several threads. 
  2075. A process is an executing application and the resources it uses, a thread is 
  2076. the smallest unit of execution within a process. Other than its stack and 
  2077. registers, a thread owns no resources; it uses those of its parent process. 
  2078. This chapter discusses threads, references to processes are for contrast only. 
  2079.  
  2080. Multithread programs allow more complex processing than single-thread programs. 
  2081. In a single-thread program, all operations are performed serially. That is, one 
  2082. operation begins when the preceding one has finished. 
  2083.  
  2084. The advantage of having multiple threads are: 
  2085.  
  2086.    1. on multi-processor systems, threads can execute concurrently and thus the 
  2087.       entire multithread program is completed faster 
  2088.  
  2089.    2. on single or multiple processor systems, if any thread is blocked 
  2090.       (waiting for I/O to complete) then the rest of your application can 
  2091.       continue to process or respond to user data. 
  2092.  
  2093.  Although threads within a process share the same address space and files, each 
  2094.  thread runs independently and is not affected by the control flow of any other 
  2095.  thread in the process. Because a function from any thread can perform any 
  2096.  task, such as input or output, threads are well suited to programs that have 
  2097.  multiple uses of the same data or resources. 
  2098.  
  2099.  
  2100. ΓòÉΓòÉΓòÉ 6.1.1. Thread Control ΓòÉΓòÉΓòÉ
  2101.  
  2102. The mechanisms for creating and deleting threads under VisualAge for C++are: 
  2103.  
  2104.      _beginthread and _endthread from the multithread libraries, 
  2105.  
  2106.      CreateThread and ExitThread from the Windows API, or 
  2107.  
  2108.      IThread from the User Interface classes. 
  2109.  These are discussed in more detail below. 
  2110.  
  2111.  _beginthread and _endthread 
  2112.  
  2113.  The multithread libraries provide two functions, _beginthread and _endthread, 
  2114.  to create new threads and to end them. You should use _beginthread to create 
  2115.  any threads that call VisualAge for C++ library functions. When the thread is 
  2116.  started, the library environment performs certain initializations that ensure 
  2117.  resources and data are handled correctly between threads. The VisualAge for 
  2118.  C++ product also provides the global variable _threadid that identifies your 
  2119.  current thread, and the function _threadstore that gives you a private thread 
  2120.  pointer to which you can assign any thread-specific data structure. For more 
  2121.  detail on the functions _endthread and _beginthread, see the C Library 
  2122.  Reference. 
  2123.  
  2124.  CreateThread and ExitThread 
  2125.  
  2126.  You can also create threads with the CreateThread API. 
  2127.  
  2128.  Threads created by the CreateThread API do not have access to the resource 
  2129.  management facilities or to VisualAge for C++ exception handling, you must use 
  2130.  a #pragma handler directive for the thread function to ensure correct 
  2131.  exception handling. You should also call _fpreset from the new thread to 
  2132.  ensure the floating-point control word is set correctly for the thread. 
  2133.  Although you can use ExitThread to end threads created with CreateThread, you 
  2134.  should use _endthread to ensure that the necessary cleanup of the environment 
  2135.  is done. 
  2136.  
  2137.  IThread 
  2138.  
  2139.  The start member function of the IThread class is used to start additional 
  2140.  threads.  This member function has three overloaded versions and three 
  2141.  corresponding constructors for: 
  2142.  
  2143.      Functions compatible with _beginthread. That is, the functions which have 
  2144.       _Optlink linkage, take one argument of void* type, and return void. 
  2145.  
  2146.      Functions compatible with CreateThread. That is, the functions which have 
  2147.       __stdcall linkage, take one argument of unsigned long type, and return 
  2148.       void. 
  2149.  
  2150.      Any other function. 
  2151.  
  2152.  Because IThread can handle functions which fall under both of the previously 
  2153.  discussed thread control mechanisms, as well as being able to handle functions 
  2154.  which fall under neither, it is the preferred thread handling mechanism. It 
  2155.  does not only what other mechanisms do, it does it better. Unlike 
  2156.  _beginthread, you don't have to explicitly call _endthread to clean up the 
  2157.  environment, and unlike CreateThread, you don't have to write your own 
  2158.  exception handler. 
  2159.  
  2160.  You can use the IThread class in your multithread programs to : 
  2161.  
  2162.      Set thread priority 
  2163.      Set thread attributes 
  2164.      Do a reference count for objects dispatched on a thread so they are 
  2165.       automatically deleted when the thread ends 
  2166.      Dispatch a member function of a C++ object on a separate thread 
  2167.      Control other aspects of your threads. 
  2168.  For a description of the IThread class and how to use it, see the Open Class 
  2169.  Library Reference. 
  2170.  
  2171.  
  2172. ΓòÉΓòÉΓòÉ 6.2. Understanding Multithreaded Variables ΓòÉΓòÉΓòÉ
  2173.  
  2174. Thread Local Storage (TLS) is a mechanism whereby each thread in a 
  2175. multithreaded process will allocate storage for the data corresponding to that 
  2176. thread. VisualAge for C++ provides both a dynamic and a static technique of 
  2177. using TLS. 
  2178.  
  2179. Dynamic TLS is provided by a set of four Win32 API's: TlsAlloc, TlsFree, 
  2180. TlsSetValue, and TlsGetValue. With these API's, the user must handle the 
  2181. allocation and initialization of the the thread-local data and, as such, are 
  2182. more difficult to use. However, there are situations (noted later) when the 
  2183. API's are the only choice. 
  2184.  
  2185. Static TLS uses the same concept as dynamic TLS but has the advantage of being 
  2186. simpler from the high-level view. It allows TLS data to be defined and 
  2187. initialized in a manner similar to ordinary static variables. 
  2188.  
  2189. The thread local data objects are declared by the __thread attribute: 
  2190.  
  2191.  
  2192.  __thread dataObject
  2193.  
  2194. where the dataObject can be one of the following: 
  2195.  
  2196.      global data objects 
  2197.  
  2198.      local static data objects 
  2199.  
  2200.      static data members of a class 
  2201.  
  2202.  
  2203. ΓòÉΓòÉΓòÉ 6.2.1. Rules and Restrictions on using TLS ΓòÉΓòÉΓòÉ
  2204.  
  2205.    1. __thread can only be used for data declarations and definitions. 
  2206.  
  2207.             /* Declaration of an integer thread local variable and its initialization: */
  2208.  
  2209.              __thread int tlsVar1 = 1;
  2210.  
  2211.              static __thread int tlsVar2 = 100;
  2212.  
  2213.    2. The thread attribute cannot be used on function declarations or 
  2214.       definitions. 
  2215.  
  2216.             /* Declaration of a thread local function: */
  2217.  
  2218.              __thread void func();          // Error
  2219.  
  2220.    3. The thread attribute can only be specified on data items with static 
  2221.       storage duration. 
  2222.  
  2223.             /* Declaration of an integer thread local variable and its initialization: */
  2224.  
  2225.              __thread int tlsVar1 = 1;
  2226.  
  2227.              static __thread int tlsVar2 = 100;
  2228.  
  2229.    4. The thread attribute cannot be used to declare automatic data objects. 
  2230.  
  2231.             /* Declaration of a thread local variable with an
  2232.               automatic storage duration */
  2233.  
  2234.              void
  2235.              func1()
  2236.              {
  2237.                __thread int tlsVar;         // Error
  2238.              }
  2239.  
  2240.              int
  2241.              func2( __thread int tlsVar )      // Error
  2242.              {
  2243.                 return tlsVar;
  2244.              }
  2245.  
  2246.              auto __thread float tlsVar;       // Error
  2247.  
  2248.    5. The thread attribute must be used for the declaration and definition of a 
  2249.       thread local object. This is true regardless of whether the declaration 
  2250.       and definition occur in the same file or separate files. 
  2251.  
  2252.             /* Mismatch in declaring and defining a thread local object either in the
  2253.               same file or in separate files: */
  2254.  
  2255.              extern int tlsVar;       // This is not allowed since the declaration
  2256.              __thread int tlsVar;      // and the definition differ.
  2257.  
  2258.    6. Because C++ objects with constructors and destructors, as well as objects 
  2259.       that use initialization semantics, can be allocated as thread local, an 
  2260.       associated initialization routine must be called to initialize the 
  2261.       object. 
  2262.  
  2263.             /* Initializing the thread local object by the class constructor: */
  2264.  
  2265.              class tlsClass
  2266.              {
  2267.                 public:
  2268.                  tlsClass() { x = 1; } ;
  2269.                  ~tlsClass();
  2270.  
  2271.                 private:
  2272.                  int x;
  2273.              }
  2274.  
  2275.              __thread tlsClass tlsObject;
  2276.              extern int func();
  2277.              __thread int y = func();
  2278.  
  2279.    7. On Windows95, __thread objects with constructors and destructors are not 
  2280.       run at thread initialization/termination. 
  2281.  
  2282.    8. The thread attribute cannot be used as a type modifier. Therefore, if the 
  2283.       thread attribute is used as a type modifier, it will have no effect on 
  2284.       the type. 
  2285.  
  2286.    9. The thread attribute cannot be used by the C++ classes or enumerated 
  2287.       types. However, the C++ class objects or variables of an enumerated type 
  2288.       can be initiated with the thread attribute. 
  2289.  
  2290.             /* Declaring a C++ class with a thread attribute: */
  2291.  
  2292.              __thread class C        // Error
  2293.              {
  2294.                . . .
  2295.              };
  2296.              C CObject;
  2297.  
  2298.             /* Declaring a C++ class object with a thread attribute.
  2299.               Because the declaration of C++ objects that use the thread
  2300.               attribute is permitted, these two examples are semantically
  2301.               equivalent:  */
  2302.  
  2303.              __thread class B
  2304.              {
  2305.                . . .
  2306.              } BObject;
  2307.  
  2308.              class B
  2309.              {
  2310.                . . .
  2311.              }
  2312.              __thread B BObject;
  2313.  
  2314.   10. The address of a thread local object is not considered constant, and any 
  2315.       expression involving such an address is not considered a constant 
  2316.       expression. Therefore, the address of a thread local variable cannot be 
  2317.       used as an initializer in C. 
  2318.  
  2319.             /* Initializing a pointer by the address of the thread local variable: */
  2320.  
  2321.              __thread int tlsVar;
  2322.              int *p = &tlsVar;           // C Error, NOT a C++ error
  2323.  
  2324.   11. Thread local data cannot be imported or exported. 
  2325.  
  2326.              extern __thread int _Import i:  /* error */
  2327.  
  2328.   12. A DLL that contains static TLS data cannot be dynamically loaded with the 
  2329.       LoadLibrary system call. On the Windows 95 operating system, the 
  2330.       LoadLibrary call will fail. In the Windows NT and Win32s operating 
  2331.       environments, the LoadLibrary call will succeed but you will trap in the 
  2332.       DLL when you try to access the __thread data. 
  2333.  
  2334.  Statically declared __thread data objects can be used only in statically 
  2335.  loaded files. This fact makes it unreliable to use TLS in a DLL, unless you 
  2336.  know that the DLL (or anything statically linked to it) will never be loaded 
  2337.  dynamically. In particular, do not attempt to use __thread data objects in 
  2338.  DLLs that will be dynamically loaded through the LoadLibrary API. This 
  2339.  restiction does not apply to dynamically loaded DLLs that use the 
  2340.  thread-local-storage APIs. 
  2341.  
  2342.  
  2343. ΓòÉΓòÉΓòÉ 6.2.2. Thread Local Storage Sample ΓòÉΓòÉΓòÉ
  2344.  
  2345. If you installed the VisualAge for C++ sample programs, you will find the 
  2346. Thread Local Storage sample in the Guide to Samples notebook. You can access 
  2347. the source files plus a readme file for each of these samples through the Guide 
  2348. to Samples notebook or directly via the \ibmcppw\samples\compiler\tls 
  2349. directory. To access the files through the notebook, open the VisualAge for C++ 
  2350. program object in Program Manager. Open the Guide to Samples notebook to the 
  2351. Components page. Select Compiler from the components list box, then select 
  2352. Thread Local Storage from the samples list. Finally, click the Open Project 
  2353. View button. You will see the files in the upper portion of the project window. 
  2354.  
  2355. For a discussion of address space in the Win32s environment, see Developing 
  2356. Applications for Win32s. 
  2357.  
  2358.  
  2359. ΓòÉΓòÉΓòÉ 6.3. Using the Multithread Libraries ΓòÉΓòÉΓòÉ
  2360.  
  2361. The VisualAge for C++ compiler has two standard libraries that provide library 
  2362. functions for use in multithread programs. The CPPWM35.LIB library is a 
  2363. statically linked multithread library, and CPPWM35I.LIB is an import 
  2364. multithread library, with the addresses of the functions contained in VisualAge 
  2365. for C++ DLLs. 
  2366.  
  2367. In addition to the above two standard libraries, the User Interface Class 
  2368. library is also available in multithread form.  A singlethread version of this 
  2369. library is not provided. 
  2370.  
  2371. Not all of the VisualAge for C++ Standard class libraries are available for 
  2372. multithread programs. The Complex Mathematics library is available for both 
  2373. single- and multithread programs. The single-thread Complex library is 
  2374. CPPWOX3.LIB, while the multithread version is CPPWOY3.LIB. The C++ I/O Stream 
  2375. library is built into both the VisualAge for C++ single-thread and the 
  2376. multithread runtime libraries. The User Interface class library also offers an 
  2377. IThread class that is an encapsulation of the Windows APIs for multithread 
  2378. programming. 
  2379.  
  2380. When you use the multithread libraries, you have more to consider than with the 
  2381. single-thread libraries. For example, because many library functions share data 
  2382. and other resources, the access to these resources must be serialized (limited 
  2383. to one thread at a time) to prevent functions from interfering with each other. 
  2384. Other functions can affect all threads running within a process. Global 
  2385. variables and error handling are also affected by the multithread environment. 
  2386.  
  2387.  
  2388. ΓòÉΓòÉΓòÉ 6.3.1. Reentrant Functions ΓòÉΓòÉΓòÉ
  2389.  
  2390. Reentrant functions are those which can be suspended at any point and 
  2391. reentered, after which they can return to that same point to resume processing, 
  2392. with no adverse effects. If a function used no data that can be accessed by 
  2393. more than one thread, the function is said to be reentrant. In particular, a 
  2394. reentrant function cannot use data on the heap or in static memory. It can use 
  2395. only automatic (stack) and thread-local data. Because the function uses no data 
  2396. that can be modified by other threads, no additional care needs to be taken to 
  2397. serialize access to data or resources. 
  2398.  
  2399. Note, though, that even if a function is written to be reentrant, it is 
  2400. possible to subvert this reentrancy by passing a pointer to shared data as a 
  2401. parameter to the function. In general, it is impossible for the compiler and 
  2402. library to determine whether you are doing this, so it is your responsibility 
  2403. to ensure that pointer parameters to library functions point at data whose 
  2404. access is properly serialized. 
  2405.  
  2406. All functions in the C++ Complex Mathematics Library are fully reentrant. The 
  2407. I/O Stream Library functions are nonreentrant. 
  2408.  
  2409. The following functions are reentrant: 
  2410.  
  2411. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  2412. Γöé absolut   Γöé fstat    Γöé localtime  Γöé stat    Γöé strupr   Γöé
  2413. Γöé acos    Γöé _ftime   Γöé log     Γöé strcat   Γöé strxfrm   Γöé
  2414. Γöé asctime   Γöé _fullpath  Γöé log10    Γöé strchr   Γöé swab    Γöé
  2415. Γöé asin    Γöé gamma    Γöé _lrotl   Γöé strcmp   Γöé tan     Γöé
  2416. Γöé assert   Γöé _gcvt    Γöé _lrotr   Γöé strcmpi   Γöé tanh    Γöé
  2417. Γöé atan    Γöé _getcwd   Γöé lsearch   Γöé strcoll   Γöé time    Γöé
  2418. Γöé atan2    Γöé _getdcwd  Γöé _ltoa    Γöé strcpy   Γöé _toascii  Γöé
  2419. Γöé atof    Γöé _getdrive  Γöé _makepath  Γöé strcspn   Γöé tolower   Γöé
  2420. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2421. Γöé atoi    Γöé getpid   Γöé mblen    Γöé _strdate  Γöé _tolower  Γöé
  2422. Γöé atol    Γöé gmtime   Γöé mbstowcs  Γöé strerror  Γöé toupper   Γöé
  2423. Γöé atold    Γöé hypot    Γöé mbtowc   Γöé _strerror  Γöé _toupper  Γöé
  2424. Γöé bsearch   Γöé isalnum   Γöé memccpy   Γöé strftime  Γöé _tzset   Γöé
  2425. Γöé _cabs    Γöé isalpha   Γöé memchr   Γöé stricmp   Γöé _ultoa   Γöé
  2426. Γöé ceil    Γöé isascii   Γöé memcmp   Γöé strlen   Γöé utime    Γöé
  2427. Γöé chdir    Γöé iscntrl   Γöé memcpy   Γöé strlwr   Γöé vsprintf  Γöé
  2428. Γöé _chdrive  Γöé isdigit   Γöé memicmp   Γöé strncat   Γöé wait    Γöé
  2429. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2430. Γöé clock    Γöé isgraph   Γöé memmove   Γöé strncmp   Γöé wcscat   Γöé
  2431. Γöé cos     Γöé islower   Γöé memset   Γöé strncpy   Γöé wcschr   Γöé
  2432. Γöé cosh    Γöé isprint   Γöé mkdir    Γöé strnicmp  Γöé wcscmp   Γöé
  2433. Γöé ctime    Γöé ispunct   Γöé mktime   Γöé strnset   Γöé wcscpy   Γöé
  2434. Γöé _cwait   Γöé isspace   Γöé modf    Γöé strpbrk   Γöé wcscspn   Γöé
  2435. Γöé difftime  Γöé isupper   Γöé pow     Γöé strrchr   Γöé wcslen   Γöé
  2436. Γöé div     Γöé isxdigit  Γöé qsort    Γöé strrev   Γöé wcsncat   Γöé
  2437. Γöé _ecvt    Γöé _itoa    Γöé rmdir    Γöé strset   Γöé wcsncmp   Γöé
  2438. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  2439. Γöé erf     Γöé _j0     Γöé _rotl    Γöé strspn   Γöé wcsncpy   Γöé
  2440. Γöé erfc    Γöé _j1     Γöé _rotr    Γöé strstr   Γöé wcspbrk   Γöé
  2441. Γöé exp     Γöé _jn     Γöé sin     Γöé _strtime  Γöé wcsrchr   Γöé
  2442. Γöé fabs    Γöé labs    Γöé sinh    Γöé strtok   Γöé wcsspn   Γöé
  2443. Γöé _fcvt    Γöé ldexp    Γöé _splitpath Γöé strtod   Γöé wcstombs  Γöé
  2444. Γöé floor    Γöé ldiv    Γöé sprintf   Γöé strtol   Γöé wctomb   Γöé
  2445. Γöé fmod    Γöé lfind    Γöé sqrt    Γöé strtold   Γöé _y0     Γöé
  2446. Γöé _freemod  Γöé _loadmod  Γöé sscanf   Γöé strtoul   Γöé _y1     Γöé
  2447. Γöé frexp    Γöé       Γöé       Γöé       Γöé _yn     Γöé
  2448. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  2449.  
  2450.  
  2451. ΓòÉΓòÉΓòÉ 6.3.2. Nonreentrant Functions ΓòÉΓòÉΓòÉ
  2452.  
  2453. Other nonreentrant library functions can access data or resources that are 
  2454. common to all threads in the process, including files, environment variables, 
  2455. and I/O resources. To prevent any interference among themselves, these 
  2456. functions use semaphores, provided by the Windows operating system, to 
  2457. serialize access to data and resources. 
  2458.  
  2459. Operations involving file handles and standard I/O streams are serialized so 
  2460. that multiple threads can send output to the same stream without intermingling 
  2461. the output. 
  2462.  
  2463.       Example of Serialized I/O 
  2464.  
  2465.  
  2466. ΓòÉΓòÉΓòÉ <hidden> Example of Serialized I/O ΓòÉΓòÉΓòÉ
  2467.  
  2468. If thread1 and thread2 execute the calls in the example below, the output could 
  2469. appear in several different ways, but never garbled as shown at the end of the 
  2470. example. 
  2471.  
  2472.  
  2473. Example of Serialized I/O
  2474.  
  2475. #include <stdio.h>
  2476.  
  2477. int done_1 = 0;
  2478. int done_2 = 0;
  2479.  
  2480. void _Optlink thread1(void)
  2481. {
  2482.   fprintf(stderr,"This is thread 1\n");
  2483.   fprintf(stderr,"More from 1\n");
  2484.   done_1 = 1;
  2485. }
  2486.  
  2487. void _Optlink thread2(void)
  2488. {
  2489.   fprintf(stderr,"This is thread 2\n");
  2490.   fprintf(stderr,"More from 2\n");
  2491.   done_2 = 1;
  2492. }
  2493.  
  2494. int main(void)
  2495. {
  2496.   _beginthread(thread1, NULL, 4096, NULL);
  2497.   _beginthread(thread2, NULL, 4096, NULL);
  2498.  
  2499.   while (1)
  2500.   {
  2501.    if (done_1 && done_2)
  2502.      break;
  2503.   }
  2504.   return 0;
  2505. }
  2506.  
  2507. /* Possible output could be:
  2508.  
  2509.     This is thread 1
  2510.     This is thread 2
  2511.     More from 1
  2512.     More from 2
  2513. or
  2514.     This is thread 1
  2515.     More from 1
  2516.     This is thread 2
  2517.     More from 2
  2518. or
  2519.     This is thread 1
  2520.     This is thread 2
  2521.     More from 2
  2522.     More from 1
  2523.  
  2524.   The output will never look like this:
  2525.  
  2526.     This is This is thrthread 1
  2527.     ead 2
  2528.     More froMore m 2
  2529.     from 1               */
  2530.  
  2531. Several nonreentrant functions have specific restrictions: 
  2532.  
  2533.      The getc, getchar, putc, and putchar file I/O operations are implemented 
  2534.       as macros in the single-thread C libraries. In the multithread libraries, 
  2535.       they are redefined as functions to implement any necessary serialization 
  2536.       of resources. 
  2537.  
  2538.      Use the _fcloseall function only after all file I/O has been completed. 
  2539.  
  2540.      When you use printf or vprintf and the subsystem libraries, you must 
  2541.       provide the necessary serialization for stdout yourself. 
  2542.  
  2543.  The functions in the C++ I/O Stream Library are also nonreentrant. To use 
  2544.  these I/O Stream objects in a multithread environment, you must provide your 
  2545.  own serialization either using the Windows semaphore APIs or the 
  2546.  IResourceLock, IPrivateResource, and ISharedResource classes from the User 
  2547.  Interface classes. 
  2548.  
  2549.  
  2550. ΓòÉΓòÉΓòÉ 6.3.3. Process Control Functions ΓòÉΓòÉΓòÉ
  2551.  
  2552. The process termination functions abort, exit, and _exit end all threads within 
  2553. the process, not just the thread that calls the termination function.  In 
  2554. general, you should allow only thread 1 to terminate a process, and only after 
  2555. all other threads have ended. 
  2556.  
  2557. Note: 
  2558.  
  2559.    1. If your program exits from a signal or exception handler it may be 
  2560.       necessary to terminate the process from a thread other than thread 1. 
  2561.  
  2562.    2. A routine that resides in a DLL must not terminate the process, except in 
  2563.       the case of a critical error.  If the DLL and the executable for the 
  2564.       process have different runtime libraries, terminating the process from 
  2565.       the DLL would bypass any onexit or atexit functions that the executable 
  2566.       may have registered. 
  2567.  
  2568.  
  2569. ΓòÉΓòÉΓòÉ 6.3.4. Signal Handling in Multithread Programs ΓòÉΓòÉΓòÉ
  2570.  
  2571. Signal handling , as described in Signal and Windows Exception Handling, also 
  2572. applies to the multithread environment. The default handling of signals is 
  2573. usually either to terminate the program or to ignore the signal. 
  2574. Special-purpose signal handling, however, can be complicated in the multithread 
  2575. environment. 
  2576.  
  2577. Handlers for synchronous signals are registered independently on each thread. A 
  2578. synchronous signal is always handled on the thread that generated it. For 
  2579. example, if thread 1 calls signal as follows: 
  2580.  
  2581.   signal(SIGFPE, handlerfunc);
  2582.  
  2583. then the handler handlerfunc is registered for thread 1 only. Any other threads 
  2584. are handled using the defaults. 
  2585.  
  2586. The three asynchronous signals SIGBREAK, SIGINT, and SIGTERM are handled on the 
  2587. new thread the operating system creates for the handler. This means other 
  2588. threads will be running at the same time with the handler even if you linked to 
  2589. the single-threaded library. This situation may cause a problem because the 
  2590. single-threaded library is not serialized. Therefore, users should not assume 
  2591. that single threaded library functions are reentrant. 
  2592.  
  2593. For more information and examples on handling signals, refer to Signal and 
  2594. Windows Exception Handling. 
  2595.  
  2596.  
  2597. ΓòÉΓòÉΓòÉ 6.3.5. Global Data and Variables ΓòÉΓòÉΓòÉ
  2598.  
  2599. The following two variables need to have a unique value for each thread in 
  2600. which they are defined: 
  2601.  
  2602.      errno 
  2603.      _doserrno 
  2604.  The C library maintains thread-specific values for these global variables. 
  2605.  Other variables, such as _environ are common across all threads and do not 
  2606.  automatically get unique values in each thread that uses them. 
  2607.  
  2608.  For example, the following program shows how the value of errno is unique to 
  2609.  each thread.  Although an error occurs in the thread openProc, the value of 
  2610.  errno is 0 because it is checked from the main thread. 
  2611.  
  2612.  
  2613.   Example of a Per-Thread Variable
  2614.  
  2615.   #include <stdio.h>
  2616.   #include <stdlib.h>
  2617.   #include <string.h>
  2618.   #include <errno.h>
  2619.  
  2620.   int done = 0;
  2621.  
  2622.   void _Optlink openProc(void * argument)
  2623.   {
  2624.     FILE *filePointer ;
  2625.     filePointer = fopen("C:\\OS2","w");
  2626.     printf("openProc, errno = %d\n",errno);
  2627.     done = 1;
  2628.   }
  2629.  
  2630.   int main(void)
  2631.   {
  2632.     char holder[80];
  2633.  
  2634.     errno = 0 ;
  2635.     _beginthread(openProc,NULL,4096,NULL) ;
  2636.  
  2637.     while (1)  /* Break only when the thread is done. */
  2638.     {
  2639.      printf("Press <enter> to continue.\n");
  2640.      gets(holder);
  2641.      if (done)
  2642.        break ;
  2643.      printf("The thread is still executing! \n");
  2644.     }
  2645.  
  2646.     printf("Main program, errno = %d.\n",errno);
  2647.     return 0;
  2648.  
  2649.     /* The expected output is:
  2650.  
  2651.      Press <enter> to continue.
  2652.      openProc, errno = 60
  2653.  
  2654.      Main program, errno = 0.   */
  2655.  
  2656.   }
  2657.  
  2658.  When you call longjmp, the buffer you pass to it must have been initialized by 
  2659.  a call to setjmp on the same thread. If the buffer was not initialized on the 
  2660.  same thread, the process terminates. 
  2661.  
  2662.  The internal buffers used by asctime, ctime, gmtime, and localtime are also 
  2663.  allocated on a per-thread basis. That is, these functions return addresses of 
  2664.  buffers that are specific to the thread from where the function was called. 
  2665.  
  2666.  There is one seed per thread for generating random numbers with the rand and 
  2667.  srand functions. This ensures that the pseudorandom numbers generated in each 
  2668.  thread are independent of other threads. Each thread starts with the same seed 
  2669.  (1); that is, each thread gets the same sequence of pseudorandom numbers 
  2670.  unless the seed is changed by a call to srand. 
  2671.  
  2672.  
  2673. ΓòÉΓòÉΓòÉ 6.3.5.1. Global Variables Requiring Serialization ΓòÉΓòÉΓòÉ
  2674.  
  2675. These global variables containing environment strings should be treated as 
  2676. read-only data. They should only be modified by library functions: 
  2677.  
  2678.   int _daylight;
  2679.   long _timezone;
  2680.   char *_tzname[2];
  2681.  
  2682.   char _osmajor;
  2683.   char _osminor;
  2684.   char _osmode;
  2685.  
  2686.   char **_environ;
  2687.  
  2688. Note:  The _timezone variable contains the time difference (in seconds) between 
  2689. the local time and Greenwich Mean Time (GMT). 
  2690.  
  2691. The environment strings are copied from the Windows environment when a program 
  2692. starts. This procedure is the same in multithread and single thread programs. 
  2693. Because all threads share the environment strings, any change made to the 
  2694. strings by one thread affects the environment accessed by the other threads. 
  2695.  
  2696. Each thread can call getenv to obtain a copy of the environment strings and 
  2697. copy the string to a private data buffer so that any later changes to the 
  2698. environment by putenv will not affect it. If the thread must always access the 
  2699. latest version of the environment strings, it must call getenv each time. The 
  2700. putenv and getenv functions are described in the C Library Reference. 
  2701.  
  2702.  
  2703. ΓòÉΓòÉΓòÉ 6.3.5.2. Using Common Variables ΓòÉΓòÉΓòÉ
  2704.  
  2705. User variables that are referenced by multiple threads and are not declared 
  2706. using the __thread attribute, should have the attribute volatile to ensure that 
  2707. all changes to the value of the variable are seen immediately by other threads. 
  2708. For example, because of the way the compiler optimizes code, the following 
  2709. example may not work as intended when compiled with the /O+ option: 
  2710.  
  2711. static int common_var;
  2712.  
  2713. /*  code executing in thread 1  */
  2714.  
  2715.   common_var = 0;
  2716.     ...
  2717.   common_var = 1;
  2718.     ...
  2719.   common_var = 2;
  2720.  
  2721. /*  code executing in thread 2  */
  2722.  
  2723.   switch (common_var)
  2724.   {
  2725.    case 0:
  2726.      ...
  2727.     break;
  2728.    case 1:
  2729.      ...
  2730.     break;
  2731.    default:
  2732.      ...
  2733.     break;
  2734.   }
  2735.  
  2736. When optimizing, the compiler may not immediately store the value 1 for the 
  2737. variable common_var in thread 1. If it determines that common_var is not 
  2738. accessed by this code until after the value 2 is stored, it may never store the 
  2739. value 1. Thread 2 therefore does not necessarily access the true value of 
  2740. common_var. 
  2741.  
  2742. Declaring a variable as volatile indicates to the compiler that references to 
  2743. the variable have side effects, or that the variable may change in ways the 
  2744. compiler cannot determine. Optimization will not eliminate any action involving 
  2745. the volatile variable, changes to the value of the variable are then stored 
  2746. immediately, and uses of the variable will always cause it to be re-fetched 
  2747. from memory (in case its value has been altered by another thread). 
  2748.  
  2749.  
  2750. ΓòÉΓòÉΓòÉ 6.4. Compiling and Linking Multithread Programs ΓòÉΓòÉΓòÉ
  2751.  
  2752. When you compile your multithread program, you must specify that you want to 
  2753. use the multithread libraries described in Using the Multithread Libraries. 
  2754. Because threads share data, the operating system and library functions must 
  2755. ensure that only one thread is reading or writing data at one time. The 
  2756. multithread libraries provide this support. (You can use these libraries for 
  2757. single-thread programs, but the multithread support causes unnecessary 
  2758. overhead.) 
  2759.  
  2760. To indicate that you want the multithread libraries, specify the /Gm+ compiler 
  2761. option.  For example: 
  2762.  
  2763.   icc /Gm+ mymulti.c
  2764.  
  2765. Conversely, the /Gm- option, which is the default, specifies explicitly to use 
  2766. the single-thread version of the library. 
  2767.  
  2768. If you intend to compile your source code into separate modules and then link 
  2769. them into one executable program file, you must compile each module using the 
  2770. /Gm+ option and ensure that the multithread libraries are used when you link 
  2771. them. You cannot mix modules that have been compiled with /Gm+ with modules 
  2772. compiled using /Gm-. 
  2773.  
  2774. You can use either static (/Gd-) or dynamic (/Gd+) linking with multithread 
  2775. programs. 
  2776.  
  2777.  
  2778. ΓòÉΓòÉΓòÉ 6.5. Sample Multithread Program ΓòÉΓòÉΓòÉ
  2779.  
  2780. If you installed the VisualAge for C++ sample programs, you will find SAMPLE2A 
  2781. and sample2b. in the Guide to Samples notebook. These multithread samples 
  2782. create one thread for each numerical argument passed to them. Each thread then 
  2783. prints a message the number of times specified by the argument. You can access 
  2784. the source files plus a readme file for each of these samples through the Guide 
  2785. to Samples notebook or directly via the \ibmcppw\samples\compiler\sample02 
  2786. directory. To access the files through the notebook, open the VisualAge for C++ 
  2787. program object in Program Manager. Open the Guide to Samples notebook to the 
  2788. Components page. Select Compiler from the components list box, then select 
  2789. Multithread Hello World from the samples list. Finally, click the Open Project 
  2790. View button. You will see the files in the upper portion of the project window. 
  2791.  
  2792.  
  2793. ΓòÉΓòÉΓòÉ 7. Building Dynamic Link Libraries ΓòÉΓòÉΓòÉ
  2794.  
  2795. Dynamic linking is the process of resolving references to external data and 
  2796. code at runtime or loadtime instead of at link time. A dynamic link library 
  2797. (DLL) is an executable module which can be shared by more than one process. You 
  2798. can dynamically link with the supplied VisualAge for C++ runtime DLLs, as well 
  2799. as with your own DLLs. 
  2800.  
  2801. The advantages of using a dynamic link library include: 
  2802.  
  2803.      smaller memory requirement as several applications can all share the same 
  2804.       dynamic link library instead of each application having its own copy of 
  2805.       the functions contained in the DLL. 
  2806.      simplified application modification because modifications to an 
  2807.       application's executable module does not necessitate recompilation of the 
  2808.       DLL. 
  2809.      flexible software support as DLL executable modules can be replaced with 
  2810.       newly released, improved versions without forcing recompilation of the 
  2811.       application code. 
  2812.  
  2813.  There are basically two types of dynamic link libraries (DLLs) - those which 
  2814.  contain code and those which do not. An example of the latter are resource 
  2815.  DLL's which contain no code, only resources such as menus or icons. Dynamic 
  2816.  Link Libraries which contain code can be further classified along three 
  2817.  dimensions: whether they link statically or dynamically to the VisualAge for 
  2818.  C++ runtime, whether they support multithread or only singlethread 
  2819.  executables, and whether they use the full system or the subsystem libraries. 
  2820.  
  2821.  This chapter first provides an overview of the process of building and using a 
  2822.  dynamic link library, then goes on to discuss each step in detail. 
  2823.  
  2824.  This chapter also provides information on: 
  2825.  
  2826.      Initializing and Terminating the DLL Environment 
  2827.      Writing Your Own _DLL_InitTerm Function 
  2828.      Creating C++ DLLs 
  2829.      Creating Resource DLLs 
  2830.      Creating Your Own Runtime Library DLLs 
  2831.  
  2832.  Sample code which illustrates the chapter's discussions is provided with the 
  2833.  VisualAge for C++ product. If you installed the VisualAge for C++ 
  2834.  documentation and samples, you will find the Three Sort DLL and Geometric Area 
  2835.  samples in the Guide to Samples notebook. 
  2836.  
  2837.  The notebook can be accessed by opening the VisualAge for C++ program object 
  2838.  in Program Manager. Next, open the Guide to Samples notebook to the Components 
  2839.  page. Select Compiler from the components list box, and then select Three Sort 
  2840.  DLL from the samples list. Finally, click the Open Project View button. You 
  2841.  will see the files in the upper half of the Project window. 
  2842.  
  2843.  Alternatively, you can access the source files plus the readme files for Three 
  2844.  Sort DLL and Geometric Area directly via the 
  2845.  \ibmcppw\samples\compiler\sample03 and \ibmcppw\samples\compiler\sample07 
  2846.  directories, respectively. 
  2847.  
  2848.  
  2849. ΓòÉΓòÉΓòÉ 7.1. Steps for Building a DLL ΓòÉΓòÉΓòÉ
  2850.  
  2851. Building a Dynamic Link Library (DLL) involves the use of the IBM Library 
  2852. Manager (ILIB) and the IBM Linker (ILINK). There are basically two ways to 
  2853. build a DLL, one which requires changes to your source code and one which does 
  2854. not. 
  2855.  
  2856. Building a DLL - Method 1 (source code changes) 
  2857.  
  2858.    1. Code your DLL source files using _Export, #pragma export, or 
  2859.       __declspec(dllexport). 
  2860.  
  2861.    2. Compile the source code (at least one file must be compiled with /Ge-). 
  2862.  
  2863.    3. Link the object modules using icc with /Ge-. icc will call ILIB to 
  2864.       produce a LIB import library and a EXP export object. 
  2865.  
  2866.    4. Include the LIB import library when you link a module which calls the 
  2867.       DLL. 
  2868.  Building a DLL - Method 2 (no source code changes) 
  2869.  
  2870.    1. Code your DLL source files. 
  2871.  
  2872.    2. Compile the source code (at least one file must be compiled with /Ge-). 
  2873.  
  2874.    3. Create a DEF file using CPPFILT. Run CPPFILT on the objects to produce an 
  2875.       export listing, use /B and /P options. Comment out or remove any function 
  2876.       names in the CPPFILT output that you do not want to export. Create a 
  2877.       skeleton DEF file with a LIBRARY and an EXPORTS statement. imbed the 
  2878.       edited CPPFILT output under the EXPORTS statement. 
  2879.  
  2880.    4. Invoke ILIB with the /geni option and pass it the DEF file. ILIB 
  2881.       generates a LIB import library and an EXP export object. 
  2882.  
  2883.    5. Link the DLL and include the EXP object. 
  2884.  
  2885.    6. Include the LIB import library when you link a module which calls the 
  2886.       DLL. 
  2887.  
  2888.  Each of these steps, and variations, are discussed in more detail in the 
  2889.  following sections. 
  2890.  
  2891.  
  2892. ΓòÉΓòÉΓòÉ 7.2. Creating DLL Source Files ΓòÉΓòÉΓòÉ
  2893.  
  2894. To build a DLL, you must first create source files containing the data and/or 
  2895. functions that you want to include in your DLL. No special file extension is 
  2896. required for DLL source files. The source code can be written in C or C++. 
  2897.  
  2898. Each function that you want to export from the DLL (that is, each function that 
  2899. you plan to call from other executable modules or DLLs) must be an externally 
  2900. visible. Otherwise, the linker will not find your function references and will 
  2901. generate errors. 
  2902.  
  2903. The SAMPLE03.C sample file in the IBMCPPW\SAMPLES\COMPILER\SAMPLE03\SORT 
  2904. directory contains the source code for: 
  2905.  
  2906.      Three sorting functions: bubble, insertion, and selection 
  2907.      Two static functions, swap and compare, that are called by the sorting 
  2908.       functions 
  2909.      A function, list, that lists the contents of an array. 
  2910.  
  2911.  
  2912. ΓòÉΓòÉΓòÉ 7.3. Defining Functions and Variables to be Exported ΓòÉΓòÉΓòÉ
  2913.  
  2914. When you export a function from a DLL, you make it available to programs that 
  2915. call the DLL. If you do not export a function, it can only be used within the 
  2916. DLL itself. 
  2917.  
  2918. There are two ways to export the functions in a DLL so that they are available 
  2919. to other programs. You can use any combination of the following methods: 
  2920.  
  2921.      Using _Export, #pragma export, or _declspec(dllexport) in your source 
  2922.       files. 
  2923.  
  2924.            _Export is the easiest method for exporting functions or data. 
  2925.  
  2926.            With the #pragma method, you can export the functions by either 
  2927.            ordinal or name. Exporting by ordinal is of little advantage on 
  2928.            Windows - it is recommended that you do not specify an ordinal 
  2929.            number. The DEF file can be used in addition to either the _Export 
  2930.            or #pragma export keywords in source files. 
  2931.  
  2932.            When you use the keyword or #pragma directive for C++ functions, use 
  2933.            the normal function name, not the encoded name. 
  2934.  
  2935.       For more information on _Export and #pragma export, see the Language 
  2936.       Reference. For more information on using __declspec(dllexport), see the 
  2937.       Language Reference. 
  2938.  
  2939.      Using a DEF file. 
  2940.  
  2941.       With this method, you can avoid source changes such as _Export, 
  2942.       declspec(dllexport), and #pragma export discussed above. 
  2943.  
  2944.       Disadvantages include the fact that a C++ DEF file can be difficult to 
  2945.       write and maintain if you export by name because you must use the mangled 
  2946.       names of the functions that you want to export. Although CPPFILT eases 
  2947.       the necessity of using mangled names. 
  2948.  
  2949.  
  2950. ΓòÉΓòÉΓòÉ 7.3.1. Creating a Module Definition File ΓòÉΓòÉΓòÉ
  2951.  
  2952. A module definition (DEF) file is a plain text file that describes the names, 
  2953. exports,  and other characteristics of an application or dynamic link library. 
  2954.  
  2955. There are four ways to create a DEF file: 
  2956.  
  2957.    1. hand code it 
  2958.    2. generate it from a DLL using ILIB 
  2959.    3. generate it from object files using ILIB 
  2960.    4. generate it from object files using CPPFILT 
  2961.  
  2962.  If you require a DEF file, we strongly recommend that you use CPPFILT or ILIB 
  2963.  to generate it as this avoids having to know the compiler's name mangling 
  2964.  scheme. 
  2965.  
  2966.  If you do not have the source files to a compiled DLL, you may need to use the 
  2967.  DLL to generate the DEF file.  For details of this method of creating a DEF 
  2968.  file, see the User's Guide. 
  2969.  
  2970.  
  2971. ΓòÉΓòÉΓòÉ 7.3.2. Example of a Module Definition File ΓòÉΓòÉΓòÉ
  2972.  
  2973. The DEF file shown here illustrates the most common statements used in a module 
  2974. definition file to build DLLs. 
  2975.  
  2976.  
  2977. DLL Module Definition File
  2978.  
  2979. LIBRARY
  2980. EXPORTS
  2981. _nSize   ; array size
  2982. _pArray   ; pointer to base of array of ints
  2983. _nSwaps   ; number of swaps required to sort the array
  2984. _nCompares ; number of comparisons required to sort the array
  2985. _list    ; array listing function
  2986. ?bubble   ; bubble sort function
  2987. ?insertion ; insertion sort function
  2988.  
  2989. The module statements specified in the DEF file are as follows: 
  2990.  
  2991.  LIBRARY 
  2992.            This statement identifies the executable file as a dynamic link 
  2993.            library. 
  2994.  
  2995.  EXPORTS 
  2996.            This statement defines exported functions and data. 
  2997.  
  2998.  These module definition keywords should always be entered in upper case. 
  2999.  (Mixed case and lower case equivalents are also reserved but should not be 
  3000.  used.) 
  3001.  
  3002.  You will notice there is no IMPORTS statement. That is because an import 
  3003.  library for the executable is automatically generated from the EXPORTS 
  3004.  statement when ILIB is invoked. If an IMPORTS statement is present (as in the 
  3005.  case of an OS/2 DEF file), ILIB will simply ignore it. ILIB will safely ignore 
  3006.  most other DEF file statements. 
  3007.  
  3008.  For a complete description of module definition files, including keywords and 
  3009.  attributes, refer to the VisualAge for C++ linker utility section of the 
  3010.  User's Guide. 
  3011.  
  3012.  
  3013. ΓòÉΓòÉΓòÉ 7.4. Compiling and Linking Your DLL ΓòÉΓòÉΓòÉ
  3014.  
  3015. You can compile and link your source files in one step or in separate steps. 
  3016. The preferred method is to use the one-step method -- this is described below. 
  3017. Details of the two-step method are explained later. 
  3018.  
  3019.  
  3020. ΓòÉΓòÉΓòÉ 7.4.1. Compiling and Linking Your DLL in One Step ΓòÉΓòÉΓòÉ
  3021.  
  3022. When you use icc to compile and link your DLL: 
  3023.  
  3024.      use the /Ge- compiler option to tell the compiler you are building a DLL, 
  3025.       rather than an executable file. 
  3026.  
  3027.      Specify the runtime libraries you want to use. 
  3028.  
  3029.         -  Single-thread (/Gm-) or multithread (/Gm+), single-thread is the 
  3030.            default. 
  3031.  
  3032.            For information on multithread libraries, see Creating Multithread 
  3033.            Programs. 
  3034.  
  3035.         -  Statically linked (/Gd-) or dynamically linked (/Gd+), statically 
  3036.            linked is the default. 
  3037.  
  3038.            For more information on static and dynamic linking, see the User's 
  3039.            Guide. 
  3040.  
  3041.            Note: 
  3042.  
  3043.              1. The method of linking used for the runtime libraries is 
  3044.                 independent of the module type you create; you can statically 
  3045.                 link the runtime functions in a dynamic link library. 
  3046.  
  3047.              2. All objects in a DLL must be compiled with the same settings of 
  3048.                 /Gm and /Gd. 
  3049.  
  3050.      Specify on the command line all the DLL source, object and library files, 
  3051.       followed by the module definition file, if used. 
  3052.  
  3053.       By default, the name of the first source file (without the file name 
  3054.       extension) is used as the name of the DLL. 
  3055.  
  3056.       For example, to compile and link the files mydlla.c and mydllb.c, using 
  3057.       the mydll.def module definition file, use the command: 
  3058.  
  3059.               icc /Ge- mydlla.c mydllb.c mydll.def
  3060.  
  3061.       The resulting DLL will be called mydlla.dll. 
  3062.  
  3063.       Alternatively, you may specifically name the output DLL as follows: 
  3064.  
  3065.               icc /Ge- mydlla.c mydllb.c mydll.def /Femyname.dll
  3066.  
  3067.  If your DLL contains C++ code that uses templates, there are additional 
  3068.  considerations.  See Creating C++ DLLs for details on creating a C++ DLL. 
  3069.  
  3070.  
  3071. ΓòÉΓòÉΓòÉ 7.4.2. Compiling and Linking in Separate Steps ΓòÉΓòÉΓòÉ
  3072.  
  3073. To compile and link your DLL in separate steps: 
  3074.  
  3075.      Invoke the compiler with the /C+ option to compile your source files 
  3076.       without linking them, and the /Ge- option so the compiler knows you are 
  3077.       not creating an executable. 
  3078.  
  3079.      If you did not use #pragma export, declspec(dllexport), or _Export in 
  3080.       your source files to indicate which functions and data you wished to 
  3081.       export, you will need to create a DEF file to provide that information. 
  3082.       Run CPPFILT on your files to create the entries for the EXPORTS section 
  3083.       of a DEF file. Or, create the DEF file in the previous step by passing 
  3084.       the /gendef option along with the /geni option. 
  3085.  
  3086.      Pass your object and library files to ILIB to create a LIB import library 
  3087.       and an EXP export object. 
  3088.  
  3089.      Link them, giving the following information to the VisualAge for C++ 
  3090.       linker: 
  3091.  
  3092.         -  The compiled object (OBJ) files for the DLL 
  3093.         -  The name to give the DLL 
  3094.         -  The C libraries to use 
  3095.         -  The name of the EXP intermediate file output from ILIB. 
  3096.  
  3097.       Note:  The compiler includes information in the object files on the C 
  3098.       libraries you indicated by the compiler options that control code 
  3099.       generation (see the User's Guide). These libraries are automatically used 
  3100.       at link time.  You do not need to specify C runtime libraries on the 
  3101.       linker command line. 
  3102.  
  3103.  For example, the following commands 
  3104.  
  3105.      Compile the source files mydlla.c and mydllb.c 
  3106.      Link the resulting object files with the single-thread (default), 
  3107.       statically linked C libraries (default), using the definition file 
  3108.       mydll.def, to create the DLL finaldll.dll. 
  3109.  
  3110.     icc /C+ /Ge- mydlla.c mydllb.c
  3111.     ILIB /geni:finaldll.lib mydlla.obj mydllb.obj
  3112.     ILINK mydlla.obj mydllb.obj mydll.exp /OUT:finaldll.dll
  3113.  
  3114.  If your DLL contains C++ code that uses templates, there are additional 
  3115.  considerations.  See Creating C++ DLLs for details on creating a C++ DLL. 
  3116.  
  3117.  
  3118. ΓòÉΓòÉΓòÉ 7.5. Creating C++ DLLs ΓòÉΓòÉΓòÉ
  3119.  
  3120. If your DLL is written in C++, you must specify the mangled or encoded name of 
  3121. the function when coding a DEF file. The CPPFILT utility is provided to assist 
  3122. you with this task. For an explanation of how to use the CPPFILT utility to 
  3123. mangle and demangle function names, see Demangling (Decoding) C++ Function 
  3124. Names. 
  3125.  
  3126. Also, ensure that you export all member functions that are required. If an 
  3127. inlined or exported function uses private or protected members, you must also 
  3128. export those members. In addition, you should export all static data members. 
  3129. If you do not export the static data members of a particular class, users of 
  3130. that class cannot debug their code because the reference to the static data 
  3131. members cannot be resolved. 
  3132.  
  3133. When your DLL is written in C++, there are considerations that do not apply to 
  3134. DLLs written in C. You must ensure that classes and class members are exported 
  3135. correctly, especially if they use templates. 
  3136.  
  3137. You can build C++ DLLs using any combination of the following methods: 
  3138.  
  3139.      Using _Export, #pragma export and __declspec(dllexport), and 
  3140.      Using CPPFILT to Create a DLL 
  3141.  
  3142.  
  3143. ΓòÉΓòÉΓòÉ 7.5.1. Using _Export, #pragma export and __declspec(dllexport) ΓòÉΓòÉΓòÉ
  3144.  
  3145. This is the simplest method of creating a C++ DLL: 
  3146.  
  3147.    1. Use _Export, #pragma export, or __declspec(dllexport) in your source 
  3148.       files to specify the classes, functions (including member functions) and 
  3149.       data that you want to export from your DLL. 
  3150.  
  3151.       For example: 
  3152.  
  3153.               class triangle : public area
  3154.               {
  3155.                public:
  3156.                  static int _Export objectCount;
  3157.                  double _Export getarea();
  3158.                  _Export triangle(void);
  3159.               };
  3160.  
  3161.       exports the getarea function and the constructor for class triangle. 
  3162.  
  3163.       Alternatively, you could use #pragma export: 
  3164.  
  3165.               #pragma export(triangle::objectCount,,1)
  3166.               #pragma export(triangle::getarea(),,1)
  3167.               #pragma export(triangle::triangle(void),,2)
  3168.  
  3169.       Or, you could use __declspec to export the static data objectCount : 
  3170.  
  3171.               class triangle : public area
  3172.               {
  3173.                public:
  3174.                  static int __declspec(dllexport) objectCount;
  3175.                  double _Export getarea();
  3176.                  _Export triangle(void);
  3177.               };
  3178.  
  3179.       Important  You must always export constructors and destructors. Also, 
  3180.       when you use the _Export keyword or the #pragma directive, for C++ 
  3181.       functions, you must use the normal name, not the encoded one. 
  3182.  
  3183.       The _Export keyword and #pragma directive are described in more detail in 
  3184.       the online Language Reference. 
  3185.  
  3186.    2. If you have marked all functions and data to be exported, you do not need 
  3187.       to create a DEF file. (Otherwise, create a DEF file as described in 
  3188.       Creating a Module Definition File for any functions or data to be 
  3189.       exported which you have not marked.) 
  3190.  
  3191.    3. Use icc to compile and link the DLL. If you use any of the Complex, 
  3192.       Collection, or User Interface class libraries, you must specify the 
  3193.       library names on the command line for the link step. If you link in a 
  3194.       separate step, use the same options as when you compiled. 
  3195.  
  3196.  
  3197. ΓòÉΓòÉΓòÉ 7.6. Using CPPFILT to Create a DLL ΓòÉΓòÉΓòÉ
  3198.  
  3199. To build a DLL using the CPPFILT utility: 
  3200.  
  3201.    1. Compile your source files as you would for any DLL. 
  3202.  
  3203.    2. If you use templates, compile either: 
  3204.  
  3205.           with the /Ft- compiler option, or 
  3206.           compile the template-include files located in the TEMPINC directory 
  3207.            under the source directory. 
  3208.  
  3209.            The template-include files contain the implementation of all 
  3210.            instantiated templates that are used in the files you compiled and 
  3211.            are needed when you link your DLL. 
  3212.  
  3213.            Copy the objects created from the template-include files into the 
  3214.            directory with your other DLL objects. 
  3215.  
  3216.    3. Run CPPFILT on all your object files together. Because CPPFILT sends 
  3217.       output to stdout, ensure you redirect the output to a file. For example: 
  3218.  
  3219.               CPPFILT /B /P file1.obj file2.obj > cppdll.def
  3220.  
  3221.       The /B option specifies that the files are binary, and the /P option 
  3222.       specifies to include all public symbols in the CPPFILT output.  For more 
  3223.       details on the CPPFILT utility, see Using the CPPFILT Utility. 
  3224.  
  3225.    4. Edit the output file.  Delete entries for functions and variables that 
  3226.       you do not want to export from your DLL. Then create a DEF file by 
  3227.       specifying the remaining entries under the EXPORTS heading. 
  3228.  
  3229.    5. Use icc to link your objects, libraries, and DEF file into a DLL. If you 
  3230.       use any of the Complex, Collection, or User Interface classes, you must 
  3231.       specify the library names on the command line. You must also specify the 
  3232.       /Tdp option. 
  3233.  
  3234.    6. Erase the template-include objects that you have included in the DLL so 
  3235.       they are not linked into any applications that use your DLL. 
  3236.       Alternatively, use the /Ft- option when you link the accessing 
  3237.       applications.  If these objects are included more than once, the linker 
  3238.       will generate error messages about multiply-defined symbols. 
  3239.  
  3240.  The source files plus a readme file for the sample can be accessed through the 
  3241.  Guide to Samples notebook (if you installed the VisualAge for C++ samples and 
  3242.  documentation) or directly via the \ibmcppw\samples\compiler\sample07 
  3243.  directory. The notebook can be accessed by opening the VisualAge for C++ 
  3244.  program object in Program Manager. Open the notebook to the Components page. 
  3245.  Select Compiler from the components list box, then select SAMPLE07 from the 
  3246.  samples list. Finally, click the Open Project View button. You will see the 
  3247.  files in the upper portion of the project window. 
  3248.  
  3249.  
  3250. ΓòÉΓòÉΓòÉ 7.6.1. Exporting Virtual Function Tables from a DLL ΓòÉΓòÉΓòÉ
  3251.  
  3252. Follow these steps to export a VFT from a DLL: 
  3253.  
  3254.      A virtual function table (VFT) is usually generated in the compilation 
  3255.       unit that defines the first non-inline virtual function in a class.  You 
  3256.       can use the /Wvft option to find out which function that is.  The object 
  3257.       file that contains the definition for this function will also contain the 
  3258.       VFT. 
  3259.      Once you know which object file contains the VFT, you can use CPPFILT to 
  3260.       dump the symbols in the object file.  One of these symbols will be the 
  3261.       name of the VFT that you want to export. 
  3262.      After you have determined what the name of the VFT is, you can either use 
  3263.       the output of CPPFILT directly in the DEF file or you can manually add an 
  3264.       entry for the VFT in the DEF file. 
  3265.  An example of the symbols dumped by CPPFILT 
  3266.  
  3267.   ;From object file:  .\vf.obj
  3268.    ;PUBDEFs (Symbols available from object file):
  3269.     ;area::?getdim(double&,double&)
  3270.     ?getdim__4areaFRdT1
  3271.     ;area::_objectCount
  3272.     _objectCount__4area
  3273.     ;triangle::?__ct()
  3274.     ?__ct__8triangleFv
  3275.     ;rectangle::?getarea()
  3276.     ?getarea__9rectangleFv
  3277.     ;rectangle::_objectCount
  3278.     _objectCount__9rectangle
  3279.     ___vft9rectangle4area
  3280.     ;area::?__ct()
  3281.     ?__ct__4areaFv
  3282.     ;area::?setarea(double,double)
  3283.     ?setarea__4areaFdT1
  3284.     ;rectangle::?__ct()
  3285.     ?__ct__9rectangleFv
  3286.     ___vft8triangle4area
  3287.     ___vft4area
  3288.     ;triangle::_objectCount
  3289.     _objectCount__8triangle
  3290.     ;area::?getarea()
  3291.     ?getarea__4areaFv
  3292.     ;triangle::?getarea()
  3293.     ?getarea__8triangleFv
  3294.  
  3295.  An example of VFTs in the .DEF file. 
  3296.  
  3297.   LIBRARY
  3298.   EXPORTS
  3299.   ;From object file:  .\vf.obj
  3300.    ;PUBDEFs (Symbols available from object file):
  3301.     ;rectangle::_objectCount
  3302.     _objectCount__9rectangle
  3303.     ___vft9rectangle4area
  3304.     ;rectangle::?__ct()
  3305.     ?__ct__9rectangleFv
  3306.     ___vft8triangle4area
  3307.     ___vft4area
  3308.  
  3309.  
  3310. ΓòÉΓòÉΓòÉ 7.7. Using Your DLL ΓòÉΓòÉΓòÉ
  3311.  
  3312. Write the source files that are to access your DLL as if the functions and/or 
  3313. variables are to be statically linked at compile time. Then when you link the 
  3314. program, you must inform the linker that some function and/or variable 
  3315. references are to a DLL and will be resolved at run time. There are two steps 
  3316. to communicating this information to the linker: 
  3317.  
  3318.    1. Use the _Import or __declspec(dllimport) keywords with a function name or 
  3319.       external variable to declare the function or variable is to be imported 
  3320.       from a DLL. The function must be defined in the same compilation unit in 
  3321.       which the _Export keyword is used. 
  3322.  
  3323.       You must mark data imports by _Import or __declspec(dllimport) and it is 
  3324.       recommended that you also mark functions which are being imported as 
  3325.       well. You will get better performance from the generated code if you do. 
  3326.  
  3327.       Note:  The /qautoimport switch (default is /qnoautoimport) removes the 
  3328.       necessity to mark data imports in the DLL client by assuming that ALL 
  3329.       external data references will be resolved at runtime. This "import 
  3330.       everything" assumption may be what you want in certain situations. For 
  3331.       example, the use of this switch would allow the same set of objects to be 
  3332.       used for both static and dynamic linking. However, while /qautoimported 
  3333.       may be easier for the programmer, marking function and data imports in a 
  3334.       DLL client generates more efficient code. 
  3335.  
  3336.       For more information on the _Import or __declspec(dllimport) keyword, see 
  3337.       the Language Reference 
  3338.  
  3339.    2. Use the LIB file created when you built the DLL. 
  3340.  
  3341.    3. When you link an executable module, the linker uses this LIB import 
  3342.       library to resolve external references to the DLL. 
  3343.  
  3344.       On the Windows operating system, you must always access the DLL by means 
  3345.       of an import library. 
  3346.  
  3347.       If you don't have a LIB file, you can use ILIB to first generate a DEF 
  3348.       file. Verify and edit the entries in the DEF file, then use ILIB with the 
  3349.       DEF file to generate a LIB file.. 
  3350.  
  3351.       If you invoke the linker directly, give the name of the import library 
  3352.       where you normally specify library names.  For example: 
  3353.  
  3354.                ILINK /DLL mymain.obj finaldll.lib
  3355.  
  3356.       If you invoke the linker through the icc command, you must put the name 
  3357.       of the import library in the compiler invocation string.  For example: 
  3358.  
  3359.               icc /Ge- mymain.obj finaldll.lib
  3360.  
  3361.       See the User's Guide for more information on ILIB. The import libraries 
  3362.       for the VisualAge for C++ runtime DLLs have been supplied with the 
  3363.       compiler. 
  3364.  
  3365.  Note:  To make functions and data in a DLL available to other programs, the 
  3366.  name of those functions and data must have been exported when the DLL was 
  3367.  linked. 
  3368.  
  3369.  Export functions and data by using #pragma export, the _Export keyword or the 
  3370.  __declspec(dllexport) keyword in the source files OR export functions and data 
  3371.  using an EXPORT entry in the DEF file. 
  3372.  
  3373.  Also, all DLLs must be in a directory listed in the PATH environment variable 
  3374.  (as described in Setting Runtime Environment Variables). 
  3375.  
  3376.  
  3377. ΓòÉΓòÉΓòÉ 7.8. Initializing and Terminating the DLL Environment ΓòÉΓòÉΓòÉ
  3378.  
  3379. The initialization and termination entry point for a DLL is the _DLL_InitTerm 
  3380. function. When each new process gains access to the DLL, this function 
  3381. initializes the necessary environment for the DLL, including storage, 
  3382. semaphores, and variables. When each process frees its access to the DLL, the 
  3383. _DLL_InitTerm function terminates the DLL environment created for that process. 
  3384.  
  3385. The default _DLL_InitTerm function supplied by VisualAge for C++ compiler 
  3386. performs the actions required to initialize and terminate the runtime 
  3387. environment. It is called automatically when you link to the DLL. 
  3388.  
  3389. If you require additional initialization or termination actions for your 
  3390. runtime environment, you will need to write your own _DLL_InitTerm function. 
  3391. For more information, see Writing Your Own _DLL_InitTerm Function. A sample 
  3392. _DLL_InitTerm function is included for the Three Sort DLL project (see Example 
  3393. of a User-Created _DLL_InitTerm Function.) 
  3394.  
  3395. Note:  The _DLL_InitTerm function provided in the subsystem library differs 
  3396. from the runtime version.  See Building a Subsystem DLL  for more information 
  3397. about building subsystem DLLs. 
  3398.  
  3399.  
  3400. ΓòÉΓòÉΓòÉ 7.9. Sample Program to Build a DLL ΓòÉΓòÉΓòÉ
  3401.  
  3402. The sample project Three Sort DLL shows how to build and use a DLL that 
  3403. contains three different sorting functions. These functions keep track of the 
  3404. number of swap and compare operations required to do the sorting. 
  3405.  
  3406. The files for the sample program are: 
  3407.  
  3408.  MAIN03.C      The main program. 
  3409.  
  3410.  SAMPLE03.C    The source file for the DLL. 
  3411.  
  3412.  SAMPLE03.H    The user include file. 
  3413.  
  3414.  INITTERM.C    The _DLL_InitTerm function, shown in Example of a User-Created 
  3415.                _DLL_InitTerm Function. 
  3416.  
  3417.  SAMPLE03.MAK  The makefile to create the EXE. 
  3418.  
  3419.  SORT.MAK      The makefile to create the DLL. 
  3420.  The source files plus a readme file for the sample can be accessed through the 
  3421.  Guide to Samples notebook (if you installed the VisualAge for C++ samples and 
  3422.  documentation) or directly via the \ibmcppw\samples\compiler\sample03 
  3423.  directory. To access the files through the Notebook, open the VisualAge for 
  3424.  C++ program object in Program Manager. Open the Guide to Samples notebook to 
  3425.  the Components page. Select Compiler from the components list box, then select 
  3426.  Three Sort DLL from the samples list. Finally, click the Open Project View 
  3427.  button. You will see the files in the upper portion of the project window. 
  3428.  
  3429.  To compile and link this sample program 
  3430.  
  3431.    1. from the \ibmcppw\samples\compiler\sample03\sort directory, 
  3432.  
  3433.               nmake
  3434.  
  3435.    2. then move back up one level to the \ibmcppw\samples\compiler\sample03 
  3436.       directory, 
  3437.  
  3438.               nmake
  3439.  
  3440.       To compile and link the program yourself, use the following commands: 
  3441.  
  3442.             ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  3443.             Γöé COMMAND                Γöé DESCRIPTION       Γöé
  3444.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  3445.             Γöé "icc /Ge- /Gd /Ti /Fo"%|dpfF.obj"   Γöé Compiles and links    Γöé
  3446.             Γöé %s"                  Γöé Three Sort DLL using   Γöé
  3447.             Γöé                    Γöé default options and   Γöé
  3448.             Γöé                    Γöé             Γöé
  3449.             Γöé                    Γöé o  Creates a DLL    Γöé
  3450.             Γöé                    Γöé   ("/Ge-")       Γöé
  3451.             Γöé                    Γöé o  Uses the version of Γöé
  3452.             Γöé                    Γöé   the runtime library Γöé
  3453.             Γöé                    Γöé   that is dynamically Γöé
  3454.             Γöé                    Γöé   linked ("/Gd")    Γöé
  3455.             Γöé                    Γöé o  Generates Debugger  Γöé
  3456.             Γöé                    Γöé   information ("/Ti") Γöé
  3457.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  3458.             Γöé "icc MAIN03.C MAIN03.DEF"       Γöé Compiles "MAIN03.C"   Γöé
  3459.             Γöé                    Γöé using default options.  Γöé
  3460.             ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  3461.  
  3462.    3. To run the program, enter MAIN03. 
  3463.  
  3464.  
  3465. ΓòÉΓòÉΓòÉ 7.10. Writing Your Own _DLL_InitTerm Function ΓòÉΓòÉΓòÉ
  3466.  
  3467. If your DLL requires initialization or termination actions in addition to the 
  3468. actions performed for the runtime environment, you will need to create your own 
  3469. _DLL_InitTerm function. The prototype for the _DLL_InitTerm function is: 
  3470.  
  3471.   unsigned long __stdcall _DLL_InitTerm(HINSTANCE hModule,
  3472.    DWORD ulFlag, LPVOID dummy)
  3473.  
  3474. If ulFlag is equal to DLL_PROCESS_ATTACH (whose value is zero), the DLL 
  3475. environment is initialized. If ulFlag is equal to DLL_PROCESS_DETACH (whose 
  3476. value is 1), the DLL environment is ended. 
  3477.  
  3478. The hModule parameter is the module handle assigned by the operating system for 
  3479. this DLL. The module handle can be used as a parameter to various Windows API 
  3480. calls. 
  3481.  
  3482. The return code from _DLL_InitTerm tells the loader if the initialization or 
  3483. termination was performed successfully. If the call was successful, 
  3484. _DLL_InitTerm returns a nonzero value. A return code of 0 indicates that the 
  3485. function failed. If a failure is indicated, the loader will not load the 
  3486. program that is accessing the DLL. 
  3487.  
  3488. Note:  A _DLL_InitTerm function for a subsystem DLL has the same prototype, but 
  3489. the content of the function is different because there is no runtime 
  3490. environment to initialize or terminate. For an example of a _DLL_InitTerm 
  3491. function for a subsystem DLL, see Example of a Subsystem _DLL_InitTerm 
  3492. Function. 
  3493.  
  3494.  
  3495. ΓòÉΓòÉΓòÉ 7.10.1. Initializing the Environment ΓòÉΓòÉΓòÉ
  3496.  
  3497. Before you can call any VisualAge for C++ library functions, you must first 
  3498. initialize the runtime environment. Use the function _CRT_init, which is 
  3499. provided in the runtime libraries. If _CRT_init has been called, there must 
  3500. also be a matching _CRT_term to insure library termination. 
  3501.  
  3502. The prototype for the _CRT_init function is: 
  3503.  
  3504.   int _Optlink _CRT_init(void);
  3505.  
  3506. If the runtime environment is successfully initialized, _CRT_init returns 0. A 
  3507. return code of -1 indicates an error. If an error occurs, an error message is 
  3508. written to file handle 2, which is the usual destination of stderr. 
  3509.  
  3510. If your DLL contains C++ code, you must also call __ctordtorInit after 
  3511. _CRT_init to ensure that static constructors and destructors are initialized 
  3512. properly.  The prototype for __ctordtorInit is: 
  3513.  
  3514.   void __ctordtorInit(int flag)
  3515.  
  3516. Calling _ctordtorInit with a value of 0 for flag causes constructors to be 
  3517. called for process initialization. Calling the function with a non-zero value 
  3518. for flag causes only constructors for thread-specific objects in the current 
  3519. thread to be called. In your DLL startup, you should call __ctordtorInit with a 
  3520. value of 0. 
  3521.  
  3522.  
  3523. ΓòÉΓòÉΓòÉ 7.10.2. Terminating the Environment ΓòÉΓòÉΓòÉ
  3524.  
  3525. You must use the _CRT_term function to correctly terminate the C runtime 
  3526. environment. The _CRT_term function is provided in the VisualAge for C++ 
  3527. runtime libraries. It has the following prototype: 
  3528.  
  3529.   void _Optlink _CRT_term(void);
  3530.  
  3531. If your DLL contains C++ code, you must also call __ctordtorTerm before you 
  3532. call _CRT_term to ensure that static constructors and destructors are 
  3533. terminated correctly. The prototype for __ctordtorTerm is: 
  3534.  
  3535.   void __ctordtorTerm(int flag);
  3536. Calling __ctordtorTerm with a value of 0 for flag causes destructors to be 
  3537. called for process termination. Calling the function with a non-zero value for 
  3538. flag causes only destructors for thread-specific objects in the current thread 
  3539. to be called. 
  3540.  
  3541. Once you have called _CRT_term, you cannot call any other library functions. If 
  3542. your DLL is dynamically linked, you cannot call library functions in the 
  3543. termination section of your _DLL_InitTerm function. 
  3544.  
  3545.  
  3546. ΓòÉΓòÉΓòÉ 7.11. Example of a User-Created _DLL_InitTerm Function ΓòÉΓòÉΓòÉ
  3547.  
  3548. The following figure shows the _DLL_InitTerm function for the sample project 
  3549. Three Sort DLL. 
  3550.  
  3551.  
  3552. INITTERM.C - _DLL_InitTerm Function for Three Sort DLL
  3553.  
  3554.  
  3555. #include <windows.h>
  3556. #include <stdlib.h>
  3557. #include <stdio.h>
  3558. #include <string.h>
  3559.  
  3560. /* _CRT_init is the C run-time environment initialization function.     */
  3561. /* It will return 0 to indicate success and -1 to indicate failure.     */
  3562.  
  3563. int _CRT_init(void);
  3564.  
  3565. /* _CRT_term is the C run-time environment termination function.       */
  3566. /* It only needs to be called when the C run-time functions are statically  */
  3567. /* linked.                                  */
  3568.  
  3569. void _CRT_term(void);
  3570. size_t nSize;
  3571. int *pArray;
  3572.  
  3573. /* _DLL_InitTerm is the function that gets called by the operating system  */
  3574. /* loader when it loads and frees this DLL for each process that accesses  */
  3575. /* this DLL.  However, it only gets called the first time the DLL is loaded */
  3576. /* and the last time it is freed for a particular process.  The system    */
  3577. /* linkage convention MUST be used because the operating system loader is  */
  3578. /* calling this function.                          */
  3579.  
  3580. unsigned long __stdcall _DLL_InitTerm(HINSTANCE
  3581. hModule, DWORD ulFlag, LPVOID dummy)
  3582. {
  3583.   size_t i;
  3584.   DWORD rc;
  3585.   char namebuf[MAX_PATH];
  3586.  
  3587.   /* If ulFlag is DLL_PROCESS_ATTACH then the DLL is being loaded so initialization should*/
  3588.   /* be performed.  If ulFlag is 1 then the DLL is being freed so      */
  3589.   /* termination should be performed.                    */
  3590.  
  3591.   switch (ulFlag) {
  3592.    case DLL_PROCESS_ATTACH:
  3593.  
  3594.      /*******************************************************************/
  3595.      /* The C run-time environment initialization function must be    */
  3596.      /* called before any calls to C run-time functions that are not   */
  3597.      /* inlined.                             */
  3598.      /*******************************************************************/
  3599.  
  3600.      if (_CRT_init() == -1)
  3601.       return 0UL;
  3602.       __ctordtorInit (FALSE);
  3603.      if (GetModuleName(hModule, nonebut MAX_PATH==0)
  3604.       printf("GetModuleName returned error %lu\n", );
  3605.      else
  3606.       printf("The name of this DLL is %s\n", namebuf);
  3607.      srand(17);
  3608.      nSize = (rand()%128)+32;
  3609.      printf("The array size for this process is %u\n", nSize);
  3610.      if ((pArray = malloc(nSize *sizeof(int))) == NULL) {
  3611.       printf("Could not allocate space for unsorted array.\n");
  3612.       return 0UL;
  3613.      }
  3614.      for (i = 0; i < nSize; ++i)
  3615.       pArray[i] = rand();
  3616.      break;
  3617.    case DLL_PROCESS_DETACH:
  3618.      printf("The array will now be freed.\n");
  3619.      free(pArray);
  3620.      __ctordtorTerm (FALSE);
  3621.      _CRT_term();
  3622.      break;
  3623.    default  :
  3624.      printf("ulFlag = %lu\n", ulFlag);
  3625.      return 0UL;
  3626.   }
  3627.  
  3628.   /* A non-zero value must be returned to indicate success.         */
  3629.  
  3630.   return 1UL;
  3631. }
  3632.  
  3633. The Three Sort DLL program is described in more detail in Sample Program to 
  3634. Build a DLL. 
  3635.  
  3636.  
  3637. ΓòÉΓòÉΓòÉ 7.12. Creating Resource DLLs ΓòÉΓòÉΓòÉ
  3638.  
  3639. Resource DLLs contain application resources that your program uses, such as 
  3640. menus, bitmaps, and dialog templates. You can define these resources in a .RC 
  3641. file using Windows APIs, or with the Icon Editor and Dialog Editor. Use the 
  3642. Resource Compiler to build the resources into a DLL, which is then called by 
  3643. your executable program at run time. 
  3644.  
  3645. One of the benefits of using a resource DLL instead of binding the resources 
  3646. directly into your executable file includes easier maintenance and less 
  3647. duplication of resources.  You may even be able to use a common resource DLL 
  3648. for multiple applications. 
  3649.  
  3650. Another benefit is that you can completely isolate your program from your 
  3651. resources. Translations can be made to your resource DLL without your program 
  3652. having to be recompiled or linked, or even re-bound to run in the new language. 
  3653. Alternatively, you can create a different resource DLL per locale or codepage 
  3654. setting and load either the most appropriate one based on your locale and 
  3655. codepage setting, or load the default one if a specific one is not available. 
  3656.  
  3657. For instance, you could have three resource DLLs: my844.DLL, my029.DLL, and 
  3658. myDef.dll. If running in codepage 844, load my844.DLL; in codepage 029, load 
  3659. my029.DLL; else load mydef.DLL.  Again, no changes are required to the program 
  3660. to work in a potentially endless number of codepages. 
  3661.  
  3662. To create a resource DLL: 
  3663.  
  3664.    1. Create a RC file that defines your resources. 
  3665.  
  3666.    2. Compile your RC file with the resource compiler to create a RES file. 
  3667.       For example, 
  3668.  
  3669.               IRC myres.rc
  3670.  
  3671.    3. Use VisualAge for C++ linker to create a DLL from the RES file. 
  3672.  
  3673.                 ILINK myres.res /DLL /OUT:resdll.dll
  3674.  
  3675.  Your application can use Windows APIs to load the resource DLL and access the 
  3676.  resources it contains. Like other DLLs, resource DLLs must be in a directory 
  3677.  specified in your PATH environment variable. 
  3678.  
  3679.  For more information on resources and the Resource Compiler, see the User's 
  3680.  Guide. 
  3681.  
  3682.  
  3683. ΓòÉΓòÉΓòÉ 7.13. Creating Your Own Runtime Library DLLs ΓòÉΓòÉΓòÉ
  3684.  
  3685. If you are shipping your application to other users, you must use one of three 
  3686. methods to make the VisualAge for C++ runtime library functions available to 
  3687. the users of your application: 
  3688.  
  3689.    1. Statically bind every module to the library (LIB) files. 
  3690.  
  3691.       This method increases the size of your modules and also slows the 
  3692.       performance because the library environment has to be initialized for 
  3693.       each module.  Having multiple library environments also makes signal 
  3694.       handling, file I/O, and other operations more complicated. 
  3695.  
  3696.    2. Use the DLLRNAME utility to rename the VisualAge for C++ library DLLs. 
  3697.  
  3698.       You can then ship the renamed DLLs with your application. DLLRNAME is 
  3699.       described in the User's Guide. 
  3700.  
  3701.    3. Create your own runtime DLLs. 
  3702.  
  3703.       This method provides one common runtime environment for your entire 
  3704.       application.  It also lets you apply changes to the runtime library 
  3705.       without relinking your application, meaning that if the VisualAge for C++ 
  3706.       DLLs change, you need only rebuild your own DLL. In addition, you can 
  3707.       tailor your runtime DLL to contain only those functions you use, 
  3708.       including your own. 
  3709.  
  3710.  To create your own runtime library, follow these steps: 
  3711.  
  3712.    1. Copy and rename the appropriate VisualAge for C++ DEF file for the 
  3713.       program you are creating. For example, for a multithread program, copy 
  3714.       CPPWM35.DEF to myrtdll.def.  You must also change the DLL name on the 
  3715.       LIBRARY line of the DEF file. The DEF files are installed in the LIB 
  3716.       subdirectory under the main VisualAge for C++ installation directory. 
  3717.  
  3718.    2. Remove any functions that you do not use directly or indirectly (through 
  3719.       other functions) from your DEF file (myrtdll.def), file, including the 
  3720.       STUB line. Do not delete anything with the comment **** next to it; 
  3721.       variables and functions indicated by this comment are used by startup 
  3722.       functions and are always required. 
  3723.  
  3724.    3. Create a source file for your DLL, for example, myrtdll.c. If you are 
  3725.       creating a runtime library that contains only VisualAge for C++ 
  3726.       functions, create an empty source file.  If you are adding your own 
  3727.       functions to the library, put the code for them in this file. 
  3728.  
  3729.    4. Compile and link your DLL files.  Use the /Ge- option to create a DLL, 
  3730.       and the appropriate option for the type of DLL you are building 
  3731.       (single-thread or multithread). For example, to create a multithread DLL, 
  3732.       use the command: 
  3733.  
  3734.               icc /Ge- /Gm+ myrtdll.c myrtdll.def
  3735.  
  3736.    5. Use the ILIB utility to create an import library for your DLL, as 
  3737.       described in Using Your DLL.  For example: 
  3738.  
  3739.               ILIB /geni:myrtdlli.lib /def:myrtdll.def
  3740.  
  3741.    6. Use the ILIB utility to add the object modules that contain the 
  3742.       initialization and termination functions to your import library. These 
  3743.       objects are needed by all executable modules and DLLs. They are contained 
  3744.       in CPPWM35O.LIB for multithread programs and CPPWS35O.LIB for 
  3745.       single-thread programs. 
  3746.  
  3747.       See the User's Guide online documentation for information on how to use 
  3748.       ILIB. 
  3749.  
  3750.       Note:  If you do not use the ILIB utility, you must ensure that all 
  3751.       objects that access your runtime DLL are statically linked to the 
  3752.       appropriate object library. 
  3753.  
  3754.    7. Compile your executable modules and other DLLs with the /Gn+ option to 
  3755.       exclude the default library information. For example: 
  3756.  
  3757.               icc /C /Gn+ /Ge+ myprog.c
  3758.               icc /C /Gn+ /Ge- mydll.c
  3759.  
  3760.       When you link your objects, specify your own import library.  If you are 
  3761.       using or plan to use Windows APIs, specify KERNEL32.LIB also. For 
  3762.       example: 
  3763.  
  3764.                ILINK myprog.obj myrtdlli.lib KERNEL32.LIB
  3765.                ILINK mydll.obj myrtdlli.lib KERNEL32.LIB /DLL mydll.exp
  3766.  
  3767.       To compile and link in one step, use the commands: 
  3768.  
  3769.               icc /Gn+ /Ge+ myprog.c myrtdlli.lib KERNEL32.LIB
  3770.               icc /Gn+ /Ge- mydll.c myrtdlli.lib KERNEL32.LIB
  3771.  
  3772.       Note:  If you did not use the ILIB utility to add the initialization and 
  3773.              termination objects to your import library, specify the following 
  3774.              when you link your modules: 
  3775.  
  3776.         a. CPPWS35O.LIB or CPPWM35O.LIB 
  3777.         b. Your import library 
  3778.         c. KERNEL32.LIB (to allow you to use Windows APIs) 
  3779.         d. The linker option /NOD. For example: 
  3780.  
  3781.             ILINK /NOD myprog.obj CPPWS35O.LIB myrtdlli.lib KERNEL32.LIB;
  3782.             ILINK /NOD mydll.obj CPPWS35O.LIB myrtdlli.lib KERNEL32.LIB;
  3783.  
  3784.       The /NOD option tells the linker to disregard the default libraries 
  3785.       specified in the object files and use only the libraries given on the 
  3786.       command line. If you are using icc to invoke the linker for you, the 
  3787.       commands would be: 
  3788.  
  3789.             icc /B"/NOD" myprog.c CPPWS35O.LIB myrtdlli.lib KERNEL32.LIB
  3790.             icc /Ge- /B"/NOD" mydll.c CPPWS35O.LIB myrtdlli.lib KERNEL32.LIB
  3791.  
  3792.       The linker then links the objects from the object library directly into 
  3793.       your executable module or DLL. 
  3794.  
  3795.  
  3796. ΓòÉΓòÉΓòÉ 8. Developing Applications for Win32s ΓòÉΓòÉΓòÉ
  3797.  
  3798. VisualAge for C++ allows you to create applications which target the Win32s 
  3799. environment. This chapter leads you through items bearing special consideration 
  3800. as you build applications for the Win32s platform. VisualAge for C++ compiler 
  3801. options for application for the Win32s environment are noted, and steps for 
  3802. creating Win32s dynamic link libraries and executables are outlined. 
  3803.  
  3804.  
  3805. ΓòÉΓòÉΓòÉ 8.1. Win32s Considerations ΓòÉΓòÉΓòÉ
  3806.  
  3807. Win32s provides a 32 bit execution environment on Windows 3.1 that is similar 
  3808. to the Win32 environment of Windows NT and Windows95. This similarity is close 
  3809. enough that an application built for Windows NT may run without modification, 
  3810. and even without relinking, under Win32s. Different applications, though, may 
  3811. fail to load, or may load and execute but give incorrect results. 
  3812.  
  3813. The Win32s differences that may affect your program fall into three categories: 
  3814.  
  3815.      Differences in the Windows Toolkit APIs 
  3816.  
  3817.      Single address space issues 
  3818.  
  3819.      Resulting differences in the VisualAge for C++ libraries 
  3820.  
  3821.  
  3822. ΓòÉΓòÉΓòÉ 8.1.1. Differences in the Toolkit APIs ΓòÉΓòÉΓòÉ
  3823.  
  3824. Win32s does not support threads or semaphores, so calls to CreateThread always 
  3825. fail in that environment and an application that requires multiple threads will 
  3826. not work correctly. Other Win32 features are supported as no-ops because their 
  3827. function is unnecessary in Win32s. Still others, for example Sleep(), are 
  3828. supported but behave differently. Comprehensive information about these 
  3829. differences, and about Win32s in general, is available in the Win32s.hlp file 
  3830. in the X:\IBMCPPW\SDK\WIN32S\HELP directory (where X is the drive on which you 
  3831. installed VisualAge for C++). 
  3832.  
  3833.  
  3834. ΓòÉΓòÉΓòÉ 8.1.2. Single address space ΓòÉΓòÉΓòÉ
  3835.  
  3836. Win32s does not provide a distinct address space for each process. All code and 
  3837. data from all loaded 32-bit executables and DLLs is in the same single address 
  3838. space used by 16 bit applications. 
  3839.  
  3840. Executables do not share code or data, and a fresh copy of each is created each 
  3841. time the application is run. Each copy is separately allocated in the shared 
  3842. address space, so the load addresses of an executable file's code and data will 
  3843. often change between different executions. This will not affect a Win32 
  3844. application unless it relies on always loading at the same virtual addresses. 
  3845.  
  3846. Win32s DLLs are shared, and a single instance of their code and data is used by 
  3847. all applications that use the DLL. The effect is as though the SHARED attribute 
  3848. were specified for all data sections. Since the default behavior on Windows NT 
  3849. is that each process has a separate copy of the DLL data, most Windows NT DLLs 
  3850. will not behave correctly in Win32s when used by more than one application at a 
  3851. time. 
  3852.  
  3853. To help correct this problem,  you can use Thread Local Storage (TLS) in 
  3854. Win32s. Even though threads are not supported there, a version of TLS provides 
  3855. a per-process data facility in Win32s. 
  3856.  
  3857. Dynamic TLS permits explicit user management of process-specific data. The 
  3858. TlsAlloc function returns an index that is valid in all processes. When a DLL 
  3859. is first loaded it can allocate an index and store it in a shared static 
  3860. variable. Each process that uses the DLL can use the index with TlsSetValue and 
  3861. TlsGetValue to access storage specific to that process. This is in contrast 
  3862. with how dynamic TLS works in Win32, where an index is valid only within a 
  3863. single process and is used to access thread-specific storage. 
  3864.  
  3865. TLS is also available for static variables declared with the __thread (or 
  3866. __declspec(thread)) modifiers. With one exception, all of the restrictions of 
  3867. static TLS described in Rules and Restrictions on using TLS still apply in 
  3868. Win32s. The restriction that TLS data cannot be imported or exported, in 
  3869. particular, may require changing the interface of a Windows NT DLL when porting 
  3870. it to Win32s. 
  3871.  
  3872. The one exception is to the restriction that DLLs containing static TLS do not 
  3873. initialize correctly when dynamically loaded by the LoadLibrary function. 
  3874. VisualAge for C++ provides the /qwin32s compile option which works for 
  3875. dynamically loaded DLLs. Among other things, /qwin32s enables an alternative 
  3876. implementation of static TLS that is slower but more robust than the usual one. 
  3877.  
  3878. Win32s versions of the VisualAge for C++ DLLs are built using these techniques, 
  3879. and can be both dynamically loaded and shared by multiple applications. Only 
  3880. one C runtime DLL is provided and, to maximize compatibility with the Win32 
  3881. environment it is given the name of the multithreaded DLL (CPPWM35I.DLL). This 
  3882. is desirable because other VisualAge for C++ DLLs link to a runtime by that 
  3883. name, even though its multithreaded facilities are not available in Win32s. 
  3884. This does mean, though, that you should build your Win32s executables and DLLs 
  3885. with the /Gm+ option so that your code will also link to the correctly named 
  3886. runtime DLL. 
  3887.  
  3888.  
  3889. ΓòÉΓòÉΓòÉ 8.1.3. Differences in VisualAge for C++ libraries ΓòÉΓòÉΓòÉ
  3890.  
  3891. Some of the VisualAge for C++ DLLs used in Windows NT and Windows95 export 
  3892. static data that must be allocated on a per process basis in Win32s. Examples 
  3893. are the variables errno, _ctype, and stdin in the C library, whose values 
  3894. cannot safely be shared between multiple concurrent applications. Since a 
  3895. Win32s DLL can only export shared data, these interfaces must be changed. 
  3896.  
  3897. VisualAge for C++ DLLs address this problem in Win32s by eliminating some 
  3898. interfaces and modifying others. For example, the _environ variable exported by 
  3899. the C runtime is not provided, but your code can use the GetEnvironment 
  3900. function from the Windows Toolkit instead. Other variables are replaced by 
  3901. function calls that return the address of the variable, and macros that 
  3902. transparently use them. For example, stdin in the <stdio.h> header changes 
  3903. from: 
  3904.  
  3905.    extern FILE * const _Import stdin;
  3906. to 
  3907.  
  3908.    extern FILE ** const _Import _Optlink _stdin(void);
  3909.    #define stdin  (*_stdin())
  3910.  
  3911. These interface changes are reflected in the VisualAge for C++ include files 
  3912. and protected by the _WIN32S macro described in the next section. For 
  3913. compatibility, VisualAge for C++ Windows NT DLLs provide both the original 
  3914. interfaces and the modified Win32s ones. 
  3915.  
  3916. Win32s versions of the static libraries are also provided with modified Win32s 
  3917. interfaces and per-process data, in case you need them to build your own 
  3918. sharable and dynamically loadable Win32s DLLs. 
  3919.  
  3920.  
  3921. ΓòÉΓòÉΓòÉ 8.2. Win32s Compiler Options ΓòÉΓòÉΓòÉ
  3922.  
  3923.  
  3924. ΓòÉΓòÉΓòÉ 8.2.1. The /qwin32s Option ΓòÉΓòÉΓòÉ
  3925.  
  3926. Although some Windows NT application binaries will run unmodified in the Win32s 
  3927. environment, others will not. An application built for Windows NT that expects 
  3928. the VisualAge for C++ runtime DLL to export the stdin variable will not load in 
  3929. Win32s. DLLs you build on Windows NT will probably work incorrectly under 
  3930. Win32s if used by more than one application at a time. 
  3931.  
  3932. VisualAge for C++ provides the /qwin32s compile option to help build robust 
  3933. executables and DLLs for Win32s. In VisualAge for C++, this option does the 
  3934. following: 
  3935.  
  3936.      defines the macro _WIN32S, which header files use to enable 
  3937.       Win32s-specific interfaces. For example, the stdin interface change can 
  3938.       be described by: 
  3939.  
  3940.                  #ifndef _WIN32S
  3941.                  extern FILE * const _Import stdin;
  3942.                  #else
  3943.                  extern FILE ** const _Import _Optlink _stdin(void);
  3944.                  #define stdin  (*_stdin())
  3945.                  #endif
  3946.  
  3947.      causes the modified static TLS implementation to be used for variables 
  3948.       declared with the __thread or __declspec(thread) modifier, so that DLLs 
  3949.       built with static TLS data can be dynamically loaded 
  3950.  
  3951.      if you are compiling for a DLL and are statically linking the runtime 
  3952.       (options /Ge- /Gd-), links the Win32s version of the static runtime in 
  3953.       CPPWP35.LIB, or CPPWQ35.LIB if /Rn is also specified CPPWP35.LIB is the 
  3954.       full library while CPPWQ35.LIB is the subsystem library. 
  3955.  
  3956.  
  3957. ΓòÉΓòÉΓòÉ 8.2.2. The /qautothread option ΓòÉΓòÉΓòÉ
  3958.  
  3959. This option may be useful when porting existing DLL code to Win32s. It causes 
  3960. the compiler to apply the __thread modifier to all static data that is not 
  3961. declared const. It is assumed that const data has a value that can be shared 
  3962. between multiple users of the DLL. 
  3963.  
  3964. In C++, const data can be initialized dynamically with values that may be 
  3965. process specific.  When /qautothread is enabled, the compiler will warn you if 
  3966. a static variable it did not apply __thread to has runtime initialization, as 
  3967. in: 
  3968.  
  3969.    const unsigned long pid = GetProcessId();
  3970.  
  3971. You should inspect each such variable and, if its initializer is process 
  3972. dependent, manually add the __thread qualifier to that variable. 
  3973.  
  3974.  
  3975. ΓòÉΓòÉΓòÉ 8.3. Building Win32s executables ΓòÉΓòÉΓòÉ
  3976.  
  3977. No special considerations are necessary if you are careful to: 
  3978.  
  3979.      avoid any Win32 function not provided in Win32s, 
  3980.  
  3981.      statically link the runtime or link to the multithreaded runtime DLL, and 
  3982.  
  3983.      don't access any exported data interfaces available in the Win32 versions 
  3984.       of the DLLs your application requires. 
  3985.  
  3986.  Use of the /qwin32s option is recommended, since it allows header files to 
  3987.  reflect any changed interfaces and, as in the case of stdin, perhaps supply an 
  3988.  alternate implementation in the Win32s environment. 
  3989.  
  3990.  Since the Win32s interfaces are also provided by VisualAge for C++ DLLs on 
  3991.  Windows NT and Windows95, an application built with /qwin32s will also execute 
  3992.  under those operating systems, with little or no performance degradation. 
  3993.  
  3994.  
  3995. ΓòÉΓòÉΓòÉ 8.4. Building Win32s DLLs ΓòÉΓòÉΓòÉ
  3996.  
  3997. If you can either guarantee that your DLL will never be used by more than one 
  3998. application at a time or, if it requires that its data segments all be SHARED, 
  3999. it dynamically links to the runtime, then only the considerations listed in 
  4000. Building Win32s executables will apply. Generally, this is not the case, and 
  4001. DLLs require per-process data. 
  4002.  
  4003. You may use the dynamic TLS facility and manage the storage yourself. The first 
  4004. process to attach to the DLL should call TlsAlloc to allocate an index, which 
  4005. it should save in a shared static variable. Each process then uses the index 
  4006. with TlsSetValue and TlsGetValue to access a process-specific DWORD. It is 
  4007. usually convenient to store there a pointer to a block of memory allocated by 
  4008. malloc. Each process that attaches to the DLL allocates a memory block, and 
  4009. deallocates it when detaching from the DLL. The last process to detach must 
  4010. also free the TLS index with TlsFree; since Win32s doesn't tell you which 
  4011. detach this is you, must maintain your own DLL reference count in asecond 
  4012. shared static variable. 
  4013.  
  4014. A good place to perform this management is in the _DLL_InitTerm routine. If the 
  4015. separately declared "struct globals" defines the per-process storage required, 
  4016. the following _DLL_InitTerm will work for a DLL that is dynamically linked to 
  4017. the runtime (and therefore doesn't need to call CRT_Init): 
  4018.  
  4019.   #include <windows.h>
  4020.  
  4021.   void __ctordtorInit(int);  /* Only needed for DLLs containing C++ */
  4022.   void __ctordtorTerm(int);
  4023.  
  4024.   int tlsIndex;
  4025.   int attachCount = 0;
  4026.  
  4027.  
  4028.   unsigned long WINAPI _DLL_InitTerm(HINSTANCE modHandle, DWORD ulFlag, LPVOID dummy)
  4029.   {
  4030.     char* memPtr;
  4031.  
  4032.     if(ulFlag == DLL_PROCESS_ATTACH)
  4033.     {
  4034.       if(attachCount == 0)
  4035.       {
  4036.        tlsIndex = TlsAlloc();
  4037.        if(tlsIndex == -1)
  4038.          return 0;
  4039.       }
  4040.  
  4041.       memPtr = malloc(sizeof(struct globals));
  4042.       if(memPtr == NULL)
  4043.        return 0;
  4044.  
  4045.       if(TlsSetValue(tlsIndex, memPtr) == FALSE)
  4046.       {
  4047.        free(memPtr);
  4048.        return 0;
  4049.       }
  4050.       attachCount++;
  4051.  
  4052.       __ctordtorInit(0);    /* If C++ */
  4053.     }
  4054.     else if (ulFlag == DLL_PROCESS_DETACH)
  4055.     {
  4056.       __ctordtorTerm(0);    /* If C++ */
  4057.  
  4058.       memPtr = TlsGetValue(tlsIndex);
  4059.       if(memPtr != NULL)
  4060.        free(memPtr);
  4061.  
  4062.       attachCount--;
  4063.       if(attachCount <= 0)
  4064.        TlsFree(tlsIndex);
  4065.     }
  4066.     return 1;
  4067.   }
  4068.  
  4069. It is usually simpler to use the static TLS feature, either by adding the 
  4070. __thread modifier to individual variables or by using the /qautothread option 
  4071. to do it globally. In this case you should compile with the /qwin32s option so 
  4072. that your DLL can be dynamically loaded. You are not required to write your own 
  4073. _DLL_InitTerm to use static TLS, but if you do for some reason then it must 
  4074. call the function 
  4075.  
  4076.    unsigned _TlsWin32s(DWORD ulFlag);
  4077.  
  4078. to initialize and finalize the alternate static TLS implementation. _TlsWin32s 
  4079. must be called during process attach before all other initialization, and 
  4080. during process detach after all other termination. Its parameter is the ulFlag 
  4081. parameter passed to _DLL_InitTerm, and its return value is 1 for success and 0 
  4082. for failure. 
  4083.  
  4084. Additionally, if your DLL statically links the runtime then it must link with 
  4085. one of CPPWP35.LIB or CPPWQ35.LIB, which have been built using the alternate 
  4086. static TLS feature. This is most easily accomplished by using the /qwin32s 
  4087. option during your compiles. Again, if you write your own _DLL_InitTerm it must 
  4088. call _TlsWin32s on process attach and detach, to properly initialize the 
  4089. statically linked runtime. 
  4090.  
  4091. It is good practice to always call _TlsWin32s in a _DLL_InitTerm function 
  4092. written for a Win32s DLL. 
  4093.  
  4094.  
  4095. ΓòÉΓòÉΓòÉ 8.5. Running Your Win32s Application ΓòÉΓòÉΓòÉ
  4096.  
  4097. To run a Win32s application on Windows 3.1, you need to copy files from your 
  4098. Windows NT or Windows95 system. An overview of the steps are: 
  4099.  
  4100.      Copy the files you need from the IBMCPPW\BIN directory. 
  4101.  
  4102.      Copy all the files from the IBMCPPW\WIN32S directory. For the files with 
  4103.       the same names as in the IBMCPPW\BIN directory, replace the version from 
  4104.       the BIN directory with the version from the WIN32S directory. 
  4105.  
  4106.  Note:  Be aware that your Win32s application may not perform as well under 
  4107.  16-bit Windows 3.1 as it does under 32-bit Windows NT or Windows 95, due to 
  4108.  differences in the underlying operating systems. 
  4109.  
  4110.  
  4111. ΓòÉΓòÉΓòÉ 9. Introduction to Locale ΓòÉΓòÉΓòÉ
  4112.  
  4113. This chapter introduces the concept of internationalization in programming 
  4114. languages and the implementation of internationalization by the use of locales. 
  4115. The locale codesets provided with the VisualAge for C++ are listed and the 
  4116. default locale set noted. Customization of locales and conversion utilities 
  4117. provided with VisualAge for C++ are also discussed. 
  4118.  
  4119.      Differences Between Windows and VisualAge for C++ Locales 
  4120.      Differences between Windows ANSI and Windows OEM Code Pages 
  4121.      Internationalization in Programming Languages 
  4122.      Locales and Localization 
  4123.  
  4124.  
  4125. ΓòÉΓòÉΓòÉ 9.1. Differences Between Windows and VisualAge for C++ Locales ΓòÉΓòÉΓòÉ
  4126.  
  4127. The Windows-native localization model (as supported by the Win32 APIs) is not 
  4128. the same as the model supported by VisualAge for C++. For this reason, changing 
  4129. the country via the Control Panel will not alter the cultural behavior of your 
  4130. VisualAge for C++ application. Similarly, changing the LC_ environment 
  4131. variables will have no effect on an application calling native-Windows APIs. 
  4132. Further, confusion may arise because both the Windows operating system and 
  4133. VisualAge for C++ provide files known as locales but there is no similarity 
  4134. between the two. 
  4135.  
  4136.  
  4137. ΓòÉΓòÉΓòÉ 9.2. Differences between Windows ANSI and Windows OEM Code Pages ΓòÉΓòÉΓòÉ
  4138.  
  4139. The Windows operating systems support two classes of code pages: American 
  4140. National Standards Institute (ANSI) and 'other equipment manufacturers' (OEM). 
  4141. Within OEM, there is a primary and a secondary code page. Because locales are 
  4142. bound to a specific code page, there must be a separate locale for each 
  4143. country-language-codepage combination. If you want the locale that is bound to 
  4144. the ANSI code page, you must specify the codeset-qualified name that identifies 
  4145. the code page. The following 
  4146.  
  4147.  EN_GB.IBM-1252
  4148.  
  4149. identifies the English, Great Britain, codepage 1252. 
  4150.  
  4151. For locales bound to OEM code pages, you should specify only the 
  4152. language-country name. For example:, 
  4153.  
  4154.  FR_CA
  4155.  
  4156. identifies the French, Canada, using the currently active codepage. 
  4157.  
  4158.  
  4159. ΓòÉΓòÉΓòÉ 9.3. Internationalization in Programming Languages ΓòÉΓòÉΓòÉ
  4160.  
  4161. Internationalization in programming languages is a concept that comprises 
  4162.  
  4163.      externally stored cultural data, 
  4164.      a set of programming tools to create such cultural data, 
  4165.      a set of programming interfaces to access this data, and 
  4166.      a set of programming methods that enable you to write programs that 
  4167.       modify their behavior according to the user's cultural environment, 
  4168.       specified during the program's execution. 
  4169.  
  4170.  
  4171. ΓòÉΓòÉΓòÉ 9.3.1. Elements of Internationalization ΓòÉΓòÉΓòÉ
  4172.  
  4173. A locale is a collection of data that encodes information about the cultural 
  4174. environment. The typical elements of cultural environment are as follows: 
  4175.  
  4176.  Native language 
  4177.                      The text that the executing program uses to communicate 
  4178.                      with a user or environment, that is, the natural language 
  4179.                      of the end user. 
  4180.  
  4181.  Character sets and coded character sets 
  4182.                      Maps an alphabet, the characters used in a particular 
  4183.                      language, and a collating sequence onto the set of 
  4184.                      hexadecimal values (code points) that uniquely identify 
  4185.                      each character. This mapping creates the coded character 
  4186.                      set, which is uniquely identified by the character set it 
  4187.                      encodes, the set of code point values, and the mapping 
  4188.                      between these two. 
  4189.  
  4190.  Collating and ordering 
  4191.                      The relative ordering of characters used for sorting. 
  4192.  
  4193.  Character classification 
  4194.                      Determines the type of character (alphabetic, numeric, and 
  4195.                      so forth) represented by a code point. 
  4196.  
  4197.  Character case conversion 
  4198.                      Defines the mapping between uppercase and lowercase 
  4199.                      characters within a single character set. 
  4200.  
  4201.  Date and time format 
  4202.                      Defines the way date and time data (names of weekdays and 
  4203.                      months; order of month, day, and year, and so forth) are 
  4204.                      formatted. 
  4205.  
  4206.  Format of numeric and non-numeric numbers 
  4207.                      Define the way numbers and monetary units are formatted 
  4208.                      with commas, decimal points, and so forth. 
  4209.  
  4210.  Note:  The VisualAge for C++ compiler and library support of 
  4211.         internationalization is based on the IEEE POSIX P1003.2 and X/Open 
  4212.         Portability Guide standards for global locales and coded character set 
  4213.         conversion, with the following exceptions: 
  4214.  
  4215.      The grouping arguments in the LC_NUMERIC and LC_MONETARY categories must 
  4216.       be strings, not sets of integers. 
  4217.  
  4218.      The use of the ellipsis (...) in the LC_COLLATE category is limited. 
  4219.  
  4220.  For more information about the LC_NUMERIC, LC_MONETARY, and the LC_COLLATE 
  4221.  categories, see Locale Categories. 
  4222.  
  4223.  
  4224. ΓòÉΓòÉΓòÉ 9.4. Locales and Localization ΓòÉΓòÉΓòÉ
  4225.  
  4226. Localization is an action that establishes the cultural environment for an 
  4227. application by selecting the active locale. Only one locale per locale category 
  4228. can be active at one time. A program can change the active locale at any time 
  4229. during its execution. The active locale affects the behavior on the 
  4230. locale-sensitive interfaces for the entire program.  This is called the global 
  4231. locale model. 
  4232.  
  4233.  
  4234. ΓòÉΓòÉΓòÉ 9.4.1. Locale-Sensitive Interfaces ΓòÉΓòÉΓòÉ
  4235.  
  4236. The VisualAge for C++ library provide many interfaces to manipulate and access 
  4237. locales. You can use these interfaces to write internationalized C programs. 
  4238. The C locale support will also work for C++ programs. 
  4239.  
  4240. This list summarizes all the VisualAge for C++ library functions which affect 
  4241. or are affected by the current locale. 
  4242.  
  4243.  Selecting locale 
  4244.            Changing the characteristics of the user's cultural environment by 
  4245.            changing the current locale: setlocale 
  4246.  
  4247.  Querying locale 
  4248.            Retrieving the locale information that characterizes the user's 
  4249.            cultural environment: 
  4250.  
  4251.            Monetary and numeric formatting conventions: 
  4252.                           localeconv 
  4253.  
  4254.            Date and time formatting conventions: 
  4255.                           localdtconv 
  4256.  
  4257.            User-specified information: 
  4258.                           nl_langinfo 
  4259.  
  4260.            Encoding of the variant part of the portable character set: 
  4261.                           getsyntx 
  4262.  
  4263.            Character set identifier: 
  4264.                           csid, wcsid 
  4265.  
  4266.  Classification of characters: 
  4267.  
  4268.            Single-byte characters: 
  4269.                           isalnum, isalpha, isblank, iscntrl, isdigit, isgraph, 
  4270.                           islower, isprint, ispunct, isspace, isupper, isxdigit 
  4271.  
  4272.            Wide characters: 
  4273.                           iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, 
  4274.                           iswgraph, iswlower, iswprint, iswpunct, iswspace, 
  4275.                           iswupper, iswxdigit, wctype, iswctype 
  4276.  
  4277.  Character case mapping: 
  4278.  
  4279.            Single-byte characters: 
  4280.                           tolower, toupper 
  4281.  
  4282.            Wide characters: 
  4283.                           towlower, towupper 
  4284.  
  4285.  Multibyte character and multibyte string conversion: 
  4286.            mblen, mbrlen, mbtowc, mbrtowc, wctomb, wcrtomb, mbstowcs, 
  4287.            mbsrtowcs, wcstombs, wcsrtombs,  mbsinit, wctob 
  4288.  
  4289.  String conversions to arithmetic: 
  4290.            strtod, wcstod, strtol, wcstol, strtoul, wcstoul, atof, atoi, atol 
  4291.  
  4292.  String collating: 
  4293.            strcoll, strxfrm, wcscoll, wcsxfrm 
  4294.  
  4295.  Character display width: 
  4296.            wcswidth, wcwidth 
  4297.  
  4298.  Date, time, and monetary formatting: 
  4299.            strftime, strptime, wcsftime, mktime, ctime, gmtime, localtime, 
  4300.            strfmon 
  4301.  
  4302.  Formatted input/output: 
  4303.            printf (and family of functions), scanf (and family of functions), 
  4304.            vswprintf, swprintf, swscanf 
  4305.  
  4306.  Processing regular expressions: 
  4307.            regcomp, regexec 
  4308.  
  4309.  Wide character unformatted input/output: 
  4310.            fgetwc, fgetws, fputwc, fputws, getwc, getwchar, putwc, putwchar, 
  4311.            ungetwc 
  4312.  
  4313.  Response matching: 
  4314.            rpmatch 
  4315.  
  4316.  Collating elements: 
  4317.            ismccollel, strtocoll, colltostr, collequiv, collrange, collorder, 
  4318.            cclass, maxcoll, getmccoll, getwmccoll 
  4319.  
  4320.  
  4321. ΓòÉΓòÉΓòÉ 9.5. Customizing a Locale ΓòÉΓòÉΓòÉ
  4322.  
  4323. This section describes how you can create your own locales, based on the locale 
  4324. definition files supplied by IBM. The information in this chapter applies to 
  4325. the format of locales based on the LOCALDEF utility. 
  4326.  
  4327. Note:  The LOCALDEF utility provided with VisualAge for C++ is equivalent to 
  4328. the localedef in POSIX but is called LOCALDEF due to the 8.3 naming convention 
  4329. of FAT file systems. 
  4330.  
  4331. In this example you will build a locale named TEXAN using the charmap file 
  4332. representing the ibm-437 encoded character set. The locale is derived from the 
  4333. locale representing the English language and the cultural conventions of the 
  4334. United States. 
  4335.  
  4336.    1. Determine the source of the locale you are going to use. In this case, it 
  4337.       is the locale for the English language in the United States, the source 
  4338.       for which is en_us\ibm-437.loc. 
  4339.  
  4340.    2. Create your own directory, then copy the selected file 
  4341.       (en_us\ibm-437.loc) from the source directory to your directory and 
  4342.       rename it. For example, assuming you created a subdirectory called fred 
  4343.       and you are now in the VisualAge for C++ locale directory, 
  4344.       \IBMCPPW\LOCALE you would type the following: 
  4345.  
  4346.             copy en_us\ibm-437.loc \IBMCPPW\LOCALE\fred\texan.loc
  4347.  
  4348.    3. In your new file, change the locale variables to the desired values. For 
  4349.       example, change 
  4350.  
  4351.             d__fmt "%a %b %e %H:%M:%S %Z %Y"
  4352.  
  4353.       to 
  4354.  
  4355.             d_t_fmt "Howdy Pardner %a %b %e %H:%M:%S %Z %Y"
  4356.  
  4357.    4. Generate a new locale load module using the LOCALDEF utility, then place 
  4358.       the produced module in the directory where your locale load modules are 
  4359.       located. (Of course, this directory must be specified in the LOCPATH 
  4360.       variable.) For instance, if you were in the directory containing your 
  4361.       load modules and X was the drive on which VisualAge for C++ was 
  4362.       installed: 
  4363.  
  4364.             localdef /f X:\IBMCPPW\LOCALE\IBM437.cm /i texan.loc texan.lcl
  4365.  
  4366.       See the User's Guide for detailed information about the syntax of the 
  4367.       LOCALDEF utility. 
  4368.  
  4369.  The customized locale is now ready to be used in calls made by the setlocale 
  4370.  function in VisualAge for C++ application code, such as: 
  4371.  
  4372.   setlocale(LC_ALL, "texan");
  4373.  
  4374.  
  4375. ΓòÉΓòÉΓòÉ <hidden> Referring Explicitly to a Customized Locale ΓòÉΓòÉΓòÉ
  4376.  
  4377. Here is a program with an explicit reference to the TEXAN locale. 
  4378.  
  4379.  
  4380. Referring Explicitly to a Customized Locale
  4381.  
  4382. /* This example shows how to get the local time formatted
  4383. by the current locale */
  4384.  
  4385. #include <stdio.h>
  4386. #include <time.h>
  4387. #include <locale.h>
  4388.  
  4389. int main(void){
  4390.   char dest[80];
  4391.   int ch;
  4392.   time_t temp;
  4393.   struct tm *timeptr;
  4394.   char *locname;
  4395.   temp = time(NULL);
  4396.   timeptr = localtime(&temp);
  4397.  
  4398.   /* Fetch default locale name */
  4399.   printf("Default locale is %s\n", (locname = setlocale(LC_ALL,"") ));
  4400.   ch = strftime(dest, sizeof(dest)-1, "datetime is %c", timeptr);
  4401.   printf("Locale %s %s\n", locname, dest);
  4402.  
  4403.   /* Set new Texan locale name */
  4404.   printf("New locale is %s\n", (locname = setlocale(LC_ALL,"Texan")));
  4405.   ch = strftime(dest, sizeof(dest)-1, "datetime is %c", timeptr);
  4406.   printf("Locale %s %s\n", locname, dest);
  4407.  
  4408.   return(0);
  4409. }
  4410.  
  4411. Compile and run the above program. The output should be similar to: 
  4412.  
  4413. Default locale is C
  4414. Locale C datetime is Fri Aug 20 14:58:12  1993
  4415. New locale is Texan
  4416. Locale Texan datetime is Howdy Pardner
  4417. Fri Aug 20 14:58:12  1993
  4418.  
  4419.  
  4420. ΓòÉΓòÉΓòÉ 9.6. Using Environment Variables to Select a Locale ΓòÉΓòÉΓòÉ
  4421.  
  4422. You can use environment variables to specify the names of locale categories. 
  4423. However, to do this you must call setlocale, regardless of the current 
  4424. environment variable settings. Call setlocale without specifying the locale 
  4425. argument to establish a locale which reflects the current values of the 
  4426. environment variables. 
  4427.  
  4428. Note:  New settings will not be visible to setlocale if they have been set 
  4429. inside a DOS session on the Windows operating system. 
  4430.  
  4431.  Here is an example: 
  4432.  
  4433.  
  4434. Using Environment Variables to Select a Locale
  4435.  
  4436.  
  4437. #include <locale.h>
  4438. #include <stdio.h>
  4439. #include <stdlib.h>
  4440.  
  4441. int main(void){
  4442.  printf("Default locale = \"%s\"\n", setlocale(LC_ALL, ""));
  4443.  _putenv("LC_ALL=TEXAN");
  4444.  setlocale(LC_ALL,"");
  4445.  printf("Default locale = \"%s\"\n", setlocale(LC_ALL,NULL));
  4446.  return(0);
  4447.  
  4448. }
  4449.  
  4450. If you run the program above, you can expect the following result: 
  4451.  
  4452. Default locale = "C"
  4453. Default locale = "TEXAN"
  4454.  
  4455. Note:  Passing NULL as the locale name string in setlocale call will query the 
  4456. current locale without modifying it. 
  4457.  
  4458. Passing an empty string will cause the current locale to be set as specified by 
  4459. the environment variable. If the environment variable isn't set, the current 
  4460. locale is set to the default C locale. 
  4461.  
  4462. The names of the environment variables match the names of the locale 
  4463. categories: 
  4464.  
  4465.      LC_ALL 
  4466.      LC_COLLATE 
  4467.      LC_CTYPE 
  4468.      LANG 
  4469.      LC_MESSAGES 
  4470.      LC_MONETARY 
  4471.      LC_NUMERIC 
  4472.      LC_TIME 
  4473.      LC_TOD 
  4474.      LC_SYNTAX 
  4475.  
  4476.  Note:  The LANG environment variable is functionally equivalent to the LC_ALL 
  4477.  environment variable and is provided only for AIX compatibility. It is 
  4478.  recommended that LANG not be used because of conflict with other programs 
  4479.  which also use LANG. These other programs use LANG to specify the locale they 
  4480.  use but their locale specification format may not match VisualAge for C++ and 
  4481.  may cause setlocale() to return NULL. 
  4482.  
  4483.  For more information about setting environment variables, see Setting Runtime 
  4484.  Environment Variables. For information about the setlocale function., see the 
  4485.  C Library Reference. 
  4486.  
  4487.  
  4488. ΓòÉΓòÉΓòÉ 9.7. Code Set Conversion Utilities ΓòÉΓòÉΓòÉ
  4489.  
  4490. This section describes the code set conversion utilities supported by the 
  4491. VisualAge for C++ compiler.  These utilities are as follows: 
  4492.  
  4493.  ICONV utility 
  4494.       Converts a file from one code set encoding to another. 
  4495.  
  4496.  ICONV functions 
  4497.       Perform code set translation.  These functions are iconv_open, iconv, and 
  4498.       iconv_close. They are used by the ICONV utility and may be called from 
  4499.       any VisualAge for C++ program requiring code set translation. 
  4500.  
  4501.  ICONVDEF utility 
  4502.       Generates a translation table for use by the ICONV utility and iconv 
  4503.       functions. 
  4504.  
  4505.  For descriptions of the ICONVDEF and ICONV utilities, see the User's Guide. 
  4506.  For descriptions of the iconv functions, see the C Library Reference. 
  4507.  
  4508.  
  4509. ΓòÉΓòÉΓòÉ 9.7.1. The ICONVDEF Utility ΓòÉΓòÉΓòÉ
  4510.  
  4511. The ICONVDEF utility reads a source translation file from a specified input 
  4512. file and writes the compiled version to a specified output file. If you do not 
  4513. specify an input file or you do not specify an output file, ICONVDEF uses 
  4514. standard input (stdin) and standard output (stdout), respectively. The source 
  4515. translation file contains directives that are acted upon by the ICONVDEF 
  4516. utility to produce the compiled version of the translation table. 
  4517.  
  4518. For more information on the ICONVDEF tool, see the User's Guide. 
  4519.  
  4520.  
  4521. ΓòÉΓòÉΓòÉ 9.7.2. The ICONV Utility ΓòÉΓòÉΓòÉ
  4522.  
  4523. The ICONV utility reads characters from the input file, converts them from one 
  4524. coded character set definition to another, and writes them to the output file. 
  4525.  
  4526. For more information on the ICONV utility, see the User's Guide. 
  4527.  
  4528.  
  4529. ΓòÉΓòÉΓòÉ 9.7.3. Code Conversion Functions ΓòÉΓòÉΓòÉ
  4530.  
  4531. The iconv_open, iconv, and iconv_close library functions can be called from C 
  4532. and C++ language sources to initialize and perform the character conversions 
  4533. from one character set encoding to another. 
  4534.  
  4535. For more information on these functions, see the C Library Reference. 
  4536.  
  4537.  
  4538. ΓòÉΓòÉΓòÉ 9.8. Code Set Converters Supplied ΓòÉΓòÉΓòÉ
  4539.  
  4540. The code set converters provided convert to and from the 2-byte Unicode 
  4541. Character Set (UCS-2 ISO 10646). They are provided either as tables built by 
  4542. the ICONVDEF utility or as functions inside UCSTBL.DLL and UTF-8.DLL. 
  4543.  
  4544. The code set converters use the "Enforced subset match" method for characters 
  4545. that are in the input code set but are not in the output code set. All 
  4546. characters not in the output code set are replaced by the SUB character, which 
  4547. is 0x3F on the HOST and 0x1A on a PC. 
  4548.  
  4549. The following tables list the code set converters supplied with VisualAge for 
  4550. C++: 
  4551.  
  4552.      Japanese  SBCS <-> SBCS 
  4553.      Japanese  MBCS <-> MBCS 
  4554.      Japanese  Host  SBCS/DBCS <-> MBCS 
  4555.      Korean MBCS <-> MBCS 
  4556.      Korean Host  SBCS/DBCS <-> MBCS 
  4557.      Traditional Chinese MBCS <-> MBCS 
  4558.      Traditional Chinese Host SBCS/DBCS <-> MBCS 
  4559.      Simplified Chinese  MBCS <-> MBCS 
  4560.      Simplified Chinese  Host SBCS/DBCS <-> MBCS 
  4561.  
  4562.  
  4563. ΓòÉΓòÉΓòÉ 9.8.1. Japanese  SBCS <-> SBCS ΓòÉΓòÉΓòÉ
  4564.  
  4565. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4566. Γöé     Γöé 290   Γöé 1027  Γöé
  4567. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4568. Γöé 00290  Γöé N/A   Γöé Y    Γöé
  4569. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4570. Γöé 01027  Γöé Y    Γöé N/A   Γöé
  4571. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4572.  
  4573.  
  4574. ΓòÉΓòÉΓòÉ 9.8.2. Japanese  MBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4575.  
  4576. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4577. Γöé    Γöé 932 Γöé 942 Γöé 943 Γöé 5026Γöé 5035Γöé 954 Γöé 1200Γöé 1208Γöé 5052Γöé 5053Γöé 5054Γöé 5055Γöé 956 Γöé 957 Γöé 958 Γöé 959 Γöé
  4578. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4579. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4580. Γöé 00932 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4581. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4582. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4583. Γöé 00942 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4584. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4585. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4586. Γöé 00943 Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4587. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4588. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4589. Γöé 05026 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4590. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4591. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4592. Γöé 05035 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4593. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4594. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4595. Γöé 00954 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4596. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4597. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4598. Γöé 01200 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4599. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4600. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4601. Γöé 01208 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4602. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4603. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4604. Γöé 05052 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4605. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4606. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4607. Γöé 05053 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4608. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4609. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4610. Γöé 05054 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4611. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4612. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4613. Γöé 05055 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4614. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4615. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4616. Γöé 00956 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4617. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4618. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4619. Γöé 00957 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4620. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4621. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4622. Γöé 00958 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4623. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4624. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4625. Γöé 00959 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/A Γöé N/  Γöé
  4626. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4627. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4628.  
  4629.  
  4630. ΓòÉΓòÉΓòÉ 9.8.3. Japanese  Host  SBCS/DBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4631.  
  4632. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4633. Γöé    Γöé 0029Γöé 1027Γöé 4396Γöé 932 Γöé 942 Γöé 943 Γöé 954 Γöé 1200Γöé 1208Γöé
  4634. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4635. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4636. Γöé 00290 Γöé N/A Γöé -  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4637. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4638. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4639. Γöé 01027 Γöé -  Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4640. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4641. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4642. Γöé 04396 Γöé N/A Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4643. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4644. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4645. Γöé 00932 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé -  Γöé -  Γöé -  Γöé -  Γöé
  4646. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4647. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4648. Γöé 00942 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé N/A Γöé -  Γöé -  Γöé -  Γöé -  Γöé
  4649. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4650. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4651. Γöé 00943 Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé
  4652. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4653. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4654. Γöé 00954 Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé
  4655. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4656. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4657. Γöé 01200 Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé
  4658. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4659. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4660. Γöé 01208 Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé
  4661. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4662. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4663.  
  4664.  
  4665. ΓòÉΓòÉΓòÉ 9.8.4. Korean MBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4666.  
  4667. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4668. Γöé    Γöé 949 Γöé 1361Γöé 933 Γöé 970 Γöé 1200Γöé 1208Γöé 1735Γöé
  4669. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4670. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4671. Γöé 00949 Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4672. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4673. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4674. Γöé 01361 Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4675. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4676. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4677. Γöé 00933 Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4678. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4679. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4680. Γöé 00970 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé
  4681. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4682. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4683. Γöé 01200 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé Y  Γöé
  4684. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4685. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4686. Γöé 01208 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé Y  Γöé
  4687. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4688. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4689. Γöé 17354 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé
  4690. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4691. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4692.  
  4693.  
  4694. ΓòÉΓòÉΓòÉ 9.8.5. Korean Host  SBCS/DBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4695.  
  4696. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4697. Γöé    Γöé 833 Γöé 834 Γöé 949 Γöé 1361Γöé 970 Γöé 1200Γöé 1208Γöé
  4698. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4699. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4700. Γöé 00833 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4701. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4702. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4703. Γöé 00834 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4704. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4705. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4706. Γöé 00949 Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé -  Γöé
  4707. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4708. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4709. Γöé 01361 Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé
  4710. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4711. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4712. Γöé 00970 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé
  4713. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4714. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4715. Γöé 01200 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé
  4716. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4717. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4718. Γöé 01208 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé
  4719. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4720. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4721.  
  4722.  
  4723. ΓòÉΓòÉΓòÉ 9.8.6. Traditional Chinese MBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4724.  
  4725. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4726. Γöé    Γöé 938 Γöé 948 Γöé 950 Γöé 937 Γöé 964 Γöé 1200Γöé 1208Γöé 965 Γöé
  4727. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4728. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4729. Γöé 00938 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4730. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4731. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4732. Γöé 00948 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4733. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4734. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4735. Γöé 00950 Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4736. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4737. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4738. Γöé 00937 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4739. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4740. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4741. Γöé 00964 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé
  4742. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4743. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4744. Γöé 01200 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé Y  Γöé
  4745. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4746. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4747. Γöé 01208 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé Y  Γöé
  4748. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4749. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4750. Γöé 00965 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé
  4751. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4752. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4753.  
  4754.  
  4755. ΓòÉΓòÉΓòÉ 9.8.7. Traditional Chinese Host SBCS/DBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4756.  
  4757. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4758. Γöé    Γöé 37  Γöé 835 Γöé 938 Γöé 948 Γöé 950 Γöé 964 Γöé 1200Γöé 1208Γöé
  4759. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4760. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4761. Γöé 00037 Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4762. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4763. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4764. Γöé 00835 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4765. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4766. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4767. Γöé 00938 Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé -  Γöé -  Γöé
  4768. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4769. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4770. Γöé 00948 Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé -  Γöé
  4771. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4772. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4773. Γöé 00950 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé
  4774. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4775. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4776. Γöé 00964 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé
  4777. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4778. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4779. Γöé 01200 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé
  4780. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4781. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4782. Γöé 01208 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé
  4783. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4784. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4785.  
  4786.  
  4787. ΓòÉΓòÉΓòÉ 9.8.8. Simplified Chinese  MBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4788.  
  4789. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4790. Γöé    Γöé 1381Γöé 935 Γöé 1383Γöé 1200Γöé 1208Γöé 9575Γöé
  4791. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4792. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4793. Γöé 01381 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4794. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4795. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4796. Γöé 00935 Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4797. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4798. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4799. Γöé 01383 Γöé Y  Γöé Y  Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé
  4800. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4801. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4802. Γöé 01200 Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé Y  Γöé
  4803. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4804. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4805. Γöé 01208 Γöé Y  Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé Y  Γöé
  4806. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4807. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4808. Γöé 09575 Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé N/A Γöé
  4809. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4810. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4811.  
  4812.  
  4813. ΓòÉΓòÉΓòÉ 9.8.9. Simplified Chinese  Host SBCS/DBCS <-> MBCS ΓòÉΓòÉΓòÉ
  4814.  
  4815. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4816. Γöé    Γöé 836 Γöé 837 Γöé 1381Γöé 1383Γöé 1200Γöé 1208Γöé
  4817. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4818. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4819. Γöé 00836 Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4820. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4821. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4822. Γöé 00837 Γöé N/A Γöé N/A Γöé Y  Γöé Y  Γöé Y  Γöé Y  Γöé
  4823. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4824. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4825. Γöé 01381 Γöé Y  Γöé Y  Γöé N/A Γöé -  Γöé -  Γöé -  Γöé
  4826. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4827. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4828. Γöé 01383 Γöé Y  Γöé Y  Γöé -  Γöé N/A Γöé -  Γöé -  Γöé
  4829. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4830. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4831. Γöé 01200 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé N/A Γöé -  Γöé
  4832. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4833. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4834. Γöé 01208 Γöé Y  Γöé Y  Γöé -  Γöé -  Γöé -  Γöé N/A Γöé
  4835. Γöé    Γöé   Γöé   Γöé   Γöé   Γöé   Γöé   Γöé
  4836. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4837.  
  4838.  
  4839. ΓòÉΓòÉΓòÉ 9.9. Dynamic Link Libraries Needed by Locale Handling ΓòÉΓòÉΓòÉ
  4840.  
  4841. If you are shipping locales with your product, you must also ship CPPWMTHI.DLL. 
  4842. All the locale files (.lcl) are dynamic link libraries (DLL) and they link 
  4843. dynamically to CPPWMTHI.DLL. (Dynamic linking was done to reduce the size of 
  4844. the locale files.) You can find the DLL in the X:\IBMCPPW\BIN directory, where 
  4845. X is the drive onto which you installed the product. 
  4846.  
  4847. The IBM VisualAge for C++ for Windows License Agreement gives you the right to 
  4848. ship the DLL. The only requirement is that the DLL must be renamed before 
  4849. shipping. We provide the DLLRNAME utility for this purpose, or you may use any 
  4850. other equivalent utility. Make sure your application installs the renamed DLL 
  4851. to a directory in the customer's LIB path. 
  4852.  
  4853. Here's how you would use DLLRNAME: 
  4854.  
  4855.    1. rename cppwmthi.dll 
  4856.  
  4857.               ddlrname cppwmthi.dll cppwmthi=NEWNAME
  4858.  
  4859.    2. then apply DLLRNAME to each locale that you are shipping 
  4860.  
  4861.               dllrname xxxxx.lcl cppwmthi=NEWNAME
  4862.  
  4863.  Note that the new name must be the same number of characters as the old name. 
  4864.  
  4865.  
  4866.  
  4867. ΓòÉΓòÉΓòÉ 10. Building a Locale ΓòÉΓòÉΓòÉ
  4868.  
  4869. Cultural information is encoded in the locale source file using the locale 
  4870. definition language. One locale source file characterizes one cultural 
  4871. environment. 
  4872.  
  4873. The locale source file is processed by the locale compilation tool, called the 
  4874. LOCALDEF tool. See the User's Guide for information on using this tool. 
  4875.  
  4876. To enhance portability of the locale source files, certain information related 
  4877. to the character sets can be encoded using the symbolic names of characters. 
  4878. The mapping between the symbolic names and the characters they represent and 
  4879. its associated hexadecimal value is defined in the character set description 
  4880. file or charmap file. 
  4881.  
  4882. The conceptual model of the locale build process is presented below: 
  4883.  
  4884.  cultural    ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ      ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ   coded
  4885.  environment  Γöé locale source Γöé      Γöé charmap Γöé   character set
  4886.  definition   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ      ΓööΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÿ   definition
  4887.             Γöé             Γöé
  4888.             Γöé             Γöé
  4889.             ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4890.                   Γöé
  4891.                   
  4892.               ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4893.               Γöé  LOCALDEF tool Γöé
  4894.               ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  4895.                   Γöé
  4896.                   
  4897.               ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ      compiled object
  4898.               Γöé Compiled locale ΓöéΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ used by the
  4899.               ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ      VisualAge for C++
  4900.                              interfaces
  4901.  
  4902.  
  4903. ΓòÉΓòÉΓòÉ 10.1. Using the charmap File ΓòÉΓòÉΓòÉ
  4904.  
  4905. The charmap file defines a mapping between the symbolic names of characters and 
  4906. the hexadecimal values associated with the character in a given coded character 
  4907. set.  Optionally, it can provide the alternate symbolic names for characters. 
  4908. Characters in the locale source file can be referred to by their symbolic names 
  4909. or alternate symbolic names, thereby allowing for writing generic locale source 
  4910. files independent of the encoding of the character set they represent. 
  4911.  
  4912. Each charmap file must contain at least the definition of the portable 
  4913. character set and the character symbolic names associated with each character. 
  4914. The characters in the portable character set and the corresponding symbolic 
  4915. names, and optional alternate symbolic names, are defined in the following 
  4916. table. 
  4917.  
  4918. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  4919. Γöé Table 2. Characters in portable character set and corre-    Γöé
  4920. Γöé      sponding symbolic names                Γöé
  4921. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4922. Γöé SYMBOLIC NAME     Γöé ALTERNATE Γöé CHARACTER   Γöé HEX VALUE   Γöé
  4923. Γöé            Γöé NAME    Γöé        Γöé        Γöé
  4924. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4925. Γöé "<NUL>"        Γöé      Γöé        Γöé 00      Γöé
  4926. Γöé            Γöé      Γöé        Γöé        Γöé
  4927. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4928. Γöé "<tab>"        Γöé "<SE10>"  Γöé " "      Γöé 05      Γöé
  4929. Γöé            Γöé      Γöé        Γöé        Γöé
  4930. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4931. Γöé "<vertical-tab>"   Γöé "<SE12>"  Γöé " "      Γöé 0b      Γöé
  4932. Γöé            Γöé      Γöé        Γöé        Γöé
  4933. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4934. Γöé "<form-feed>"     Γöé "<SE13>"  Γöé " "      Γöé 0c      Γöé
  4935. Γöé            Γöé      Γöé        Γöé        Γöé
  4936. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4937. Γöé "<carriage-return>"  Γöé "<SE14>"  Γöé " "      Γöé 0d      Γöé
  4938. Γöé            Γöé      Γöé        Γöé        Γöé
  4939. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4940. Γöé "<newline>"      Γöé "<SE11>"  Γöé " "      Γöé 15      Γöé
  4941. Γöé            Γöé      Γöé        Γöé        Γöé
  4942. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4943. Γöé "<backspace>"     Γöé "<SE09>"  Γöé " "      Γöé 16      Γöé
  4944. Γöé            Γöé      Γöé        Γöé        Γöé
  4945. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4946. Γöé "<alert>"       Γöé "<SE08>"  Γöé " "      Γöé 2f      Γöé
  4947. Γöé            Γöé      Γöé        Γöé        Γöé
  4948. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4949. Γöé "<space>"       Γöé "<SP01>"  Γöé " "      Γöé 40      Γöé
  4950. Γöé            Γöé      Γöé        Γöé        Γöé
  4951. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4952. Γöé "<period>"      Γöé "<SP11>"  Γöé "."      Γöé 4b      Γöé
  4953. Γöé            Γöé      Γöé        Γöé        Γöé
  4954. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4955. Γöé "<less-than-sign>"  Γöé "<SA03>"  Γöé "<"      Γöé 4c      Γöé
  4956. Γöé            Γöé      Γöé        Γöé        Γöé
  4957. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4958. Γöé "<left-parenthesis>" Γöé "<SP06>"  Γöé "("      Γöé 4d      Γöé
  4959. Γöé            Γöé      Γöé        Γöé        Γöé
  4960. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4961. Γöé "<plus-sign>"     Γöé "<SA01>"  Γöé "+"      Γöé 4e      Γöé
  4962. Γöé            Γöé      Γöé        Γöé        Γöé
  4963. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4964. Γöé "<ampersand>"     Γöé "<SM03>"  Γöé "&"      Γöé 50      Γöé
  4965. Γöé            Γöé      Γöé        Γöé        Γöé
  4966. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4967. Γöé "<right-parenthesis>"Γöé "<SP07>"  Γöé ")"      Γöé 5d      Γöé
  4968. Γöé            Γöé      Γöé        Γöé        Γöé
  4969. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4970. Γöé "<semicolon>"     Γöé "<SP14>"  Γöé ";"      Γöé 5e      Γöé
  4971. Γöé            Γöé      Γöé        Γöé        Γöé
  4972. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4973. Γöé "<hyphen>"      Γöé "<SP10>"  Γöé "-"      Γöé 60      Γöé
  4974. Γöé            Γöé      Γöé        Γöé        Γöé
  4975. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4976. Γöé "<hyphen-minus>"   Γöé "<SP10>"  Γöé "-"      Γöé 60      Γöé
  4977. Γöé            Γöé      Γöé        Γöé        Γöé
  4978. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4979. Γöé "<slash>"       Γöé "<SP12>"  Γöé "/"      Γöé 61      Γöé
  4980. Γöé            Γöé      Γöé        Γöé        Γöé
  4981. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4982. Γöé "<solidus>"      Γöé "<SP12>"  Γöé "/"      Γöé 61      Γöé
  4983. Γöé            Γöé      Γöé        Γöé        Γöé
  4984. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4985. Γöé "<comma>"       Γöé "<SP08>"  Γöé ","      Γöé 6b      Γöé
  4986. Γöé            Γöé      Γöé        Γöé        Γöé
  4987. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4988. Γöé "<percent-sign>"   Γöé "<SM02>"  Γöé "%"      Γöé 6c      Γöé
  4989. Γöé            Γöé      Γöé        Γöé        Γöé
  4990. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4991. Γöé "<underscore>"    Γöé "<SP09>"  Γöé "_"      Γöé 6d      Γöé
  4992. Γöé            Γöé      Γöé        Γöé        Γöé
  4993. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4994. Γöé "<low-line>"     Γöé "<SP09>"  Γöé "_"      Γöé 6d      Γöé
  4995. Γöé            Γöé      Γöé        Γöé        Γöé
  4996. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  4997. Γöé "<greater-than-sign>"Γöé "<SA05>"  Γöé ">"      Γöé 6e      Γöé
  4998. Γöé            Γöé      Γöé        Γöé        Γöé
  4999. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5000. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5001. Γöé Table 2. Characters in portable character set and corre-    Γöé
  5002. Γöé      sponding symbolic names                Γöé
  5003. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5004. Γöé SYMBOLIC NAME     Γöé ALTERNATE Γöé CHARACTER   Γöé HEX VALUE   Γöé
  5005. Γöé            Γöé NAME    Γöé        Γöé        Γöé
  5006. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5007. Γöé "<question-mark>"   Γöé "<SP15>"  Γöé "?"      Γöé 6f      Γöé
  5008. Γöé            Γöé      Γöé        Γöé        Γöé
  5009. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5010. Γöé "<colon>"       Γöé "<SP13>"  Γöé ":"      Γöé 7a      Γöé
  5011. Γöé            Γöé      Γöé        Γöé        Γöé
  5012. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5013. Γöé "<apostrophe>"    Γöé "<SP05>"  Γöé "'"      Γöé 7d      Γöé
  5014. Γöé            Γöé      Γöé        Γöé        Γöé
  5015. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5016. Γöé "<equals-sign>"    Γöé "<SA04>"  Γöé "="      Γöé 7e      Γöé
  5017. Γöé            Γöé      Γöé        Γöé        Γöé
  5018. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5019. Γöé "<quotation-mark>"  Γöé "<SP04>"  Γöé """      Γöé 7f      Γöé
  5020. Γöé            Γöé      Γöé        Γöé        Γöé
  5021. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5022. Γöé "<a>"         Γöé "<LA01>"  Γöé "a"      Γöé 81      Γöé
  5023. Γöé            Γöé      Γöé        Γöé        Γöé
  5024. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5025. Γöé "<b>"         Γöé "<LB01>"  Γöé "b"      Γöé 82      Γöé
  5026. Γöé            Γöé      Γöé        Γöé        Γöé
  5027. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5028. Γöé "<c>"         Γöé "<LC01>"  Γöé "c"      Γöé 83      Γöé
  5029. Γöé            Γöé      Γöé        Γöé        Γöé
  5030. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5031. Γöé "<d>"         Γöé "<LD01>"  Γöé "d"      Γöé 84      Γöé
  5032. Γöé            Γöé      Γöé        Γöé        Γöé
  5033. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5034. Γöé "<e>"         Γöé "<LE01>"  Γöé "e"      Γöé 85      Γöé
  5035. Γöé            Γöé      Γöé        Γöé        Γöé
  5036. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5037. Γöé "<f>"         Γöé "<LF01>"  Γöé "f"      Γöé 86      Γöé
  5038. Γöé            Γöé      Γöé        Γöé        Γöé
  5039. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5040. Γöé "<g>"         Γöé "<LG01>"  Γöé "g"      Γöé 87      Γöé
  5041. Γöé            Γöé      Γöé        Γöé        Γöé
  5042. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5043. Γöé "<h>"         Γöé "<LH01>"  Γöé "h"      Γöé 88      Γöé
  5044. Γöé            Γöé      Γöé        Γöé        Γöé
  5045. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5046. Γöé "<i>"         Γöé "<LI01>"  Γöé "i"      Γöé 89      Γöé
  5047. Γöé            Γöé      Γöé        Γöé        Γöé
  5048. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5049. Γöé "<j>"         Γöé "<LJ01>"  Γöé "j"      Γöé 91      Γöé
  5050. Γöé            Γöé      Γöé        Γöé        Γöé
  5051. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5052. Γöé "<k>"         Γöé "<LK01>"  Γöé "k"      Γöé 92      Γöé
  5053. Γöé            Γöé      Γöé        Γöé        Γöé
  5054. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5055. Γöé "<l>"         Γöé "<LL01>"  Γöé "l"      Γöé 93      Γöé
  5056. Γöé            Γöé      Γöé        Γöé        Γöé
  5057. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5058. Γöé "<m>"         Γöé "<LM01>"  Γöé "m"      Γöé 94      Γöé
  5059. Γöé            Γöé      Γöé        Γöé        Γöé
  5060. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5061. Γöé "<n>"         Γöé "<LN01>"  Γöé "n"      Γöé 95      Γöé
  5062. Γöé            Γöé      Γöé        Γöé        Γöé
  5063. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5064. Γöé "<o>"         Γöé "<LO01>"  Γöé "o"      Γöé 96      Γöé
  5065. Γöé            Γöé      Γöé        Γöé        Γöé
  5066. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5067. Γöé "<p>"         Γöé "<LP01>"  Γöé "p"      Γöé 97      Γöé
  5068. Γöé            Γöé      Γöé        Γöé        Γöé
  5069. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5070. Γöé "<q>"         Γöé "<LQ01>"  Γöé "q"      Γöé 98      Γöé
  5071. Γöé            Γöé      Γöé        Γöé        Γöé
  5072. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5073. Γöé "<r>"         Γöé "<LR01>"  Γöé "r"      Γöé 99      Γöé
  5074. Γöé            Γöé      Γöé        Γöé        Γöé
  5075. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5076. Γöé "<s>"         Γöé "<LS01>"  Γöé "s"      Γöé a2      Γöé
  5077. Γöé            Γöé      Γöé        Γöé        Γöé
  5078. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5079. Γöé "<t>"         Γöé "<LT01>"  Γöé "t"      Γöé a3      Γöé
  5080. Γöé            Γöé      Γöé        Γöé        Γöé
  5081. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5082. Γöé "<u>"         Γöé "<LU01>"  Γöé "u"      Γöé a4      Γöé
  5083. Γöé            Γöé      Γöé        Γöé        Γöé
  5084. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5085. Γöé "<v>"         Γöé "<LU01>"  Γöé "v"      Γöé a5      Γöé
  5086. Γöé            Γöé      Γöé        Γöé        Γöé
  5087. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5088. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5089. Γöé Table 2. Characters in portable character set and corre-    Γöé
  5090. Γöé      sponding symbolic names                Γöé
  5091. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5092. Γöé SYMBOLIC NAME     Γöé ALTERNATE Γöé CHARACTER   Γöé HEX VALUE   Γöé
  5093. Γöé            Γöé NAME    Γöé        Γöé        Γöé
  5094. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5095. Γöé "<w>"         Γöé "<LW01>"  Γöé "w"      Γöé a6      Γöé
  5096. Γöé            Γöé      Γöé        Γöé        Γöé
  5097. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5098. Γöé "<x>"         Γöé "<LX01>"  Γöé "x"      Γöé a7      Γöé
  5099. Γöé            Γöé      Γöé        Γöé        Γöé
  5100. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5101. Γöé "<y>"         Γöé "<LY01>"  Γöé "y"      Γöé a8      Γöé
  5102. Γöé            Γöé      Γöé        Γöé        Γöé
  5103. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5104. Γöé "<z>"         Γöé "<LZ01>"  Γöé "z"      Γöé a9      Γöé
  5105. Γöé            Γöé      Γöé        Γöé        Γöé
  5106. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5107. Γöé "<A>"         Γöé "<LA02>"  Γöé "A"      Γöé c1      Γöé
  5108. Γöé            Γöé      Γöé        Γöé        Γöé
  5109. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5110. Γöé "<B>"         Γöé "<LB02>"  Γöé "B"      Γöé c2      Γöé
  5111. Γöé            Γöé      Γöé        Γöé        Γöé
  5112. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5113. Γöé "<C>"         Γöé "<LC02>"  Γöé "C"      Γöé c3      Γöé
  5114. Γöé            Γöé      Γöé        Γöé        Γöé
  5115. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5116. Γöé "<D>"         Γöé "<LD02>"  Γöé "D"      Γöé c4      Γöé
  5117. Γöé            Γöé      Γöé        Γöé        Γöé
  5118. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5119. Γöé "<E>"         Γöé "<LE02>"  Γöé "E"      Γöé c5      Γöé
  5120. Γöé            Γöé      Γöé        Γöé        Γöé
  5121. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5122. Γöé "<F>"         Γöé "<LF02>"  Γöé "F"      Γöé c6      Γöé
  5123. Γöé            Γöé      Γöé        Γöé        Γöé
  5124. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5125. Γöé "<G>"         Γöé "<LG02>"  Γöé "G"      Γöé c7      Γöé
  5126. Γöé            Γöé      Γöé        Γöé        Γöé
  5127. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5128. Γöé "<H>"         Γöé "<LH02>"  Γöé "H"      Γöé c8      Γöé
  5129. Γöé            Γöé      Γöé        Γöé        Γöé
  5130. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5131. Γöé "<I>"         Γöé "<LI02>"  Γöé "I"      Γöé c9      Γöé
  5132. Γöé            Γöé      Γöé        Γöé        Γöé
  5133. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5134. Γöé "<J>"         Γöé "<LJ02>"  Γöé "J"      Γöé d1      Γöé
  5135. Γöé            Γöé      Γöé        Γöé        Γöé
  5136. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5137. Γöé "<K>"         Γöé "<LK02>"  Γöé "K"      Γöé d2      Γöé
  5138. Γöé            Γöé      Γöé        Γöé        Γöé
  5139. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5140. Γöé "<L>"         Γöé "<LL02>"  Γöé "L"      Γöé d3      Γöé
  5141. Γöé            Γöé      Γöé        Γöé        Γöé
  5142. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5143. Γöé "<M>"         Γöé "<LM02>"  Γöé "M"      Γöé d4      Γöé
  5144. Γöé            Γöé      Γöé        Γöé        Γöé
  5145. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5146. Γöé "<N>"         Γöé "<LN02>"  Γöé "N"      Γöé d5      Γöé
  5147. Γöé            Γöé      Γöé        Γöé        Γöé
  5148. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5149. Γöé "<O>"         Γöé "<LO02>"  Γöé "O"      Γöé d6      Γöé
  5150. Γöé            Γöé      Γöé        Γöé        Γöé
  5151. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5152. Γöé "<P>"         Γöé "<LP02>"  Γöé "P"      Γöé d7      Γöé
  5153. Γöé            Γöé      Γöé        Γöé        Γöé
  5154. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5155. Γöé "<Q>"         Γöé "<LQ02>"  Γöé "Q"      Γöé d8      Γöé
  5156. Γöé            Γöé      Γöé        Γöé        Γöé
  5157. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5158. Γöé "<R>"         Γöé "<LR02>"  Γöé "R"      Γöé d9      Γöé
  5159. Γöé            Γöé      Γöé        Γöé        Γöé
  5160. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5161. Γöé "<S>"         Γöé "<LS02>"  Γöé "S"      Γöé e2      Γöé
  5162. Γöé            Γöé      Γöé        Γöé        Γöé
  5163. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5164. Γöé "<T>"         Γöé "<LT02>"  Γöé "T"      Γöé e3      Γöé
  5165. Γöé            Γöé      Γöé        Γöé        Γöé
  5166. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5167. Γöé "<U>"         Γöé "<LU02>"  Γöé "U"      Γöé e4      Γöé
  5168. Γöé            Γöé      Γöé        Γöé        Γöé
  5169. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5170. Γöé "<V>"         Γöé "<LV02>"  Γöé "V"      Γöé e5      Γöé
  5171. Γöé            Γöé      Γöé        Γöé        Γöé
  5172. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5173. Γöé "<W>"         Γöé "<LW02>"  Γöé "W"      Γöé e6      Γöé
  5174. Γöé            Γöé      Γöé        Γöé        Γöé
  5175. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5176. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5177. Γöé Table 2. Characters in portable character set and corre-    Γöé
  5178. Γöé      sponding symbolic names                Γöé
  5179. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5180. Γöé SYMBOLIC NAME     Γöé ALTERNATE Γöé CHARACTER   Γöé HEX VALUE   Γöé
  5181. Γöé            Γöé NAME    Γöé        Γöé        Γöé
  5182. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5183. Γöé "<X>"         Γöé "<LX02>"  Γöé "X"      Γöé e7      Γöé
  5184. Γöé            Γöé      Γöé        Γöé        Γöé
  5185. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5186. Γöé "<Y>"         Γöé "<LY02>"  Γöé "Y"      Γöé e8      Γöé
  5187. Γöé            Γöé      Γöé        Γöé        Γöé
  5188. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5189. Γöé "<Z>"         Γöé "<LZ02>"  Γöé "Z"      Γöé e9      Γöé
  5190. Γöé            Γöé      Γöé        Γöé        Γöé
  5191. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5192. Γöé "<zero>"       Γöé "<ND10>"  Γöé "0"      Γöé f0      Γöé
  5193. Γöé            Γöé      Γöé        Γöé        Γöé
  5194. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5195. Γöé "<one>"        Γöé "<ND01>"  Γöé "1"      Γöé f1      Γöé
  5196. Γöé            Γöé      Γöé        Γöé        Γöé
  5197. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5198. Γöé "<two>"        Γöé "<ND02>"  Γöé "2"      Γöé f2      Γöé
  5199. Γöé            Γöé      Γöé        Γöé        Γöé
  5200. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5201. Γöé "<three>"       Γöé "<ND03>"  Γöé "3"      Γöé f3      Γöé
  5202. Γöé            Γöé      Γöé        Γöé        Γöé
  5203. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5204. Γöé "<four>"       Γöé "<ND04>"  Γöé "4"      Γöé f4      Γöé
  5205. Γöé            Γöé      Γöé        Γöé        Γöé
  5206. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5207. Γöé "<five>"       Γöé "<ND05>"  Γöé "5"      Γöé f5      Γöé
  5208. Γöé            Γöé      Γöé        Γöé        Γöé
  5209. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5210. Γöé "<six>"        Γöé "<ND06>"  Γöé "6"      Γöé f6      Γöé
  5211. Γöé            Γöé      Γöé        Γöé        Γöé
  5212. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5213. Γöé "<seven>"       Γöé "<ND07>"  Γöé "7"      Γöé f7      Γöé
  5214. Γöé            Γöé      Γöé        Γöé        Γöé
  5215. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5216. Γöé "<eight>"       Γöé "<ND08>"  Γöé "8"      Γöé f8      Γöé
  5217. Γöé            Γöé      Γöé        Γöé        Γöé
  5218. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5219. Γöé "<nine>"       Γöé "<ND09>"  Γöé "9"      Γöé f9      Γöé
  5220. Γöé            Γöé      Γöé        Γöé        Γöé
  5221. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5222. Γöé "<vertical-line>"   Γöé "<SM13>"  Γöé "|"      Γöé (4f)     Γöé
  5223. Γöé            Γöé      Γöé        Γöé        Γöé
  5224. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5225. Γöé "<exclamation-mark>" Γöé "<SP02>"  Γöé "!"      Γöé (5a)     Γöé
  5226. Γöé            Γöé      Γöé        Γöé        Γöé
  5227. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5228. Γöé "<dollar-sign>"    Γöé "<SC03>"  Γöé "$"      Γöé (5b)     Γöé
  5229. Γöé            Γöé      Γöé        Γöé        Γöé
  5230. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5231. Γöé "<circumflex>"    Γöé "<SD15>"  Γöé "^"      Γöé (5f)     Γöé
  5232. Γöé            Γöé      Γöé        Γöé        Γöé
  5233. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5234. Γöé "<circumflex-accent>"Γöé "<SD15>"  Γöé "^"      Γöé (5f)     Γöé
  5235. Γöé            Γöé      Γöé        Γöé        Γöé
  5236. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5237. Γöé "<grave-accent>"   Γöé "<SD13>"  Γöé "`"      Γöé (79)     Γöé
  5238. Γöé            Γöé      Γöé        Γöé        Γöé
  5239. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5240. Γöé "<number-sign>"    Γöé "<SM01>"  Γöé "#"      Γöé (7b)     Γöé
  5241. Γöé            Γöé      Γöé        Γöé        Γöé
  5242. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5243. Γöé "<commercial-at>"   Γöé "<SM05>"  Γöé "@"      Γöé (7c)     Γöé
  5244. Γöé            Γöé      Γöé        Γöé        Γöé
  5245. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5246. Γöé "<tilde>"       Γöé "<SD19>"  Γöé "~"      Γöé (a1)     Γöé
  5247. Γöé            Γöé      Γöé        Γöé        Γöé
  5248. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5249. Γöé "<left-square-bracketΓöé""<SM06>"  Γöé "["      Γöé (ad)     Γöé
  5250. Γöé            Γöé      Γöé        Γöé        Γöé
  5251. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5252. Γöé "<right-square-brackeΓöé>"<SM08>"  Γöé "]"      Γöé (bd)     Γöé
  5253. Γöé            Γöé      Γöé        Γöé        Γöé
  5254. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5255. Γöé "<left-brace>"    Γöé "<SM11>"  Γöé "{"      Γöé (c0)     Γöé
  5256. Γöé            Γöé      Γöé        Γöé        Γöé
  5257. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5258. Γöé "<left-curly-bracket>Γöé "<SM11>"  Γöé "{"      Γöé (c0)     Γöé
  5259. Γöé            Γöé      Γöé        Γöé        Γöé
  5260. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5261. Γöé "<right-brace>"    Γöé "<SM14>"  Γöé "}"      Γöé (d0)     Γöé
  5262. Γöé            Γöé      Γöé        Γöé        Γöé
  5263. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5264. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5265. Γöé Table 2. Characters in portable character set and corre-    Γöé
  5266. Γöé      sponding symbolic names                Γöé
  5267. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5268. Γöé SYMBOLIC NAME     Γöé ALTERNATE Γöé CHARACTER   Γöé HEX VALUE   Γöé
  5269. Γöé            Γöé NAME    Γöé        Γöé        Γöé
  5270. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5271. Γöé "<right-curly-bracketΓöé""<SM14>"  Γöé "}"      Γöé (d0)     Γöé
  5272. Γöé            Γöé      Γöé        Γöé        Γöé
  5273. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5274. Γöé "<backslash>"     Γöé "<SM07>"  Γöé "\"      Γöé (e0)     Γöé
  5275. Γöé            Γöé      Γöé        Γöé        Γöé
  5276. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5277. Γöé "<reverse-solidus>"  Γöé "<SM07>"  Γöé "\"      Γöé (e0)     Γöé
  5278. Γöé            Γöé      Γöé        Γöé        Γöé
  5279. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5280.  
  5281. The portable character set is the basis for the syntactic and semantic 
  5282. processing of the LOCALDEF tool, and for most of the utilities and functions 
  5283. that access the locale object files. Therefore the portable character set must 
  5284. always be defined. 
  5285.  
  5286. The charmap file is divided into two main sections: 
  5287.  
  5288.    1. the character symbolic name to hexadecimal mapping section, or CHARMAP 
  5289.  
  5290.    2. the character symbolic name to character set identifier section, or 
  5291.       CHARSETID 
  5292.  
  5293.  The following definitions can precede the two sections listed above. Each 
  5294.  consists of the symbol shown in the following list, starting in column 1, 
  5295.  including the surrounding brackets, followed by one or more <blank>s, followed 
  5296.  by the value to be assigned to the symbol. 
  5297.  
  5298.  <code_set_name> 
  5299.            The string literal containing the name of the coded character set 
  5300.            name 
  5301.  
  5302.  <mb_cur_max> 
  5303.            the maximum number of bytes in a multibyte character which can be 
  5304.            set to a value of either 1 or 2. If it is 1, each character in the 
  5305.            character set defined in this charmap is encoded by a one-byte 
  5306.            value. If it is 2, each character in the character set defined in 
  5307.            this charmap is encoded by a one- or two-byte value. If it is not 
  5308.            specified, the default value of 1 is assumed. If a value of other 
  5309.            than 1 or 2, is specified, a warning message is issued and the 
  5310.            default value of 1 is assumed. i2 refid=mbcs.in locale definition 
  5311.  
  5312.  <mb_cur_min> 
  5313.            The minimum number of bytes in a multibyte character.  Can be set to 
  5314.            1 only. If a value of other than 1 is specified, a warning message 
  5315.            is issued and the default value of 1 is assumed. 
  5316.  
  5317.  <escape_char> 
  5318.            Specifies the escape character that is used to specify hexadecimal 
  5319.            or octal notation for numeric values. It defaults to the hexadecimal 
  5320.            value 0x5C, which represents the \ character in the coded character 
  5321.            set IBM-850. 
  5322.  
  5323.  <comment_char> 
  5324.            Denotes the character chosen to indicate a comment within a charmap 
  5325.            file. It defaults to the hexadecimal value 0x23, which represents 
  5326.            the # character in the coded character set IBM-850. 
  5327.  
  5328.  
  5329. ΓòÉΓòÉΓòÉ 10.1.1. The CHARMAP Section ΓòÉΓòÉΓòÉ
  5330.  
  5331. The CHARMAP section defines the values for the symbolic names representing 
  5332. characters in the coded character set. Each charmap file must define at least 
  5333. the portable character set. The character symbolic names or alternate symbolic 
  5334. names (or both) must be be used to define the portable character set. These are 
  5335. shown in Characters in portable character set and corresponding symbolic names. 
  5336.  
  5337. Additional characters can be defined by the user with symbolic character names. 
  5338.  
  5339. The CHARMAP section starts with the line containing the keyword CHARMAP, and 
  5340. ends with the line containing the keywords END CHARMAP. CHARMAP and END CHARMAP 
  5341. must both start in column one. 
  5342.  
  5343. The character set mapping definitions are all the lines between the first and 
  5344. last lines of the CHARMAP section. 
  5345.  
  5346. The formats of the character set mappings for this section are as follows: 
  5347.  
  5348. "%s %s %s\n", <symbolic-name>, <encoding>, <comments>
  5349. "%s...%s %s %s\n", <symbolic-name>, <symbolic-name>, <encoding>, <comments>
  5350.  
  5351. The first format defines a single symbolic name and a corresponding encoding. A 
  5352. symbolic name is one or more characters with visible glyphs, enclosed between 
  5353. angle brackets. 
  5354.  
  5355. A character following an escape character is interpreted as itself; for 
  5356. example, the sequence <\\\>> represents the symbolic name \> enclosed within 
  5357. angle brackets, where the backslash (\) is the escape character. 
  5358.  
  5359. The second format defines a group of symbolic names associated with a range of 
  5360. values.  The two symbolic names are comprised of two parts, a prefix and 
  5361. suffix.  The prefix consists of zero or more non-numeric invariant visible 
  5362. glyph characters and is the same for both symbolic names.  The suffix consists 
  5363. of a positive decimal integer.  The suffix of the first symbolic name must be 
  5364. less than or equal to the suffix of the second symbolic name. As an example, 
  5365. <j0101>...<j0104> is interpreted as the symbolic names 
  5366. <j0101>,<j0102>,<j0103>,<j0104>. The common prefix is 'j' and the suffixes are 
  5367. '0101' and '0104'. 
  5368.  
  5369. The encoding part can be written in one of two forms: 
  5370.  
  5371.  <escape-char><number>            (single byte value)
  5372.  <escape-char><number><escape-char><number>  (double byte value)
  5373.  
  5374. The number can be written using octal, decimal, or hexadecimal notation. 
  5375. Decimal numbers are written as a 'd' followed by 2 or 3 decimal digits. 
  5376. Hexadecimal numbers are written as an 'x' followed by 2 hexadecimal digits. An 
  5377. octal number is written with 2 or 3 octal digits. As an example, the single 
  5378. byte value x1F could be written as '\37', '\x1F', or '\d31'. The double byte 
  5379. value of x1A1F could be written as '\32\37', '\x1A\x1F', or '\d26\d31'. 
  5380.  
  5381. In lines defining ranges of symbolic names, the encoded value is the value for 
  5382. the first symbolic name in the range (the symbolic name preceding the 
  5383. ellipsis). Subsequent names defined by the range have encoding values in 
  5384. increasing order. 
  5385.  
  5386. When constants are concatenated for multibyte character values, they must be of 
  5387. the same type, and are interpreted in byte order from first to last with the 
  5388. least significant byte of the multibyte character specified by the last 
  5389. constant. For example, the following line: 
  5390.  
  5391.   <j0101>...<j0104>       \d129\d254
  5392.  
  5393. would be interpreted as follows: 
  5394.  
  5395.   <j0101>              \d129\d254
  5396.   <j0102>              \d129\d255
  5397.   <j0103>              \d130\d0
  5398.   <j0104>              \d130\d1
  5399.  
  5400.  
  5401. ΓòÉΓòÉΓòÉ 10.1.2. The CHARSETID Section ΓòÉΓòÉΓòÉ
  5402.  
  5403. The character set identifier section of the charmap file maps the symbolic 
  5404. names defined in the CHARMAP section to a character set identifier. 
  5405.  
  5406. Note:  The two functions csid and wcsid query the locales and return the 
  5407.        character set identifier for a given character.  This information is not 
  5408.        currently used by any other library function. 
  5409.  
  5410.  The CHARSETID section starts with a line containing the keyword CHARSETID, and 
  5411.  ends with the line containing the keywords END CHARSETID. Both CHARSETID and 
  5412.  END CHARSETID must begin in column 1. The lines between the first and last 
  5413.  lines of the CHARSETID section define the character set identifier for the 
  5414.  defined coded character set. 
  5415.  
  5416.  The character set identifier mappings are defined as follows: 
  5417.  
  5418.   "%s %c", <symbolic-name>, <value>
  5419.   "%c %c", <value>, <value>
  5420.   "%s...%s %c", <symbolic-name>, <symbolic-name>, <value>
  5421.   "%c...%c %c", <value>, <value>, <value>
  5422.   "%s...%c %c", <symbolic-name>, <value>, <value>
  5423.   "%c...%s %c", <value>, <symbolic-name>, <value>
  5424.  
  5425.  The individual characters are specified by the symbolic name or the value. The 
  5426.  group of characters are specified by two symbolic names or by two numeric 
  5427.  values (or combination) separated by an ellipsis (...). The interpretation of 
  5428.  ranges of values is the same as specified in the CHARMAP section. The 
  5429.  character set identifier is specified by a numeric value. 
  5430.  
  5431.  
  5432. ΓòÉΓòÉΓòÉ 10.2. Locale Source Files ΓòÉΓòÉΓòÉ
  5433.  
  5434. Locales are defined through the specification of a locale definition file. The 
  5435. locale definition contains one or more distinct locale category source 
  5436. definitions and not more than one definition of any category.  Each category 
  5437. controls specific aspects of the cultural environment. A category source 
  5438. definition is either the explicit definition of a category or the copy 
  5439. directive, which indicates that the category definition should be copied from 
  5440. another locale definition file. 
  5441.  
  5442. The definition file is composed of an optional definition section for the 
  5443. escape and comment characters to be used, followed by the category source 
  5444. definitions.  Comment lines and blank lines can appear anywhere in the locale 
  5445. definition file. If the escape and comment characters are not defined, default 
  5446. code points are used (x5C for the escape character and x23 for the comment 
  5447. character, respectively). The definition section consists of the following 
  5448. optional lines: 
  5449.  
  5450. escape_char   <character>
  5451. comment_char   <character>
  5452.  
  5453. where <character> in both cases is a single-byte character to be used, for 
  5454. example: 
  5455.  
  5456. escape_char   /
  5457.  
  5458. defines the escape character in this file to be '/' (the <slash> character). 
  5459.  
  5460. Locale definition files passed to the LOCALDEF utility are assumed to be in 
  5461. coded character set IBM-850. 
  5462.  
  5463. Each category source definition consists of a category header, a category body, 
  5464. and a category trailer, in that order. 
  5465.  
  5466.  category header 
  5467.                      consists of the keyword naming the category. Each category 
  5468.                      name starts with the characters LC_ The following category 
  5469.                      names are supported: LC_CTYPE, LC_COLLATE, LC_NUMERIC, 
  5470.                      LC_MONETARY, LC_TIME, LC_MESSAGES, LC_TOD, and LC_SYNTAX. 
  5471.  
  5472.                      The LC_TOD and LC_SYNTAX categories, if present, must be 
  5473.                      the last two categories in the locale definition file. 
  5474.  
  5475.  category body 
  5476.                      consists of one or more lines describing the components of 
  5477.                      the category. Each component line has the following 
  5478.                      format: 
  5479.  
  5480.                                             <identifer>  <operand1>
  5481.                                             <identifer>  <operand1>;<operand2>;...;<operandN>
  5482.  
  5483.                      <identifier> is a keyword that identifies a locale 
  5484.                      element, or a symbolic name that identifies a collating 
  5485.                      element. <operand> is a character, collating element, or 
  5486.                      string literal. Escape sequences can be specified in a 
  5487.                      string literal using the <escape_character>. If multiple 
  5488.                      operands are specified, they must be separated by 
  5489.                      semicolons. White space can be before and after the 
  5490.                      semicolons. 
  5491.  
  5492.  category trailer 
  5493.                      consists of the keyword END followed by one or more 
  5494.                      <blank>s and the category name of the corresponding 
  5495.                      category header. 
  5496.  Here is an example of locale source containing the header, body, and trailer: 
  5497.  
  5498.     # Here is a simple locale definition file consisting of one
  5499.     # category source definition, LC_CTYPE.
  5500.  
  5501.     LC_CTYPE
  5502.     upper <A>;...;<Z>
  5503.     END LC_CTYPE
  5504.  
  5505.  You do not have to define each category. Where category definitions are absent 
  5506.  from the locale source, default definitions are used. 
  5507.  
  5508.  In each category the keyword copy followed by a string specifies the name of 
  5509.  an existing locale to be used as the source for the definition of this 
  5510.  category. The compiler searches for a specified existing locale as follows: 
  5511.  
  5512.    1. If you specify a path, the compiler searches that path. 
  5513.    2. If you specify a file name but no path, the compiler searches the current 
  5514.       directory. 
  5515.    3. If you specify a file name but no path and the file is not in the current 
  5516.       directory, the compiler searches the paths that you specified in the 
  5517.       DPATH environment variable. 
  5518.  
  5519.  If the locale is not found, an error is reported and no locale output is 
  5520.  created. 
  5521.  
  5522.  You can continue a line in a locale definition file by placing an escape 
  5523.  character as the last character on the line. This continuation character is 
  5524.  discarded from the input. Even though there is no limitation on the length of 
  5525.  each line, for portability reasons it is suggested that each line be no longer 
  5526.  than 2048 characters (bytes). There is no limit on the accumulated length of a 
  5527.  continued line. You cannot continue comment lines on a subsequent line by 
  5528.  using an escaped <newline>. 
  5529.  
  5530.  Individual characters, characters in strings, and collating elements are 
  5531.  represented using symbolic names, as defined below. Characters can also be 
  5532.  represented as the characters themselves, or as octal, hexadecimal, or decimal 
  5533.  constants. If you use non-symbolic notation, the resultant locale definition 
  5534.  file may not be portable among systems and environments. The left angle 
  5535.  bracket (<) is a reserved symbol, denoting the start of a symbolic name; if 
  5536.  you use it to represent itself, you must precede it with the escape character. 
  5537.  
  5538.  The following rules apply to the character representation: 
  5539.  
  5540.    1. A character can be represented by a symbolic name, enclosed within angle 
  5541.       brackets. The symbolic name, including the angle brackets, must exactly 
  5542.       match a symbolic name defined in the charmap file.  The symbolic name is 
  5543.       replaced by the character value determined from the value associated with 
  5544.       the symbolic name in the charmap file. 
  5545.  
  5546.       The use of a symbolic name not found in the charmap file constitutes an 
  5547.       error, unless the name is in the category LC_CTYPE or LC_COLLATE, in 
  5548.       which case it constitutes a warning. Use of the escape character or right 
  5549.       angle bracket within a symbolic name is invalid unless the character is 
  5550.       preceded by the escape character. For example: 
  5551.  
  5552.       <c>;<c-cedilla>     specifies two characters whose symbolic names are "c" 
  5553.                           and "c-cedilla" 
  5554.  
  5555.       "<M><a><y>"         specifies a 3-character string composed of letters 
  5556.                           represented by symbolic names "M", "a", and "y". 
  5557.  
  5558.       "<a><\>>"           specifies a 2-character string composed of letters 
  5559.                           represented by symbolic names "a" and ">" (assuming 
  5560.                           the escape character is \) 
  5561.  
  5562.    2. A character can represent itself. Within a string, the double quotation 
  5563.       mark, the escape character, and the left angle bracket must be escaped 
  5564.       (preceded by the escape character) to be interpreted as the characters 
  5565.       themselves. For example: 
  5566.  
  5567.       c              'c' character represented by itself 
  5568.  
  5569.       "may"          represents a 3-character string, each character within the 
  5570.                      string represented by itself 
  5571.  
  5572.       "###"#>"       represents the three character long string "#">", where 
  5573.                      the escape character is defined as #. 
  5574.  
  5575.    3. A character can be represented as an octal constant. An octal constant is 
  5576.       specified as the escape character followed by two or more octal digits. 
  5577.       Each constant represents a byte value. 
  5578.  
  5579.       For example: 
  5580.  
  5581.             \131 "\212\126\165" \16\66\163\17
  5582.  
  5583.    4. A character can be represented as a hexadecimal constant. A hexadecimal 
  5584.       constant is specified as the escape character, followed by an x, followed 
  5585.       by two or more hexadecimal digits. Each constant represents a byte value. 
  5586.  
  5587.       Example: \x83 "\xD4\x81\xA8" 
  5588.  
  5589.    5. A character can be represented as a decimal constant. A decimal constant 
  5590.       is specified as the escape character followed by a d followed by two or 
  5591.       more decimal digits. Each constant represents a byte value. 
  5592.  
  5593.       Example: \d131 "\d212\d129\d168" \d14\d66\d193\d15 
  5594.  
  5595.  
  5596.  Multibyte characters can be represented by concatenating constants specified 
  5597.  in byte order with the last constant specifying the least significant byte of 
  5598.  the character. 
  5599.  
  5600.  
  5601. ΓòÉΓòÉΓòÉ 10.3. Using the LOCALDEF Utility ΓòÉΓòÉΓòÉ
  5602.  
  5603. The locale objects or locales are generated using the LOCALDEF utility. The 
  5604. LOCALDEF utility: 
  5605.  
  5606.    1. Reads the locale definition file. 
  5607.  
  5608.    2. Resolves all the character symbolic names to the values of characters 
  5609.       defined in the specified character set definition file. 
  5610.  
  5611.    3. Produces a VisualAge for C++ source file. 
  5612.  
  5613.    4. Compiles the source file using the VisualAge for C++ compiler and links 
  5614.       the object file to produce a locale module. 
  5615.  
  5616.  The locale module can be loaded by the setlocale function and then accessed by 
  5617.  the VisualAge for C++ functions that are sensitive to the cultural 
  5618.  information, or that can query the locales. For a list of all the library 
  5619.  functions sensitive to locale, see Locale-Sensitive Interfaces. For detailed 
  5620.  information on how to invoke the LOCALDEF utility, see the User's Guide. 
  5621.  
  5622.  
  5623. ΓòÉΓòÉΓòÉ 10.3.1. Locale Naming Conventions ΓòÉΓòÉΓòÉ
  5624.  
  5625. The setlocale library function that selects the active locale maps the 
  5626. descriptive locale name into the name of the locale object before loading the 
  5627. locale and making it accessible. 
  5628.  
  5629. In VisualAge for C++ programs, the locale modules are referred to by 
  5630. descriptive locale names.  The locale names themselves are not case sensitive. 
  5631. They follow these conventions: 
  5632.  
  5633. <Language>_<Territory>.<Codeset>
  5634.  
  5635. Where: 
  5636.  
  5637.  Language 
  5638.            is a two-letter abbreviation for the language name.  The 
  5639.            abbreviations come from the ISO 639 standard. 
  5640.  
  5641.  Territory 
  5642.            is a two-letter abbreviation for the territory name.  The 
  5643.            abbreviation comes from the ISO 3166 standard. 
  5644.  
  5645.  Codeset 
  5646.            is the name registered by the MIT X Consortium that identifies the 
  5647.            registration authority that owns the specific encoding. 
  5648.  
  5649.            A modifier may be added to the registered name but is not required. 
  5650.            The modifier is of the form @modifier and identifies the coded 
  5651.            character set as defined by that registration authority. 
  5652.  
  5653.            Note:  On FAT file systems, the modifier cannot be used as it causes 
  5654.            the filename to exceed the 8 character FAT filename limit. 
  5655.  
  5656.  The Codeset parts are optional. If they are not specified, Codeset defaults to 
  5657.  IBM-nnn, where nnn is the current code page.  (The modifier portion defaults 
  5658.  to nothing.) 
  5659.  
  5660.  The setlocale function tries to load the locale from the current directory, or 
  5661.  from the directories that you specified in the LOCPATH environment variable. 
  5662.  The specified paths are searched to find the DLL that contains the locale. If 
  5663.  you do not specify the extension .lcl, it is appended to the DLL name. 
  5664.  
  5665.  The locale name parameter is processed to produce a filename suitable for use 
  5666.  with the FAT file system: 
  5667.  
  5668.    1. The locale name parameter is separated into two parts, language_territory 
  5669.       and codeset. 
  5670.  
  5671.    2. If you specify the codeset name, the locale name is built as: 
  5672.  
  5673.               language_territory\codeset.lcl
  5674.  
  5675.    3. If you do not specify the codeset name, the locale name is built as 
  5676.  
  5677.              language_territory.lcl
  5678.  
  5679.    4. If the locale cannot be found, the GetOEMCP function determines the 
  5680.       current codepage. The codeset name is built as IBM-nnn, where nnn is the 
  5681.       current codepage. 
  5682.  
  5683.       The locale name is then built as: 
  5684.  
  5685.               language_territory\codeset.lcl
  5686.  
  5687.  The exceptions to the rule above are the following special locale names, which 
  5688.  are already recognized: 
  5689.  
  5690.      C 
  5691.      POSIX 
  5692.  
  5693.       The following locale names are provided: 
  5694.  
  5695.             ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5696.             Γöé Table 3. Compiled locales supplied with VisualAge for C++    Γöé
  5697.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5698.             Γöé LANGUAGE  Γöé COUNTRY   Γöé CODESET  Γöé LOCALE MODULE Γöé LOCALE   Γöé
  5699.             Γöé       Γöé       Γöé      Γöé NAME      Γöé NAME AS  Γöé
  5700.             Γöé       Γöé       Γöé      Γöé        Γöé IN     Γöé
  5701.             Γöé       Γöé       Γöé      Γöé        Γöé SETLOCALE(Γöé
  5702.             Γöé       Γöé       Γöé      Γöé        Γöé ARGUMENT  Γöé
  5703.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5704.             Γöé  -     Γöé  -     Γöé IBM-850  Γöé  -      Γöé C     Γöé
  5705.             Γöé       Γöé       Γöé IBM-850  Γöé  -      Γöé POSIX   Γöé
  5706.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5707.             Γöé Arabic   Γöé Arabic   Γöé IBM-864  Γöé AR_AA\IBM-864 Γöé AR_AA-IBM-Γöé64
  5708.             Γöé       Γöé       Γöé IBM1256  Γöé AR_AA\IBM-1256Γöé AR_AA.IBM-Γöé256
  5709.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5710.             Γöé Portugese  Γöé Brazil   Γöé IBM-850  Γöé PT_BR\IBM-850 Γöé PT_BR.IBM-Γöé50
  5711.             Γöé       Γöé       Γöé IBM-1252 Γöé PT_BR\IBM-1252Γöé PT_BR.IBM-Γöé252
  5712.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5713.             Γöé Bulgarian  Γöé Bulgaria  Γöé IBM-855  Γöé BG_BG\IBM-855 Γöé BG_BG.IBM-Γöé55
  5714.             Γöé       Γöé       Γöé IBM-1251 Γöé BG_BG\IBM-1251Γöé BG_BG.IBM-Γöé251
  5715.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5716.             Γöé Chinese   Γöé China    Γöé IBM-936  Γöé ZH_CN\IBM-936 Γöé ZH_CN.IBM-Γöé36
  5717.             Γöé (Simpli-  Γöé       Γöé      Γöé Note 1     Γöé Note 1   Γöé
  5718.             Γöé fied)    Γöé       Γöé      Γöé        Γöé      Γöé
  5719.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5720.             Γöé Chinese   Γöé China    Γöé IBM-950  Γöé ZH_TW\IBM-950 Γöé ZH_TW.IBM-Γöé50
  5721.             Γöé (Tradi-   Γöé       Γöé      Γöé        Γöé      Γöé
  5722.             Γöé tional)   Γöé       Γöé      Γöé        Γöé      Γöé
  5723.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5724.             Γöé Croation  Γöé Croatia   Γöé IBM-852  Γöé HR_HR\IBM-852 Γöé HR_HR.IBM-Γöé52
  5725.             Γöé       Γöé       Γöé IBM-1250 Γöé HR_HR\IBM-1250Γöé HR_HR\IBM-Γöé250
  5726.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5727.             Γöé CzechoslovaΓöéiCzechoslovaΓöéiIBM-852  Γöé CS_CZ\IBM-852 Γöé CS_CZ.IBM-Γöé52
  5728.             Γöé       Γöé       Γöé IBM-1250 Γöé CS_CZ\IBM-1250Γöé CS_CZ.IBM-Γöé250
  5729.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5730.             Γöé Danish   Γöé Denmark   Γöé IBM-437  Γöé DA_DK\IBM-437 Γöé DA_DK.IBM-Γöé37
  5731.             Γöé       Γöé       Γöé IBM-850  Γöé DA_DK\IBM-850 Γöé DA_DK.IBM-Γöé50
  5732.             Γöé       Γöé       Γöé IBM-1252 Γöé DA_DK\IBM-1252Γöé DA_DK.IBM-Γöé252
  5733.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5734.             Γöé Deutsch   Γöé Germany   Γöé IBM-437  Γöé DE_DE\IBM-437 Γöé DE_DE.IBM-Γöé37
  5735.             Γöé (German)  Γöé       Γöé IBM-850  Γöé DE_DE\IBM-850 Γöé DE_DE.IBM-Γöé50
  5736.             Γöé       Γöé       Γöé IBM-1252 Γöé DE_DE\IBM-1252Γöé DE_DE.IBM-Γöé252
  5737.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5738.             Γöé Deutsch   Γöé SwitzerlandΓöé IBM-437  Γöé DE_CH\IBM-437 Γöé DE_CH.IBM-Γöé37
  5739.             Γöé (German)  Γöé       Γöé IBM-850  Γöé DE_CH\IBM-850 Γöé DE_CH.IBM-Γöé50
  5740.             Γöé       Γöé       Γöé IBM-1252 Γöé DE_CH\IBM-1252Γöé DE_CH.IBM-Γöé252
  5741.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5742.             Γöé English   Γöé United   Γöé IBM-437  Γöé EN_GB\IBM-437 Γöé EN_GB.IBM-Γöé37
  5743.             Γöé       Γöé Kingdom   Γöé IBM-850  Γöé EN_GB\IBM-850 Γöé EN_GB.IBM-Γöé50
  5744.             Γöé       Γöé       Γöé IBM-1252 Γöé EN_GB\IBM-1252Γöé EN_GB.IBM-Γöé252
  5745.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5746.             Γöé English   Γöé Japan    Γöé IBM-437  Γöé EN_JP\IBM-437 Γöé EN_JP.IBM-Γöé37
  5747.             Γöé       Γöé       Γöé IBM-850  Γöé EN_JP\IBM-850 Γöé EN_JP.IBM-Γöé50
  5748.             Γöé       Γöé       Γöé IBM-1252 Γöé EN_JP\IBM-1252Γöé EN_JP.IBM-Γöé252
  5749.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5750.             Γöé English   Γöé United   Γöé IBM-437  Γöé EN_US\IBM-437 Γöé EN_US.IBM-Γöé37
  5751.             Γöé       Γöé States   Γöé IBM-850  Γöé EN_US\IBM-850 Γöé EN_US.IBM-Γöé50
  5752.             Γöé       Γöé       Γöé IBM-1252 Γöé EN_US\IBM-1252Γöé EN_US.IBM-Γöé252
  5753.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5754.             Γöé Espa╨┤ol   Γöé Spain    Γöé IBM-437  Γöé ES_ES\IBM-437 Γöé ES_ES.IBM-Γöé37
  5755.             Γöé (Spanish)  Γöé       Γöé IBM-850  Γöé ES_ES\IBM-850 Γöé ES_ES.IBM-Γöé50
  5756.             Γöé       Γöé       Γöé IBM-1252 Γöé ES_ES\IBM-1252Γöé ES_ES.IBM-Γöé252
  5757.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5758.             Γöé Finnish   Γöé Finland   Γöé IBM-437  Γöé FI_FI\IBM-437 Γöé FI_FI.IBM-Γöé37
  5759.             Γöé       Γöé       Γöé IBM-850  Γöé FI_FI\IBM-850 Γöé FI_FI.IBM-Γöé50
  5760.             Γöé       Γöé       Γöé IBM-1252 Γöé FI_FI\IBM-1252Γöé FI_FI.IBM-Γöé252
  5761.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5762.             Γöé French   Γöé Belgium   Γöé IBM-437  Γöé FR_BE\IBM-437 Γöé FR_BE.IBM-Γöé37
  5763.             Γöé       Γöé       Γöé IBM-850  Γöé FR_BE\IBM-850 Γöé FR_BE.IBM-Γöé50
  5764.             Γöé       Γöé       Γöé IBM-1252 Γöé FR_BE\IBM-1252Γöé FR_BE.IBM-Γöé252
  5765.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5766.             Γöé French   Γöé Canada   Γöé IBM-850  Γöé FR_CA\IBM-850 Γöé FR_CA.IBM-Γöé50
  5767.             Γöé       Γöé       Γöé IBM-863  Γöé FR_CA\IBM-863 Γöé FR_CA.IBM-Γöé63
  5768.             Γöé       Γöé       Γöé IBM-1252 Γöé FR_CA\IBM-1252Γöé FR_CA.IBM-Γöé252
  5769.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5770.             Γöé French   Γöé SwitzerlandΓöé IBM-437  Γöé FR_CH\IBM-437 Γöé FR_CH.IBM-Γöé37
  5771.             Γöé       Γöé       Γöé IBM-850  Γöé FR_CH\IBM-850 Γöé FR_CH.IBM-Γöé50
  5772.             Γöé       Γöé       Γöé IBM-1252 Γöé FR_CH\IBM-1252Γöé FR_CH.IBM-Γöé252
  5773.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5774.             Γöé French   Γöé France   Γöé IBM-437  Γöé FR_FR\IBM-437 Γöé FR_FR.IBM-Γöé37
  5775.             Γöé       Γöé       Γöé IBM-850  Γöé FR_FR\IBM-850 Γöé FR_FR.IBM-Γöé50
  5776.             Γöé       Γöé       Γöé IBM-1252 Γöé FR_FR\IBM-1252Γöé FR_FR.IBM-Γöé252
  5777.             ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5778.             ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  5779.             Γöé Table 3. Compiled locales supplied with VisualAge for C++    Γöé
  5780.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5781.             Γöé LANGUAGE  Γöé COUNTRY   Γöé CODESET  Γöé LOCALE MODULE Γöé LOCALE   Γöé
  5782.             Γöé       Γöé       Γöé      Γöé NAME      Γöé NAME AS  Γöé
  5783.             Γöé       Γöé       Γöé      Γöé        Γöé IN     Γöé
  5784.             Γöé       Γöé       Γöé      Γöé        Γöé SETLOCALE(Γöé
  5785.             Γöé       Γöé       Γöé      Γöé        Γöé ARGUMENT  Γöé
  5786.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5787.             Γöé Greek    Γöé Greece   Γöé IBM-737  Γöé EL_GR\IBM-737 Γöé EL_GR.IBM-Γöé37
  5788.             Γöé       Γöé       Γöé IBM-1253 Γöé EL_GR\IBM-1253Γöé EL_GR.IBM-Γöé253
  5789.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5790.             Γöé Hungarian  Γöé Hungary   Γöé IBM-852  Γöé HU_HU\IBM-852 Γöé HU_HU.IBM-Γöé52
  5791.             Γöé       Γöé       Γöé IBM-1250 Γöé HU_HU\IBM-1250Γöé HU_HU.IBM-Γöé250
  5792.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5793.             Γöé Hebrew   Γöé Israel   Γöé IBM-862  Γöé IW_IL\IBM-862 Γöé IW_IL.IBM-Γöé62
  5794.             Γöé       Γöé       Γöé IBM-1255 Γöé IW_IL\IBM-1255Γöé IW_IL.IBM-Γöé255
  5795.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5796.             Γöé Γòôslensk   Γöé Iceland   Γöé IBM-850  Γöé IS_IS\IBM-850 Γöé IS_IS.IBM-Γöé50
  5797.             Γöé (Icelandic)Γöé       Γöé IBM-861  Γöé IS_IS\IBM-861 Γöé IS_IS.IBM-Γöé61
  5798.             Γöé       Γöé       Γöé IBM-1252 Γöé IS_IS\IBM-1252Γöé IS_IS.IBM-Γöé252
  5799.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5800.             Γöé Italian   Γöé Italy    Γöé IBM-437  Γöé IT_IT\IBM-437 Γöé IT_IT.IBM-Γöé37
  5801.             Γöé       Γöé       Γöé IBM-850  Γöé IT_IT\IBM-850 Γöé IT_IT.IBM-Γöé50
  5802.             Γöé       Γöé       Γöé IBM-1252 Γöé IT_IT\IBM-1252Γöé IT_IT.IBM-Γöé252
  5803.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5804.             Γöé Japanese  Γöé Japan    Γöé IBM-932  Γöé JA_JP\IBM-932 Γöé JA_JP.IBM-Γöé32
  5805.             Γöé       Γöé       Γöé Note 2  Γöé Note 2     Γöé Note 2   Γöé
  5806.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5807.             Γöé Korean   Γöé Korea    Γöé IBM-949  Γöé KO_KR\IBM-949 Γöé KO_KR.IBM-Γöé49
  5808.             Γöé       Γöé       Γöé      Γöé        Γöé      Γöé
  5809.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5810.             Γöé Macedonian Γöé Macedonia  Γöé IBM-855  Γöé MK_MK\IBM-855 Γöé MK_MK.IBM-Γöé55
  5811.             Γöé       Γöé       Γöé IBM-1251 Γöé MK_MK\IBM-1251Γöé MK_MK.IBM-Γöé251
  5812.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5813.             Γöé Nederlands Γöé Belgium   Γöé IBM-437  Γöé NL_BE\IBM-437 Γöé NL_BE.IBM-Γöé37
  5814.             Γöé (Dutch)   Γöé       Γöé IBM-850  Γöé NL_BE\IBM-850 Γöé NL_BE.IBM-Γöé50
  5815.             Γöé       Γöé       Γöé IBM-1252 Γöé NL_BE\IBM-1252Γöé NL_BE.IBM-Γöé252
  5816.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5817.             Γöé Nederlands Γöé NetherlandsΓöé IBM-437  Γöé NL_NL\IBM-437 Γöé NL_NL.IBM-Γöé37
  5818.             Γöé (Dutch)   Γöé       Γöé IBM-850  Γöé NL_NL\IBM-850 Γöé NL_NL.IBM-Γöé50
  5819.             Γöé       Γöé       Γöé IBM-1252 Γöé NL_NL\IBM-1252Γöé NL_NL.IBM-Γöé252
  5820.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5821.             Γöé Norwegian  Γöé Norway   Γöé IBM-437  Γöé NO_NO\IBM-437 Γöé NO_NO.IBM-Γöé37
  5822.             Γöé       Γöé       Γöé IBM-850  Γöé NO_NO\IBM-850 Γöé NO_NO.IBM-Γöé50
  5823.             Γöé       Γöé       Γöé IBM-1252 Γöé NO_NO\IBM-1252Γöé NO_NO.IBM-Γöé252
  5824.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5825.             Γöé Polish   Γöé Poland   Γöé IBM-852  Γöé PL_PL\IBM-852 Γöé PL_PL.IBM-Γöé52
  5826.             Γöé       Γöé       Γöé IBM-1250 Γöé PL_PL\IBM-1250Γöé PL_PL.IBM-Γöé250
  5827.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5828.             Γöé Portuguese Γöé Portugal  Γöé IBM-850  Γöé PT_PT\IBM-850 Γöé PT_PT.IBM-Γöé50
  5829.             Γöé       Γöé       Γöé IBM-860  Γöé PT_PT\IBM-860 Γöé PT_PT.IBM-Γöé60
  5830.             Γöé       Γöé       Γöé IBM-1252 Γöé PT_PT\IBM-1252Γöé PT_PT.IBM-Γöé252
  5831.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5832.             Γöé Romanian  Γöé Romania   Γöé IBM-852  Γöé RO_RO\IBM-852 Γöé RO_RO.IBM-Γöé52
  5833.             Γöé       Γöé       Γöé IBM-1250 Γöé RO_RO\IBM-1250Γöé RO_RO.IBM-Γöé250
  5834.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5835.             Γöé Russian   Γöé Russia   Γöé IBM-866  Γöé RU_RU\IBM-866 Γöé RU_RU.IBM-Γöé66
  5836.             Γöé       Γöé       Γöé IBM-1251 Γöé RU_RU\IBM-1251Γöé RU_RU.IBM-Γöé251
  5837.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5838.             Γöé Slovak   Γöé Slovakia  Γöé IBM-852  Γöé SK_SK\IBM-852 Γöé SK_SK.IBM-Γöé52
  5839.             Γöé       Γöé       Γöé IBM-1250 Γöé SK_SK\IBM-1250Γöé SK_SK.IBM-Γöé250
  5840.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5841.             Γöé Slovene   Γöé Slovenia  Γöé IBM-852  Γöé SL_SI\IBM-852 Γöé SL_SI.IBM-Γöé52
  5842.             Γöé       Γöé       Γöé IBM-1250 Γöé SL_SI\IBM-1250Γöé SL_SI.IBM-Γöé250
  5843.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5844.             Γöé Svensk   Γöé Sweden   Γöé IBM-437  Γöé SV_SE\IBM-437 Γöé SV_SE.IBM-Γöé37
  5845.             Γöé (Swedish)  Γöé       Γöé IBM-850  Γöé SV_SE\IBM-850 Γöé SV_SE.IBM-Γöé50
  5846.             Γöé       Γöé       Γöé IBM-1252 Γöé SV_SE\IBM-1252Γöé SV_SE.IBM-Γöé252
  5847.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5848.             Γöé Thai    Γöé Thailand  Γöé IBM-874  Γöé TH_TH\IBM-874 Γöé TH_TH.IBM-Γöé74
  5849.             Γöé       Γöé       Γöé      Γöé        Γöé      Γöé
  5850.             Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  5851.             Γöé Turkish   Γöé Turkey   Γöé IBM-857  Γöé TR_TR\IBM-857 Γöé TR_TR.IBM-Γöé57
  5852.             Γöé       Γöé       Γöé IBM-1254 Γöé TR_TR\IBM-1254Γöé TR_TR.IBM-Γöé254
  5853.             ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  5854.  
  5855.       Note: 
  5856.         1. The locale will be shipped with the name of "ZH_CN.IBM-936" but will 
  5857.            respond with codeset "ZH_CN.IBM-1381". 
  5858.  
  5859.         2. The locale will be shipped with the name of "JA_JP.IBM-932" but will 
  5860.            respond with codeset "JA_JP.IBM-943". 
  5861.  
  5862.  You can use the LC_C macro, defined in the <locale.h> header file, as a 
  5863.  synonyms for the special locale C. 
  5864.  
  5865.  
  5866. ΓòÉΓòÉΓòÉ 11. Using Templates in C++ Programs ΓòÉΓòÉΓòÉ
  5867.  
  5868. Templates may be used in C++ to declare and define classes, functions, and 
  5869. static data members of template classes. The C++ language describes the syntax 
  5870. and meaning of each kind of template.  Each particular compiler, however, 
  5871. determines the mechanism that controls when and how often a template is 
  5872. expanded. 
  5873.  
  5874. VisualAge for C++ offers several alternative organizations with a range of 
  5875. convenience and compile performance to meet the needs of any application.  This 
  5876. chapter describes those alternatives and the criteria you should use to select 
  5877. which one is right for you. 
  5878.  
  5879. This section discusses: 
  5880.  
  5881.      Template Terms 
  5882.      How the Compiler Expands Templates 
  5883.      Example of Generating Template Function Definitions 
  5884.      Including Defining Templates 
  5885.  
  5886.  For a general description of templates, see the online Language Reference. 
  5887.  
  5888.   CAUTION:
  5889.  Do not attempt to link objects produced from compiling the assembler listings 
  5890.  of programs containing templates. Even if the  listing does compile, it will 
  5891.  not link correctly. (The linker may perform the link without error but the 
  5892.  .EXE will produce incorrect results.) 
  5893.  
  5894.  
  5895. ΓòÉΓòÉΓòÉ 11.1. Template Terms ΓòÉΓòÉΓòÉ
  5896.  
  5897. The following terms are used to describe the template constructs in C++: 
  5898.  
  5899.  class template 
  5900.            A template used to generate classes.  Classes generated in this 
  5901.            fashion are called template classes. A class template describes a 
  5902.            family of related classes. It can simply be a declaration, or it can 
  5903.            can be a definition of a particular class. 
  5904.  
  5905.  function template 
  5906.            A template used to generate functions.  Functions generated in this 
  5907.            fashion are called template functions. A function template describes 
  5908.            a family of related functions. It can simply be a declaration, or it 
  5909.            can be a definition of a particular function. 
  5910.  
  5911.  declaring template 
  5912.            A class template or function template that includes a declaration 
  5913.            but does not include a definition.  For example, this is what a 
  5914.            declaring function template would look like. 
  5915.  
  5916.                         template<class A> void foo(A*a);
  5917.  
  5918.            A declaring class template would look like this 
  5919.  
  5920.                         template<class T> class C;
  5921.  
  5922.  defining template 
  5923.            A class template or function template declaration that includes a 
  5924.            definition. A defining function template would look like this: 
  5925.  
  5926.                         template<class A> void foo(A*a) {a ->Bar();};
  5927.  
  5928.            A defining class template would look like this: 
  5929.  
  5930.                         template<class T> class C : public A {public: void boo();};
  5931.  
  5932.  explicit definition 
  5933.            A user-supplied definition that overrides a template.  For example, 
  5934.            an explicit definition of the foo() function would look like this: 
  5935.  
  5936.                         void foo(int *a) {a++;}
  5937.  
  5938.            An explicit definition of a template class looks like this: 
  5939.  
  5940.                         class C<short> {
  5941.                          public: int moo();
  5942.                         }
  5943.  
  5944.  Instantiation 
  5945.            A defining template defines a whole family of classes or functions. 
  5946.            An instantiation of a template class or function is a specific class 
  5947.            or function that is based on the template. 
  5948.  
  5949.  
  5950. ΓòÉΓòÉΓòÉ 11.2. How the Compiler Expands Templates ΓòÉΓòÉΓòÉ
  5951.  
  5952. You can choose from three alternatives for instantiating templates: 
  5953.  
  5954.    1. Including defining templates everywhere.  See Including Defining 
  5955.       Templates Everywhere for more details. 
  5956.  
  5957.    2. Using VisualAge for C++'s automatic facility to ensure that there is a 
  5958.       single instantiation of the template.  See Structuring for Automatic 
  5959.       Instantiation for more details. 
  5960.  
  5961.    3. Manually structuring your code so that there is a single instantiation of 
  5962.       the template.  See Manually Structuring for Single Instantiation for more 
  5963.       details. 
  5964.  If you want to make the best choice among these alternatives, it is easiest if 
  5965.  you first understand how the compiler reacts when it encounters templates. 
  5966.  When you use templates in your program, the VisualAge for C++ compiler 
  5967.  automatically instantiates each defining template that is: 
  5968.  
  5969.      Referenced in the source code, and 
  5970.      Visible to the compiler (included as the result of an #include 
  5971.       statement), and 
  5972.      Not explicitly defined by the programmer 
  5973.  
  5974.  If an application consists of several separate compilation units that are 
  5975.  compiled separately, it is possible that a given template is expanded in two 
  5976.  or more of the compilation units. For templates that define classes, inline 
  5977.  functions, or static nonmember functions, this is usually the desired 
  5978.  behaviour.  These templates normally need to be defined in each compilation 
  5979.  unit where they are used. 
  5980.  
  5981.  For other functions and for static data members, which have external linkage, 
  5982.  defining them in more than one compilation unit would normally cause an error 
  5983.  when the program is linked.  VisualAge for C++ avoids this problem by giving 
  5984.  special treatment to template-generated versions of these objects.  At link 
  5985.  time, VisualAge for C++ gathers all template-generated functions and static 
  5986.  member definitions, plus any explicit definitions, and resolves references to 
  5987.  them in the following manner: 
  5988.  
  5989.      If an explicit definition of the function or static member exists, it is 
  5990.       used for all references.  All template-generated definitions of that 
  5991.       function or static member are discarded. 
  5992.  
  5993.      If no explicit definition exists, one of the template-generated 
  5994.       definitions is used for all references.  Any other template-generated 
  5995.       definitions of that function or static member are discarded. 
  5996.  
  5997.  Note that you may have only one explicit definition of a template instance 
  5998.  that has external linkage. 
  5999.  
  6000.  
  6001. ΓòÉΓòÉΓòÉ 11.3. Example of Generating Template Function Definitions ΓòÉΓòÉΓòÉ
  6002.  
  6003. The class template Stack provides an example of generating a template class 
  6004. from a class template. Stack implements a stack of items. The overloaded 
  6005. operators << and >> are used to push items on to the stack and pop items from 
  6006. the stack. Assume that the declaration of the Stack class template is contained 
  6007. in the file stack.h: 
  6008.  
  6009.  
  6010. Declaration of Stack in stack.h
  6011.  
  6012.    template <class Item, int size> class Stack {
  6013.     public:
  6014.       int operator << (Item item);  // push operator
  6015.       int operator >> (Item& item); // pop operator
  6016.       Stack() { top = 0; }      // constructor defined inline
  6017.      private:
  6018.       Item stack[size];       // stack of items
  6019.       int  top;           // index to top of stack
  6020.    };
  6021.  
  6022. In the class template, the constructor function is defined inline. Assume the 
  6023. other member functions are defined using separate function templates in the 
  6024. file stack.c: 
  6025.  
  6026.  
  6027. Definition of operator functions in stack.c
  6028.  
  6029.    template <class Item, int size>
  6030.     int Stack<Item,size>::operator << (Item item) {
  6031.      if (top >= size) return 0;
  6032.       stack[top++] = item;
  6033.       return 1;
  6034.     }
  6035.    template <class Item, int size>
  6036.      int Stack<Item,size>::operator >> (Item& item)
  6037.     {
  6038.       if (top <= 0) return 0;
  6039.       item = stack[--top];
  6040.       return 1;
  6041.     }
  6042.  
  6043. In this example, the constructor has internal linkage because it is defined 
  6044. inline in the class template declaration. In each compilation unit that uses an 
  6045. instance of the Stack class, the compiler generates the constructor function 
  6046. body. This results in each compilation unit using its own copy of the 
  6047. constructor. 
  6048.  
  6049. In each compilation unit that includes the file stack.c, for any instance of 
  6050. the Stack class in that unit, the compiler generates definitions for the 
  6051. following functions (assuming there is no explicit definition) : 
  6052.  
  6053.   Stack<item,size>::operator<<(item)
  6054.   Stack<item,size>::operator>>(item&)
  6055.  
  6056. For example, given the following source file stack.cpp: 
  6057.  
  6058.   #include "stack.h"
  6059.   #include "stack.c"
  6060.  
  6061.   void Swap(int i&, Stack<int,20>& s)
  6062.   {
  6063.    int j;
  6064.    s >> j;
  6065.    s << i;
  6066.    i = j;
  6067.   }
  6068.  
  6069. the compiler generates the functions Stack<int,20>::operator<<(int) and 
  6070. Stack<int,20>::operator>>(int&) because both those functions are used in the 
  6071. program, their defining templates are visible, and no explicit definitions were 
  6072. seen. 
  6073.  
  6074.  
  6075. ΓòÉΓòÉΓòÉ 11.4. Including Defining Templates ΓòÉΓòÉΓòÉ
  6076.  
  6077. The following sections describe the three methods of including defining 
  6078. templates and how they would be applied to this example. The methods are: 
  6079.  
  6080.      including defining templates everywhere 
  6081.      structuring for automatic instantiation 
  6082.      manually stucturing for single instantiation 
  6083.  
  6084.  Automatic instantiation is the recommended method. 
  6085.  
  6086.  
  6087. ΓòÉΓòÉΓòÉ 11.4.1. Including Defining Templates Everywhere ΓòÉΓòÉΓòÉ
  6088.  
  6089. The simplest way to instantiate templates is to include the defining template 
  6090. in every compilation unit that uses the template. This alternative has the 
  6091. following disadvantages: 
  6092.  
  6093.      If you make even a trivial change to the implementation of a template, 
  6094.       you must recompile every compilation unit that uses it. 
  6095.      The compilation process is slower, and the resulting object files are 
  6096.       bigger because the templates are expanded in every compilation unit where 
  6097.       they are used.  Note, however, that the duplicated code for the templates 
  6098.       is eliminated during linking, so the executable files are not larger if 
  6099.       you choose to include defining templates everywhere. 
  6100.  
  6101.  For example, to use this method with the Stack template, include both stack.h 
  6102.  and stack.c in all compilation units that use an instance of the Stack class. 
  6103.  The compiler then generates definitions for each template function. Each 
  6104.  template function may be defined multiple times, increasing the size of the 
  6105.  object file. 
  6106.  
  6107.  
  6108. ΓòÉΓòÉΓòÉ 11.4.2. Structuring for Automatic Instantiation ΓòÉΓòÉΓòÉ
  6109.  
  6110. The recommended way to instantiate templates is to structure your program for 
  6111. their automatic instantiation. The advantages of this method are: 
  6112.  
  6113.      It is easy to do. 
  6114.      Unlike the method of including defining templates everywhere, you do not 
  6115.       get larger object files and slower compile times. 
  6116.      Unlike the method of including defining templates everywhere, you do not 
  6117.       have to recompile all of the compilation units that use a template if 
  6118.       that template implementation is changed. 
  6119.  
  6120.  The disadvantages of this method are: 
  6121.  
  6122.      It may not be practical in a team programming environment because the 
  6123.       compiler may update source files that are being modified at the same time 
  6124.       by somebody else. 
  6125.      The modifications that are made to source files may not be file system 
  6126.       independent.  For example, header files that are locally available may be 
  6127.       included rather than header files that are available on a network. 
  6128.       Changes made to the network headers would therefore be missed. 
  6129.      There are some situations where the compiler cannot determine exactly 
  6130.       which header files should be included. 
  6131.  
  6132.  To use this facility: 
  6133.  
  6134.    1. Declare your template functions in a header file using class or function 
  6135.       templates, but do not define them. Include the header file in your source 
  6136.       code. 
  6137.  
  6138.    2. For each header file, create a template-implementation file with the same 
  6139.       name as the header and the extension .c. Define the template functions in 
  6140.       this template-implementation file. 
  6141.  
  6142.  Note:  Use the same compiler options to link your object files that you use to 
  6143.         compile them.  For example, if you compile with the command: 
  6144.  
  6145.                   icc /C /Gm /Sa myfile.cpp
  6146.  
  6147.  link with the command: 
  6148.  
  6149.     icc /Tdp /Gm /Sa myfile.obj
  6150.  
  6151.  This is especially important for options that control libraries, linkage, and 
  6152.  code compatibility. This does not apply to options that affect only the 
  6153.  creation of object code (for example, /C and /Fo). 
  6154.  
  6155.  Note that in the compile step, the /Tdp was implicit because it is the default 
  6156.  for files with the extension .cpp. However, when linking files with the 
  6157.  extension .obj, the /Tdp option must be specified to inform the linker that it 
  6158.  is linking C++ objects. 
  6159.  
  6160.  For each header file with template functions that need to be defined, the 
  6161.  compiler generates a template-include file. The template-include file 
  6162.  generates #include statements in that file for: 
  6163.  
  6164.      The header file with the template declaration 
  6165.  
  6166.      The corresponding template-implementation file 
  6167.  
  6168.      Any other header files that declare types used in template parameters. 
  6169.  
  6170.  Important  If you have other declarations that are used inside templates but 
  6171.             are not template parameters, you must place or #include them in 
  6172.             either the template-implementation file or one of the header files 
  6173.             that will be included as a result of the above three steps. Define 
  6174.             any classes that are used in template arguments and that are 
  6175.             required to generate the template function in the header file. If 
  6176.             the class definitions require other header files, include them with 
  6177.             the #include directive. The class definitions are then available in 
  6178.             the template-implementation file when the function definition is 
  6179.             compiled. Do not put the definitions of any classes used in 
  6180.             template arguments in your source code. 
  6181.  
  6182.                           foo.h
  6183.                            template<class T> void foo(T*);
  6184.  
  6185.                           hoo.h
  6186.                            void hoo(A*);
  6187.  
  6188.                           foo.c
  6189.                            template<class T> void foo(T* t)
  6190.                             {t -> goo(); hoo(t);}
  6191.  
  6192.                           other.h
  6193.                            class A {public: void goo() {} };
  6194.  
  6195.                           main.cpp
  6196.                            #include "foo.h"
  6197.                            #include "other.h"
  6198.                            #include "hoo.h"
  6199.                            int main() { A a;  foo(&a); }
  6200.  
  6201.  This requires the expansion of the foo(T*) template with "class A" as the 
  6202.  template type parameter. The compiler will create a template-include file 
  6203.  TEMPINC\foo.cpp. The file contents (simplified below) would be: 
  6204.  
  6205.    #include "foo.h"     //the template declaration header
  6206.    #include "other.h"    //file defining template type parameter
  6207.    #include "foo.c"     //corresponding template implementation
  6208.    void foo(A*);       //triggers template instantiation
  6209.  
  6210.  This won't compile properly because the header "hoo.h" didn't satisfy the 
  6211.  conditions for inclusion but the header is required to compile the body of 
  6212.  foo(A*).  One solution is to move the declaration of hoo(A*) into the 
  6213.  "other.h" header. 
  6214.  
  6215.  The function definitions in your template-implementation file can be explicit 
  6216.  definitions, template definitions, or both. Any explicit definitions are used 
  6217.  instead of the definitions generated by the template. 
  6218.  
  6219.  Before it invokes the linker, the compiler compiles the template-include files 
  6220.  and generates the necessary template function definitions. Only one definition 
  6221.  is generated for each template function. 
  6222.  
  6223.  By default, the compiler stores the template-include files in the TEMPINC 
  6224.  subdirectory under the current directory. The compiler creates the TEMPINC 
  6225.  directory if it does not already exist. To redirect the template-include files 
  6226.  to another directory, use the /Ftdir compiler option, where dir is the 
  6227.  directory to contain the template-include files. You can specify a 
  6228.  fully-qualified path name or a path name relative to the current directory. 
  6229.  
  6230.  If you specify a different directory for your template-include files, make 
  6231.  sure that you specify it consistently for all compilations of your program, 
  6232.  including the link step. 
  6233.  
  6234.  Note:  After the compiler creates a template-include file, it may add 
  6235.         information to the file as each compilation unit is compiled. However, 
  6236.         the compiler never removes information from the file. If you remove 
  6237.         function instantiations or reorganize your program so that the 
  6238.         template-include files become obsolete, you may want to delete one or 
  6239.         more of these files and recompile your program. In addition, if error 
  6240.         messages are generated for a file in the TEMPINC directory, you must 
  6241.         either correct the errors manually or delete the file and recompile. To 
  6242.         regenerate all of the template-include files, delete the TEMPINC 
  6243.         directory, the .OBJ files, and recompile your program. 
  6244.  
  6245.  If you do not delete the .OBJ files, typical MAKEFILE rules will prevent the 
  6246.  OBJs from being recompiled, and therefore the template-include files will not 
  6247.  be updated with all the lines needed for all the compilation units used in the 
  6248.  program.  The end result would be that the link would fail. 
  6249.  
  6250.  
  6251. ΓòÉΓòÉΓòÉ 11.4.2.1. Example of a Template-Implementation File ΓòÉΓòÉΓòÉ
  6252.  
  6253. In the Stack example, the file stack.c is a template-implementation file. To 
  6254. create a program using the Stack class template, stack.h and stack.c must 
  6255. reside in the same directory. You would include stack.h in any source files 
  6256. that use an instance of the class. The stack.c file does not need to be 
  6257. included in any source files. Then, given the source file: 
  6258.  
  6259.   #include "stack.h"
  6260.  
  6261.   void Swap(int i&, Stack<int,20>& s)
  6262.   {
  6263.    int j;
  6264.    s >> j;
  6265.    s << i;
  6266.    i = j;
  6267.   }
  6268.  
  6269. the compiler automatically generates the functions 
  6270. Stack<int,20>::operator<<(int) and Stack<int,20>::operator>>(int&). 
  6271.  
  6272. You can change the name of the template-implementation file or place it in a 
  6273. different directory using the #pragma implementation directive. This #pragma 
  6274. directive has the format: 
  6275.  
  6276.   #pragma implementation(path)
  6277.  
  6278. where path is the path name for the template-implementation file. If it is only 
  6279. a partial path name, it must be relative to the directory containing the header 
  6280. file. 
  6281.  
  6282. Note:  This path is a quoted string following the normal conventions for 
  6283.        writing string literals.  In particular, backslashes must be doubled. 
  6284.  
  6285.  For example, in the Stack class, to use the file stack.def as the 
  6286.  template-implementation file instead of stack.c, add the line: 
  6287.  
  6288.     #pragma implementation("stack.def")
  6289.  
  6290.  anywhere in the stack.h file. The compiler then looks for the 
  6291.  template-implementation file stack.def in the same directory as stack.h. 
  6292.  
  6293.  
  6294. ΓòÉΓòÉΓòÉ 11.4.2.2. Example of a Template-Include File ΓòÉΓòÉΓòÉ
  6295.  
  6296. The following example shows the information you would find in a typical 
  6297. template-include file generated by the compiler: 
  6298.  
  6299.   /*0000000000*/ #pragma sourcedir("c:\swearsee\src")  0
  6300.   /*0698421265*/ #include "c:\swearsee\src\list.h"    1
  6301.   /*0000000000*/ #include "c:\swearsee\src\list.c"    2
  6302.   /*0698414046*/ #include "c:\swearsee\src\mytype.h"   3
  6303.   /*0698414046*/ #include "c:\IBMCPP\INCLUDE\iostream.h" 4
  6304.   #pragma define(List<MyType>)             5
  6305.   ostream& operator<<(ostream&,List<MyType>);      6
  6306.   #pragma undeclared                  7
  6307.   int count(List<MyType>);               8
  6308.  
  6309.  0    This pragma ensures that the compiler will look for nested include files 
  6310.       in the directory containing the original source file, as required by the 
  6311.       VisualAge for C++ file inclusion rules. 
  6312.  
  6313.  1    The header file that corresponds to the template-include file. The number 
  6314.       in comments at the start of each #include line (for this line 
  6315.       /*0698421265*/) is a time stamp for the included file. The compiler uses 
  6316.       this number to determine if the template-include file is current or 
  6317.       should be recompiled. A time stamp containing only zeroes (0) as in line 
  6318.       2 means the compiler is to ignore the time stamp. 
  6319.  
  6320.  2    The template-implementation file that corresponds to the header file in 
  6321.       line 1 
  6322.  
  6323.  3    Another header file that the compiler requires to compile the 
  6324.       template-include file. All other header files that the compiler needs to 
  6325.       compile the template-include file are inserted at this point. 
  6326.  
  6327.  4    Another header file required by the compiler. It is referenced in the 
  6328.       function declaration in line 6. 
  6329.  
  6330.  5    The compiler inserts #pragma define directives to force the definition of 
  6331.       template classes. In this case, the class List<MyType> is to be defined 
  6332.       and its member functions are to be generated. 
  6333.  
  6334.  6    The operator<< function is a nonmember function that matched a template 
  6335.       declaration in the list.h file. The compiler inserts this declaration to 
  6336.       force the generation of the function definition. 
  6337.  
  6338.  7    The #pragma undeclared directive is used only by the compiler and only in 
  6339.       template-include files. All template functions that were explicitly 
  6340.       declared in at least one compilation unit appear before this line. All 
  6341.       template functions that were called, but never declared, appear after 
  6342.       this line. This division is necessary because the C++ rules for function 
  6343.       overload resolution treat declared and undeclared template functions 
  6344.       differently. 
  6345.  
  6346.  8    count is an example of a template function that was called but not 
  6347.       declared. The template declaration of the function must have been 
  6348.       contained in list.h, but the instance count(List<MyType>) was never 
  6349.       declared. 
  6350.  
  6351.  Note:  Although you can edit the template-include files, it is not normally 
  6352.  necessary or advisable to do so. 
  6353.  
  6354.  
  6355. ΓòÉΓòÉΓòÉ 11.4.3. Manually Structuring for Single Instantiation ΓòÉΓòÉΓòÉ
  6356.  
  6357. If you do not want to use the automatic instantiation method of generating 
  6358. template function definitions, you can structure your program in such a way 
  6359. that you define template functions directly in your compilation units. The 
  6360. advantages of this approach are: 
  6361.  
  6362.      Object files are smaller and compile times are shorter than they are when 
  6363.       you include defining templates everywhere. When you structure your code 
  6364.       manually for template instantiation, you avoid the potential problems 
  6365.       that automatic instantiation can cause, such as dependency on a 
  6366.       particular file system or file sharing problems. 
  6367.  
  6368.  There are also disadvantages to structuring your code manually for template 
  6369.  instantiation: 
  6370.  
  6371.      You have to do more work than for the other two methods.  You may have to 
  6372.       reorganize source files and create new compilation units. 
  6373.      You have to be aware of all of the instantiations of templates that are 
  6374.       required by the entire program. 
  6375.  
  6376.  Note:  It is recommended that you use the compiler's automatic instantiation 
  6377.  facility.  The manual structuring method described here is useful if you find 
  6378.  you cannot work around the limitations of the automatic instantiation method. 
  6379.  
  6380.  Use #pragma define directives to force the compiler to generate the necessary 
  6381.  definitions for all template classes used in other compilation units.  Use 
  6382.  explicit declarations of non-member template functions to force the compiler 
  6383.  to generate them. 
  6384.  
  6385.  To use the second method, include stack.h in all compilation units that use an 
  6386.  instance of the Stack class, but include stack.c in only one of the files. 
  6387.  Alternatively, if you know what instances of the Stack class are being used in 
  6388.  your program, you can define all of the instances in a single compilation 
  6389.  unit. For example: 
  6390.  
  6391.      #include "stack.h"
  6392.      #include "stack.c"
  6393.      #include "myclass.h"  // Definition of "myClass" class
  6394.      #pragma define(Stack<int,20>)
  6395.      #pragma define(Stack<myClass,100>)
  6396.  
  6397.  The #pragma define directive forces the definition of two instances of the 
  6398.  Stack class without creating any object of the class.  Because these instances 
  6399.  reference the member functions of that class, template function definitions 
  6400.  are generated for those functions. See the online Language Reference for more 
  6401.  information about the #pragma directive. 
  6402.  
  6403.  You can compile and link in one step or two, but you must use icc to invoke 
  6404.  the linker.  For example, to compile and link stack.cpp, you could use the 
  6405.  command: 
  6406.  
  6407.     icc stack.cpp
  6408.  
  6409.  or the commands: 
  6410.  
  6411.     icc /C stack.cpp
  6412.     icc /Tdp stack.obj
  6413.  
  6414.  Note that in the first example, the /Tdp was implicit because it is the 
  6415.  default for files with the extension .cpp. However, when linking files with 
  6416.  the extension .obj, the /Tdp option must be specified to inform the linker 
  6417.  that it is linking C++ objects. 
  6418.  
  6419.  When you use these methods, you may also need to specify the /Ft- option to 
  6420.  ensure that the compiler does not also automatically create the TEMPINC files 
  6421.  according to the automatic generation facility. 
  6422.  
  6423.  
  6424. ΓòÉΓòÉΓòÉ 12. Calling Conventions ΓòÉΓòÉΓòÉ
  6425.  
  6426. This chapter describes the calling conventions used by the VisualAge for C++ 
  6427. compiler for both C and C++: 
  6428.  
  6429.      _Optlink 
  6430.      _System 
  6431.      __stdcall 
  6432.      __cdecl 
  6433.  
  6434.  The _Optlink convention is specific to the VisualAge for C++ compiler and is 
  6435.  the fastest method of calling C or C++ functions or assembler routines, but it 
  6436.  is not standard for all Windows applications. The _Optlink calling convention 
  6437.  is described in more detail in _Optlink Calling Convention. There is no 
  6438.  _System calling convention, per se. Specifying _System linkage is synonymous 
  6439.  with specifying __stdcall _System linkage will be implemented the same as 
  6440.  __stdcall. But be careful, the compiler still considers the names to be 
  6441.  distinct and will commplain if you mix them. For example: 
  6442.  
  6443.    void _System f(void);
  6444.    void (__stdcall *fp)(void) = f;   /* error */
  6445.  
  6446.  You can specify a default calling convention for all functions within a 
  6447.  program using the options /Mp (for _Optlink), /Mt (for __stdcall), or /Mc(for 
  6448.  __cdecl). In a C program, the default applies to all functions that don't have 
  6449.  a linkage keyword or #pragma linkage applied to them. In a C++ program, the 
  6450.  default applies to all non-member functions declared as extern "C". If you 
  6451.  don't specify a default, _Optlink is assumed. 
  6452.  
  6453.  Note: 
  6454.  
  6455.    1. You cannot call a function using a different calling convention than the 
  6456.       one with which it is compiled. For example, if a function is compiled 
  6457.       with __cdecl linkage, you cannot later call it specifying _Optlink 
  6458.       linkage. 
  6459.  
  6460.    2. VisualAge for C++ does not allow functions that use the __stdcall calling 
  6461.       convention to have both the following characteristics: 
  6462.  
  6463.           No prototype 
  6464.           A variable number of arguments. 
  6465.  
  6466.       In particular, an unprototyped function that accepts a variable number of 
  6467.       arguments and uses the __stdcall calling convention will not link. This 
  6468.       is because __stdcall functions are referenced in OBJ files using a name 
  6469.       that is a combination of the function name and the amount of stack space 
  6470.       used by the parameters the function expects. Therefore, if one 
  6471.       compilation has defined it with a different amount of parameter storage 
  6472.       than another compilation unit, the two references to the function will 
  6473.       have different external function names. The linker will not be able to 
  6474.       resolve them. 
  6475.  
  6476.       Prototyped functions don't have this problem because the external name is 
  6477.       generated based on the prototype, which must be consistent across all 
  6478.       compilations. 
  6479.  
  6480.  
  6481. ΓòÉΓòÉΓòÉ 12.1. Using Linkage Keywords to Specify the Calling Convention ΓòÉΓòÉΓòÉ
  6482.  
  6483. In addition to using options to specify the calling convention for all of the 
  6484. functions in a program, you can also use linkage keywords to specify the 
  6485. calling convention for individual functions. The linkage keywords and their 
  6486. equivalent calling convention suboptions of /Mp, /Ms, /Mc, and /Mt are listed 
  6487. in the following table. 
  6488.  
  6489. In C, the linkage of a function or function pointer is given by: 
  6490.  
  6491.      the attached linkage keyword, if present, else 
  6492.      the command line option, if used, else 
  6493.      the default _Optlink linkage. 
  6494.  
  6495.  In C++, the linkage of a nonmember function or function pointer is given by: 
  6496.  
  6497.      the attached linkage keyword, if present, else 
  6498.      the command line option, if an extern "C" linkage specification is 
  6499.       present, else 
  6500.      any enclosing C++ linkage specification, if present, else 
  6501.      C++ linkage. 
  6502.  
  6503.  The linkage of a member function or pointer to member function is: 
  6504.  
  6505.      the attached linkage keyword, if present, else 
  6506.      C++ linkage. 
  6507.  
  6508.  Note that linkage specifications don't affect member functions. 
  6509.  
  6510.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  6511.   Γöé Table 4. Equivalent Linkage Keywords and Compiler Suboptions  Γöé
  6512.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6513.   Γöé C++ LINKAGE SPEC-  Γöé LINKAGE KEYWORD   Γöé EQUIVALENT COM-   Γöé
  6514.   Γöé IFICATION      Γöé           Γöé PILER SUBOPTION   Γöé
  6515.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6516.   Γöé extern "SYSTEM"   Γöé _System       Γöé /Ms         Γöé
  6517.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6518.   Γöé extern "OPTLINK"   Γöé _Optlink       Γöé /Mp (default)    Γöé
  6519.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6520.   Γöé extern "C"      Γöé _Optlink suboption  Γöé           Γöé
  6521.   Γöé           Γöé for /Mp,       Γöé           Γöé
  6522.   Γöé           Γöé _System suboption  Γöé           Γöé
  6523.   Γöé           Γöé for /Ms       Γöé           Γöé
  6524.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6525.   Γöé extern "C++"     Γöé _Optlink with    Γöé           Γöé
  6526.   Γöé           Γöé mangling, over-   Γöé           Γöé
  6527.   Γöé           Γöé loading, etc.    Γöé           Γöé
  6528.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6529.   Γöé extern "BUILTIN"   Γöé _BUILTIN       Γöé           Γöé
  6530.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6531.   Γöé extern "STDCALL"   Γöé __stdcall      Γöé /Mt         Γöé
  6532.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6533.   Γöé extern "CDECL"    Γöé __cdecl       Γöé /Mc         Γöé
  6534.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6535.  
  6536.  Note:  extern "C++" linkage functions use the _Optlink calling convention, but 
  6537.  they also have long internal names (called mangled names) that encode their 
  6538.  containing class name and parameter types. In addition, member functions also 
  6539.  have an implicit this parameter that refers to the object on which they are 
  6540.  invoked. This combination of _Optlink rules, name mangling, and the this 
  6541.  parameter is called C++ linkage, and it is considered distinct from _Optlink 
  6542.  alone. 
  6543.  
  6544.  In C programs, you can also use #pragma linkage for all but __stdcall and 
  6545.  __cdecl. However, you should use the calling convention keywords discussed 
  6546.  above rather than the pragma. Problems encountered when using #pragma linkage 
  6547.  include: 
  6548.  
  6549.      it does not exist in C++, so it can't be used in any headers that will be 
  6550.       used in C and C++. 
  6551.      it is difficult to mark function pointers with #pragma linkage, 
  6552.       especially if they are in structures or hidden behind arrays. 
  6553.      code which uses #pragma linkage tends to be less clear than code using 
  6554.       the other methods described earlier. 
  6555.  The following examples illustrate the drawbacks. 
  6556.  
  6557.   /* Defining a callback function using #pragma linkage */
  6558.   typedef int foo(void);
  6559.   #pragma linkage(foo, optlink)
  6560.   struct ss {
  6561.    int x;
  6562.    foo * callback;
  6563.   };
  6564.  
  6565.  Observe the improved clarity when the same code is written using keywords: 
  6566.  
  6567.   /* Defining a callback function using keywords */
  6568.   struct ss {
  6569.    int x;
  6570.    int (_Optlink * callback)(void);
  6571.   };
  6572.  
  6573.  See the User's Guide for more details on setting the calling convention and on 
  6574.  compiler options. For information about linkage keywords and #pragma linkage, 
  6575.  see the online Language Reference. 
  6576.  
  6577.  
  6578. ΓòÉΓòÉΓòÉ 12.2. _Optlink Calling Convention ΓòÉΓòÉΓòÉ
  6579.  
  6580. This is the default calling convention. It is an alternative to the _System 
  6581. convention that is normally used for calls to the operating system. It provides 
  6582. a faster call than the _System convention, while ensuring conformance to the 
  6583. ANSI and SAA language standards. 
  6584.  
  6585. You can explicitly give a function the _Optlink convention with the _Optlink 
  6586. keyword. 
  6587.  
  6588.      Features of _Optlink 
  6589.      Tips for Using _Optlink 
  6590.      General-Purpose Register Implications 
  6591.      Examples of Passing Parameters 
  6592.  
  6593.  
  6594. ΓòÉΓòÉΓòÉ 12.2.1. Features of _Optlink ΓòÉΓòÉΓòÉ
  6595.  
  6596.      Function names are prefixed with a leading ?. 
  6597.  
  6598.      Parameters are pushed from right to left onto the stack to allow for 
  6599.       varying length parameter lists without having to use hidden parameters. 
  6600.  
  6601.      The caller cleans up the parameters. 
  6602.  
  6603.      The general-purpose registers EBP, EBX, EDI, and ESI are preserved across 
  6604.       the call. 
  6605.  
  6606.      The general-purpose registers EAX, EDX, and ECX are not preserved across 
  6607.       the call. 
  6608.  
  6609.      Floating-point registers are not preserved across the call. 
  6610.  
  6611.      The three conforming parameters that are lexically leftmost (conforming 
  6612.       parameters are 1, 2, and 4-byte signed and unsigned integers, 
  6613.       enumerations, and all pointer types) are passed in EAX, EDX, and ECX, 
  6614.       respectively. 
  6615.  
  6616.      Up to four floating-point parameters (the lexically first four) are 
  6617.       passed in extended-precision format (80-bit) in the floating-point 
  6618.       register stack. 
  6619.  
  6620.      All other parameters are passed on the runtime stack. 
  6621.  
  6622.      Space for the parameters in registers is allocated on the stack, but the 
  6623.       parameters are not copied into that space. 
  6624.  
  6625.      Conforming return values, with the exception of 64-bit integers, are 
  6626.       returned in EAX. In the case of 64-bit integers, the most significant 32 
  6627.       bits are returned in EDX and the least significant 32 bits are returned 
  6628.       in EAX. 
  6629.  
  6630.      Floating-point return values are returned in extended-precision format in 
  6631.       the topmost register of the floating-point stack. 
  6632.  
  6633.      When you call external functions, the floating-point register stack 
  6634.       contains only valid parameter registers on entry and valid return values 
  6635.       on exit.  (When you call functions in the current compilation unit that 
  6636.       do not call any other functions, this state may not be true.) 
  6637.  
  6638.      Under some circumstances, the compiler will not use EBP to access 
  6639.       automatic and parameter values, thus increasing the efficiency of the 
  6640.       application. Whether it is used or not, EBP will not change across the 
  6641.       call. 
  6642.  
  6643.      Calls with aggregates returned by value pass a hidden first parameter 
  6644.       that is the address of a storage area determined by the caller. This area 
  6645.       becomes the returned aggregate.  The hidden pointer parameter is always 
  6646.       considered "nonconforming", and is not passed in a register.  The called 
  6647.       function must load it into EAX before returning. 
  6648.  
  6649.      The direction flag must be clear upon entry to functions and clear on 
  6650.       exit from functions.  The state of the other flags is ignored on entry to 
  6651.       a function and undefined on exit. 
  6652.  
  6653.      The compiler will not change the contents of the floating-point control 
  6654.       register.  If you want to change the control register contents for a 
  6655.       particular operation, save the contents before making the changes and 
  6656.       restore them after the operation. 
  6657.  
  6658.      In a prototyped function taking a variable number of parameters (that is, 
  6659.       one whose parameter list ends in an elipsis), only the parameters 
  6660.       preceding the elipsis are eligible to be passed in registers. 
  6661.  
  6662.  
  6663. ΓòÉΓòÉΓòÉ 12.2.2. Tips for Using _Optlink ΓòÉΓòÉΓòÉ
  6664.  
  6665. To obtain the best performance when using the _Optlink convention, follow these 
  6666. tips: 
  6667.  
  6668.      Prototype all function declarations for better performance. The C++ 
  6669.       language requires all functions to have prototypes. 
  6670.  
  6671.       Note:  All calls and functions must be prototyped consistently; that is, 
  6672.              functions declared more than once must have identical prototypes. 
  6673.              If prototyping is not consistent, the results will be undefined. 
  6674.  
  6675.      Place the conforming and floating-point parameters that are most heavily 
  6676.       used lexically leftmost in the parameter list so they will be considered 
  6677.       for registers first. If they are adjacent to each other, the preparation 
  6678.       of the parameter list will be faster. 
  6679.  
  6680.      If you have a parameter that is only used near the end of a function, put 
  6681.       it at or near the end of the parameter list. If all of your parameters 
  6682.       are only used near the end of functions, consider using __stdcall or 
  6683.       __cdecl linkages. 
  6684.  
  6685.      If you are passing structures by value, put them at the end of the 
  6686.       parameter list. 
  6687.  
  6688.      Avoid using variable arguments in nonprototype functions. This practice 
  6689.       results in undefined behavior under the ANSI C standard. 
  6690.  
  6691.      If you have a variable-length argument list, consider using __stdcall or 
  6692.       __cdecl linkage. It is faster in this situation. 
  6693.  
  6694.      Compile with optimization on by specifying /O+. 
  6695.  
  6696.  For additional tips on how to improve the performance of your program, see 
  6697.  Optimizing Your Program. 
  6698.  
  6699.  
  6700. ΓòÉΓòÉΓòÉ 12.2.3. General-Purpose Register Implications ΓòÉΓòÉΓòÉ
  6701.  
  6702. EAX, EDX, and ECX are used for the lexically first three conforming parameters 
  6703. with EAX containing the first parameter, EDX the second, and ECX the third. 
  6704. Four bytes of stack storage are allocated for each register parameter that is 
  6705. present, but the parameters exist only in the registers at the time of the 
  6706. call. 
  6707.  
  6708. If there is no prototype or an incomplete prototype for the function called, an 
  6709. eyecatcher is placed after the call instruction to tell the callee how the 
  6710. register parameters correspond to the stack storage mapped for them. Fully 
  6711. prototyped code never needs eyecatchers. 
  6712.  
  6713.  
  6714. ΓòÉΓòÉΓòÉ 12.2.3.1. Eyecatchers ΓòÉΓòÉΓòÉ
  6715.  
  6716. An eyecatcher is a recognizable sequence of bytes that tells unprototyped code 
  6717. which parameters are passed in which registers. Eyecatchers apply only to code 
  6718. without prototype statements. 
  6719.  
  6720. The eyecatcher instruction is placed after the call instruction for a 
  6721. nonprototype function. The choice of instruction for the eyecatcher relies on 
  6722. the fact that the TEST instruction does not modify the referenced register, 
  6723. meaning that the return register of the call instruction is not modified by the 
  6724. eyecatcher instruction. The absence of an eyecatcher in unprototyped code 
  6725. implies that there are no parameters in registers. (Note that this eyecatcher 
  6726. scheme does not allow the use of execute-only code segments.) 
  6727.  
  6728. The eyecatcher has the format: 
  6729.  
  6730.   TEST EAX, immed32
  6731.  
  6732. Note that the short-form binary encoding (A9) of TEST EAX must be used for the 
  6733. eyecatcher instruction. 
  6734.  
  6735. The 32-bit immediate operand is interpreted as a succession of 2-bit fields, 
  6736. each of which describes a register parameter or a 4-byte slot of stack memory. 
  6737. Because only one 32-bit read of the eyecatcher is made, only 24 bits of the 
  6738. immediate operand are loaded. The actual number of parameters that can be 
  6739. considered for registers is restricted to 12. 
  6740.  
  6741. Because of byte reversal, the bits that are loaded are the low-order 24 bits of 
  6742. the 32-bit immediate operand. The highest-order 2-bit field of the 24 bits 
  6743. analyzed corresponds to the lexically first parameter, while subsequent 
  6744. parameters correspond to the subsequent lower-order 2-bit fields. The meaning 
  6745. of the values of the fields is as follows: 
  6746.  
  6747.  Value     Meaning 
  6748.  
  6749.  00        This value indicates that there are no parameters remaining to be 
  6750.            put into registers, or that there are parameters that could be put 
  6751.            into registers but there are no registers remaining. It also 
  6752.            indicates the end of the eyecatcher. 
  6753.  
  6754.  01        The corresponding parameter is in a general-purpose register. The 
  6755.            leftmost field of this value has its parameter in EAX, the second 
  6756.            leftmost (if it exists) in EDX, and the third (if it exists) in ECX. 
  6757.  
  6758.  10        The corresponding parameter is in a floating-point register and has 
  6759.            8 bytes of stack reserved for it (that is, it is a double). ST(0), 
  6760.            ST(1), ST(2), and ST(3) contain the lexically-first four 
  6761.            floating-point parameters (fewer registers are used if there are 
  6762.            fewer floating-point parameters). ST(0) contains the lexically first 
  6763.            (leftmost 2-bit field of type 10 or 11) parameter, ST(1) the 
  6764.            lexically second parameter, and so on. 
  6765.  
  6766.  11        The corresponding parameter is in a floating-point register and has 
  6767.            16 bytes of stack reserved for it (that is, it is a long double). 
  6768.  
  6769.  
  6770. ΓòÉΓòÉΓòÉ 12.2.4. Examples of Passing Parameters ΓòÉΓòÉΓòÉ
  6771.  
  6772. The following examples have been provided for the purposes of illustration and 
  6773. clarity only.  They have not been optimized. These examples assume that you are 
  6774. familiar with programming in assembler. Note that, in each example, the stack 
  6775. grows toward the bottom of the page, and ESP always points to the top of the 
  6776. stack. 
  6777.  
  6778.      Passing Conforming Parameters to a Prototyped Routine 
  6779.      Passing Conforming Parameters to an Unprototyped Routine 
  6780.      Passing Floating-Point Parameters to a Prototyped Routine 
  6781.      Passing Floating-Point Parameters to an Unprototyped Routine 
  6782.      Passing and Returning Aggregates by Value to a Prototyped Routine 
  6783.      Passing and Returning Aggregates by Value to an Unprototyped Routine 
  6784.  
  6785.  
  6786. ΓòÉΓòÉΓòÉ 12.2.4.1. Passing Conforming Parameters to a Prototyped Routine ΓòÉΓòÉΓòÉ
  6787.  
  6788. The following example shows the code sequences and a picture of the stack for a 
  6789. call to the function foo: 
  6790.  
  6791.  
  6792.   long foo(char p1, short p2, long p3, long p4);
  6793.  
  6794.   short x;
  6795.   long y;
  6796.  
  6797.   y = foo('A', x, y+x, y);
  6798.  
  6799. Caller's code surrounding call: 
  6800.  
  6801.  
  6802.   PUSH   y      ; Push p4 onto the runtime stack
  6803.   SUB    ESP, 12   ; Allocate stack space for
  6804.             ;  register parameters
  6805.   MOV    AL, 'A'   ; Put p1 into AL
  6806.   MOV    DX,  x    ; Put p2 into DX
  6807.   MOVSX   ECX, DX   ; Sign-extend x to long
  6808.   ADD    ECX, y    ; Calculate p3 and put it into ECX
  6809.   CALL   FOO     ; Make call
  6810.  
  6811.  
  6812.        Stack Just After Call    Register Set Just After Call
  6813.  
  6814.       Γöé           Γöé      ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÉ
  6815.       Γöé  caller's Local   Γöé    EAX  Γöé  undefined  Γöé p1 Γöé
  6816.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  6817.       Γöé     p4      Γöé    EBX  Γöé  caller's EBX   Γöé
  6818.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  6819.       Γöé  Blank Slot For p3 Γöé    ECX  Γöé     p3   Γöé   Γöé
  6820.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  6821.       Γöé  Blank Slot For p2 Γöé    EDX  ΓöéundefinedΓöé   p2  Γöé
  6822.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöñ
  6823.       Γöé  Blank Slot For p1 Γöé    EDI  Γöé  caller's EDI   Γöé
  6824.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6825.       Γöé  caller's EIP    Γöé    ESI  Γöé  caller's ESI   Γöé
  6826.  ESPΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ      ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6827.  
  6828. Callee's prolog code: 
  6829.  
  6830.  
  6831.   PUSH   EBP            ; Save caller's EBP
  6832.   MOV    EBP, ESP         ; Set up callee's EBP
  6833.   SUB    ESP, callee's local size ; Allocate callee's Local
  6834.   PUSH   EBX            ; Save preserved registers -
  6835.   PUSH   EDI            ;  will optimize to save
  6836.   PUSH   ESI            ;  only registers callee uses
  6837.  
  6838.        Stack After Prolog     Register Set After Prolog
  6839.  
  6840.        Γöé          Γöé      ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÉ
  6841.        Γöé  caller's Local  Γöé    EAX Γöé   undefined Γöé p1 Γöé
  6842.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  6843.        Γöé     p4     Γöé    EBX Γöé    undefined   Γöé
  6844.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöñ
  6845.        Γöé Blank Slot For p3 Γöé    ECX Γöé      p3     Γöé
  6846.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöñ
  6847.        Γöé Blank Slot For p2 Γöé    EDX Γöéundefined Γöé  p2   Γöé
  6848.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöñ
  6849.        Γöé Blank Slot For p1 Γöé    EDI Γöé    undefined   Γöé
  6850.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6851.        Γöé  caller's EIP   Γöé    ESI Γöé    undefined   Γöé
  6852.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ      ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6853.        Γöé  caller's EBP   Γöé
  6854.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6855.        Γöé          Γöé
  6856.        .          .
  6857.        .  callee's Local  .
  6858.        .          .
  6859.        Γöé          Γöé
  6860.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6861.        Γöé   Saved EBX   Γöé
  6862.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6863.        Γöé   Saved EDI   Γöé
  6864.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6865.        Γöé   Saved ESI   Γöé
  6866.  ESPΓöÇΓöÇΓöÇ   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6867.  
  6868. Note:  The term undefined in registers EBX, EDI, and ESI refers to the fact 
  6869. that they can be safely overwritten by the code in foo. 
  6870.  
  6871. Callee's epilog code: 
  6872.  
  6873.  
  6874.   MOV    EAX, RetVal ; Put return value in EAX
  6875.   POP    ESI     ; Restore preserved registers
  6876.   POP    EDI
  6877.   POP    EBX
  6878.   MOV    ESP, EBP   ; Deallocate callee's local
  6879.   POP    EBP     ; Restore caller's EBP
  6880.   RET          ; Return to caller
  6881.  
  6882.  
  6883.        Stack After Epilog     Register Set After Epilog
  6884.  
  6885.        Γöé          Γöé       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÉ
  6886.        Γöé  caller's Local  Γöé    EAX  Γöé  ReturnΓöéValue  Γöé
  6887.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6888.        Γöé     p4     Γöé    EBX  Γöé  caller's EBX  Γöé
  6889.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6890.        Γöé Blank Slot For p3 Γöé    ECX  Γöé   undefined   Γöé
  6891.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6892.        Γöé Blank Slot For p2 Γöé    EDX  Γöé   undefined   Γöé
  6893.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöñ
  6894.        Γöé Blank Slot For p1 Γöé    EDI  Γöé  caller's EDI  Γöé
  6895.        Γöé          Γöé       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6896.  ESPΓöÇΓöÇΓöÇΓöÇ   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ    ESI  Γöé  caller's ESI  Γöé
  6897.                        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6898.  
  6899. Caller's code just after call: 
  6900.  
  6901.  
  6902.   ADD    ESP, 16    ; Remove parameters from stack
  6903.   MOV    y,  EAX   ; Use return value.
  6904.  
  6905.  
  6906.        Stack After Cleanup     Register Set After Cleanup
  6907.  
  6908.         Γöé         Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÉ
  6909.         Γöé caller's Local Γöé     EAX  Γöé  ReturnΓöéValue  Γöé
  6910.   ESPΓöÇΓöÇΓöÇΓöÇ   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6911.                      EBX  Γöé  caller's EBX  Γöé
  6912.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6913.                      ECX  Γöé   undefined   Γöé
  6914.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  6915.                      EDX  Γöé   undefined   Γöé
  6916.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöñ
  6917.                      EDI  Γöé  caller's EDI  Γöé
  6918.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6919.                      ESI  Γöé  caller's ESI  Γöé
  6920.                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  6921.  
  6922.  
  6923. ΓòÉΓòÉΓòÉ 12.2.4.2. Passing Conforming Parameters to an Unprototyped Routine ΓòÉΓòÉΓòÉ
  6924.  
  6925. This example differs from the previous one by providing: 
  6926.  
  6927.      An eyecatcher after the call to foo in the caller's code 
  6928.      The code necessary to perform the default widening rules required by ANSI 
  6929.      The instruction to clean up the parameters from the stack. 
  6930.  
  6931.  If foo were an ellipsis routine with fewer than three conforming parameters in 
  6932.  the invariant portion of its parameter list, it would also include the code to 
  6933.  interpret the eyecatchers in its prolog. 
  6934.  
  6935.     y = foo('A', x, y+x, y);
  6936.  
  6937.  Caller's code surrounding call: 
  6938.  
  6939.  
  6940.     PUSH   y         ; Push p4 onto the runtime stack
  6941.     SUB    ESP, 12      ; Allocate stack space for register parameters
  6942.     MOV    EAX, 00000041h  ; Put p1 into EAX (41 hex = A ASCII)
  6943.     MOVSX   EDX, x      ; Put p2 into EDX
  6944.     MOV    ECX, y      ; Load y to calculate p3
  6945.     ADD    ECX, x      ; Calculate p3 and put it into ECX
  6946.     CALL   FOO        ; Make call
  6947.     TEST   EAX, 00540000h  ; Eyecatcher indicating 3 general-purpose
  6948.                  ;  register parameters (see page Eyecatchers)
  6949.     ADD    ESP, 16      ; Clean up parameters after return
  6950.  
  6951.  
  6952. ΓòÉΓòÉΓòÉ 12.2.4.3. Passing Floating-Point Parameters to a Prototyped Routine ΓòÉΓòÉΓòÉ
  6953.  
  6954. The following example shows code sequences, runtime stack layouts, and 
  6955. floating-point register stack states for a call to the routine fred. For 
  6956. simplicity, the general-purpose registers are not shown. 
  6957.  
  6958.  
  6959.   double fred(float p1, double p2, long double p3, float p4, double p5);
  6960.  
  6961.   double a, b, c;
  6962.   float  d, e;
  6963.  
  6964.   a = b + fred(a, d, (long double)(a + c), e, c);
  6965.  
  6966. Caller's code up until call: 
  6967.  
  6968.  
  6969.   PUSH   2ND DWORD OF c    ; Push upper 4 bytes of c onto stack
  6970.   PUSH   1ST DWORD OF c    ; Push lower 4 bytes of c onto stack
  6971.   FLD   DWORD_PTR e      ; Load e into 80387, promotion
  6972.                 ;  requires no conversion code
  6973.   FLD   QWORD_PTR a      ; Load a to calculate p3
  6974.   FADD   ST(0), QWORD_PTR c  ; Calculate p3, result is long double
  6975.                 ;  from nature of 80387 hardware
  6976.   FLD   DWORD_PTR d      ; Load d, no conversion necessary
  6977.   FLD   QWORD_PTR a      ; Load a, demotion requires conversion
  6978.   FSTP   DWORD_PTR [EBP - T1] ; Store to a temp (T1) to convert to float
  6979.   FLD   DWORD_PTR [EBP - T1] ; Load converted value from temp (T1)
  6980.   SUB   ESP, 32        ; Allocate the stack space for
  6981.                 ;  parameter list
  6982.   CALL   FRED         ; Make call
  6983.  
  6984.  
  6985.       Stack Just After Call  Floating-point Register Set Just After Call
  6986.  
  6987.       Γöî           ΓöÉ       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  6988.       Γöé  caller's Local   Γöé   ST(7)  Γöé    Empty     Γöé
  6989.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6990.       Γöé Upper Dword of p5  Γöé   ST(6)  Γöé    Empty     Γöé
  6991.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6992.       Γöé Lower Dword of p5  Γöé   ST(5)  Γöé    Empty     Γöé
  6993.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6994.       Γöé Blank Dword for p4  Γöé   ST(4)  Γöé    Empty     Γöé
  6995.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6996.       Γöé    Four      Γöé   ST(3)  Γöé    p4 (e)    Γöé
  6997.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  6998.       Γöé    Blank     Γöé   ST(2)  Γöé   p3 (a + c)   Γöé
  6999.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7000.       Γöé    Dwords     Γöé   ST(1)  Γöé    p2 (d)    Γöé
  7001.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7002.       Γöé    for p3     Γöé   ST(0)  Γöé    p1 (a)    Γöé
  7003.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7004.       Γöé   Two Blank    Γöé
  7005.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ
  7006.       Γöé  Dwords for p2   Γöé
  7007.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7008.       Γöé Blank Dword for p1  Γöé
  7009.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7010.       Γöé   caller's EIP   Γöé
  7011.  ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7012.  
  7013. Callee's prolog code: 
  7014.  
  7015.  
  7016.   PUSH   EBP            ; Save caller's EBP
  7017.   MOV    EBP, ESP         ; Set up callee's EBP
  7018.   SUB    ESP, callee's local size ; Allocate callee's Local
  7019.   PUSH   EBX            ; Save preserved registers -
  7020.   PUSH   EDI            ;  will optimize to save
  7021.   PUSH   ESI            ;  only registers callee uses
  7022.  
  7023.        Stack After Prolog    80387 Register Set After Prolog
  7024.  
  7025.       Γöé           Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7026.       Γöé  caller's Local  Γöé    ST(7)  Γöé    Empty    Γöé
  7027.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7028.       Γöé Upper Dword of p5  Γöé    ST(6)  Γöé    Empty    Γöé
  7029.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ Γöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7030.       Γöé Lower Dword of p5  Γöé    ST(5)  Γöé    Empty    Γöé
  7031.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7032.       Γöé Blank Dword for p4 Γöé    ST(4)  Γöé    Empty    Γöé
  7033.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7034.       Γöé    Four     Γöé    ST(3)  Γöé    p4     Γöé
  7035.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ Γöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7036.       Γöé    Blank     Γöé    ST(2)  Γöé    p3     Γöé
  7037.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ Γöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7038.       Γöé    Dwords    Γöé    ST(1)  Γöé    p2     Γöé
  7039.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ Γöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7040.       Γöé    for p3    Γöé    ST(0)  Γöé    p1     Γöé
  7041.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7042.       Γöé   Two Blank    Γöé
  7043.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ Γöñ
  7044.       Γöé  Dwords for p2   Γöé
  7045.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7046.       Γöé Blank Dword for p1 Γöé
  7047.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7048.       Γöé   caller's EIP   Γöé
  7049.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7050.       Γöé   caller's EBP   Γöé
  7051.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7052.       Γöé           Γöé
  7053.       .           .
  7054.       .  callee's Local  .
  7055.       .           .
  7056.       Γöé           Γöé
  7057.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7058.       Γöé    Saved EBX   Γöé
  7059.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7060.       Γöé    Saved EDI   Γöé
  7061.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7062.       Γöé    Saved ESI   Γöé
  7063.  ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7064.  
  7065. Callee's epilog code: 
  7066.  
  7067.  
  7068.   FLD    RETVAL    ; Load return value onto floating-point stack
  7069.   POP    ESI     ; Restore preserved registers
  7070.   POP    EDI
  7071.   POP    EBX
  7072.   MOV    ESP, EBP   ; Deallocate callee's local
  7073.   POP    EBP     ; Restore caller's EBP
  7074.   RET          ; Return to caller
  7075.  
  7076.  
  7077.        Stack After Epilog    80387 Register Set After Epilog
  7078.  
  7079.       Γöé           Γöé       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7080.       Γöé  caller's Local   Γöé   ST(7)  Γöé    Empty    Γöé
  7081.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7082.       Γöé Upper Dword of p5  Γöé   ST(6)  Γöé    Empty    Γöé
  7083.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7084.       Γöé Lower Dword of p5  Γöé   ST(5)  Γöé    Empty    Γöé
  7085.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7086.       Γöé Blank Dword for p4  Γöé   ST(4)  Γöé    Empty    Γöé
  7087.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7088.       Γöé    Four      Γöé   ST(3)  Γöé    Empty    Γöé
  7089.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7090.       Γöé    Blank     Γöé   ST(2)  Γöé    Empty    Γöé
  7091.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7092.       Γöé    Dwords     Γöé   ST(1)  Γöé    Empty    Γöé
  7093.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7094.       Γöé    for p3     Γöé   ST(0)  Γöé  Return Value  Γöé
  7095.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7096.       Γöé   Two Blank    Γöé
  7097.       Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ
  7098.       Γöé  Dwords for p2   Γöé
  7099.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7100.       Γöé Blank Dword for p1  Γöé
  7101.  ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7102.  
  7103. Caller's code just after call: 
  7104.  
  7105.  
  7106.   ADD    ESP, 40    ; Remove parameters from stack
  7107.   FADD   QWORD_PTR b  ; Use return value
  7108.   FSTP   QWORD_PTR a  ; Store expression to variable a
  7109.  
  7110.        Stack After Cleanup    80387 Register Set After Cleanup
  7111.  
  7112.       Γöé         Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7113.       Γöé  caller's Local Γöé     ST(7)  Γöé    Empty     Γöé
  7114.       Γöé         Γöé        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7115.  ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ     ST(6)  Γöé    Empty     Γöé
  7116.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7117.                     ST(5)  Γöé    Empty     Γöé
  7118.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7119.                     ST(4)  Γöé    Empty     Γöé
  7120.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7121.                     ST(3)  Γöé    Empty     Γöé
  7122.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7123.                     ST(2)  Γöé    Empty     Γöé
  7124.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7125.                     ST(1)  Γöé    Empty     Γöé
  7126.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7127.                     ST(0)  Γöé   Return Value   Γöé
  7128.                        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7129.  
  7130.  
  7131. ΓòÉΓòÉΓòÉ 12.2.4.4. Passing Floating-Point Parameters to an Unprototyped Routine ΓòÉΓòÉΓòÉ
  7132.  
  7133. This example differs from the previous floating-point example by the presence 
  7134. of an eyecatcher after the call to fred in the caller's code and the code 
  7135. necessary to perform the default widening rules required by ANSI. 
  7136.  
  7137.  
  7138.   double a, b, c;
  7139.   float  d, e;
  7140.  
  7141.   a = b + fred(a, d, (long double)(a + c), e, c);
  7142.  
  7143. Caller's code up until call: 
  7144.  
  7145.  
  7146.   PUSH   2ND DWORD OF c    ; Push upper 4 bytes of c onto stack
  7147.   PUSH   1ST DWORD OF c    ; Push lower 4 bytes of c onto stack
  7148.   FLD   DWORD_PTR e      ; Load e into 80387, promotion
  7149.                 ;  requires no conversion code
  7150.   FLD   QWORD_PTR a      ; Load a to calculate p3
  7151.   FADD   ST(0), QWORD_PTR c  ; Calculate p3, result is long double
  7152.                 ;  from nature of 80387 hardware
  7153.   FLD   DWORD_PTR d      ; Load d, no conversion necessary
  7154.   FLD   QWORD_PTR a      ; Load a, no conversion necessary
  7155.   SUB   ESP, 40        ; Allocate the stack space for
  7156.                 ;  parameter list
  7157.   CALL   FRED         ; Make call
  7158.   TEST   EAX, 00ae0000h    ; Eyecatcher maps the register parameters
  7159.   ADD   ESP, 48        ; Clean up parameters from stack
  7160.  
  7161.  
  7162. ΓòÉΓòÉΓòÉ 12.2.4.5. Passing and Returning Aggregates by Value to a Prototyped Routine ΓòÉΓòÉΓòÉ
  7163.  
  7164. If an aggregate is passed by value, the following code sequences are produced 
  7165. for the caller and callee: 
  7166.  
  7167. 'C' Source:
  7168.  
  7169.   struct s_tag {
  7170.        long  a;
  7171.        float b;
  7172.        long  c;
  7173.        } x, y;
  7174.   long  z;
  7175.   double q;
  7176.  
  7177.   /* Prototype */
  7178.   struct s_tag bar(long lvar, struct s_tag aggr, float fvar);
  7179.   .
  7180.   .
  7181.   .
  7182.  
  7183.   /* Actual Call */
  7184.   y = bar(z, x, q);
  7185.   .
  7186.   .
  7187.   .
  7188.  
  7189.   /* callee */
  7190.   struct s_tag bar(long lvar, struct s_tag aggr, float fvar)
  7191.   {
  7192.    struct s_tag temp;
  7193.  
  7194.    temp.a = lvar + aggr.a + 23;
  7195.    temp.b = fvar - aggr.b;
  7196.    temp.c = aggr.c
  7197.  
  7198.    return temp;
  7199.   }
  7200.  
  7201. Caller's code up until call: 
  7202.  
  7203.  
  7204.   FLD   QWORD_PTR q      ; Load lexically first floating-point
  7205.                 ;  parameter to be converted
  7206.   FSTP   DWORD_PTR [EBP - T1] ; Convert to formal parameter type by
  7207.   FLD   DWORD_PTR [EBP - T1] ; Storing and loading from a temp (T1)
  7208.   SUB   ESP, 4        ; Allocate space for the floating-point
  7209.                 ;  register parameter
  7210.   PUSH   x.c          ; Push nonconforming parameters on
  7211.   PUSH   x.b          ;  stack
  7212.   PUSH   x.a          ;
  7213.   MOV   EAX, Z        ; Load lexically first conforming
  7214.                 ;  parameter into EAX
  7215.   SUB   ESP, 4        ; Allocate stack space for the first
  7216.                 ;  general-purpose register parameter.
  7217.   PUSH   addr y        ; Push hidden first parameter (address of
  7218.                 ;  return space)
  7219.   CALL   BAR
  7220.  
  7221.  
  7222.       Stack Just After Call   General-Purpose Registers Just After Call
  7223.  
  7224.      Γöé           Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÉ
  7225.      Γöé  caller's Local   Γöé     EAX  Γöé     z     Γöé
  7226.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  7227.      Γöé Blank Slot for q   Γöé     EBX  Γöé  caller's EBX  Γöé
  7228.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  7229.      Γöé     x.c      Γöé     ECX  Γöé   undefined   Γöé
  7230.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöñ
  7231.      Γöé     x.b      Γöé     EDX  Γöé   undefined   Γöé
  7232.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöñ
  7233.      Γöé     x.a      Γöé     EDI  Γöé  caller's EDI  Γöé
  7234.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7235.      Γöé Blank Slot for z   Γöé     ESI  Γöé  caller's ESI  Γöé
  7236.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7237.      Γöé Hidden Ret Val Addr Γöé
  7238.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7239. ESPΓöÇΓöÇΓöÇΓöÇΓöÇ Γöé   caller's EIP   Γöé
  7240.      ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7241.  
  7242.         Floating-point Register Set Just After Call
  7243.  
  7244.              ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7245.          ST(7)  Γöé    Empty    Γöé
  7246.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7247.          ST(6)  Γöé    Empty    Γöé
  7248.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7249.          ST(5)  Γöé    Empty    Γöé
  7250.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7251.          ST(4)  Γöé    Empty    Γöé
  7252.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7253.          ST(3)  Γöé    Empty    Γöé
  7254.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7255.          ST(2)  Γöé    Empty    Γöé
  7256.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7257.          ST(1)  Γöé    Empty    Γöé
  7258.              Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7259.          ST(0)  Γöé fvar [(float)q]  Γöé
  7260.              ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7261.  
  7262. Callee's prolog code: 
  7263.  
  7264.  
  7265.   PUSH   EBP      ; Save caller's EBP
  7266.   MOV    EBP, ESP   ; Set up callee's EBP
  7267.   SUB    ESP, 12    ; Allocate callee's Local
  7268.              ;  = sizeof(struct s_tag)
  7269.   PUSH   EBX      ; Save preserved registers -
  7270.   PUSH   EDI      ;  will optimize to save
  7271.   PUSH   ESI      ;  only registers callee uses
  7272.  
  7273.       Stack After Prolog        Register Set After Prolog
  7274.  
  7275.      Γöé           Γöé       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÉ
  7276.      Γöé   caller's Local  Γöé     EAX  Γöé   lvarΓöé(z)    Γöé
  7277.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7278.      Γöé  Blank Slot for q  Γöé     EBX  Γöé  caller's EBX   Γöé
  7279.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7280.      Γöé     x.c     Γöé     ECX  Γöé   undefined   Γöé
  7281.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7282.      Γöé     x.b     Γöé     EDX  Γöé   undefined   Γöé
  7283.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöñ
  7284.      Γöé     x.a     Γöé     EDI  Γöé  caller's EDI   Γöé
  7285.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7286.      Γöé  Blank Slot for z  Γöé     ESI  Γöé  caller's ESI   Γöé
  7287.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7288.      Γöé Hidden Ret Val Addr Γöé
  7289.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ     The term undefined
  7290.      Γöé   caller's EIP   Γöé     in registers ECX and EDX
  7291.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ     refers to the fact that they
  7292.      Γöé   caller's EBP   Γöé     can be safely overwritten by
  7293.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ     the code in bar.
  7294.      Γöé           Γöé
  7295.      .           .
  7296.      .   callee's Local  .
  7297.      .           .   Floating-point Register Set Just After Call
  7298.      Γöé           Γöé
  7299.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7300.      Γöé    Saved EBX   Γöé    ST(7)  Γöé    Empty     Γöé
  7301.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7302.      Γöé    Saved EDI   Γöé    ST(6)  Γöé    Empty     Γöé
  7303.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7304.      Γöé    Saved ESI   Γöé    ST(5)  Γöé    Empty     Γöé
  7305. ESPΓöÇΓöÇΓöÇΓöÇΓöÇ Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7306.                     ST(4)  Γöé    Empty     Γöé
  7307.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7308.                     ST(3)  Γöé    Empty     Γöé
  7309.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7310.                     ST(2)  Γöé    Empty     Γöé
  7311.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7312.                     ST(1)  Γöé    Empty     Γöé
  7313.                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7314.                     ST(0)  Γöé  fvar [(float)q]  Γöé
  7315.                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7316.  
  7317. Callee's code: 
  7318.  
  7319.  
  7320.   temp.a = lvar + aggr.a + 23;
  7321.   temp.b = fvar - aggr.b;
  7322.   temp.c = aggr.c
  7323.  
  7324.   return temp;
  7325.  
  7326.   ADD    EAX, 23        ;
  7327.   ADD    EAX, [EBP + 16]    ; Calculate temp.a
  7328.   MOV    [EBP - 12], EAX    ;
  7329.  
  7330.   FSUB    DWORD_PTR [EBP + 20]  ; Calculate temp.b
  7331.   FSTP    DWORD_PTR [EBP - 8]  ;
  7332.  
  7333.   MOV    EAX, [EBP + 24]    ; Calculate temp.c
  7334.   MOV    [EBP - 4], EAX     ;
  7335.  
  7336.   MOV    EAX, [EBP + 8]     ; Load hidden parameter (address
  7337.                   ;  of return value storage). Useful
  7338.                   ;  both for setting return value
  7339.                   ;  and for returning address in EAX.
  7340.  
  7341.   MOV    EBX, [EBP - 12]    ; Return temp by copying its contents
  7342.   MOV    [EAX], EBX       ;  to the return value storage
  7343.   MOV    EBX, [EBP - 8]     ;  addressed by the hidden parameter.
  7344.   MOV    [EAX + 4], EBX     ;  String move instructions would be
  7345.   MOV    EBX, [EBP - 4]     ;  faster above a certain threshold
  7346.   MOV    [EAX + 8], EBX     ;  size of returned aggregate.
  7347.  
  7348.   POP    ESI          ; Begin Epilog by restoring
  7349.   POP    EDI          ;  preserved registers.
  7350.   POP    EBX
  7351.   MOV    ESP, EBP        ; Deallocate callee's local
  7352.   POP    EBP          ; Restore caller's EBP
  7353.   RET               ; Return to caller
  7354.  
  7355.        Stack After Epilog    General-Purpose Registers After Epilog
  7356.  
  7357.       Γöé          Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7358.       Γöé  caller's Local  Γöé      EAX  Γöé Addr of Return Value Γöé
  7359.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7360.       Γöé Blank Slot for q  Γöé      EBX  Γöé   caller's EBX    Γöé
  7361.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7362.       Γöé     x.c     Γöé      ECX  Γöé    undefined    Γöé
  7363.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7364.       Γöé     x.b     Γöé      EDX  Γöé    undefined    Γöé
  7365.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7366.       Γöé     x.a     Γöé      EDI  Γöé   caller's EDI    Γöé
  7367.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7368.       Γöé Blank Slot for z  Γöé      ESI  Γöé   caller's ESI    Γöé
  7369.       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7370.       Γöé Hidden Return   Γöé
  7371.       Γöé  Value Address   Γöé
  7372. ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7373.  
  7374.    80387 Register Set After Epilog
  7375.  
  7376.        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7377.    ST(7)  Γöé    Empty    Γöé
  7378.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7379.    ST(6)  Γöé    Empty    Γöé
  7380.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7381.    ST(5)  Γöé    Empty    Γöé
  7382.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7383.    ST(4)  Γöé    Empty    Γöé
  7384.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7385.    ST(3)  Γöé    Empty    Γöé
  7386.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7387.    ST(2)  Γöé    Empty    Γöé
  7388.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7389.    ST(1)  Γöé    Empty    Γöé
  7390.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7391.    ST(0)  Γöé    Empty    Γöé
  7392.        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7393.  
  7394. Caller's code just after call: 
  7395.  
  7396.  
  7397.   ADD   ESP, 24    ; Remove parameters from stack
  7398.   ...         ; Because address of y was given as the
  7399.             ;  hidden parameter, the assignment of the
  7400.             ;  return value has already been performed.
  7401.  
  7402.        Stack After Cleanup    General-Purpose Registers After Cleanup
  7403.  
  7404.       Γöé         Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7405.       Γöé  caller's Local Γöé      EAX  Γöé Addr of Return Value Γöé
  7406.  ESPΓöÇΓöÇΓöÇΓöÇΓöÇ  ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7407.                      EBX  Γöé   caller's EBX    Γöé
  7408.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7409.   80387 Register Set After Cleanup   ECX  Γöé   undefined     Γöé
  7410.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7411.        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ     EDX  Γöé   undefined     Γöé
  7412.    ST(7)  Γöé    Empty    Γöé        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7413.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ     EDI  Γöé   caller's EDI    Γöé
  7414.    ST(6)  Γöé    Empty    Γöé        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7415.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ     ESI  Γöé   caller's ESI    Γöé
  7416.    ST(5)  Γöé    Empty    Γöé        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7417.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7418.    ST(4)  Γöé    Empty    Γöé
  7419.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7420.    ST(3)  Γöé    Empty    Γöé
  7421.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7422.    ST(2)  Γöé    Empty    Γöé
  7423.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7424.    ST(1)  Γöé    Empty    Γöé
  7425.        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7426.    ST(0)  Γöé    Empty    Γöé
  7427.        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7428.  
  7429. If a y.a = bar(x).b construct is used instead of the more common y = bar(x) 
  7430. construct, the address of the return value is available in EAX. In this case, 
  7431. the address of the return value (hidden parameter) would point to a temporary 
  7432. variable allocated by the compiler in the automatic storage of the caller. 
  7433.  
  7434.  
  7435. ΓòÉΓòÉΓòÉ 12.2.4.6. Passing and Returning Aggregates by Value to an Unprototyped Routine ΓòÉΓòÉΓòÉ
  7436.  
  7437. This example differs from the previous one by the presence of an eyecatcher 
  7438. after the call to bar in the caller's code and the code necessary to perform 
  7439. the default widening rules required by ANSI. 
  7440.  
  7441.   struct s_tag {
  7442.        long  a;
  7443.        float b;
  7444.        long  c;
  7445.        } x, y;
  7446.   long  z;
  7447.   double q;
  7448.  
  7449.   /* Actual Call */
  7450.   y = bar(z, x, q);
  7451.   ...
  7452.  
  7453.   /* callee */
  7454.   struct s_tag bar(long lvar, struct s_tag aggr, float fvar)
  7455.   {
  7456.    struct s_tag temp;
  7457.  
  7458.    temp.a = lvar + aggr.a + 23;
  7459.    temp.b = fvar - aggr.b;
  7460.    temp.c = aggr.c
  7461.  
  7462.    return temp;
  7463.   }
  7464.  
  7465. Caller's code up until call: 
  7466.  
  7467.  
  7468.   FLD   QWORD_PTR q      ; Load lexically first floating-point
  7469.                 ;  parameter to be converted
  7470.   SUB   ESP, 8        ; Allocate space for the floating-point
  7471.                 ;  register parameter
  7472.   PUSH   x.c          ; Push nonconforming parameters on
  7473.   PUSH   x.b          ;  stack
  7474.   PUSH   x.a          ;
  7475.   MOV   EAX, z        ; Load lexically first
  7476.                 ;  conforming parameter
  7477.                 ;  into EAX
  7478.   SUB   ESP, 4        ; Allocate stack space for the first
  7479.                 ;  general-purpose register parameter.
  7480.   PUSH   addr y        ; Push hidden first parameter (address of
  7481.                 ;  return space)
  7482.   CALL   BAR
  7483.   TEST   EAX, 00408000h    ; Eyecatcher
  7484.   ADD   ESP, 28        ; Clean up parameters
  7485.  
  7486.       Stack Just After Call   General-Purpose Registers Just After Call
  7487.  
  7488.      Γöé           Γöé       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÉ
  7489.      Γöé   caller's Local  Γöé     EAX  Γöé     z     Γöé
  7490.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7491.      Γöé    Two Blank   Γöé     EBX  Γöé  caller's EBX   Γöé
  7492.      Γö£ΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöÇ ΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7493.      Γöé   Dwords for q   Γöé     ECX  Γöé    Garbage    Γöé
  7494.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöñ
  7495.      Γöé     x.c     Γöé     EDX  Γöé    Garbage    Γöé
  7496.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöñ
  7497.      Γöé     x.b     Γöé     EDI  Γöé  caller's EDI   Γöé
  7498.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7499.      Γöé     x.a     Γöé     ESI  Γöé  caller's ESI   Γöé
  7500.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ       ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7501.      Γöé  Blank Slot for z  Γöé
  7502.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7503.      Γöé Hidden Ret Val Addr Γöé  Floating-point Register Set Just After Call
  7504.      Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7505.      Γöé   caller's EIP   Γöé       ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  7506. ESPΓöÇΓöÇΓöÇΓöÇΓöÇ ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ    ST(7)  Γöé    Empty    Γöé
  7507.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7508.                     ST(6)  Γöé    Empty    Γöé
  7509.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7510.                     ST(5)  Γöé    Empty    Γöé
  7511.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7512.                     ST(4)  Γöé    Empty    Γöé
  7513.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7514.                     ST(3)  Γöé    Empty    Γöé
  7515.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7516.                     ST(2)  Γöé    Empty    Γöé
  7517.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7518.                     ST(1)  Γöé    Empty    Γöé
  7519.                        Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7520.                     ST(0)  Γöé  fvar [(float)q]  Γöé
  7521.                        ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  7522.  
  7523.  
  7524. ΓòÉΓòÉΓòÉ 12.3. __stdcall Calling Convention ΓòÉΓòÉΓòÉ
  7525.  
  7526. To use this linkage convention, use the __stdcall keyword in the declaration of 
  7527. the function. You can make __stdcall the default linkage by specifying the /Mt 
  7528. option when you invoke the compiler. There is no #pragma linkage for this 
  7529. convention. 
  7530.  
  7531. The following rules apply to the __stdcall calling convention: 
  7532.  
  7533.      All parameters are passed on the stack. 
  7534.  
  7535.      The parameters are pushed onto the stack in a lexical right-to-left 
  7536.       order. 
  7537.  
  7538.      The called function removes the parameters from the stack. 
  7539.  
  7540.      Floating point values are returned in ST(0), the top register of the 
  7541.       floating point register stack. Functions returning non-floating point 
  7542.       values return them as follows: 
  7543.  
  7544.       Size of Aggregate      Value Returned in 
  7545.       8 bytes                EAX-EDX pair 
  7546.       5, 6, 7 bytes          EAX The address to place the return values is 
  7547.                              passed as a hidden parameter in EAX. 
  7548.       4 bytes                EAX 
  7549.       3 bytes                EAX The address to place the return values is 
  7550.                              passed as a hidden parameter to EAX. 
  7551.       2 bytes                AX 
  7552.       1 byte                 AL 
  7553.  
  7554.       * For functions that return aggregates 5, 6, 7 or more than 8 bytes in 
  7555.       size, the address to place the return values in is placed as a hidden 
  7556.       parameter and the address is passed back in EAX. 
  7557.  
  7558.      __stdcall has the restriction that an unprototyped __stdcall function 
  7559.       with a variable number of arguments will not work. 
  7560.  
  7561.      Function names are decorated with an underscore prefix, and a suffix 
  7562.       which consists of an at (@), followed by the number of bytes of 
  7563.       parameters (in decimal). Parameters of less than four bytes are rounded 
  7564.       up to four bytes. Structure sizes are also rounded up to a multiple of 
  7565.       four bytes. For example, a function fred prototyped as follows: 
  7566.  
  7567.              int fred(int, int, short);
  7568.  
  7569.       would appear as: 
  7570.  
  7571.              _fred@12
  7572.  
  7573.       in the object module. 
  7574.  
  7575.  Note:  When building export lists in DEF files, the decorated version of the 
  7576.  name should be used. This is automatically handled when using #pragma export. 
  7577.  If you use undecorated names in the DEF file, you must give the object files 
  7578.  to ILIB along with the DEF file. ILIB will use the object files to determine 
  7579.  how each name ended up after decoration. 
  7580.  
  7581.  
  7582. ΓòÉΓòÉΓòÉ 12.3.1. Examples Using the __stdcall Convention ΓòÉΓòÉΓòÉ
  7583.  
  7584. The following examples are included for purposes of illustration and clarity 
  7585. only. They have not been optimized. The examples assume that you are familiar 
  7586. with programming in assembler. Note that, in the examples, the stack grows 
  7587. toward the bottom of the page, and ESP always points to the top of the stack. 
  7588.  
  7589. For the call 
  7590.  
  7591.   m = func(a,b,c);
  7592.  
  7593. a, b, and c are 32-bit integers and func has two local variables, x and y (both 
  7594. 32-bit integers). 
  7595.  
  7596. The stack for the call to func would look like this: 
  7597.  
  7598.                Stack
  7599.           Γöé             Γöé
  7600.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ    Higher Memory
  7601.           Γöé      c       Γöé
  7602.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7603.           Γöé      b       Γöé
  7604.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7605.           Γöé      a       Γöé
  7606.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7607.           Γöé   caller's EIP    Γöé
  7608.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7609.           Γöé   caller's EBP    Γöé
  7610.   EBP ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7611.           Γöé      x       Γöé
  7612.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7613.           Γöé      y       Γöé
  7614.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ  ΓöÇΓöÉ
  7615.           Γöé    Saved EDI     Γöé   Γöé
  7616.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ   Γöé These would only be
  7617.           Γöé    Saved ESI     Γöé   Γöé pushed if they were
  7618.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ   Γöé used in this function.
  7619.           Γöé    Saved EBX     Γöé   Γöé
  7620.   ESP ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ  ΓöÇΓöÿ
  7621.           Γöé             Γöé    Lower Memory
  7622.  
  7623. The instructions used to create this activation record on the stack look like 
  7624. this on the calling side: 
  7625.  
  7626.  
  7627.   PUSH   c
  7628.   PUSH   b
  7629.   PUSH   a
  7630.   CALL   func@12
  7631.     .
  7632.     .
  7633.   MOV   m, EAX
  7634.     .
  7635.     .
  7636.  
  7637. For the callee, the code looks like this: 
  7638.  
  7639. _func@12 PROC
  7640.   PUSH   EBP
  7641.   MOV   EBP, ESP    ;  Allocating 8 bytes of storage
  7642.   SUB   ESP, 8     ;  for two local variables.
  7643.   PUSH   EDI       ; These would only be
  7644.   PUSH   ESI       ;  pushed if they were used
  7645.   PUSH   EBX       ;  in this function.
  7646.   .
  7647.   .
  7648.   MOV   EAX, [EBP - 8]   ; Load y into EAX
  7649.   MOV   EBX, [EBP + 12]  ; Load b into EBX
  7650.   .
  7651.   .
  7652.   XOR   EAX, EAX      ; Zero the return value
  7653.   POP   EBX         ; Restore the saved registers
  7654.   POP   ESI
  7655.   POP   EDI
  7656.   LEAVE            ; Equivalent to  MOV  ESP, EBP
  7657.                ;         POP  EBP
  7658.   RET   0CH
  7659. _func@12 ENDP
  7660.  
  7661. The saved register set is EBX, ESI, and EDI. 
  7662.  
  7663. Structures are not returned on the stack. The caller pushes the address where 
  7664. the returned structure is to be placed as a lexically first hidden parameter. A 
  7665. function that returns a structure must be aware that all parameters are 4 bytes 
  7666. farther away from EBP than they would be if no structure return were involved. 
  7667. The address of the returned structure is returned in EAX. 
  7668.  
  7669. In the most common case, where the return from a function is simply assigned to 
  7670. a variable, the compiler merely pushes the address of the variable as the 
  7671. hidden parameter. For example: 
  7672.  
  7673.   struct test_tag {
  7674.        int a;
  7675.        int some_array[100];
  7676.        } test_struct;
  7677.  
  7678.   struct test_tag test_function@404(struct test_tag test_parm)
  7679.   {
  7680.    test_parm.a = 42;
  7681.    return test_parm;
  7682.   }
  7683.  
  7684.   int main(void)
  7685.   {
  7686.    test_struct = test_function@404(test_struct);
  7687.    return test_struct.a;
  7688.   }
  7689.  
  7690. The code generated for the above example would be: 
  7691.  
  7692.  
  7693. test_function@404 PROC
  7694.   PUSH   EBP
  7695.   MOV   EBP, ESP
  7696.   PUSH   ESI
  7697.   PUSH   EDI
  7698.   MOV   DWORD PTR [ESP+0cH], 02aH  ; test_parm.a
  7699.   MOV   EAX, [EBP+08H]        ; Get the target of the return value
  7700.   MOV   EDI, EAX           ; Value
  7701.   LEA   ESI, [EBP+0cH]        ; test_parm
  7702.   MOV   ECX, 065H
  7703.   REP MOVSD
  7704.   POP   EDI
  7705.   POP   ESI
  7706.   LEAVE
  7707.   RET   198H
  7708. test_function@404  ENDP
  7709.  
  7710.   PUBLIC  main
  7711. main  PROC
  7712.   PUSH   EBP
  7713.   MOV   EBP, ESP
  7714.   PUSH   ESI
  7715.   PUSH   EDI
  7716.  
  7717.   SUB   ESP, 0194H          ; Adjust the stack pointer
  7718.   MOV   EDI, ESP
  7719.   MOV   ESI, OFFSET FLAT: test_struct
  7720.   MOV   ECX, 065H
  7721.   REP MOVSD              ; Copy the parameter
  7722.   PUSH   OFFSET FLAT: test_struct   ; Push the address of the target
  7723.   CALL   TEST_FUNCTION&404
  7724.  
  7725.   MOV   EAX, DWORD PTR test_struct  ; Take care of the return
  7726.   POP   EDI             ;  from main
  7727.   POP   ESI
  7728.   LEAVE
  7729.   RET
  7730. main  ENDP
  7731.  
  7732.  
  7733. ΓòÉΓòÉΓòÉ 12.4. __cdecl Calling Convention ΓòÉΓòÉΓòÉ
  7734.  
  7735. To use this linkage convention, use the __cdecl keyword in the declaration of 
  7736. the function.  You can make __cdecl the default linkage by specifying the /Mc 
  7737. option when you invoke the linker.  There is no #pragma linkage for this 
  7738. convention. 
  7739.  
  7740. The following rules apply to the __cdecl calling convention: 
  7741.  
  7742.      All parameters are passed on the stack. 
  7743.  
  7744.      The parameters are pushed onto the stack in a lexical right-to-left 
  7745.       order. 
  7746.  
  7747.      The calling function removes the parameters from the stack. 
  7748.  
  7749.      Floating point values are returned in ST(0). All functions returning 
  7750.       non-floating point values return them in EAX, except for the special case 
  7751.       of returning aggregates less than or equal to four bytes in size. For 
  7752.       functions that return aggregates less than or equal to four bytes in 
  7753.       size, the values are returned as follows: 
  7754.  
  7755.       Size of Aggregate      Value Returned in 
  7756.       8 bytes                EAX-EDX pair 
  7757.       5, 6, 7 bytes          EAX The address to place return values is passed 
  7758.                              as a hidden parameter to EAX. 
  7759.       4 bytes                EAX 
  7760.       3 bytes                EAX The address to place return values is passed 
  7761.                              as a hidden parameter to EAX. 
  7762.       2 bytes                AX 
  7763.       1 byte                 AL 
  7764.  
  7765.       For functions that return aggregates 5, 6, 7 or more than 8 bytes in 
  7766.       size, the address to place the return values is passed as a hidden 
  7767.       parameter, and the address is passed back in EAX. 
  7768.  
  7769.      Function names are decorated with an underscore prefix when they appear 
  7770.       in object modules. For example, a function named fred in the source 
  7771.       program will appear as _fred in the object. 
  7772.  
  7773.  Note:  When building export or import lists in DEF files, the decorated 
  7774.  version of the name should be used. This is automatically handled when using 
  7775.  #pragma export. If you use undecorated names in the DEF file, you must give 
  7776.  the object files to ILIB along with the DEF file. ILIB will use the object 
  7777.  files to determine how each name ended up after decoration. 
  7778.  
  7779.  
  7780. ΓòÉΓòÉΓòÉ 12.4.1. Examples Using the __cdecl Convention ΓòÉΓòÉΓòÉ
  7781.  
  7782. The following examples are included for purposes of illustration and clarity 
  7783. only. They have not been optimized. The examples assume that you are familiar 
  7784. with programming in assembler. Note that, in the examples, the stack grows 
  7785. toward the bottom of the page, and ESP always points to the top of the stack. 
  7786.  
  7787. For the call 
  7788.  
  7789.   m = func(a,b,c);
  7790.  
  7791. a, b, and c are 32-bit integers and func has two local variables, x and y (both 
  7792. 32-bit integers). 
  7793.  
  7794. The stack for the call to func would look like this: 
  7795.  
  7796.                Stack
  7797.           Γöé             Γöé
  7798.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ    Higher Memory
  7799.           Γöé      c       Γöé
  7800.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7801.           Γöé      b       Γöé
  7802.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7803.           Γöé      a       Γöé
  7804.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7805.           Γöé   caller's EIP    Γöé
  7806.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7807.           Γöé   caller's EBP    Γöé
  7808.   EBP ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7809.           Γöé      x       Γöé
  7810.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  7811.           Γöé      y       Γöé
  7812.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ  ΓöÇΓöÉ
  7813.           Γöé    Saved EDI     Γöé   Γöé
  7814.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ   Γöé These would only be
  7815.           Γöé    Saved ESI     Γöé   Γöé pushed if they were
  7816.           Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ   Γöé used in this function.
  7817.           Γöé    Saved EBX     Γöé   Γöé
  7818.   ESP ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ  ΓöÇΓöÿ
  7819.           Γöé             Γöé    Lower Memory
  7820.  
  7821. The instructions used to create this activation record on the stack look like 
  7822. this on the calling side: 
  7823.  
  7824.  
  7825.   PUSH   c
  7826.   PUSH   b
  7827.   PUSH   a
  7828.   CALL   _func
  7829.     .
  7830.     .
  7831.   ADD   ESP, 12   ; Cleaning up the parameters
  7832.     .
  7833.     .
  7834.   MOV   m, EAX
  7835.     .
  7836.     .
  7837.  
  7838. For the callee, the code looks like this: 
  7839.  
  7840. _func PROC
  7841.   PUSH   EBP
  7842.   MOV   EBP, ESP    ;  Allocating 8 bytes of storage
  7843.   SUB   ESP, 08H    ;  for two local variables.
  7844.   PUSH   EDI       ; These would only be
  7845.   PUSH   ESI       ;  pushed if they were used
  7846.   PUSH   EBX       ;  in this function.
  7847.   .
  7848.   .
  7849.   MOV   EAX, [EBP - 8]   ; Load y into EAX
  7850.   MOV   EBX, [EBP + 12]  ; Load b into EBX
  7851.   .
  7852.   .
  7853.   XOR   EAX, EAX      ; Zero the return value
  7854.   POP   EBX         ; Restore the saved registers
  7855.   POP   ESI
  7856.   POP   EDI
  7857.   LEAVE            ; Equivalent to  MOV  ESP, EBP
  7858.                ;         POP  EBP
  7859.   RET
  7860. _func ENDP
  7861.  
  7862. The saved register set is EBX, ESI, and EDI. In the case where the structure is 
  7863. passed as a value parameter and the size of the structure is 5, 6, 7, or more 
  7864. than 8 bytes in size, the address to place the return values is passed as a 
  7865. hidden parameter, and the address passed back in EAX. 
  7866.  
  7867.   struct test_tag {
  7868.        int a;
  7869.        int some_array[100];
  7870.        } test_struct;
  7871.  
  7872.   struct test_tag __cdecl test_function(struct test_tag test_parm)
  7873.   {
  7874.    test_parm.a = 42;
  7875.    return test_parm;
  7876.   }
  7877.  
  7878.   int main(void)
  7879.   {
  7880.    test_struct = test_function(test_struct);
  7881.    return test_struct.a;
  7882.   }
  7883.  
  7884. The code generated for the above example would be: 
  7885.  
  7886.  
  7887. _test_function  PROC
  7888.   PUSH   EDI
  7889.   PUSH   ESI
  7890.   MOV   DWORD PTR [ESP+0cH], 02aH  ; test_parm.a
  7891.   MOV   EAX, [ESP+08H]        ; Get the target of the return value
  7892.   MOV   EDI, EAX           ; Value
  7893.   LEA   ESI, [ESP+0cH]        ; test_parm
  7894.   REP MOVSD
  7895.   POP   ESI
  7896.   POP   EDI
  7897.   RET
  7898. _test_function  ENDP
  7899.  
  7900.   PUBLIC  ?main
  7901. ?main  PROC
  7902.   PUSH   EBP
  7903.   MOV   EBP, ESP
  7904.   PUSH   ESI
  7905.   PUSH   EDI
  7906.  
  7907.   SUB   ESP, 0194H          ; Adjust the stack pointer
  7908.   MOV   EDI, ESP
  7909.   MOV   ESI, OFFSET FLAT:_test_struct
  7910.   MOV   ECX, 065H
  7911.   REP MOVSD              ; Copy the parameter
  7912.   PUSH   OFFSET FLAT:_test_struct   ; Push the address of the target
  7913.   CALL   _TEST_FUNCTION
  7914.   ADD   ESP,0198H
  7915.  
  7916.   MOV   EAX, DWORD PTR _test_struct  ; Take care of the return
  7917.   POP   EDI             ;  from main
  7918.   POP   ESI
  7919.   LEAVE
  7920.   RET
  7921. ?main  ENDP
  7922.  
  7923.  
  7924. ΓòÉΓòÉΓòÉ 13. Developing Subsystems ΓòÉΓòÉΓòÉ
  7925.  
  7926. A subsystem is a collection of code and/or data that can be shared across 
  7927. processes and that does not use the VisualAge for C++ runtime environment. This 
  7928. chapter describes how to create a subsystem. 
  7929.  
  7930. A subsystem may have code and data segments that are shared by all processes, 
  7931. or it may have separate segments for each process. If the subsystem is a DLL, 
  7932. there is also an initialization routine associated with it. 
  7933.  
  7934. By default, VisualAge for C++ compiler creates a runtime environment for you 
  7935. using C or C++ initializations, exception management, and termination. This 
  7936. environment allows runtime functions to perform input/output and other 
  7937. services. However, many applications require no runtime environment and must be 
  7938. written as subsystems. For example, you will want to turn off the runtime 
  7939. environment support to: 
  7940.  
  7941.      Reduce the size of the EXE. 
  7942.  
  7943.      Develop installable file system drivers 
  7944.  
  7945.      Create DLLs with global initialization/termination and a single automatic 
  7946.       data segment that is shared by all processes. The 
  7947.       initialization/termination function is called once when the DLL is first 
  7948.       loaded and once more when it is last freed. 
  7949.  
  7950.  
  7951. ΓòÉΓòÉΓòÉ 13.1. Creating a Subsystem ΓòÉΓòÉΓòÉ
  7952.  
  7953. To create a subsystem, you must first create one or more source files as you 
  7954. would for any other program. Subsystems can be written in C or C++. No special 
  7955. file extension is required. 
  7956.  
  7957. When you do not use the runtime environment, you must provide your own 
  7958. initialization functions, multithread support, exception handling, and 
  7959. termination functions. You can use Win32 APIs. For more information on the 
  7960. Win32 APIs, see the Windows operating system documentation. 
  7961.  
  7962. If you need to pass parameters to a subsystem executable module, the argv and 
  7963. argc command-line parameters to main are supported. However, you cannot use the 
  7964. envp parameter to main. 
  7965.  
  7966.  
  7967. ΓòÉΓòÉΓòÉ 13.1.1. Subsystem Library Functions ΓòÉΓòÉΓòÉ
  7968.  
  7969. The libraries CPPWN35.LIB and CPPWN35I.DLL are provided specifically for 
  7970. subsystem development. Use CPPWN35.LIB for static linking, and CPPWN35I.DLL for 
  7971. dynamic linking. The CPPWN35I.LIB and CPPWN35O.LIB libraries are also provided 
  7972. for dynamic linking. The CPPWN35I.LIB library contains only symbols that are 
  7973. exported from the DLL. The CPPWN35O.LIB library contains functions that are 
  7974. always statically linked (for example, startup code). 
  7975.  
  7976. You can also use the CPPWN35O.LIB library to create your own subsystem runtime 
  7977. DLL.  See Creating Your Own Subsystem Runtime Library DLLs for more information 
  7978. on creating subsystem runtime DLLs. 
  7979.  
  7980. Those VisualAge for C++ library functions that require a runtime environment 
  7981. cannot be used in a subsystem. The subsystem libraries contain the library 
  7982. functions that do not require a runtime environment, including the extensions 
  7983. that allow low-level I/O.  No other I/O functions are provided. 
  7984.  
  7985. With the exception of the memory allocation functions (calloc, malloc, realloc, 
  7986. and free), all of the functions in the subsystem libraries are reentrant. 
  7987.  
  7988. Note:  Although the low-level I/O functions defined in <io.h> are reentrant, 
  7989. you should serialize access to these functions within each file.  If you do not 
  7990. serialize the access, you may get unexpected input or output. 
  7991.  
  7992. The exception handling functions (throw, try and catch), the C Structured 
  7993. Exception Handling (SEH) functions (try, except, continue, and finally), and 
  7994. the C++ runtime functions (new and delete) and are all available for subsystem 
  7995. development. However, none of the Open Classes are available. 
  7996.  
  7997. There are three groups of functions that you can use in a subsystem: 
  7998.  
  7999.    1. The subsystem library functions listed below.  These functions are 
  8000.       available whether or not you have optimization turned on (/O+). 
  8001.  
  8002.    2. Built-in instrinsic functions.  These are listed in the C Library 
  8003.       Reference. These functions are also available whether or not you have 
  8004.       optimization turned on. 
  8005.  
  8006.    3. Other intrinsic functions. These are listed in the C Library Reference. 
  8007.       These functions are only available for use in a subsystem if optimization 
  8008.       is turned on. 
  8009.  
  8010.  The functions available in the subsystem libraries are: 
  8011.  
  8012.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  8013.   Γöé abort         Γöé __eof      Γöé qsort          Γöé _tell           Γöé
  8014.   Γöé abs          Γöé exit(2)     Γöé read          Γöé _uaddmem          Γöé
  8015.   Γöé access        Γöé _filelength   Γöé realloc         Γöé _ucalloc          Γöé
  8016.   Γöé atof         Γöé _fpreset     Γöé realloc         Γöé _uclose          Γöé
  8017.   Γöé atoi(1)        Γöé free       Γöé _set_crt_msg_handle   Γöé _ucreate          Γöé
  8018.   Γöé atol(1)        Γöé _heap_check   Γöé setjmp(3)        Γöé _udefault         Γöé
  8019.   Γöé atold         Γöé _heap_walk    Γöé _setmode        Γöé _udestroy         Γöé
  8020.   Γöé atoll         Γöé _heapchk     Γöé _sopen         Γöé _udump_allocated      Γöé
  8021.   Γöé bsearch        Γöé _heapmin     Γöé sprintf(4)       Γöé _udump_allocated_delta   Γöé
  8022.   Γöé calloc        Γöé _heapset     Γöé sscanf(4)        Γöé _uheap_check        Γöé
  8023.   Γöé chmod         Γöé isatty      Γöé _status87        Γöé _uheap_walk        Γöé
  8024.   Γöé _chsize        Γöé _itoa      Γöé strcat         Γöé _uheapchk         Γöé
  8025.   Γöé _clear87       Γöé labs       Γöé strchr         Γöé _uheapmin         Γöé
  8026.   Γöé close         Γöé llabs      Γöé strcmp         Γöé _uheapset         Γöé
  8027.   Γöé _control87      Γöé ldiv       Γöé strcpy         Γöé _ulltoa          Γöé
  8028.   Γöé creat         Γöé lldiv      Γöé strcspn         Γöé _ultoa           Γöé
  8029.   Γöé _debug_calloc     Γöé longjmp(3)    Γöé strdup         Γöé _umalloc          Γöé
  8030.   Γöé _debug_free      Γöé lseek      Γöé strncat         Γöé umask           Γöé
  8031.   Γöé _debug_heapmin    Γöé _ltoa      Γöé strncmp         Γöé _uopen           Γöé
  8032.   Γöé _debug_malloc     Γöé malloc      Γöé strncpy         Γöé _ustats          Γöé
  8033.   Γöé _debug_realloc    Γöé memchr      Γöé strpbrk         Γöé va_arg(5)         Γöé
  8034.   Γöé _debug_ucalloc    Γöé memcmp      Γöé strrchr         Γöé va_end(5)         Γöé
  8035.   Γöé _debug_uheapmin    Γöé memcpy      Γöé strspn         Γöé va_start(5)        Γöé
  8036.   Γöé _debug_umalloc    Γöé memmove     Γöé strstr         Γöé vprintf(4)         Γöé
  8037.   Γöé div          Γöé memset      Γöé strtol         Γöé vsprintf(4)        Γöé
  8038.   Γöé _dump_allocated_deltaΓöé _mheap      Γöé strtoul         Γöé write           Γöé
  8039.   Γöé _dump_allocated    Γöé _msize      Γöé strtoull        Γöé              Γöé
  8040.   Γöé dup          Γöé open       Γöé             Γöé              Γöé
  8041.   Γöé dup2         Γöé printf(4)    Γöé             Γöé              Γöé
  8042.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  8043.  
  8044.  Note: 
  8045.  
  8046.    1. The subsystem library versions of these functions do not use the locale 
  8047.       information that the standard library versions use. 
  8048.  
  8049.    2. atexit and _onexit are not provided. 
  8050.  
  8051.    3. When you use these functions in a subsystem, \n will be translated to 
  8052.       \r\n and WriteFile will be used to write the contents of the buffer to 
  8053.       stdout. There is no serialization protection and no multibyte support. 
  8054.       These functions use only the default "C" locale information. 
  8055.  
  8056.    4. These functions are implemented as macros. va_start is mapped to the 
  8057.       built-in __va_start, va_end is mapped to __va_arg, a library function, 
  8058.       and va_end is mapped to do-nothing. For portability, you MUST USE the 
  8059.       va_start, va_arg, and va_end versions. 
  8060.  
  8061.  
  8062. ΓòÉΓòÉΓòÉ 13.1.2. Calling Conventions for Subsystem Functions ΓòÉΓòÉΓòÉ
  8063.  
  8064. When creating a subsystem, you can use the __cdecl, __stdcall, _System (which 
  8065. defaults to __stdcall) or _Optlink calling convention for your functions. Any 
  8066. external functions that will be called from programs not compiled by the 
  8067. VisualAge for C++ compiler must use the __cdecl convention. 
  8068.  
  8069. You can use the /Mp, /Ms, /Mc, and Mt options (for _Optlink, __stdcall, 
  8070. __cdecl, and __stdcall, respectively) to specify the default calling convention 
  8071. for all functions in a program. You can use linkage keywords to specify the 
  8072. convention for individual functions. 
  8073.  
  8074.  
  8075. ΓòÉΓòÉΓòÉ 13.2. Building a Subsystem DLL ΓòÉΓòÉΓòÉ
  8076.  
  8077. To create a subsystem DLL, follow the steps described in Building Dynamic Link 
  8078. Libraries.  The steps are the same as for a DLL that uses the runtime 
  8079. environment. The steps to create a subsystem DLL, are the same as for a DLL 
  8080. that uses the runtime environment. 
  8081.  
  8082. The one difference between the two types of DLLs is the _DLL_InitTerm function. 
  8083. This function is the initialization and termination entry point for all DLLs. 
  8084. In the C runtime environment, _DLL_InitTerm initializes and terminates the 
  8085. necessary environment for the DLL, including storage, semaphores, and 
  8086. variables. The version provided in the subsystem libraries defines the entry 
  8087. point for the DLL, but provides no initialization or termination functions. 
  8088.  
  8089. If your subsystem DLL requires any initialization or termination, you will need 
  8090. to create your own _DLL_InitTerm function.  Otherwise, you can use the default 
  8091. version. 
  8092.  
  8093.  
  8094. ΓòÉΓòÉΓòÉ 13.2.1. Writing Your Own Subsystem _DLL_InitTerm Function ΓòÉΓòÉΓòÉ
  8095.  
  8096. The prototype for the _DLL_InitTerm function is: 
  8097.  
  8098.   unsigned long __stdcall _DLL_InitTerm(HINSTANCE hModule,
  8099.                DWORD ulFlag, LPVOID *dummy)    ;
  8100.  
  8101. The ulFlag variable indicates why the DLL entry point function is being called. 
  8102. If ulFlag==DLL_PROCESS_ATTACH, the DLL environment is initialized. For 
  8103. ulFlag==DLL_PROCESS_DETACH, the DLL environment is ended. This function is also 
  8104. called on thread creation and ends with parameter ulFlag equal to 
  8105. DLL_THREAD_ATTACH and DLL_THREAD_DETACH, respectively. Refer to the 
  8106. DLLEntryPoint in the Win32 API reference. 
  8107.  
  8108. The hModule parameter is the module handle assigned by the operating system for 
  8109. this DLL. The module handle can be used as a parameter to various Windows API 
  8110. calls.  For example, DosQueryModuleName can be used to return the fully 
  8111. qualified path name of the DLL, which tells you where the DLL was loaded from. 
  8112.  
  8113. The return code from _DLL_InitTerm tells the loader if the initialization or 
  8114. termination was performed successfully. If the call was successful, 
  8115. _DLL_InitTerm returns a nonzero value. A return code of 0 indicates that the 
  8116. function failed. If a failure is indicated, the loader will not load the 
  8117. program that is accessing the DLL. 
  8118.  
  8119. Because it is called by the operating system loader, the _DLL_InitTerm function 
  8120. must be declared as having the _System calling convention. 
  8121.  
  8122. You do not need to call _CRT_init and _CRT_term in your _DLL_InitTerm function, 
  8123. because there is no runtime environment to initialize or terminate. However, if 
  8124. you are using subsystem memory calls, use _rmem_init() or _rmem_term()). If you 
  8125. are coding in C++, you need to call __ctordtorInit at the beginning of 
  8126. _DLL_InitTerm to correctly initialize static constructors and destructors, and 
  8127. __ctordtorTerm at the end to correctly terminate them. 
  8128.  
  8129. If you change your DLL at a later time to use the regular runtime libraries, 
  8130. you must add calls to _CRT_init and _CRT_term , as described in Writing Your 
  8131. Own _DLL_InitTerm Function, to ensure that the runtime environment is correctly 
  8132. initialized. 
  8133.  
  8134.  
  8135. ΓòÉΓòÉΓòÉ 13.2.1.1. Example of a Subsystem _DLL_InitTerm Function ΓòÉΓòÉΓòÉ
  8136.  
  8137. The following example shows the _DLL_InitTerm function from the VisualAge for 
  8138. C++ sample for building subsystem DLLs. The source files plus a readme file for 
  8139. the sample can be accessed through the Guide to Samples notebook (if you 
  8140. installed the VisualAge for C++ samples and documentation) or directly via the 
  8141. \ibmcppw\samples\compiler\sample05 directory. The notebook can be accessed by 
  8142. opening the VisualAge for C++ program object in Program Manager. Open the 
  8143. notebook to the Components page. Select Compiler from the components list box, 
  8144. then select Subsystem Registration DLL from the samples list. Finally, click 
  8145. the Open Project View button. You will see the files in the upper portion of 
  8146. the project window. 
  8147.  
  8148. For information on how to build and debug a project, see the User's Guide. 
  8149. Alternatively, if you wish to compile, link, and run the sample from the 
  8150. command line, you will find a readme file with instructions. in the 
  8151. \ibmcppw\samples\compiler\sample05 directory along with the files needed. This 
  8152. _DLL_InitTerm function is included in the sample05.C source file. You could 
  8153. also make your _DLL_InitTerm function a separate file. Note that this figure 
  8154. shows only a fragment of SAMPLE05.C and not the entire source file. 
  8155.  
  8156.  
  8157. ΓòÉΓòÉΓòÉ 13.2.1.2. _DLL_InitTerm Function for SAMPLE05 ΓòÉΓòÉΓòÉ
  8158.  
  8159. /* _DLL_InitTerm() - called by the loader for DLL initialization/termination  */
  8160. /* This function must return a non-zero value if successful and a zero value  */
  8161. /* if unsuccessful.                              */
  8162.  
  8163. unsigned long __stdcall _DLL_InitTerm( HINSTANCE hModule,
  8164.                    DWORD ulFlag, LPVOID dummy)
  8165.   {
  8166.   ULONG rc;
  8167.  
  8168.   /* If ulFlag is DLL_PROCESS_ATTACH then initialization is required:     */
  8169.   /*   If the shared memory pointer is NULL then the DLL is being loaded   */
  8170.   /*   for the first time so acquire the named shared storage for the    */
  8171.   /*   process control structures.  A linked list of process control     */
  8172.   /*   structures will be maintained.  Each time a new process loads this  */
  8173.   /*   DLL, a new process control structure is created and it is inserted  */
  8174.   /*   at the end of the list by calling DLLREGISTER.            */
  8175.   /*                                     */
  8176.   /* If ulFlag is DLL_PROCESS_DETTACH then termination is required:      */
  8177.   /*   Call DLLDEREGISTER which will remove the process control structure  */
  8178.   /*   and free the shared memory block from its virtual address space.   */
  8179.  
  8180.   switch( ulFlag )
  8181.    {
  8182.    case DLL_PROCESS_ATTACH:
  8183.      _rmem_init();
  8184.      if ( !ulProcessCount )
  8185.       {
  8186.       /* Create the shared mutex semaphore.               */
  8187.  
  8188.       if (( hmtxSharedSem = CreateMutex(NULL,
  8189.                        FALSE,
  8190.                        SHARED_SEMAPHORE_NAME)) == NULL)
  8191.         {
  8192.         printf( "CreateMutex  rc = %lu\n", GetLastError() );
  8193.         return FALSE;
  8194.         }
  8195.       }
  8196.  
  8197.      /* Register the current process.                   */
  8198.  
  8199.      if ( DLLREGISTER( ) )
  8200.       return FALSE;
  8201.  
  8202.      break;
  8203.  
  8204.    case DLL_PROCESS_DETACH:
  8205.      /* De-register the current process.                  */
  8206.  
  8207.      if ( DLLDEREGISTER( ) )
  8208.       return 0;
  8209.  
  8210.      _rmem_term();
  8211.      break;
  8212.  
  8213.    default:
  8214.      return 0;
  8215.    }
  8216.  
  8217.   /* Indicate success.  Non-zero means success!!!               */
  8218.  
  8219.   return TRUE;
  8220.   }
  8221.  
  8222.  
  8223. ΓòÉΓòÉΓòÉ 13.3. Compiling Your Subsystem ΓòÉΓòÉΓòÉ
  8224.  
  8225. To compile your source files into a subsystem, use the /Rn compiler option. 
  8226. When you use this option, the compiler does not generate the external 
  8227. references that would build an environment. The subsystem libraries are also 
  8228. specified in each object file to be linked in at link time. The default 
  8229. compiler option is /Re, which creates an object with a runtime environment. 
  8230.  
  8231. If you are creating a subsystem DLL, you must use the /Ge- option in addition 
  8232. to /Rn. You can use either static linking (/Gd-), which is the default, or 
  8233. dynamic linking (/Gd+). 
  8234.  
  8235.  
  8236. ΓòÉΓòÉΓòÉ 13.4. Restrictions When You Are Using Subsystems ΓòÉΓòÉΓòÉ
  8237.  
  8238. If you are creating an executable module, the envp parameter to main is not 
  8239. supported. However, the argv and argc parameters are available.  See Passing 
  8240. Data to a Program for a description of envp under the runtime environment. 
  8241.  
  8242. The low-level I/O functions allow you to perform some input and output 
  8243. operations.  You are responsible for the buffering and formatting of I/O. 
  8244.  
  8245.  
  8246. ΓòÉΓòÉΓòÉ 13.5. Example of a Subsystem DLL ΓòÉΓòÉΓòÉ
  8247.  
  8248. The sample program SAMPLE05 shows how to create a simple subsystem DLL and a 
  8249. program to access it. 
  8250.  
  8251. The DLL keeps a global count of the number of processes that access it, running 
  8252. totals for each process that accesses the subsystem, and a grand total for all 
  8253. processes. There are two external entry points for programs accessing the 
  8254. subsystem. The first is DLLINCREMENT, which increments both the grand total and 
  8255. the total for the calling process by the amount passed in. The second entry 
  8256. point is DLLSTATS, which prints out statistics kept by the subsystem, including 
  8257. the grand total and the total for the current process. 
  8258.  
  8259. The grand total and the total for the process are stored in a single shared 
  8260. data segment of the subsystem. Each process total is stored in its own data 
  8261. segment. 
  8262.  
  8263. The files for the sample program are: 
  8264.  
  8265.  SAMPLE05.C    The source file to create the DLL. 
  8266.  
  8267.  SAMPLE05.DEF  The module definition file for the DLL. 
  8268.  
  8269.  SAMPLE05.H    The user include file. 
  8270.  
  8271.  MAIN05.C      The main program that accesses the subsystem. 
  8272.  
  8273.  MAIN05.DEF    The module definition file for MAIN05.C. 
  8274.  
  8275.  If you installed the Sample programs, you will find the SAMPLE05 project in 
  8276.  the VisualAge for C++ Samples folder. For information on how to build and 
  8277.  debug a project, see the User's Guide. Alternatively, if you wish to compile, 
  8278.  link, and run the sample from the command line, you will find a readme file 
  8279.  with instructions in the \ibmcppw\samples\compiler\sample05 directory along 
  8280.  with the files needed. 
  8281.  
  8282.  
  8283. ΓòÉΓòÉΓòÉ 13.6. Creating Your Own Subsystem Runtime Library DLLs ΓòÉΓòÉΓòÉ
  8284.  
  8285. If you are shipping your application to other users, you can use one of three 
  8286. methods to make the VisualAge for C++ subsystem library functions available to 
  8287. the users of your application: 
  8288.  
  8289.      Statically bind every module to the library (.LIB) files. 
  8290.  
  8291.       This method increases the size of your modules and also slows the 
  8292.       performance because the DLL environment has to be initialized for each 
  8293.       module. 
  8294.  
  8295.      Use the DLLRNAME utility to rename the VisualAge for C++ subsystem 
  8296.       library DLLs. 
  8297.  
  8298.       You can then ship the renamed DLLs with your application.  DLLRNAME is 
  8299.       described in the User's Guide. 
  8300.  
  8301.      Create your own runtime DLLs. 
  8302.  
  8303.       This method provides one common DLL environment for your entire 
  8304.       application.  It also lets you apply changes to the runtime library 
  8305.       without relinking your application, meaning that if the VisualAge for C++ 
  8306.       DLLs change, you need only rebuild your own DLL. In addition, you can 
  8307.       tailor your runtime DLL to contain only those functions you use, 
  8308.       including your own. 
  8309.  
  8310.  To create your own subsystem runtime library, follow these steps: 
  8311.  
  8312.    1. Copy and rename the VisualAge for C++ CPPWN35.DEF file, for example to 
  8313.       mysdll.def. You must also change the DLL name on the LIBRARY line of the 
  8314.       .DEF file. CPPWN35.DEF is installed in the LIB subdirectory under the 
  8315.       main VisualAge for C++ installation directory. 
  8316.  
  8317.    2. Remove any functions that you do not use directly or indirectly (through 
  8318.       other functions) from your .DEF file (mysdll.def), including the STUB 
  8319.       line. Do not delete anything with the comment **** next to it; variables 
  8320.       and functions indicated by this comment are used by startup functions and 
  8321.       are always required. 
  8322.  
  8323.    3. Create a source file for your DLL, for example, mysdll.c. If you are 
  8324.       creating a runtime library that contains only VisualAge for C++ 
  8325.       functions, create an empty source file.  If you are adding your own 
  8326.       functions to the library, put the code for them in this file. 
  8327.  
  8328.    4. Compile and link your DLL files.  Use the /Ge- option to create a DLL and 
  8329.       the /Rn option to create a subsystem.  For example: 
  8330.  
  8331.               icc /Ge- /Rn mysdll.c mysdll.def
  8332.  
  8333.    5. Use the ILIB utility to add the object modules that contain the 
  8334.       initialization and termination functions to your import library. These 
  8335.       objects are needed by all executable modules and DLLs, and are contained 
  8336.       in CPPWN35O.LIB for subsystem programs. See the User's Guide for 
  8337.       information on how to use ILIB. 
  8338.  
  8339.       Note:  If you do not use the ILIB utility, you must ensure that all 
  8340.       objects that access your runtime DLL are statically linked to the 
  8341.       appropriate object library.  The compile and link commands are described 
  8342.       in the next step. 
  8343.  
  8344.    6. Compile your executable modules and other DLLs with the /Gn+ option to 
  8345.       exclude the default library information. For example: 
  8346.  
  8347.               icc /C /Gn+ /Ge+ /Rn myprog.c
  8348.               icc /C /Gn+ /Ge- /Rn mydll.c
  8349.  
  8350.       When you link your objects, specify your own import library. For example: 
  8351.  
  8352.               ILINK myprog.obj mysdlli.lib KERNEL32.LIB
  8353.               ILINK mydll.obj mysdlli.lib KERNEL32.LIB /DEF mydll.exp
  8354.  
  8355.       To compile and link in one step, use the commands: 
  8356.  
  8357.               icc /Gn+ /Ge+ /Rn myprog.c mysdlli.exp KERNEL32.LIB
  8358.               icc /Gn+ /Ge- /Rn mydll.c mysdlli.exp KERNEL32.LIB
  8359.  
  8360.       Note:  If you did not use the ILIB utility to add the initialization and 
  8361.              termination objects to your import library, when you link your 
  8362.              modules, specify: 
  8363.  
  8364.         a. CPPWN35O.LIB 
  8365.         b. Your import library 
  8366.         c. The linker option /NOD. For example: 
  8367.  
  8368.             ILINK /NOD mydll.obj CPPWN35O.LIB mysdlli.lib KERNEL32.LIB /DLL mydll.exp;
  8369.  
  8370.       The /NOD option tells the linker to disregard the default libraries 
  8371.       specified in the object files and use only the libraries given on the 
  8372.       command line. If you are using icc to invoke the linker for you, the 
  8373.       commands would be: 
  8374.  
  8375.             icc /B /NOD /Rn myprog.c CPPWN35O.LIB mysdlli.lib
  8376.             icc /Ge- /B /NOD /Rn mydll.c CPPWN35O.LIB mysdlli.lib
  8377.  
  8378.       The linker then links the objects from the object library directly into 
  8379.       your executable module or DLL. 
  8380.  
  8381.  
  8382. ΓòÉΓòÉΓòÉ 14. Signal and Windows Exception Handling ΓòÉΓòÉΓòÉ
  8383.  
  8384. The VisualAge for C++ product and the Windows operating system both have the 
  8385. capability to detect and report runtime errors and abnormal conditions. 
  8386.  
  8387. Abnormal conditions can be reported to you and handled in one of the following 
  8388. ways: 
  8389.  
  8390.    1. Using VisualAge for C++ signal handlers. Error handling by signals is 
  8391.       defined by the SAA and ANSI C standards and can be used in both C and C++ 
  8392.       programs. 
  8393.  
  8394.    2. Using Windows exception handlers. The VisualAge for C++ library provides 
  8395.       a C-language Windows exception handler, _Exception, to map Windows 
  8396.       exceptions to C signals and signal handlers. Instead, you can create and 
  8397.       use your own exception handlers. 
  8398.  
  8399.    3. Using C++ exception handling constructs.  These constructs belong to the 
  8400.       C++ language definition and can only be used in C++ code. C++ exception 
  8401.       handling is described in detail in the Language Reference. 
  8402.  
  8403.    4. Structured Exception Handling in C programs. This allows you to use 
  8404.       C++-like try blocks to capture exceptions. For more detail on Structured 
  8405.       Exception Handling, see Structured Exception Handling. 
  8406.  
  8407.  This chapter describes how to use signal handlers and Windows exception 
  8408.  handlers alone and in combination. Where appropriate, the interaction between 
  8409.  C++ exception handling and the handling of signals and Windows exceptions is 
  8410.  also described. Both signal and Windows exception handling are implemented in 
  8411.  C++ as they are in C. The next chapter discusses Structured Exception handling 
  8412.  in C programs. 
  8413.  
  8414.  This chapter is only necessary for the advanced programming of exception 
  8415.  handling and not for simply debugging exception handling problems.  You should 
  8416.  use the debugger to debug exception handling problems as complete notification 
  8417.  and stack tracing is available through the debugger. For more information on 
  8418.  Windows exceptions and exception handlers, see the Windows operating system 
  8419.  documentation. 
  8420.  
  8421.  Note: 
  8422.  
  8423.    1. The terms signal, Windows exception, and C++ exception are not 
  8424.       interchangeable.  A signal exists only within the C and C++ languages. A 
  8425.       Windows exception is generated by the operating system, and may be used 
  8426.       by the VisualAge for C++ library to generate a signal. A C++ exception 
  8427.       exists only within the C++ language. In this chapter, the term exception 
  8428.       refers to an Windows exception unless otherwise specified. 
  8429.  
  8430.    2. VisualAge for C++ implements C++ exception handling using the Windows 
  8431.       exception handling facility. 
  8432.  
  8433.  
  8434. ΓòÉΓòÉΓòÉ 14.1. Using C++ and Windows Exception Handling in the Same Program ΓòÉΓòÉΓòÉ
  8435.  
  8436. You can make use of C++ exception handling facilities and the Windows exception 
  8437. handling facilities in the same program. In fact, VisualAge for C++ implements 
  8438. the C++ exception handling facilities using the Windows exception handling. You 
  8439. should always avoid using such an exception handler, but you should be 
  8440. particularly careful to avoid it in programs that use C++ exception handling 
  8441. because the results can be unpredictable. 
  8442.  
  8443.  
  8444. ΓòÉΓòÉΓòÉ 14.2. Handling Signals ΓòÉΓòÉΓòÉ
  8445.  
  8446. Signals are C and C++ language constructs provided for error handling. A signal 
  8447. is a condition reported as a result of an error in program execution. It may 
  8448. also be caused by deliberate programmer action. With the VisualAge for C++ 
  8449. product, operating system exceptions are mapped to signals for you. VisualAge 
  8450. for C++ provides a number of different symbols to differentiate between error 
  8451. conditions. The signal constants are defined in the <signal.h> header. 
  8452.  
  8453. C provides two functions that deal with signal handling in the runtime 
  8454. environment: raise and signal. Signals can be reported by an explicit call to 
  8455. raise, but are generally reported as a result of a machine interrupt (for 
  8456. example, division by zero), of a user action (for example, pressing Ctrl-C or 
  8457. Ctrl-Break), or of an operating system exception. 
  8458.  
  8459. Use the signal function to specify how to handle a particular signal. For each 
  8460. signal, you can specify one of 3 types of handlers: 
  8461.  
  8462.    1. SIG_DFL 
  8463.  
  8464.       Use the VisualAge for C++ default handling.  For most signals, the 
  8465.       default action is to terminate the process with an error message. See 
  8466.       Default Handling of Signals for a list of signals and the default action 
  8467.       for each. If the /Tx+ option is specified, the default action can be 
  8468.       accompanied by a dump of the machine state to file handle 2, which is 
  8469.       usually associated with stderr. Note that you can change the destination 
  8470.       of the machine-state dump and other messages using the 
  8471.       _set_crt_msg_handle function, which is described in the C Library 
  8472.       Reference. 
  8473.  
  8474.    2. SIG_IGN 
  8475.  
  8476.       Ignore the condition and continue running the program. Some signals 
  8477.       cannot be ignored, such as division by zero. If you specify SIG_IGN for 
  8478.       one of these signals, the VisualAge for C++ library will treat the signal 
  8479.       as if SIG_DFL was specified. 
  8480.  
  8481.    3. Your own signal handler function 
  8482.  
  8483.       Call the function you specify. It can be any function with __cdecl or 
  8484.       _Optlink linkage and can call any library function. Note that when the 
  8485.       signal is reported and your function is called, signal handling is reset 
  8486.       to SIG_DFL to prevent recursion should the same signal be reported from 
  8487.       your function. 
  8488.  
  8489.  The initial setting for all signals is SIG_DFL, the default action. 
  8490.  
  8491.  The signal and raise functions are described in more detail in the C Library 
  8492.  Reference. 
  8493.  
  8494.  
  8495. ΓòÉΓòÉΓòÉ 14.3. Default Handling of Signals ΓòÉΓòÉΓòÉ
  8496.  
  8497. The runtime environment will perform default handling of a given signal unless 
  8498. a specific signal handler is established or the signal is disabled (set to 
  8499. SIG_IGN). You can also set or reset default handling by coding: 
  8500.  
  8501.   signal(sig, SIG_DFL);
  8502.  
  8503. The default handling depends upon the signal that is being handled. For most 
  8504. signals, the default is to pass the signal to the next exception handler in the 
  8505. chain (the chaining of exception handlers is described in Registering a Windows 
  8506. Exception Handler). 
  8507.  
  8508. Unless you have set up your own exception handler, the default Windows 
  8509. exception handler receives the signal and performs the default action, which is 
  8510. to terminate the program and return an exit code. The exit code indicates: 
  8511.  
  8512.    1. The reason for the program termination. For the possible values and 
  8513.       meanings of the termination code, see CreateProcess in the Windows 
  8514.       operating system documentation. 
  8515.  
  8516.    2. The return code from ExitThread. For the ExitThread return codes, see the 
  8517.       Windows operating system documentation. 
  8518.  
  8519.  The following table lists the C signals that the VisualAge for C++ runtime 
  8520.  library supports, the source of the signal, and the default handling performed 
  8521.  by the library. 
  8522.  
  8523.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  8524.   Γöé Table 5. Default Handling of Signals              Γöé
  8525.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8526.   Γöé SIGNAL   Γöé SOURCE          Γöé DEFAULT ACTION      Γöé
  8527.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8528.   Γöé SIGABRT  Γöé Abnormal termination   Γöé Terminate the program  Γöé
  8529.   Γöé      Γöé signal sent by the    Γöé with exit code 3.    Γöé
  8530.   Γöé      Γöé "abort" function     Γöé             Γöé
  8531.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8532.   Γöé SIGBREAK  Γöé Ctrl-Break signal     Γöé Pass the signal to the  Γöé
  8533.   Γöé      Γöé              Γöé next exception handler  Γöé
  8534.   Γöé      Γöé              Γöé in the chain.  If the  Γöé
  8535.   Γöé      Γöé              Γöé exception handler is   Γöé
  8536.   Γöé      Γöé              Γöé the default Windows   Γöé
  8537.   Γöé      Γöé              Γöé handler, the program   Γöé
  8538.   Γöé      Γöé              Γöé terminates.       Γöé
  8539.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8540.   Γöé SIGFPE   Γöé Floating-point      Γöé Pass the signal to the  Γöé
  8541.   Γöé      Γöé exceptions that are not  Γöé next exception handler  Γöé
  8542.   Γöé      Γöé masked(**), such as    Γöé in the chain.  If the  Γöé
  8543.   Γöé      Γöé overflow, division by   Γöé exception handler is   Γöé
  8544.   Γöé      Γöé zero, integer math    Γöé the default Windows   Γöé
  8545.   Γöé      Γöé exceptions, and oper-   Γöé handler, the program   Γöé
  8546.   Γöé      Γöé ations that are not    Γöé terminates.       Γöé
  8547.   Γöé      Γöé valid           Γöé             Γöé
  8548.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8549.   Γöé SIGILL   Γöé Disallowed instruction  Γöé Pass the signal to the  Γöé
  8550.   Γöé      Γöé              Γöé next exception handler  Γöé
  8551.   Γöé      Γöé              Γöé in the chain.  If the  Γöé
  8552.   Γöé      Γöé              Γöé exception handler is   Γöé
  8553.   Γöé      Γöé              Γöé the default Windows   Γöé
  8554.   Γöé      Γöé              Γöé handler, the program   Γöé
  8555.   Γöé      Γöé              Γöé terminates.       Γöé
  8556.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8557.   Γöé SIGINT   Γöé Ctrl-C signal       Γöé Pass the signal to the  Γöé
  8558.   Γöé      Γöé              Γöé next exception handler  Γöé
  8559.   Γöé      Γöé              Γöé in the chain.  If the  Γöé
  8560.   Γöé      Γöé              Γöé exception handler is   Γöé
  8561.   Γöé      Γöé              Γöé the default Windows   Γöé
  8562.   Γöé      Γöé              Γöé handler, the program   Γöé
  8563.   Γöé      Γöé              Γöé terminates.       Γöé
  8564.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8565.   Γöé SIGSEGV  Γöé Attempt to access a    Γöé Pass the signal to the  Γöé
  8566.   Γöé      Γöé memory address that is  Γöé next exception handler  Γöé
  8567.   Γöé      Γöé not valid         Γöé in the chain.  If the  Γöé
  8568.   Γöé      Γöé              Γöé exception handler is   Γöé
  8569.   Γöé      Γöé              Γöé the default Windows   Γöé
  8570.   Γöé      Γöé              Γöé handler, the program   Γöé
  8571.   Γöé      Γöé              Γöé terminates.       Γöé
  8572.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8573.   Γöé SIGTERM  Γöé Program termination    Γöé Pass the signal to the  Γöé
  8574.   Γöé      Γöé signal sent by the user  Γöé next exception handler  Γöé
  8575.   Γöé      Γöé or operating system    Γöé in the chain.  If the  Γöé
  8576.   Γöé      Γöé              Γöé exception handler is   Γöé
  8577.   Γöé      Γöé              Γöé the default Windows   Γöé
  8578.   Γöé      Γöé              Γöé handler, the program   Γöé
  8579.   Γöé      Γöé              Γöé terminates.       Γöé
  8580.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8581.   Γöé SIGUSR1  Γöé User-defined signal    Γöé Ignored.         Γöé
  8582.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8583.   Γöé "SIGUSR2" Γöé User-defined signal    Γöé Ignored.         Γöé
  8584.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8585.   Γöé SIGUSR3  Γöé User-defined signal    Γöé Ignored.         Γöé
  8586.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  8587.  
  8588.  
  8589. ΓòÉΓòÉΓòÉ 14.4. Establishing a Signal Handler ΓòÉΓòÉΓòÉ
  8590.  
  8591. You can establish or register your own signal handler with a call to the signal 
  8592. function: 
  8593.  
  8594.   signal(sig, sig_handler);
  8595.  
  8596. where sig_handler is the address of your signal handling function. The signal 
  8597. handler is a C function that takes a single integer argument (or two arguments 
  8598. for SIGFPE), and may have either __cdecl or _Optlink linkage. 
  8599.  
  8600. A signal handler for a particular signal remains established until one of the 
  8601. following occurs: 
  8602.  
  8603.      A different handler is established for the same signal. 
  8604.  
  8605.      The signal is explicitly reset to the system default with the function 
  8606.       call  signal(sig, SIG_DFL). 
  8607.  
  8608.      The signal is reported. When your signal handler is called, the handling 
  8609.       for that signal is reset to the default as if the function call 
  8610.       signal(sig_num, SIG_DFL) were explicitly made immediately before the 
  8611.       registered handler is called. 
  8612.  
  8613.  Note:  A signal handler can also become deregistered if the load module where 
  8614.  the signal handler resides is deleted using the _freemod function. In this 
  8615.  situation, when the signal is raised, a Windows exception occurs and the 
  8616.  behavior is undefined. 
  8617.  
  8618.  
  8619. ΓòÉΓòÉΓòÉ 14.5. Writing a Signal Handler Function ΓòÉΓòÉΓòÉ
  8620.  
  8621. A signal handler function may call any non-critical C library functions. (For a 
  8622. list of critical functions, see Critical Functions.) Your signal handler may 
  8623. handle the signal in any of the following ways: 
  8624.  
  8625.    1. Calling exit or abort to terminate the process. 
  8626.  
  8627.    2. Calling _endthread to terminate the current thread of a multithread 
  8628.       program.  The process continues to run without the thread. You must 
  8629.       ensure that the loss of the thread does not affect the process.  Note 
  8630.       that calling _endthread for thread 1 of your process is the same as 
  8631.       calling exit. 
  8632.  
  8633.    3. Calling longjmp to go back to an earlier point in the current thread 
  8634.       where you called setjmp. When you call setjmp, it saves the state of the 
  8635.       thread at the time of the call. When you call longjmp at a later time, 
  8636.       the thread is reset to the state saved by setjmp, and starts running 
  8637.       again at the place where the call to setjmp was made. 
  8638.  
  8639.    4. Returning from the function to restart the thread as though the signal 
  8640.       has not occurred.  If this is not possible, the VisualAge for C++ library 
  8641.       terminates your process. 
  8642.  
  8643.  
  8644. ΓòÉΓòÉΓòÉ 14.5.1. Example of a C Signal Handler ΓòÉΓòÉΓòÉ
  8645.  
  8646. The following code gives a simple example of a signal handler function for a 
  8647. single-thread program. In the example, the function chkptr checks a given 
  8648. number of bytes in an area of storage and returns the number of bytes that you 
  8649. can access. The flow of the function's execution is described after the code. 
  8650.  
  8651.  
  8652. Example Illustrating a Signal Handler
  8653.  
  8654. #include <signal.h>
  8655. #include <setjmp.h>
  8656. #include <stdio.h>
  8657. #include <windows.h>
  8658.  
  8659. static void mysig(int sig);     /* signal handler prototype */
  8660. static jmp_buf jbuf;         /* buffer for machine state */
  8661.  
  8662. int chkptr(void * ptr, int size)
  8663. {
  8664.   void (* oldsig)(int);      /* where to save the old signal handler */
  8665.   volatile char c;         /* volatile to ensure access occurs */
  8666.   int valid = 0;          /* count of valid bytes */
  8667.   char * p = ptr;
  8668.  
  8669.   oldsig = signal(SIGSEGV,mysig); /* set the signal handler */     1
  8670.  
  8671.   if (!setjmp(jbuf))        /* provide a point for the    */  2
  8672.   {                /*  signal handler to return to */
  8673.  
  8674.     while (size--)
  8675. Γò¥Γò¥ΓòÉ
  8676.     {                                
  8677.      c = *p++;         /* check the storage and */     3
  8678.      valid++;          /*  increase the counter */    
  8679.     }
  8680. Γò¥Γò¥
  8681.   }
  8682.  
  8683.   signal(SIGSEGV,oldsig);     /* reset the signal handler */    5
  8684.   return valid;          /* return number of valid bytes */  6
  8685. }
  8686.  
  8687. static void mysig(int sig)
  8688. Γò¥ΓòÉ
  8689. {
  8690.   UCHAR FileData[100];
  8691.   ULONG Wrote;
  8692.  
  8693.   strcpy(FileData, "Signal Occurred.\n\r");
  8694.   WriteFile(GetStdHandle(STD_ERROR_HANDLE),          ~ 4
  8695.    (LPCVOID) FileData, strlen(FileData),(LPDWORD) &Wrote,NULL);
  8696.   longjmp(jbuf,1);     /* return to the point of the setjmp call */  
  8697.  
  8698. Γò¥
  8699. }
  8700.  
  8701.       1 The program registers the signal handler mysig and saves the original 
  8702.       handler in oldsig so that it can be reset at a later time. 
  8703.  
  8704.       2 The call to setjmp saves the state of the thread in jbuf.  When you 
  8705.       call setjmp directly, it returns 0, so the code within the if statement 
  8706.       is run. 
  8707.  
  8708.       3 The loop reads in and checks each byte of the buffer, incrementing 
  8709.       valid for each byte successfully copied to c. 
  8710.  
  8711.       Assuming that not all of the buffer space is available, at some point in 
  8712.       the loop p points to a storage location the process cannot access. A 
  8713.       Windows exception is generated and translated by the VisualAge for C++ 
  8714.       library to the SIGSEGV signal. The library then resets the signal handler 
  8715.       for SIGSEGV to SIG_DFL and calls the signal handler registered for 
  8716.       SIGSEGV (mysig). 
  8717.  
  8718.       4 The mysig function prints an error message and uses longjmp to return 
  8719.       to the place of the setjmp call in chkptr. The message is printed using 
  8720.       an operating system service rather than a C runtime function like printf 
  8721.       because calling Critical Run Time functions can fail inside a signal 
  8722.       handler. For a description of Critical functions, see Critical Functions. 
  8723.  
  8724.       Note:  mysig does not reset the signal handler for SIGSEGV, because that 
  8725.       signal is not intended to occur again.  In some cases, you may want to 
  8726.       reset signal handling before the signal handler function ends. 
  8727.  
  8728.       5 Because setjmp returns a nonzero value when it is called through 
  8729.       longjmp, the if condition is now false and execution falls through to 
  8730.       this line.  The signal handling for SIGSEGV is reset to whatever it was 
  8731.       when chkptr was entered. 
  8732.  
  8733.       6 The function returns the number of valid bytes in the buffer. 
  8734.  
  8735.  As the preceding example shows, your program can recover from a signal and 
  8736.  continue to run successfully. 
  8737.  
  8738.  
  8739. ΓòÉΓòÉΓòÉ 14.5.2. Signal Handling in Multithread Programs ΓòÉΓòÉΓòÉ
  8740.  
  8741. Handlers for synchronous signals are registered independently on each thread. A 
  8742. synchronous signal is always handled on the thread that generated it. For 
  8743. example, if thread 1 calls signal as follows: 
  8744.  
  8745.   signal(SIGFPE, handlerfunc);
  8746.  
  8747. then the handler handlerfunc is registered for thread 1 only. Any other threads 
  8748. are handled using the defaults. 
  8749.  
  8750. The three asynchronous signals SIGBREAK, SIGINT, and SIGTERM are handled on the 
  8751. new thread the operating system creates for the handler. This means other 
  8752. threads will be running at the same time with the handler even if you linked to 
  8753. the single-threaded library. This situation may cause a problem because the 
  8754. single-threaded library is not serialized. Therefore, users should not assume 
  8755. that single threaded library functions are reentrant. 
  8756.  
  8757. For more information and examples on handling signals, refer to Signal and 
  8758. Windows Exception Handling. 
  8759.  
  8760. When a thread starts, all of its signal handlers are set to SIG_DFL. If you 
  8761. want any other signal handling for that thread, you must explicitly register it 
  8762. using signal. 
  8763.  
  8764.  
  8765. ΓòÉΓòÉΓòÉ 14.6. Signal Handling Considerations ΓòÉΓòÉΓòÉ
  8766.  
  8767. When you use signal handlers, keep the following points in mind: 
  8768.  
  8769.      You can register anything as a signal handler.  It is up to you to make 
  8770.       sure that you are registering a valid function. 
  8771.  
  8772.      If your signal handler resides in a DLL, ensure that you change the 
  8773.       signal handler when you unload the DLL.  If you unload your DLL without 
  8774.       changing the signal handler, no warnings or error messages are generated. 
  8775.       When your signal handler gets called, your program will probably 
  8776.       terminate.  If another DLL has been loaded in the same address range, 
  8777.       your program may continue but with undefined results. 
  8778.  
  8779.      Your signal handler should not assume that SIGSEGV always implies an 
  8780.       invalid data pointer. It can also occur, for example, if an address 
  8781.       pointer goes outside of your code segment. 
  8782.  
  8783.      The SIGILL signal is not guaranteed to occur when you call an invalid 
  8784.       function using a pointer. If the pointer points to a valid instruction 
  8785.       stream, SIGILL is not raised. 
  8786.  
  8787.      When you use longjmp to leave a signal handler, ensure that the buffer 
  8788.       you are jumping to was created by the thread that you are in.  Do not 
  8789.       call setjmp from one thread and longjmp from another.  The VisualAge for 
  8790.       C++ library terminates a process where such a call is made. 
  8791.  
  8792.      If you use console I/O functions, including gets and scanf, and a SIGINT, 
  8793.       SIGBREAK, or SIGTERM signal occurs, the signal is reported after the 
  8794.       library function returns. Because your signal handler can call any 
  8795.       non-critical library function, one of these functions could be reentered. 
  8796.       For a listing of critical runtime functions, see Critical Functions. 
  8797.  
  8798.      Variables referenced by both the signal handler and by other code should 
  8799.       be given the attribute volatile to ensure they are always updated when 
  8800.       they are referenced. Because of the way the compiler optimizes code, the 
  8801.       following example may not work as intended when compiled with the /O+ 
  8802.       option: 
  8803.  
  8804.             void sig_handler(int);
  8805.             static int stepnum;
  8806.  
  8807.             int main(void)
  8808.             {
  8809.               stepnum = 0;
  8810.               signal(SIGSEGV, sig_handler);
  8811.               .
  8812.               .
  8813.               .
  8814.               stepnum = 1;  1
  8815.               .
  8816.               .
  8817.               .
  8818.               stepnum = 2;  2
  8819.             }
  8820.  
  8821.             void sig_handler(int x)
  8822.             {
  8823.               UCHAR FileData[100];
  8824.               ULONG Wrote;
  8825.  
  8826.               sprintf(FileData, "Error at Step %d\n\r", stepnum);
  8827.               WriteFile(GetStdHandle(STD_ERROR_HANDLE),          ~ 4
  8828.                (LPCVOID) FileData, strlen(fileData),(LPDWORD) &Wrote,NULL;
  8829.             }
  8830.  
  8831.       When using optimization, the compiler may not immediately store the value 
  8832.       1 for the variable stepnum. It may never store the value 1, and store 
  8833.       only the value 2. If a signal occurs between statement 1 and statement 2, 
  8834.       the value of stepnum passed to sig_handler may not be correct. 
  8835.  
  8836.       Declaring stepnum as volatile indicates to the compiler that references 
  8837.       to this variable have side effects. Changes to the value of stepnum are 
  8838.       then stored immediately. 
  8839.  
  8840.      C++ Consideration: Because the ANSI draft of the C++ language does not 
  8841.       specify the behavior of a throw statement in a signal handler, the most 
  8842.       portable way to ensure the appropriate destructors are called is to add 
  8843.       statements to the setjmp location that will do a throw if necessary. 
  8844.  
  8845.  
  8846. ΓòÉΓòÉΓòÉ 14.7. Handling Windows Exceptions ΓòÉΓòÉΓòÉ
  8847.  
  8848. A Windows exception is generated by the operating system to report an abnormal 
  8849. condition. Windows exceptions are grouped into two categories: 
  8850.  
  8851.    1. Asynchronous exceptions, which are caused by actions outside of your 
  8852.       current thread.  There are only two: 
  8853.  
  8854.           CTRL_C_EVENT and CTRL_BREAK_EVENT, caused by a keyboard signal 
  8855.            (Ctrl-C, Ctrl-Break) or the process termination exception.  This 
  8856.            exception can only occur on thread 1 of your process. 
  8857.           CTRL_CLOSE_EVENT, caused by one of your threads terminating the 
  8858.            entire process.  This exception can occur on any thread. 
  8859.  
  8860.    2. Synchronous exceptions, which are caused by code in the thread that 
  8861.       receives the exception.  All other Windows exceptions fall into this 
  8862.       category. 
  8863.  
  8864.  Just as you use signal handlers to handle signals, use exception handlers to 
  8865.  handle Windows exceptions. Although exception handling offers additional 
  8866.  function, because signal handling is simpler you may want to use both. 
  8867.  
  8868.  You may also prefer to use Structured Exception Handling in C, since it 
  8869.  provides the same functions as Windows exceptions do, but with simpler syntax. 
  8870.  
  8871.  
  8872. ΓòÉΓòÉΓòÉ 14.7.1. VisualAge for C++ Default Windows Exception Handling ΓòÉΓòÉΓòÉ
  8873.  
  8874. The function _Exception is the C language exception handler. 
  8875.  
  8876. This exception handler is registered by the VisualAge for C++ compiler for 
  8877. every process or thread that is started by _beginthread, unless #pragma handler 
  8878. is specified for the function. For more information on #pragma handler, see the 
  8879. Language Reference. The function _Exception maps recognized Windows exceptions 
  8880. to C signals, which can then be passed by the runtime library to the 
  8881. appropriate signal handlers. 
  8882.  
  8883. Mapping Between Exceptions and C Signals shows which types of Windows exception 
  8884. are recognized by _Exception, the names of the exceptions, and the C signals to 
  8885. which each exception type is mapped. These are the only Windows exceptions 
  8886. handled by _Exception. The Continuable column indicates whether the program 
  8887. will continue if the corresponding signal handler is SIG_IGN or if a 
  8888. user-defined signal handler returns. If "No" is indicated, the program can only 
  8889. be continued if you provide a signal handler that uses longjmp to jump to 
  8890. another part of the program. 
  8891.  
  8892. If the signal handler value is set to SIG_DFL, the default action taken for 
  8893. each of these exceptions is to terminate the program with an exit code of 99. 
  8894.  
  8895. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  8896. Γöé Table 6. Mapping Between Exceptions and C Signals        Γöé
  8897. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8898. Γöé WINDOWS EXCEP-  Γöé C SIGNAL  Γöé CONTINUABLE?          Γöé
  8899. Γöé TION       Γöé       Γöé                 Γöé
  8900. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8901. Γöé Divide by zero  Γöé SIGFPE   Γöé No               Γöé
  8902. Γöé          Γöé       Γöé                 Γöé
  8903. Γöé   EXCEPTION_INTΓöéDIVIDE_BY_ZEΓöéO                Γöé
  8904. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8905. Γöé NPX387 error   Γöé SIGFPE   Γöé No; except for         Γöé
  8906. Γöé          Γöé       Γöé EXCEPTION_FLT_INEXACT_RESULT  Γöé
  8907. Γöé   EXCEPTION_FLOΓöéT_DENORMAL_OΓöéERAND              Γöé
  8908. Γöé   EXCEPTION_FLTΓöéDIVIDE_BY_ZEΓöéO                Γöé
  8909. Γöé   EXCEPTION_FLTΓöéINEXACT_RESUΓöéT                Γöé
  8910. Γöé   EXCEPTION_FLTΓöéINVALID_OPERΓöéTION               Γöé
  8911. Γöé   EXCEPTION_FLTΓöéOVERFLOW   Γöé                 Γöé
  8912. Γöé   EXCEPTION_FLTΓöéSTACK_CHECK Γöé                 Γöé
  8913. Γöé   EXCEPTION_FLTΓöéUNDERFLOW  Γöé                 Γöé
  8914. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8915. Γöé Overflow     Γöé SIGFPE   Γöé Yes; resets the overflow flag  Γöé
  8916. Γöé occurred     Γöé       Γöé                 Γöé
  8917. Γöé          Γöé       Γöé                 Γöé
  8918. Γöé   EXCEPTION_INTΓöéOVERFLOW   Γöé                 Γöé
  8919. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8920. Γöé Bound opcode   Γöé SIGFPE   Γöé No               Γöé
  8921. Γöé failed      Γöé       Γöé                 Γöé
  8922. Γöé          Γöé       Γöé                 Γöé
  8923. Γöé   EXCEPTION_ARRΓöéY_BOUNDS_EXCΓöéEDED               Γöé
  8924. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8925. Γöé Opcode not valid Γöé SIGILL   Γöé No               Γöé
  8926. Γöé          Γöé       Γöé                 Γöé
  8927. Γöé   EXCEPTION_ILLΓöéGAL_INSTRUCTΓöéON                Γöé
  8928. Γöé   ??XCPT_INVALIΓöé_LOCK_SEQUENΓöéE                Γöé
  8929. Γöé   EXCEPTION_PRIΓöéILEGED_INSTRΓöéCTION              Γöé
  8930. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8931. Γöé General Pro-   Γöé SIGSEGV   Γöé No               Γöé
  8932. Γöé tection fault   Γöé       Γöé                 Γöé
  8933. Γöé          Γöé       Γöé                 Γöé
  8934. Γöé   EXCEPTION_ACCΓöéSS_VIOLATIONΓöé                 Γöé
  8935. Γöé   EXCEPTION_DATΓöéTYPE_MISALIGΓöéMENT               Γöé
  8936. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8937. Γöé Ctrl-Break    Γöé SIGBREAK  Γöé Yes               Γöé
  8938. Γöé          Γöé       Γöé                 Γöé
  8939. Γöé   CTRL_BREAK_EVΓöéNT      Γöé                 Γöé
  8940. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8941. Γöé Ctrl-C      Γöé SIGINT   Γöé Yes               Γöé
  8942. Γöé          Γöé       Γöé                 Γöé
  8943. Γöé   CTRL_C_EVENT Γöé       Γöé                 Γöé
  8944. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8945. Γöé End process    Γöé SIGTERM   Γöé Yes               Γöé
  8946. Γöé          Γöé       Γöé                 Γöé
  8947. Γöé   CTRL_CLOSE_EVΓöéNT      Γöé                 Γöé
  8948. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  8949.  
  8950. Note:  The Integer Overflow and Bound opcode exceptions will never be caused by 
  8951. code generated by the VisualAge for C++ compiler. 
  8952.  
  8953.  
  8954. ΓòÉΓòÉΓòÉ 14.7.2. Windows Exception Handling in Library Functions ΓòÉΓòÉΓòÉ
  8955.  
  8956. There are two classes of library functions that require special exception 
  8957. handling: math functions and critical functions. 
  8958.  
  8959. Windows exceptions occurring in all other library functions are treated as 
  8960. though they occurred in regular user code. 
  8961.  
  8962.  
  8963. ΓòÉΓòÉΓòÉ 14.7.2.1. Math Functions ΓòÉΓòÉΓòÉ
  8964.  
  8965. If the cause of the Windows exception was not a floating-point error, the 
  8966. exception is returned to _Exception. The _Exception function then converts the 
  8967. Windows exception to the corresponding C signal and performs one of the 
  8968. following actions: 
  8969.  
  8970.    1. Terminates the process.  If /Tx+ was specified, _Exception performs a 
  8971.       machine-state dump to file handle 2, unless the exception was SIGBREAK, 
  8972.       SIGINT, or SIGTERM, in which case the machine state is not meaningful. 
  8973.  
  8974.    2. Handles the exception and returns ExceptionContinueExecution to the 
  8975.       operating system. 
  8976.  
  8977.    3. Calls the signal handler function provided by you for that signal. A 
  8978.       return from the signal handler results in either the return of 
  8979.       ExceptionContinueExecution to the operating system or the termination of 
  8980.       the process as in the first action above. 
  8981.  
  8982.  For more information about exception-handling return codes, refer to the 
  8983.  Windows operating system documentation. 
  8984.  
  8985.  
  8986. ΓòÉΓòÉΓòÉ 14.7.2.2. Critical Functions ΓòÉΓòÉΓòÉ
  8987.  
  8988. Nonreentrant functions are functions which cannot be used concurrently by two 
  8989. or more tasks. All nonreentrant functions are classified as critical functions. 
  8990. Most I/O and allocation functions, and those that begin or end threads or 
  8991. processes, fall in this class. The critical functions are: 
  8992.  
  8993. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  8994. Γöé Table 7. Critical Functions                   Γöé
  8995. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  8996. Γöé   atexit   Γöé   execv  Γöé   freopenΓöé   putenv      Γöé
  8997. Γöé   calloc   Γöé   execve Γöé   fscanf Γöé   puts       Γöé
  8998. Γöé   _cgets   Γöé   execvp Γöé   fseek  Γöé   raise       Γöé
  8999. Γöé   clearerr  Γöé   _execvpΓöé   fsetposΓöé   realloc      Γöé
  9000. Γöé   _cprintf  Γöé   exit  Γöé   ftell  Γöé   remove      Γöé
  9001. Γöé   _cputs   Γöé   fclose Γöé   fwrite Γöé   rename      Γöé
  9002. Γöé   _cscanf  Γöé   _fcloseΓöéll  _getch Γöé   rewind      Γöé
  9003. Γöé   _debug_calΓöéoc  fdopen Γöé   _getcheΓöé   _rmtmp      Γöé
  9004. Γöé   _debug_freΓöé   feof  Γöé   getenv Γöé   scanf       Γöé
  9005. Γöé   _debug_heaΓöémin  ferror Γöé   gets  Γöé   setlocale     Γöé
  9006. Γöé   _debug_malΓöéoc  fflush Γöé   _heap_cΓöéeck  setvbuf      Γöé
  9007. Γöé   _debug_reaΓöéloc  fgetc  Γöé   _heapchΓöé   signal      Γöé
  9008. Γöé   _debug_ucaΓöéloc  fgetposΓöé   _heapmiΓöé   _spawnl      Γöé
  9009. Γöé   _debug_uheΓöépmin fgets  Γöé   _heapseΓöé   _spawnle     Γöé
  9010. Γöé   _debug_umaΓöéloc  fileno Γöé   _heap_wΓöélk  _spawnlp     Γöé
  9011. Γöé   _dump_alloΓöéated _flushaΓöél   _interuΓöét   _spawnlpe     Γöé
  9012. Γöé   _endthreadΓöé   fopen  Γöé   _kbhit Γöé   _spawnv      Γöé
  9013. Γöé   _Excep-  Γöé   fprintfΓöé   _Lib_exΓöépt  _spawnve     Γöé
  9014. Γöé   tion    Γöé   fputc  Γöé   malloc Γöé   _spawnvp     Γöé
  9015. Γöé   execl   Γöé   fputs  Γöé   _onexitΓöé   _spawnvpe     Γöé
  9016. Γöé   execle   Γöé   fread  Γöé   printf Γöé   system      Γöé
  9017. Γöé   execlp   Γöé   free  Γöé   _putch Γöé   _tcalloc     Γöé
  9018. Γöé   _execlpe  Γöé       Γöé       Γöé            Γöé
  9019. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  9020. Γöé   tempnam  Γöé       Γöé       Γöé            Γöé
  9021. Γöé   _tfree   Γöé       Γöé       Γöé            Γöé
  9022. Γöé   _theapmin Γöé       Γöé       Γöé            Γöé
  9023. Γöé   _tmalloc  Γöé       Γöé       Γöé            Γöé
  9024. Γöé   tmpfile  Γöé       Γöé       Γöé            Γöé
  9025. Γöé   tmpnam   Γöé       Γöé       Γöé            Γöé
  9026. Γöé   _trealloc Γöé       Γöé       Γöé            Γöé
  9027. Γöé   _uaddmem  Γöé       Γöé       Γöé            Γöé
  9028. Γöé   _ucalloc  Γöé       Γöé       Γöé            Γöé
  9029. Γöé   _ucreate  Γöé       Γöé       Γöé            Γöé
  9030. Γöé   _udefault Γöé       Γöé       Γöé            Γöé
  9031. Γöé   _udestroy Γöé       Γöé       Γöé            Γöé
  9032. Γöé   _udump_allΓöécated    Γöé       Γöé            Γöé
  9033. Γöé   _dump_alloΓöéated_delta  Γöé       Γöé            Γöé
  9034. Γöé   _udump_allΓöécated_delta Γöé       Γöé            Γöé
  9035. Γöé   ungetc   Γöé       Γöé       Γöé            Γöé
  9036. Γöé   _ungetch  Γöé       Γöé       Γöé            Γöé
  9037. Γöé   _uheapchk Γöé       Γöé       Γöé            Γöé
  9038. Γöé   _uheapmin Γöé       Γöé       Γöé            Γöé
  9039. Γöé   _uheapset Γöé       Γöé       Γöé            Γöé
  9040. Γöé   _uheap_walΓöé       Γöé       Γöé            Γöé
  9041. Γöé   _umalloc  Γöé       Γöé       Γöé            Γöé
  9042. Γöé   vfprintf  Γöé       Γöé       Γöé            Γöé
  9043. Γöé   vprintf  Γöé       Γöé       Γöé            Γöé
  9044. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  9045.  
  9046. Windows exceptions in critical functions generally occur only if your program 
  9047. passes a pointer that is not valid to a library function, or if your program 
  9048. overwrites the library's data areas. Because calling a signal handler to handle 
  9049. a Windows exception from one of these functions can have unexpected results, a 
  9050. special exception handler is provided for critical functions. You cannot 
  9051. override this exception handler. 
  9052.  
  9053. If the Windows exception is synchronous (SIGFPE, SIGILL, or SIGSEGV), the 
  9054. default action is taken, which is to pass the exception on to the next 
  9055. registered exception handler. Any exception handler you may have registered 
  9056. will not be called, and will receive only the termination exception. 
  9057.  
  9058. If the Windows exception is asynchronous, it is deferred until the library 
  9059. function has finished. The exception is then passed to _Exception, which 
  9060. converts the exception to the corresponding C signal and performs the 
  9061. appropriate action. 
  9062.  
  9063. Note:  If you use console I/O functions (for example, gets) and a SIGINT, 
  9064. SIGBREAK, or SIGTERM signal occurs, the signal is deferred until the function 
  9065. returns, for example, after all data for the keyboard function has been 
  9066. entered. To avoid this side effect, use a noncritical function like read or the 
  9067. Windows API ReadFile to read data from the keyboard. 
  9068.  
  9069.  
  9070. ΓòÉΓòÉΓòÉ 14.8. Registering a Windows Exception Handler ΓòÉΓòÉΓòÉ
  9071.  
  9072. The VisualAge for C++ compiler automatically registers and deregisters the 
  9073. _Exception handler for each thread or process so the _Exception is the first 
  9074. exception handler to be called when an exception occurs. To explicitly register 
  9075. _Exception for a function, use the #pragma handler directive before the 
  9076. function definition. This directive generates the code to register the 
  9077. exception handler before the function runs.  Code to remove the exception 
  9078. handler when the function ends is also generated. 
  9079.  
  9080. The format of the directive is: 
  9081.  
  9082.   #pragma handler(function)
  9083.  
  9084. where function is the name of the function for which the exception handler is 
  9085. to be registered. 
  9086.  
  9087. Note:  If you use CreateThread to create a new thread, you must use #pragma 
  9088. handler to register the VisualAge for C++ exception handler for the function 
  9089. that the new thread will run. 
  9090.  
  9091. You can register your own exception handler in place of _Exception using these 
  9092. directives: 
  9093.  
  9094.   #pragma map(_Exception, "MyExceptHandler")
  9095.   #pragma handler(myfunc)
  9096. The handler is registered on function entry and deregistered on exit; you 
  9097. cannot register the handler over only part of a function. 
  9098.  
  9099.  
  9100. ΓòÉΓòÉΓòÉ 14.9. Handling Signals and Windows Exceptions in DLLs ΓòÉΓòÉΓòÉ
  9101.  
  9102. Handling signals and Windows exceptions in DLLs is no different than handling 
  9103. signals in executable files, provided that all your DLLs and the executable 
  9104. files that use them are created using the VisualAge for C++ compiler, and only 
  9105. one VisualAge for C++ library environment exists for your entire application 
  9106. (your executable module and all DLLs). 
  9107.  
  9108. The library environment is a section of information associated with and 
  9109. statically linked to the VisualAge for C++ library itself. You can be sure your 
  9110. program has only one library environment if: 
  9111.  
  9112.    1. It consists of a single executable module.  By definition, a single 
  9113.       module has only one copy of the VisualAge for C++ library environment 
  9114.       regardless of whether it links to the library statically or dynamically. 
  9115.  
  9116.    2. Your executable module dynamically links to a single DLL that is 
  9117.       statically bound to the VisualAge for C++ runtime library and that uses 
  9118.       the VisualAge for C++ library functions. The executable module then 
  9119.       accesses the library functions through the DLL. 
  9120.  
  9121.    3. Your executable modules and DLLs all dynamically link to the VisualAge 
  9122.       for C++ runtime library. 
  9123.  
  9124.  Note:  The licensing agreement does not allow you to ship the VisualAge for 
  9125.  C++ library DLLs with your application, unless you rename them using the 
  9126.  DLLRNAME utility, or equivalent. You can, however, create your own version of 
  9127.  the runtime library and dynamically link to it from all of your modules, 
  9128.  ensuring that only one copy of the library environment is used by your 
  9129.  application. If you call any VisualAge for C++ library functions from a user 
  9130.  DLL, you must call them all from that DLL. The method of creating your own 
  9131.  runtime library is described in Creating Your Own Runtime Library DLLs. 
  9132.  
  9133.  If more than one of your modules is statically linked to the VisualAge for C++ 
  9134.  library, your program has more than one library environment. Because there is 
  9135.  no communication between these environments, certain operations and functions 
  9136.  become restricted: 
  9137.  
  9138.      Stream I/O.  You can pass the file pointer between modules and read to or 
  9139.       write from the stream in any module, but you cannot open a stream in one 
  9140.       library environment or module and close it in another. 
  9141.  
  9142.      Memory allocation.  You can pass the storage pointer between modules, but 
  9143.       you cannot allocate storage in one library environment and free or 
  9144.       reallocate it in another. 
  9145.  
  9146.      strtok, rand, and srand functions. A call to any of these functions in 
  9147.       one library environment has no effect on calls made in another 
  9148.       environment. 
  9149.  
  9150.      errno and doserrno values.  The setting of these variables in one library 
  9151.       environment has no effect on their values in another. 
  9152.  
  9153.      Signal and Windows exception handlers.  The signal and exception handlers 
  9154.       for a library environment have no effect on the handlers for another 
  9155.       environment. 
  9156.  
  9157.  In general, it is easier to use only one library environment, but not always 
  9158.  possible.  For example, if you are building a DLL that will be called by a 
  9159.  number of applications, you should assume that there may be multiple library 
  9160.  environments and code your DLL accordingly. 
  9161.  
  9162.  The following section describes how to use signal and exception handling when 
  9163.  your program has more than one library environment. 
  9164.  
  9165.  
  9166. ΓòÉΓòÉΓòÉ 14.9.1. Signal and Exception Handling with Multiple Library Environments ΓòÉΓòÉΓòÉ
  9167.  
  9168. When you have multiple library environments, you must treat signal and 
  9169. exception handlers in a slightly different manner than you would with a single 
  9170. library environment. Otherwise, the wrong handler could be called to handle a 
  9171. signal or Windows exception. 
  9172.  
  9173. For example, if you have an executable module and a DLL, each with its own 
  9174. library environment, the _Exception exception handler is automatically 
  9175. registered for the executable module when it starts. When the executable module 
  9176. calls a function in the DLL, the thread of execution passes to the DLL. If a 
  9177. Windows exception then occurs in the code in the DLL, it is actually handled by 
  9178. the exception handler in the executable module's library environment. Any 
  9179. signal handling set up in the DLL is ignored. 
  9180.  
  9181. When you have more than one library environment, you must ensure that a Windows 
  9182. exception is always handled by the exception handler for the library 
  9183. environment where the exception occurred. 
  9184.  
  9185. Include #pragma handler statements in your DLL for every function in the DLL 
  9186. that can be called from another module.  This directive ensures the exception 
  9187. handler for the DLL's library environment is correctly registered when the 
  9188. function is called and deregistered when the function returns to the calling 
  9189. module. If functions in your executable module can themselves be called back to 
  9190. from a DLL, include a #pragma handler statement for each of them also. 
  9191.  
  9192.  
  9193. ΓòÉΓòÉΓòÉ 14.10. Using Windows Exception Handlers for Special Situations ΓòÉΓòÉΓòÉ
  9194.  
  9195. Using exception handlers can be especially helpful in the following situations: 
  9196.  
  9197.      In multithread programs that use Windows semaphores. If you acquire a 
  9198.       semaphore and then use longjmp either explicitly or through a signal 
  9199.       handler to move to another place in your program, the semaphore is still 
  9200.       owned by your code.  Other threads in your program may not be able to 
  9201.       obtain ownership of the semaphore. 
  9202.  
  9203.       If you register an exception handler for the function where the semaphore 
  9204.       is requested, the handler can check for the unwind operation that occurs 
  9205.       as a result of a longjmp call.  If it encounters an unwind operation, it 
  9206.       can then release the semaphore. 
  9207.  
  9208.      In system DLLs.  Using an exception handler allows you to run process 
  9209.       termination routines even if your DLL has global initialization and 
  9210.       termination. 
  9211.  
  9212.       When a process terminates, functions are called in the following order: 
  9213.  
  9214.         1. Functions registered with the atexit or _onexit functions. 
  9215.         2. Exception handlers for termination exceptions. 
  9216.         3. Functions registered with the DLLEntryPoint API. 
  9217.         4. DLL termination routines. 
  9218.  
  9219.       You can include process termination routines in your exception handler 
  9220.       and they will be performed before the DLL termination routines are 
  9221.       called. 
  9222.  
  9223.  
  9224. ΓòÉΓòÉΓòÉ 14.11. Windows Exception Handling Considerations ΓòÉΓòÉΓòÉ
  9225.  
  9226. All the restrictions for signal handling described on page Signal Handling 
  9227. Considerations apply to exception handling as well.  There are also a number of 
  9228. additional considerations you should keep in mind when you use exception 
  9229. handling: 
  9230.  
  9231.      You must register an exception handler whenever you change library 
  9232.       environments to ensure that exception handling is provided for all C 
  9233.       code. 
  9234.  
  9235.      If you register your own exception handler, the Windows exceptions you 
  9236.       handle are not seen by a signal handler.  The exceptions you do not 
  9237.       handle are passed to the next exception handler.  If the next handler is 
  9238.       the VisualAge for C++ default handler _Exception, it converts the 
  9239.       exception to a signal and calls the appropriate signal handler. 
  9240.  
  9241.      If you are using Windows semaphores and an exception occurs while your 
  9242.       code owns a semaphore, you must ensure that the semaphore is released. 
  9243.       You can release the semaphore either by continuing the exception or by 
  9244.       explicitly releasing the semaphore in the signal handler. 
  9245.  
  9246.      Always check the exception flags to determine how the exception occurred. 
  9247.       Any exception handler can be unwound by a subsequent handler. 
  9248.  
  9249.      Keep your exception handler simple and specific.  Exception handlers are 
  9250.       easier to write and maintain if you limit what they can do.  A handler 
  9251.       that does everything can be very large and very complicated. 
  9252.  
  9253.      Check for and handle only the exceptions that you expect to encounter, 
  9254.       and allow the default exception handler to handle the unexpected. If the 
  9255.       operating system adds new exceptions, or if you create your own, the 
  9256.       default handler will handle them. 
  9257.  
  9258.      If you are using your own exception handler, it receives the exception 
  9259.       registration record when an exception occurs, as described in Registering 
  9260.       a Windows Exception Handler.  Do not use the return address of the 
  9261.       calling function to tell you where to resume execution, because the 
  9262.       values of the registers other than EBP (for example, EBX, EBI, and EDI) 
  9263.       at the return are generally not available to your exception handler. 
  9264.  
  9265.      You need approximately 1.5K of stack remaining for the operating system 
  9266.       to be able to call your exception handler. If you do not have enough 
  9267.       stack left, the operating system terminates your process. 
  9268.  
  9269.      Neither of the VisualAge for C++ default exception handlers are available 
  9270.       in the subsystem libraries. 
  9271.  
  9272.  
  9273. ΓòÉΓòÉΓòÉ 14.11.1. Handling Floating-Point Exceptions ΓòÉΓòÉΓòÉ
  9274.  
  9275. Floating-point exceptions require special exception handling. In general, you 
  9276. cannot retry a floating-point exception without a significant knowledge of both 
  9277. the 80387 chip and the application that generated the exception. Because 
  9278. knowledge of your application is beyond the capabilities of the VisualAge for 
  9279. C++ library, it treats a floating-point exception as a terminating condition. 
  9280.  
  9281. You can use the _control87 function and the bit mask values defined in 
  9282. <float.h> to mask floating-point exceptions, that is, to prevent them from 
  9283. being reported. Each bit mask corresponds to a unique floating-point exception 
  9284. that can be masked individually. Masking exceptions also changes the state of 
  9285. the floating-point control word for the 80387 chip. When a floating-point 
  9286. exception is masked, the 80387 chip performs a predetermined corrective action. 
  9287.  
  9288. The bit masks are: 
  9289.  
  9290.  EM_INVALID     Mask exceptions resulting from floating-point operations that 
  9291.                 are not valid.  Such an exception can be caused by a 
  9292.                 floating-point value that is not valid, such as a signalling 
  9293.                 NaN, or by a problem with the 80387 stack.  The corrective 
  9294.                 action taken by the 80387 chip is to return a quiet NaN. 
  9295.  
  9296.                 Note:  Because this type of exception indicates a serious 
  9297.                 problem, you should not mask it off. 
  9298.  
  9299.  EM_DENORMAL    Mask exceptions resulting from the use of denormal 
  9300.                 floating-point values.  The corrective action is to use these 
  9301.                 values and allow for gradual underflow.  This type of exception 
  9302.                 is not meaningful under the VisualAge for C++ compiler and is 
  9303.                 masked off by default. 
  9304.  
  9305.  EM_ZERODIVIDE  Mask the divide-by-zero exception.  The 80387 chip returns a 
  9306.                 value of infinity. 
  9307.  
  9308.  EM_OVERFLOW    Mask the overflow exception.  The 80387 chip returns a value of 
  9309.                 infinity. 
  9310.  
  9311.  EM_UNDERFLOW   Mask the underflow exception.  The 80387 chip returns either a 
  9312.                 denormal number or zero. 
  9313.  
  9314.  EM_INEXACT     Mask the exception that indicates precision has been lost. 
  9315.                 Because this type of exception is only useful when performing 
  9316.                 integer arithmetic, while the 80387 chip is used for 
  9317.                 floating-point arithmetic only, the exception is not meaningful 
  9318.                 and the 80387 chip ignores it.  This exception is masked off by 
  9319.                 default. 
  9320.  By default, the following bit masks are masked on by default.  That is, the 
  9321.  exceptions that they correspond to are not masked: 
  9322.  
  9323.      EM_INVALID 
  9324.      EM_ZERODIVIDE 
  9325.      EM_OVERFLOW 
  9326.      EM_UNDERFLOW 
  9327.  
  9328.  These bit masks are masked off by default.  This means that the exceptions 
  9329.  that they correspond to are masked by default: 
  9330.  
  9331.      EM_DENORMAL 
  9332.      EM_INEXACT 
  9333.  
  9334.  For example, to mask the floating-point underflow exception from being 
  9335.  reported, you would code in your source file: 
  9336.  
  9337.     oldstate = _control87(EM_UNDERFLOW, EM_UNDERFLOW);
  9338.  
  9339.  To mask it on again, you would code: 
  9340.  
  9341.     oldstate = _control87(0, EM_UNDERFLOW);
  9342.  
  9343.  You can also reset the entire floating-point control word to the default state 
  9344.  with the _fpreset function.  Both _fpreset and _control87 are described in the 
  9345.  C Library Reference. 
  9346.  
  9347.  Important  Because the VisualAge for C++ math functions defined in <math.h> 
  9348.             use the 80387 chip, make sure that when you call any of them, the 
  9349.             floating-point control word is set to the default state to ensure 
  9350.             exceptions are handled correctly by the VisualAge for C++ library. 
  9351.  
  9352.  Note also that the state of the floating-point control word is unique for each 
  9353.  thread, and changing it in one thread does not affect any other thread. 
  9354.  
  9355.  
  9356. ΓòÉΓòÉΓòÉ 14.12. Interpreting Machine-State Dumps ΓòÉΓòÉΓòÉ
  9357.  
  9358. Note:  This section provides information to be used for Diagnosis, 
  9359. Modification, or Tuning purposes.  This information is not intended for use as 
  9360. a programming interface. 
  9361.  
  9362. If you rebuild your program with the /Ti+ option, the VisualAge for C++ 
  9363. debugger will identify where in the source an exception took place.  If the 
  9364. problem does not appear or involves many process or timing problems, you can 
  9365. use the kernel debugger instead. 
  9366.  
  9367. If you specify the /Tx+ option, when a process is ended because of an unhandled 
  9368. or incorrectly handled exception, the exception handler performs a 
  9369. machine-state dump. A machine-state dump consists of a number of runtime 
  9370. messages that show information about the state of the system, such as the 
  9371. contents of the registers and the reason for the exception. This information is 
  9372. sent to file handle 2, which is usually associated with stderr. You can also 
  9373. use the _set_crt_msg_handle function to redirect the messages to a file.  See 
  9374. the C Library Reference for more information about this function. 
  9375.  
  9376. If you do not specify /Tx+, a message is generated giving the exception and the 
  9377. address at which it occurred. 
  9378.  
  9379. For example, the following program generates a floating-point exception. 
  9380. Because the exception cannot be handled, a machine-state dump is performed. 
  9381. Example of a Machine-State Dump shows what is sent to stderr and explains the 
  9382. messages in the dump. 
  9383.  
  9384.  
  9385. Program to Cause a Machine-State Dump
  9386.  
  9387.  
  9388. #include <windows.h>
  9389.  
  9390.  int main(void)
  9391.  {
  9392.   RaiseException( EXCEPTION_ACCESS_VIOLATION, 0, 0, NULL );
  9393.  
  9394.   return 0;
  9395.  }
  9396.  
  9397.  
  9398. Example of a Machine-State Dump
  9399.  
  9400.  General Protection Fault exception occurred at EIP = 77F3CA04
  9401.  on thread 0059.    1
  9402.  Register Dump at point of exception:  2
  9403.  EAX = 0012FF64   EBX = 7FFDF000  ECX = 002D0760   EDX = 00000000
  9404.  EBP = 0012FFB4   EDI = 00141CD0  ESI = 77F331DA   ESP = 0012FF60 3
  9405.  CS =   001B  CSLIM = FFFFFFFF  DS =   0023  DSLIM = FFFFFFFF
  9406.  ES =   0023  ESLIM = FFFFFFFF  FS =   0038  FSLIM = 00000FFF
  9407.  GS =   0000  GSLIM = 00000000  SS =   0023  SSLIM = FFFFFFFF
  9408.  NPX Environment:    4
  9409.  CW = 0362    TW = FFFF  IP = 0000:00000000     5
  9410.  SW = 0000  OPCODE = 0000  OP = 0000:FFFF0000
  9411.  NPX Stack: 6
  9412.  No valid stack entries. 7
  9413.  Process terminating.  8.
  9414.  
  9415.  1   The first line always states the nature of the exception and the place and 
  9416.      thread where the exception occurred. If you specify /Tx-, this is the only 
  9417.      message that is generated. 
  9418.  
  9419.  2   Introduces the register dump. 
  9420.  
  9421.  3   Gives the values contained by each register at the time the exception 
  9422.      occurred. for information on the purpose of each register, see the 
  9423.      documentation for your processor chip. 
  9424.  
  9425.  4   Introduces the state of the numeric processor extension (NPX) at the time 
  9426.      of the exception. 
  9427.  
  9428.  5   Gives the values of the elements in the NPX environment. 
  9429.  
  9430.  6   Introduces the state of the NPX stack at the time of the exception. 
  9431.  
  9432.  7   One copy of this message appears for each valid stack entry in the NPX and 
  9433.      gives the values for each.  In this example, because there is only one 
  9434.      stack entry, the message appears only once.  If there are no valid stack 
  9435.      entries, a different message is issued in place of this message to state 
  9436.      that fact. 
  9437.  
  9438.  8   Confirms that the process is terminating. It is one of several 
  9439.      informational messages that may accompany the initial exception message 
  9440.      and register dump. 
  9441.  
  9442.  In general, a dump will always include items 1, 2, and 3. Items 4 to 7 appear 
  9443.  only if the NPX was in use at the time of the exception.  Item 8 may or may 
  9444.  not appear, depending on the circumstances of each exception. 
  9445.  
  9446.  For a list of all the runtime messages and their explanations, see the online 
  9447.  Language Reference. 
  9448.  
  9449.  Note:  If you copy and run the program in Program to Cause a Machine-State 
  9450.  Dump, you will get the same messages as shown in Example of a Machine-State 
  9451.  Dump, but the values given may be different. 
  9452.  
  9453.  
  9454. ΓòÉΓòÉΓòÉ 14.13. Common Problems that Generate Exceptions ΓòÉΓòÉΓòÉ
  9455.  
  9456. The following is a list of some of the common problems that can generate 
  9457. runtime exceptions: 
  9458.  
  9459.      Improper use of memory.  Using a pointer to an object that has already 
  9460.       been freed can cause an exception, as can corrupting the heap.  In such 
  9461.       situations, try rebuilding your program using the Debug Memory option, 
  9462.       /Tm+. 
  9463.  
  9464.      Using an invalid pointer. 
  9465.  
  9466.      Passing an invalid parameter to a system function. 
  9467.  
  9468.      Return codes from library or system calls that are not checked. 
  9469.  
  9470.  
  9471. ΓòÉΓòÉΓòÉ 14.14. Structured Exception Handling ΓòÉΓòÉΓòÉ
  9472.  
  9473. The typical code spends about ninety percent of its time handling conditions 
  9474. that occur less than one percent of the time. Structured Exception Handling 
  9475. (SEH) allows you to write code that concentrates on the normal case and 
  9476. relegates anomalous conditions to an exception handler. The programmer will 
  9477. spend more of their time focused on the code that actually does what the 
  9478. function is supposed to do rather than clutter the output with checking for 
  9479. exceptional cases. 
  9480.  
  9481. There are several differences between Structured Exception Handling and C++ 
  9482. Exception handling. The differences are summarized below: 
  9483.  
  9484.  signal(handler); 
  9485.  
  9486.                               most portable, defined by ANSI 
  9487.                               works in C or C++ 
  9488.                               non-resumptive 
  9489.                               only give access to a subset of system 
  9490.                                exceptions 
  9491.                               handler is a separate function 
  9492.  
  9493.  #pragma handler(x) 
  9494.  
  9495.                               available on Win32 and OS/2 
  9496.                               works in C or C++ 
  9497.                               resumptive or non-resumptive 
  9498.                               can catch any system exception 
  9499.                               handler is a separate function 
  9500.  
  9501.  SEH 
  9502.  
  9503.                               available only on Win32, nonportable 
  9504.                               works only in C 
  9505.                               resumptive or non-resumptive 
  9506.                               can catch any system exception 
  9507.                               handler is a separate function 
  9508.                               is always of type "unsigned int" 
  9509.  
  9510.  C++ throw/catch 
  9511.  
  9512.                               portable, defined by ANSI 
  9513.                               works only in C++ 
  9514.                               non-resumptive 
  9515.                               can only catch C++ throws, no system exceptions 
  9516.                               handler has access to local variables 
  9517.                               can be of any type 
  9518.  
  9519.  There are two types of exception handling in SEH. They are Termination 
  9520.  handling and Exception handling. 
  9521.  
  9522.  
  9523. ΓòÉΓòÉΓòÉ 14.14.1. Termination Handler ΓòÉΓòÉΓòÉ
  9524.  
  9525. Termination handling guarantees that a code body called the Termination Handler 
  9526. will be executed no matter how the guarded body was exited. It doesn't matter 
  9527. whether your function executed cleanly or encountered an exception, which was 
  9528. handled by another exception handler, the termination handler will always be 
  9529. executed. 
  9530.  
  9531. Termination handlers are ideal for simplifying error handling by moving all 
  9532. cleanup code into a common place. This improves program readability, thus 
  9533. hopefully reducing maintenance. 
  9534.  
  9535. The basics of a termination handler are 
  9536.  
  9537.  
  9538.  /*Code before try block */        1
  9539.  
  9540.  
  9541.  __try{
  9542.  /* Guarded body */             2
  9543.  }
  9544.  
  9545.  __finally{
  9546.  /*Termination handler */         3
  9547.  }
  9548.  
  9549.  
  9550.  /*Code after the termination handler */  4
  9551.  
  9552. The operating system and the compiler work together to guarantee that the 
  9553. __finally block of code will be executed. This is the case even if you were to 
  9554. place a return, goto, break, continue, or a longjump in the guarded body. The 
  9555. execution is always guaranteed to be ordered as the numbered section above. One 
  9556. good use of a termination handler is to free up precious resources such as 
  9557. memory, closing file handles, and releasing semaphores. 
  9558.  
  9559.  
  9560. ΓòÉΓòÉΓòÉ 14.14.1.1. Local Unwind ΓòÉΓòÉΓòÉ
  9561.  
  9562. There are two ways of leaving a try block -- normal termination and abnormal 
  9563. termination. When the code executes to the closing brace, the try block is said 
  9564. to have exited normally. If it exited because of a raised exception, goto, 
  9565. return, break, continue, or longjmp, then the try block is said to have exited 
  9566. abnormally. 
  9567.  
  9568. Abnormal termination causes a Local Unwind to occur. A Local Unwind occurs when 
  9569. the compiler executes the finally body, then executes the abnormal exit 
  9570. statement. A Local Unwind can also be caused by a Global Unwind which we will 
  9571. cover in a subsequent section. But for the context of this discussion, a Global 
  9572. Unwind is also an abnormal termination. 
  9573.  
  9574. The basics of an abnormal exit can be illustrated using a goto statement inside 
  9575. a try-finally block: 
  9576.  
  9577.  
  9578.  /* Code before try block */                  1
  9579.  
  9580.  __try{
  9581.  /* Guarded body */                      2
  9582.  goto label;
  9583.  /*  back here to execute the abnormal exit */   4
  9584.  }
  9585.  
  9586.  __finally{
  9587.  /* termination handler */                   3
  9588.  }
  9589.  
  9590.  /* Code directly after the termination handler will not be executed*/
  9591.  /* Code after the label will be executed */
  9592.  label:
  9593.  /* Code after the label */                  5
  9594.  
  9595. From the above code ordering, it is not surprising that the compiler generates 
  9596. instructions to remember to execute the goto (or return, break/continue, 
  9597. exception handler or longjmp) after the execution of the finally block. This is 
  9598. a performance penalty that always occurs in a Local Unwind and, as such, it 
  9599. should be avoided when possible. 
  9600.  
  9601.  
  9602. ΓòÉΓòÉΓòÉ 14.14.1.2. Leave and AbnormalTermination ΓòÉΓòÉΓòÉ
  9603.  
  9604. If you want to prematurely exit a try block without proceeding completely to 
  9605. the closing brace, use the builtin keyword __leave. This keyword causes 
  9606. execution to immediately exit the try block and enter the finally block. There 
  9607. will be no local unwind and no performance penalty. This is ideal for memory 
  9608. management where if memory was not malloc-ed successfully, you can leave the 
  9609. try block. Otherwise, you can continue execution in the try block to manipulate 
  9610. the allocated memory. 
  9611.  
  9612. In the finally block, you can call a builtin intrinsic function called 
  9613. AbnormalTermination() to tell you whether you exited the try block normally or 
  9614. abnormally. 
  9615.  
  9616. Here is an example: 
  9617.  
  9618.  
  9619.  /* Code before try block */        1
  9620.  
  9621.  
  9622.  __try{
  9623.  /* Guarded Body */             2
  9624.     someMemory = malloc (100);
  9625.     if (someMemory == NULL)
  9626.       __leave;
  9627.     /* do something with someMemory */
  9628.  }
  9629.  
  9630.  __finally{
  9631.  /* Termination handler */          3
  9632.     if (AbnormalTermination())
  9633.       printf("Boom!!\n");
  9634.     else
  9635.       free(someMemory);
  9636.  }
  9637.  
  9638.  /* Code after the termination handler */  4
  9639.  
  9640. Code is now executed without a performance hit despite the abnormal exit. When 
  9641. memory is allocated properly, calls to the finally block will execute the 
  9642. memory free function. 
  9643.  
  9644. There is one case where the Termination handler will not be called. If any 
  9645. threads call the ExitThread, ExitProcess, TerminateThread, or TerminateProcess 
  9646. system functions during the execution of the try block, the system will exit 
  9647. immediately without calling the Termination Handler. 
  9648.  
  9649.  
  9650. ΓòÉΓòÉΓòÉ 14.14.2. Exception Handler ΓòÉΓòÉΓòÉ
  9651.  
  9652. An exception can be hardware or software generated. Users can generate software 
  9653. exception using the RaiseException() system call. In the past, one may have had 
  9654. to handle hardware exceptions differently than software exceptions. This has 
  9655. been unified under SEH. (See RaiseException for more detail.) 
  9656.  
  9657. Exception handling is performed using the try-except block. 
  9658.  
  9659.  
  9660.  /* Code before try block */            1
  9661.  
  9662.  __try{
  9663.  /* Guarded body */                 2
  9664.  }
  9665.  
  9666.  __except( filter /* Exception Filter */ ){     3
  9667.  
  9668.  /* Exception handler only*/            4
  9669.  }
  9670.  
  9671.  /* Code after the exception handler */       5
  9672.  
  9673. You need to use the header <excpt.h> which contains the data structure 
  9674. definitions for an exception. There can be no code between the try and the 
  9675. except or finally block. A try block also can only have one finally or except 
  9676. block associated with it. The actual order of code movement depends on a number 
  9677. of issues. The situation illustrated above is a case where there is an 
  9678. exception in the Guarded Body, and the Exception Filter evaluates to 
  9679. EXCEPTION_EXECUTE_HANDLER. If no exception occurs in the Guarded Body, then 
  9680. step 3 and 4 are omitted. 
  9681.  
  9682. The Exception Filter is evaluated for one of three possible conditions. The 
  9683. Exception Filter itself can be a function, a constant, or an expression. The 
  9684. three options it can evaluate to are: 
  9685.  
  9686.  EXCEPTION_EXECUTE_HANDLER           1 
  9687.  
  9688.  EXCEPTION_CONTINUE_EXECUTION       -1 
  9689.  
  9690.  EXCEPTION_CONTINUE_SEARCH           0 
  9691.  
  9692.  If your filter catches an exception that it is expecting after comparing it 
  9693.  with the exception signals in <winnt.h>, the filter should return 1 
  9694.  (EXCEPTION_EXECUTE_HANDLER). This will cause your exception handler to be 
  9695.  executed. After the exception handler is executed, control resumes at the 
  9696.  first instruction after the except block. 
  9697.  
  9698.  If your filter evaluates to -1 (EXCEPTION_CONTINUE_EXECUTION), then you are 
  9699.  indicating that you have taken care of the exception and that the execution 
  9700.  can continue from the instruction that generated the exception and try again. 
  9701.  Usually, the exception is repaired in the filter, and -1 is returned. However, 
  9702.  this is not guaranteed to always work exactly as expected as it depends on the 
  9703.  machine encoding. More than one instruction may be used to encode a single 
  9704.  line of code, and the specific machine instruction that caused the exception 
  9705.  may not have a value that has been repaired. This may cause an infinite loop. 
  9706.  
  9707.  The third possibility is a return value of 0 (EXCEPTION_CONTINUE_SEARCH) which 
  9708.  means that you do not want to handle the exception. The exception dispatcher 
  9709.  will look for another exception handler by searching backwards through the 
  9710.  call stack. It will specifically look for the most-recently executing try 
  9711.  block that's associated with an except block and ignore any try blocks that 
  9712.  are matched with finally blocks. If none is found, then it will call the 
  9713.  system exception handler for an unhandled exception. 
  9714.  
  9715.  
  9716. ΓòÉΓòÉΓòÉ 14.14.2.1. Global Unwind ΓòÉΓòÉΓòÉ
  9717.  
  9718. Unwinding is the act of cleaning up the stack. In addition to the Local Unwind 
  9719. described above, there is a Global Unwind. This occurs when there are nested 
  9720. functions and an exception takes place, and an Exception Filter further up the 
  9721. call stack is evaluated to EXCEPTION_EXECUTE_HANDLER, thus causing all the 
  9722. outstanding try-finally block between the exception and the exception handler 
  9723. to be executed. 
  9724.  
  9725. The code execution sequence of a Global Unwind would be as follows: 
  9726.  
  9727.  
  9728.  /* Code before try block */                 1
  9729.  
  9730.  __try{
  9731.  /* Guarded body */                      2
  9732.  /* Call another function */
  9733.  function();
  9734.  /* Code here is never executed */
  9735.  }
  9736.  __except( EXCEPTION_EXECUTE_HANDLER /* Exception Filter */ ){6
  9737.  /* Exception handler only executes after the global unwind*/ 8
  9738.  }
  9739.  
  9740.  /* Code after the exception handler */            9
  9741.  void function(void) {
  9742.  /* function code */                      3
  9743.    __try{
  9744.    /* Guarded Body */                     4
  9745.    /* an exception occurs here */               5
  9746.    }
  9747.    __finally {
  9748.    /* Global Unwind occurs to unwind all pending finally-blocks */7
  9749.   }
  9750.  
  9751.  /* Code here never executes */
  9752.  }
  9753.  
  9754. Global Unwind can be halted by placing a return inside a finally block. 
  9755. Unwinding stops and execution continues as though nothing ever happened. The 
  9756. code inside the exception handler will not be executed even though the code 
  9757. inside the Exception Filter was executed. Usually, this technique should be 
  9758. avoided. 
  9759.  
  9760.  
  9761. ΓòÉΓòÉΓòÉ 14.14.2.2. Exception Information ΓòÉΓòÉΓòÉ
  9762.  
  9763. An exception dispatcher provides you with information about the exception. This 
  9764. exception information can be accessed in various ways. There is a function that 
  9765. returns the exception code and a function that returns a pointer to the 
  9766. exception data structure. 
  9767.  
  9768. To find the exception code of the exception that was raised, there is an 
  9769. intrinsic function called GetExceptionCode which returns a value identifying 
  9770. the exception. This exception number is defined in the file <excpt.h.> 
  9771.  
  9772.  
  9773.  DWORD GetExceptionCode(VOID).
  9774.  
  9775. GetExceptionCode can only be called in an Exception Filter or inside an 
  9776. exception handler. It cannot be called inside an Exception Filter function. 
  9777. Here is a legal way to call GetExceptionCode: 
  9778.  
  9779.  
  9780.  f(){
  9781.  /* Code before try block */                1
  9782.  
  9783.  __try{
  9784.  /* Guarded body */                    2
  9785.  }
  9786.  __except(
  9787.  ((GetExceptionCode() == EXCEPTION_ACCESS_VIOLATION ||
  9788.   GetExceptionCode() == EXCEPTION_FLT_DIVIDE_BY_ZERO)
  9789.   ? EXCEPTION_EXECUTE_HANDLER : EXCEPTION_CONTINUE_EXECUTION))
  9790.  
  9791.  ) /* Exception Filter */ ){                3
  9792.  
  9793.  /* Exception handler only*/                4
  9794.  switch (GetExceptionCode(){
  9795.    case EXCEPTION_ACCESS_VIOLATION:
  9796.      /* handle access violation
  9797.    break;
  9798.    case EXCEPTION_FLT_DIVIDE_BY_ZERO:
  9799.      /* handle divide by zero */
  9800.    break;
  9801.    }
  9802.  }
  9803.  /* Code after the exception handler */           5
  9804.  }
  9805.  
  9806. Here is an illegal way of calling GetExceptionCode: 
  9807.  
  9808.  
  9809.  f(){
  9810.  /* Code before try block */              1
  9811.  
  9812.  __try{
  9813.  /* Guarded body */                  2
  9814.  }
  9815.  
  9816.  __except( filter() /* Exception Filter */ ){     3
  9817.  /* Exception handler only*/              4
  9818.  switch (GetExceptionCode(){
  9819.    case EXCEPTION_ACCESS_VIOLATION:
  9820.      /* handle access violation
  9821.    break;
  9822.    case EXCEPTION_FLT_DIVIDE_BY_ZERO:
  9823.      /* handle divide by zero */
  9824.    break;
  9825.    }
  9826.  }
  9827.  
  9828.  /* Code after the exception handler */         5
  9829.  }
  9830.  
  9831.  LONG filter() {
  9832.     /* Compile-time error */
  9833.  return
  9834.  ((ExceptionCode()==EXCEPTION_ACCESS_VIOLATION||EXCEPTION_FLT_DIVIDE_BY_
  9835.  ZERO)?EXCEPTION_EXECUTE_HANDLER:EXCEPTION_CONTINUE_EXECUTION);
  9836.  }
  9837.  
  9838. To make the above function behave properly, simply rewrite the filter function 
  9839. with a parameter, as follows: 
  9840.  
  9841.  
  9842.  f(){
  9843.  
  9844.  /* Code before try block */                1
  9845.  
  9846.  __try{
  9847.  /* Guarded body */
  9848.  }                             2
  9849.  
  9850.  __except( filter(GetExceptionCode()) /* Exception Filter */ ){  3
  9851.  /* Exception handler only*/                4
  9852.  switch (GetExceptionCode(){
  9853.    case EXCEPTION ACCESS_VIOLATION:
  9854.      /* handle access violation
  9855.    break;
  9856.    case EXCEPTION_FLT_DIVIDE_BY_ZERO:
  9857.      /* handle divide by zero */
  9858.    break;
  9859.    }
  9860.  }
  9861.  
  9862.  /* Code after the exception handler */           5
  9863.  }
  9864.  
  9865.  LONG filter(DWORD exception_code) {
  9866.  return
  9867.  ((exception_code==EXCEPTION_ACCESS_VIOLATION||EXCEPTION_FLT_DIVIDE_BY_
  9868.  ZERO)?EXCEPTION_EXECUTE_HANDLER:EXCEPTION_CONTINUE_EXECUTION);
  9869.  }
  9870.  
  9871. When an exception occurs, the exception dispatcher saves the information into a 
  9872. data structure called the Exception_Record. This data structure is accessed 
  9873. through another intrinsic function called GetExceptionInformation. It returns a 
  9874. pointer to a structure that contains a pointer to the Exception_Record. 
  9875.  
  9876.  
  9877.  LPEXCEPTION_POINTERS GetExceptionInformation(VOID);
  9878.  
  9879. This function can only be called in an exception filter, not an Exception 
  9880. Filter function, and not inside an exception handler. It returns a pointer to a 
  9881. data structure of two pointers to structures. One points to the 
  9882. Exception_Record and the other points to the Context. The Context structure 
  9883. describes the hardware state, such as register contents, at the time of the 
  9884. exception. This structure will differ depending on which machine you executed 
  9885. your code. 
  9886.  
  9887. The Exception_Record structure is reproduced here: 
  9888.  
  9889.  
  9890.  typedef struct _EXCEPTION_RECORD {
  9891.   DWORD ExceptionCode;
  9892.   DWORD ExceptionFlags;
  9893.   struct _EXCEPTION_RECORD *ExceptionRecord;
  9894.   PVOID ExceptionAddress;
  9895.   DWORD NumberParameters;
  9896.   DWORD ExceptionInformation[EXCEPTION_MAXIMUM_PARAMETERS];
  9897.  } EXCEPTION_RECORD;
  9898.  
  9899. The Exception_Record and Context structures are all defined in <winnt.h>. 
  9900. ExceptionCode is the code of the exception and it is the same as the 
  9901. information that is returned by GetExceptionCode. 
  9902.  
  9903. ExceptionFlags contains flags about the exception that is useful for the case 
  9904. EXCEPTION_CONTINUE_EXECUTION. Specifically, if an exception cannot be 
  9905. continued, then this flag will be set to EXCEPTION_NONCONTINUABLE_EXCEPTION. 
  9906. Any attempt to continue execution by returning EXCEPTION_CONTINUE_EXECUTION 
  9907. after a noncontinuable exception causes the EXCEPTION_NONCONTINUABLE_EXCEPTION 
  9908. exception to be generated. 
  9909.  
  9910. Exception_Record points to an associated EXCEPTION_RECORD structure that may be 
  9911. chained when nested exception occurs. This means that an exception has occurred 
  9912. inside an exception handler. 
  9913.  
  9914. ExceptionAddress has the address of the instruction that caused the exception 
  9915. to occur. 
  9916.  
  9917. The last two members work together to offer additional information about the 
  9918. exception. NumberParameters gives the number of parameters in the 
  9919. ExceptionInformation array member that follows. Currently, only the exception 
  9920. EXCEPTION_ACCESS_VIOLATION will generate additional information. All other 
  9921. exceptions will have the NumberParameters member as zero. An access violation 
  9922. generates two additional pieces of information. This information is stored in 
  9923. the array ExceptionInformation. Element 0 will be set to 0 if the thread tried 
  9924. to read inaccessible data, and 1 if the thread tried to write to an 
  9925. inaccessible address. Element 1 specifies the virtual address of the 
  9926. inaccessible data. 
  9927.  
  9928.  
  9929. ΓòÉΓòÉΓòÉ 14.14.2.3. RaiseException ΓòÉΓòÉΓòÉ
  9930.  
  9931. There are two types of exceptions: hardware and software. A hardware exception 
  9932. is an event that causes the processor to alter its normal flow of execution 
  9933. inside a process's instructions. We have been primarily looking at hardware 
  9934. exceptions such as divide-by-zero and access violations. Hardware exceptions 
  9935. tend to be highly processor-dependent. 
  9936.  
  9937. Software exceptions are explicitly generated by software. You can explicitly 
  9938. generate an exception using the Windows API RaiseException. This has the 
  9939. following format: 
  9940.  
  9941.  
  9942.  VOID RaiseException(DWORD dwExceptionCode, DWORD dwExceptionFlags,
  9943.  DWORD cArguments, LPWORD lpArguments);
  9944.  
  9945. This is an easy way to have application-defined exceptions. But one should take 
  9946. care not to swallow exceptions. A swallowed exception occurs when one handles 
  9947. an exception that is meant for another handler. You should never have a filter 
  9948. that simply sets EXCEPTION_EXECUTE_HANDLER without checking whether the 
  9949. exception code is what you're expecting. 
  9950.  
  9951. The first parameter dwExceptionCode sets the user-defined exception code. The 
  9952. second parameter, dwExceptionFlags, must be 0 or 1 
  9953. (EXCEPTION_NONCONTINUABLE_EXCEPTION). A 0 indicates that you can recover from 
  9954. this exception while a 1 indicates that you cannot. If 
  9955. EXCEPTION_NONCONTINUABLE_EXCEPTION is set, then it is incorrect for a filter to 
  9956. evaluate to EXCEPTION_CONTINUE_EXECUTION. If such a filter is encountered, the 
  9957. system will generate a new exception called EXCEPTION_NONCONTINUABLE_EXCEPTION. 
  9958.  
  9959. The third and fourth parameters allow you to pass application-defined data as 
  9960. arguments. If you don't need them, set them to NULL. Otherwise, use cArguments 
  9961. to indicate the number of elements in the DWORD array pointed to by the 
  9962. lpArguments parameter. This parameter cannot exceed 
  9963. EXCEPTION_MAXIMUM_PARAMETERS which is also defined in <winnt.h>, as 15. 
  9964.  
  9965. If you decide to generate your own application-defined exceptions, follow the 
  9966. standard set in <winerror.h> for the exception code you choose. 
  9967.  
  9968. If you don't want to define any application-defined exceptions, just use 
  9969. RaiseException to emulate one of the hardware exceptions, such as: 
  9970.  
  9971.  
  9972.  RaiseException(EXCEPTION_ACCESS_VIOLATION, 0,0,0);
  9973.  
  9974.  
  9975. ΓòÉΓòÉΓòÉ 15. Managing Memory ΓòÉΓòÉΓòÉ
  9976.  
  9977. This section describes techniques you can use to manage the memory of your 
  9978. program more efficiently. It includes information on the debug versions of the 
  9979. memory management functions (like malloc), and also tells you how to create and 
  9980. use your own heaps of memory. 
  9981.  
  9982.      Differentiating between Memory Management Functions 
  9983.      Managing Memory with Multiple Heaps 
  9984.      Debugging Your Heaps 
  9985.  
  9986.  The runtime functions are described in detail in the C Library Reference. 
  9987.  
  9988.  
  9989. ΓòÉΓòÉΓòÉ 15.1. Differentiating between Memory Management Functions ΓòÉΓòÉΓòÉ
  9990.  
  9991. The memory management functions defined by ANSI are calloc, malloc, realloc, 
  9992. and free. These regular functions allocate and free memory from the default 
  9993. runtime heap. (VisualAge for C++ has added another function, _heapmin, to 
  9994. return unused memory to the system.) VisualAge for C++ also provides different 
  9995. versions of each of these functions as extensions to the ANSI definition. 
  9996.  
  9997. All the versions actually work the same way; they differ only in what heap they 
  9998. allocate from, and in whether they save information to help you debug memory 
  9999. problems. The memory allocated by all of these functions is suitably aligned 
  10000. for storing any type of object. 
  10001.  
  10002. The following table summarizes the different versions of memory management 
  10003. functions, using malloc as an example of how the names of the functions change 
  10004. for each version. They are all described in greater detail in this section. 
  10005.  
  10006. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  10007. Γöé          Γöé Regular Version  Γöé Debug Version   Γöé
  10008. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  10009. Γöé DEFAULT HEAP   Γöé malloc      Γöé _debug_malloc   Γöé
  10010. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  10011. Γöé USER HEAP     Γöé _umalloc     Γöé _debug_umalloc  Γöé
  10012. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  10013. Γöé TILED HEAP    Γöé _tmalloc     Γöé _debug_tmalloc  Γöé
  10014. Γöé ("/Gt")      Γöé          Γöé          Γöé
  10015. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  10016.  
  10017. To use these extensions, you must set the language level to extended, either 
  10018. with the /Se compiler option or the /Se compiler option or the #pragma 
  10019. langlvl(extended) directive. 
  10020.  
  10021.  
  10022. ΓòÉΓòÉΓòÉ <hidden> Related Information ΓòÉΓòÉΓòÉ
  10023.  
  10024.      Differentiating between Memory Management Functions 
  10025.      Heap-Specific Functions 
  10026.      Debug Functions 
  10027.      Managing Memory 
  10028.      Debugging Your Heaps 
  10029.  
  10030.  
  10031. ΓòÉΓòÉΓòÉ 15.1.1. Heap-Specific Functions ΓòÉΓòÉΓòÉ
  10032.  
  10033. Use the heap-specific versions to allocate and free memory from a user-created 
  10034. heap that you specify.  (You can also explicitly use the runtime heap if you 
  10035. want.)  Their names are prefixed by _u (for "user heaps"), for example, 
  10036. _umalloc, and they are defined in <umalloc.h>. 
  10037.  
  10038. The functions provided are: 
  10039.  
  10040.      _ucalloc 
  10041.      _umalloc 
  10042.      _uheapmin 
  10043.  
  10044.  Notice there is no heap-specific version of realloc or free. Because they both 
  10045.  always check what heap the memory was allocated from, you can always use the 
  10046.  regular versions regardless of what heap the memory came from. 
  10047.  
  10048.  For more information about creating your own heaps and using the heap-specific 
  10049.  memory management functions, see Managing Memory with Multiple Heaps. 
  10050.  
  10051.  
  10052. ΓòÉΓòÉΓòÉ 15.1.2. Debug Functions ΓòÉΓòÉΓòÉ
  10053.  
  10054. Use these functions to allocate and free memory from the default runtime heap, 
  10055. just as you would use the regular versions. They also provide information that 
  10056. you can use to debug memory problems. 
  10057.  
  10058. Note:  The information provided by these functions is Diagnosis, Modification, 
  10059.        and Tuning information only.  It is not intended to be used as a 
  10060.        programming interface. 
  10061.  
  10062.  When you use the debug memory compiler option, /Tm, all calls to the regular 
  10063.  memory management functions are mapped to their debug versions. You can also 
  10064.  call the debug versions explicitly. 
  10065.  
  10066.  Note:  If you parenthesize the calls to the regular memory management 
  10067.  functions, they are not mapped to their debug versions. 
  10068.  
  10069.  We recommend you place a #pragma strings(readonly) directive at the top of 
  10070.  each source file that will call debug functions, or in a common header file 
  10071.  that each includes. This directive is not essential, but it ensures that the 
  10072.  file name passed to the debug functions can't be overwritten, and that only 
  10073.  one copy of the file name string is included in the object module. 
  10074.  
  10075.  The names of the debug versions are prefixed by _debug_, for example, 
  10076.  _debug_malloc, and they are defined in <malloc.h> and <stdlib.h>. 
  10077.  
  10078.  The functions provided are: 
  10079.  
  10080.      _debug_calloc 
  10081.      _debug_free 
  10082.      _debug_heapmin 
  10083.      _debug_malloc 
  10084.      _debug_realloc 
  10085.      _debug_new 
  10086.  
  10087.  In addition to their usual behavior, these functions also store information 
  10088.  (file name and line number) about each call made to them.  Each call also 
  10089.  automatically checks the heap by calling _heap_check (described below). 
  10090.  
  10091.  Three additional debug memory management functions do not have regular 
  10092.  counterparts: 
  10093.  
  10094.      _dump_allocated 
  10095.  
  10096.       Prints information to file handle 2 (the usual destination of stderr) 
  10097.       about each memory block currently allocated by the debug functions. You 
  10098.       can change the destination of the information with the 
  10099.       _set_crt_msg_handle function. 
  10100.  
  10101.      _dump_allocated_delta 
  10102.  
  10103.       Prints information to file handle 2 about each memory block allocated by 
  10104.       the debug functions since the last call to _dump_allocated or 
  10105.       _dump_allocated_delta. Again, you can change the destination of the 
  10106.       information with the _set_crt_msg_handle function. 
  10107.  
  10108.      _heap_check 
  10109.  
  10110.       Checks all memory blocks allocated or freed by the debug functions to 
  10111.       make sure that no overwriting has occurred outside the bounds of 
  10112.       allocated blocks or in a free memory block. 
  10113.  
  10114.  The debug functions call _heap_check automatically; you can also call it 
  10115.  explicitly. To use _dump_allocated and _dump_allocated_delta, you must call 
  10116.  them explicitly. 
  10117.  
  10118.  
  10119. ΓòÉΓòÉΓòÉ 15.2. Managing Memory with Multiple Heaps ΓòÉΓòÉΓòÉ
  10120.  
  10121. VisualAge for C++ now gives you the option of creating and using your own pools 
  10122. of memory, called heaps. You can use your own heaps in place of or in addition 
  10123. to the default VisualAge for C++ runtime heap to improve the performance of 
  10124. your program. This section describes how to implement multiple user-created 
  10125. heaps using VisualAge for C++. 
  10126.  
  10127. Note:  Many readers will not be interested in creating their own heaps. Using 
  10128. your own heaps is entirely optional, and your applications will work perfectly 
  10129. well using the default memory management provided (and used by) the VisualAge 
  10130. for C++ runtime library. If you want to improve the performance and memory 
  10131. management of your program, multiple heaps can help you.  Otherwise, you can 
  10132. ignore this section and any heap-specific library functions. 
  10133.  
  10134.  
  10135. ΓòÉΓòÉΓòÉ 15.2.1. Why Use Multiple Heaps? ΓòÉΓòÉΓòÉ
  10136.  
  10137. Using a single runtime heap is fine for most programs. However, using multiple 
  10138. heaps can be more efficient and can help you improve your program's performance 
  10139. and reduce wasted memory for a number of reasons: 
  10140.  
  10141.      When you allocate from a single heap, you may end up with memory blocks 
  10142.       on different pages of memory. For example, you might have a linked list 
  10143.       that allocates memory each time you add a node to the list.  If you 
  10144.       allocate memory for other data in between adding nodes, the memory blocks 
  10145.       for the nodes could end up on many different pages. To access the data in 
  10146.       the list, the system may have to swap many pages, which can significantly 
  10147.       slow your program. 
  10148.  
  10149.       With multiple heaps, you can specify which heap you allocate from. For 
  10150.       example, you might create a heap specifically for the linked list.  The 
  10151.       list's memory blocks and the data they contain would remain close 
  10152.       together on fewer pages, reducing the amount of swapping required. 
  10153.  
  10154.      In multithread applications, only one thread can access the heap at a 
  10155.       time to ensure memory is safely allocated and freed. For example, say 
  10156.       thread 1 is allocating memory, and thread 2 has a call to free.  Thread 2 
  10157.       must wait until thread 1 has finished its allocation before it can access 
  10158.       the heap. Again, this can slow down performance, especially if your 
  10159.       program does a lot of memory operations. 
  10160.  
  10161.       If you create a separate heap for each thread, you can allocate from them 
  10162.       concurrently, eliminating both the waiting period and the overhead 
  10163.       required to serialize access to the heap. 
  10164.  
  10165.      With a single heap, you must explicitly free each block that you 
  10166.       allocate. If you have a linked list that allocates memory for each node, 
  10167.       you have to traverse the entire list and free each block individually, 
  10168.       which can take some time. 
  10169.  
  10170.       If you create a separate heap for that linked list, you can destroy it 
  10171.       with a single call and free all the memory at once. 
  10172.  
  10173.      When you have only one heap, all components share it (including the 
  10174.       VisualAge for C++ runtime library, vendor libraries, and your own code). 
  10175.       If one component corrupts the heap, another component might fail.  You 
  10176.       may have trouble discovering the cause of the problem and where the heap 
  10177.       was damaged. 
  10178.  
  10179.       With multiple heaps, you can create a separate heap for each component, 
  10180.       so if one damages the heap (for example, by using a freed pointer), the 
  10181.       others can continue unaffected. You also know where to look to correct 
  10182.       the problem. 
  10183.  
  10184.  You can create heaps of regular memory or shared memory, and you can have any 
  10185.  number of heaps of any type. (See Types of Memory for more information about 
  10186.  the different types of memory for heaps.) The only limit is the space 
  10187.  available on your operating system (your machine's memory and swapper size, 
  10188.  minus the memory required by other running applications). 
  10189.  
  10190.  VisualAge for C++ provides heap-specific versions of the memory management 
  10191.  functions (malloc and so on), and a number of new functions that you can use 
  10192.  to create and manage your own heaps of memory. Debug versions of all the 
  10193.  memory management functions are available, including the heap-specific ones. 
  10194.  
  10195.  Note:  Because multiple heaps and the functions that support them are 
  10196.  extensions to the ANSI language standard, you can only use them when the 
  10197.  language level is set to extended. The language level is set to extended using 
  10198.  either the /Se compiler option ("on" by default) or the #pragma 
  10199.  langlvl(extended) directive. 
  10200.  
  10201.  The following sections describe how to create and use your own heaps.  For 
  10202.  detailed information on each function, refer to the C Library Reference. 
  10203.  
  10204.  
  10205. ΓòÉΓòÉΓòÉ 15.2.2. Creating a Fixed-Size Heap ΓòÉΓòÉΓòÉ
  10206.  
  10207. Before you create a heap, you need to get the block of memory that will make up 
  10208. the heap. You can get this block by calling a Windows API (such as 
  10209. VirtualAlloc) or by statically allocating it. 
  10210.  
  10211. Make sure the block is large enough to satisfy all the memory requests your 
  10212. program will make of it, as well as the internal information for managing the 
  10213. heap. Once the block is fully allocated, further allocation requests to the 
  10214. heap will fail. 
  10215.  
  10216. The internal information requires _HEAP_MIN_SIZE bytes (_HEAP_MIN_SIZE is 
  10217. defined in <umalloc.h>); you cannot create a heap smaller than this. Add the 
  10218. amount of memory your program requires to this value to determine the size of 
  10219. the block you need to get. 
  10220.  
  10221. Also make sure the block is the correct type (regular or shared) for the heap 
  10222. you are creating. 
  10223.  
  10224. Once you have the block of memory, create the heap with _ucreate. 
  10225.  
  10226. For example: 
  10227.  
  10228.   Heap_t fixedHeap;   /* this is the "heap handle" */
  10229.   /* get memory for internal info plus 5000 bytes for the heap */
  10230.   static char block[_HEAP_MIN_SIZE + 5000];
  10231.  
  10232.   fixedHeap = _ucreate(block, (_HEAP_MIN_SIZE+5000),  /* block to use */
  10233.             !_BLOCK_CLEAN,  /* memory is not set to 0  */
  10234.             _HEAP_REGULAR,  /* regular memory      */
  10235.             NULL, NULL);   /* we'll explain this later */
  10236.  
  10237. The !_BLOCK_CLEAN parameter indicates that the memory in the block has not been 
  10238. initialized to 0. If it were set to 0 (for example, by VirtualAlloc or memset), 
  10239. you would specify _BLOCK_CLEAN. The calloc and _ucalloc functions use this 
  10240. information to improve their efficiency; if the memory is already initialized 
  10241. to 0, they don't need to initialize it. 
  10242.  
  10243. Note:  VirtualAlloc returns an area of 0's to you. You can also use memset to 
  10244. initialize the memory; however, memset also commits all the memory at once, 
  10245. which could slow overall performance. 
  10246.  
  10247. The fourth parameter indicates what type of memory the heap contains: regular 
  10248. (_HEAP_REGULAR) or shared (_HEAP_SHARED). The different memory types are 
  10249. described in Types of Memory. 
  10250.  
  10251. For a fixed-size heap, the last two parameters are always NULL. 
  10252.  
  10253.  
  10254. ΓòÉΓòÉΓòÉ 15.2.2.1. Using Your Heap ΓòÉΓòÉΓòÉ
  10255.  
  10256. Once you have created your heap, you need to open it for use by calling _uopen: 
  10257.  
  10258.   _uopen(fixedHeap);
  10259.  
  10260. This opens the heap for that particular process; if the heap is shared, each 
  10261. process that uses the heap needs its own call to _uopen. 
  10262.  
  10263. You can then allocate and free from your own heap just as you would from the 
  10264. default heap.  To allocate memory, use _ucalloc or _umalloc. These functions 
  10265. work just like calloc and malloc, except you specify the heap to use as well as 
  10266. the size of block that you want. For example, to allocate 1000 bytes from 
  10267. fixedHeap: 
  10268.  
  10269.   void *up;
  10270.   up = _umalloc(fixedHeap, 1000);
  10271.  
  10272. To reallocate and free memory, use the regular realloc and free functions. Both 
  10273. of these functions always check what heap the memory came from, so you don't 
  10274. need to specify the heap to use. For example, in the following code fragment: 
  10275.  
  10276.   void *p, *up;
  10277.   p = malloc(1000);  /* allocate 1000 bytes from default heap */
  10278.   up = _umalloc(fixedHeap, 1000);  /* allocate 1000 from fixedHeap */
  10279.  
  10280.   realloc(p, 2000);  /* reallocate from default heap */
  10281.   realloc(up, 100);  /* reallocate from fixedHeap   */
  10282.  
  10283.   free(p);       /* free memory back to default heap */
  10284.   free(up);      /* free memory back to fixedHeap   */
  10285.  
  10286. the realloc and free calls look exactly the same for both the default heap and 
  10287. your heap. 
  10288.  
  10289. For any object, you can find out what heap it was allocated from by calling 
  10290. _mheap. You can also get information about the heap itself by calling _ustats, 
  10291. which tells you: 
  10292.  
  10293.      How much memory the heap holds (excluding memory used for overhead) 
  10294.      How much memory is currently allocated from the heap 
  10295.      What type of memory is in the heap 
  10296.      The size of the largest contiguous piece of memory available from the 
  10297.       heap 
  10298.  
  10299.  When you call any heap function, make sure the heap you specify is valid.  If 
  10300.  the heap is not valid, the behavior of the heap functions is undefined. 
  10301.  
  10302.  
  10303. ΓòÉΓòÉΓòÉ 15.2.2.2. Adding to a Fixed-Size Heap ΓòÉΓòÉΓòÉ
  10304.  
  10305. Although you created the heap with a fixed size, you can add blocks of memory 
  10306. to it with _uaddmem. This can be useful if you have a large amount of memory 
  10307. that is allocated conditionally. Like the starting block, you must first get 
  10308. the block to add to the heap by using a Windows API or by allocating it 
  10309. statically. Make sure the block you add is the same type of memory as the heap 
  10310. you are adding it to. 
  10311.  
  10312. For example, to add 64K to fixedHeap: 
  10313.  
  10314.   void *newblock;
  10315.   /* get memory block from operating system */
  10316.   newblock = VirtualAlloc(NULL,65536,SYS_COMMIT, SYS_READWRITE)
  10317.  
  10318.   _uaddmem(fixedHeap,    /* heap to add to */
  10319.       newblock, 65536, /* block to add  */
  10320.       _BLOCK_CLEAN);  /* VirtualAlloc sets memory to 0 */
  10321.  
  10322. Using _uaddmem is the only way to increase the size of a fixed heap. 
  10323.  
  10324. Note:  For every block of memory you add, a small number of bytes from it are 
  10325. used to store internal information. To reduce the total amount of overhead, it 
  10326. is better to add a few large blocks of memory than many small blocks. 
  10327.  
  10328.  
  10329. ΓòÉΓòÉΓòÉ 15.2.2.3. Destroying Your Heap ΓòÉΓòÉΓòÉ
  10330.  
  10331. When you have finished using the heap, close it with _uclose. Once you have 
  10332. closed the heap in a process, that process can no longer allocate from or 
  10333. return memory to that heap. If other processes share the heap, they can still 
  10334. use it until you close it in each of them. Performing operations on a heap 
  10335. after you've closed it causes undefined behavior. 
  10336.  
  10337. To finally destroy the heap, call _udestroy. If blocks of memory are still 
  10338. allocated somewhere, you can force the destruction. Destroying a heap removes 
  10339. it entirely even if it was shared by other processes. Again, performing 
  10340. operations on a heap after you've destroyed it causes undefined behavior. 
  10341.  
  10342. After you destroy your fixed-size heap, it is up to you to return the memory 
  10343. for the heap (the initial block of memory you supplied to _ucreate and any 
  10344. other blocks added by _uaddmem) to the system. 
  10345.  
  10346.  
  10347. ΓòÉΓòÉΓòÉ 15.2.3. Creating an Expandable Heap ΓòÉΓòÉΓòÉ
  10348.  
  10349. With a fixed-size heap, the initial block of memory must be large enough to 
  10350. satisfy all allocation requests made to it. In this section, we will create a 
  10351. heap that can expand and contract. 
  10352.  
  10353. With the VisualAge for C++ runtime heap, when not enough storage is available 
  10354. for your malloc request, the runtime gets additional storage from the system. 
  10355. Similarly, when you minimize the heap with _heapmin or when your program ends, 
  10356. the runtime returns the memory to the operating system. 
  10357.  
  10358. When you create an expandable heap, you provide your own functions to do this 
  10359. work (we'll call them getmore_fn and release_fn, although you can name them 
  10360. whatever you choose). You specify pointers to these functions as the last two 
  10361. parameters to _ucreate (instead of the NULL pointers you used to create a 
  10362. fixed-size heap). For example: 
  10363.  
  10364.   Heap_t growHeap;
  10365.   static char block[_HEAP_MIN_SIZE];  /* get block */
  10366.  
  10367.   growHeap = _ucreate(block, _HEAP_MIN_SIZE,  /* starting block */
  10368.             !_BLOCK_CLEAN,    /* memory not set to 0 */
  10369.             _HEAP_REGULAR,    /* regular memory    */
  10370.             getmore_fn,   /* function to expand heap */
  10371.             release_fn);   /* function to shrink heap */
  10372.  
  10373. Note:  You can use the same getmore_fn and release_fn for more than one heap, 
  10374. as long as the heaps use the same type of memory and your functions are not 
  10375. written specifically for one heap. 
  10376.  
  10377.  
  10378. ΓòÉΓòÉΓòÉ 15.2.3.1. Expanding Your Heap ΓòÉΓòÉΓòÉ
  10379.  
  10380. When you call _umalloc (or a similar function) for your heap, _umalloc tries to 
  10381. allocate the memory from the initial block you provided to _ucreate. If not 
  10382. enough memory is there, it then calls your getmore_fn. Your getmore_fn then 
  10383. gets more memory from the operating system and adds it to the heap. It is up to 
  10384. you how you do this. 
  10385.  
  10386. Your getmore_fn must have the following prototype: 
  10387.  
  10388.   void *(*getmore_fn)(Heap_t uh, size_t *size, int *clean);
  10389.  
  10390. The uh is the heap to be expanded. 
  10391.  
  10392. The size is the size of the allocation request passed by _umalloc. You probably 
  10393. want to return enough memory at a time to satisfy several allocations; 
  10394. otherwise every subsequent allocation has to call getmore_fn, reducing your 
  10395. program's execution speed. Make sure that you update the size parameter. if you 
  10396. return more than the size requested. 
  10397.  
  10398. Your function must also set the clean parameter to either _BLOCK_CLEAN, to 
  10399. indicate the memory has been set to 0, or !_BLOCK_CLEAN, to indicate that the 
  10400. memory has not been initialized. 
  10401.  
  10402. The following fragment shows an example of a getmore_fn: 
  10403.  
  10404.   static void *getmore_fn(Heap_t uh, size_t *length, int *clean)
  10405.   {
  10406.    char *newblock;
  10407.  
  10408.    /* round the size up to a multiple of 64K */
  10409.    *length = (*length / 65536) * 65536 + 65536;
  10410.  
  10411.    newblock = VirtualAlloc(NULL,*length, MEM_COMMIT, PAGE_READWRITE);
  10412.  
  10413.    *clean = _BLOCK_CLEAN;  /* mark the block as "clean" */
  10414.    return(newblock);    /* return new memory block  */
  10415.   }
  10416.  
  10417. Note:  Be sure that your getmore_fn allocates the right type of memory (regular 
  10418. or shared) for the heap.  There are also special considerations for shared 
  10419. memory, described under Types of Memory. 
  10420.  
  10421. You can also use _uaddmem to add blocks to your heap, as you did for the fixed 
  10422. heap in Adding to a Fixed-Size Heap. _uaddmem works exactly the same way for 
  10423. expandable heaps. 
  10424.  
  10425.  
  10426. ΓòÉΓòÉΓòÉ 15.2.3.2. Shrinking Your Heap ΓòÉΓòÉΓòÉ
  10427.  
  10428. To coalesce the heap (return all blocks in the heap that are totally free to 
  10429. the system), use _uheapmin. _uheapmin works like _heapmin, except that you 
  10430. specify the heap to use. 
  10431.  
  10432. When you call _uheapmin to coalesce the heap or _udestroy to destroy it, these 
  10433. functions call your release_fn to return the memory to the system.  Again, it 
  10434. is up to you how you implement this function. 
  10435.  
  10436. Your release_fn must have the following prototype: 
  10437.  
  10438.   void (*release_fn)(Heap_t uh, void *block, size_t size);
  10439.  
  10440. Where uh identifies the heap to be shrunk. The pointer block and its size are 
  10441. passed to your function by _uheapmin or _udestroy.  Your function must return 
  10442. the memory pointed to by block to the system. For example: 
  10443.  
  10444.   static void release_fn(Heap_t uh, void *block, size_t size)
  10445.   {
  10446.    VirtualFree(block,0,MEM-RELEASE);
  10447.    return;
  10448.   }
  10449.  
  10450. Note: 
  10451.  
  10452.    1. _udestroy calls your release_fn to return all memory added to the uh heap 
  10453.       by your getmore_fn or by _uaddmem.  However, you are responsible for 
  10454.       returning the initial block of memory that you supplied to _ucreate. 
  10455.  
  10456.    2. Because a fixed-size heap has no release_fn, _uheapmin and _udestroy work 
  10457.       slightly differently. Calling _uheapmin for a fixed-size heap has no 
  10458.       effect but does not cause an error; _uheapmin simply returns 0. Calling 
  10459.       _udestroy for a fixed-size heap marks the heap as destroyed, so no 
  10460.       further operations can be performed on it, but returns no memory.  It is 
  10461.       up to you to return the heap's memory to the system. 
  10462.  
  10463.  
  10464. ΓòÉΓòÉΓòÉ 15.2.4. Types of Memory ΓòÉΓòÉΓòÉ
  10465.  
  10466. There are two types of memory: 
  10467.  
  10468.    1. Regular 
  10469.  
  10470.       Most programs use regular memory.  This is the type provided by the 
  10471.       default runtime heap. 
  10472.  
  10473.    2. Shared 
  10474.  
  10475.       To create and use a shared memory heap in Win32 requires: 
  10476.  
  10477.           the CreateFileMapping API to create a shareable object in the file 
  10478.            system, then 
  10479.           the MapViewOfFileEx API to map that object into the same address in 
  10480.            each process that wants to access the heap. 
  10481.           Once you have the block of memory, create the heap with _ucreate. 
  10482.  
  10483.  
  10484. ΓòÉΓòÉΓòÉ 15.2.5. Changing the Default Heap ΓòÉΓòÉΓòÉ
  10485.  
  10486. The regular memory management functions (malloc and so on) always use whatever 
  10487. heap is currently the default for that thread. The initial default heap for all 
  10488. VisualAge for C++ applications is the runtime heap provided by VisualAge for 
  10489. C++. However, you can make your own heap the default by calling _udefault. Then 
  10490. all calls to the regular memory management functions allocate from your heap 
  10491. instead of the runtime heap. 
  10492.  
  10493. The default heap changes only for the thread where you call _udefault.  You can 
  10494. use a different default heap for each thread of your program if you choose. 
  10495.  
  10496. This is useful when you want a component (such as a vendor library) to use a 
  10497. heap other than the VisualAge for C++ runtime heap, but you can't actually 
  10498. alter the source code to use heap-specific calls. For example, if you set the 
  10499. default heap to a shared heap then call a library function that calls malloc, 
  10500. the library allocates storage in shared memory. 
  10501.  
  10502. Because _udefault returns the current default heap, you can save the return 
  10503. value and later use it to restore the default heap you replaced. You can also 
  10504. change the default back to the VisualAge for C++ runtime heap by calling 
  10505. _udefault and specifying _RUNTIME_HEAP (defined in <malloc.h>). You can also 
  10506. use this macro with any of the heap-specific functions to explicitly allocate 
  10507. from the runtime heap. 
  10508.  
  10509.  
  10510. ΓòÉΓòÉΓòÉ 15.2.6. A Simple Example of a User Heap ΓòÉΓòÉΓòÉ
  10511.  
  10512. The following program shows very simply how you might create and use a heap. 
  10513.  
  10514.  
  10515. Example of a User Heap
  10516.  
  10517. #include <windows.h>
  10518. #include <stdlib.h>
  10519. #include <stdio.h>
  10520. #include <umalloc.h>
  10521.  
  10522. static void *get_fn(Heap_t usrheap, size_t *length, int *clean)
  10523. {
  10524.   void *p;
  10525.  
  10526.   /* Round up to the next chunk size */
  10527.   *length = ((*length) / 65536) * 65536 + 65536;
  10528.   *clean = _BLOCK_CLEAN;
  10529.   P = VirtualAlloc( NULL, *length,
  10530.     MEM_COMMIT|MEM_RESERVE, PAGE_READWRITE);
  10531.   return (p);
  10532. }
  10533.  
  10534. static void release_fn(Heap_t usrheap, void *p, size_t size)
  10535. {
  10536.   VirtualFree( p, 0, MEM_RELEASE );
  10537.   return;
  10538. }
  10539.  
  10540. int main(void)
  10541. {
  10542.   void   *initial_block;
  10543.   DWORD  rc;
  10544.   Heap_t  myheap;
  10545.   char   *ptr;
  10546.  
  10547.   /* Call VirtualAlloc to get the initial block of memory */
  10548.   if((initial_block == VirtualAlloc( NULL, 65536, MEM_COMMIT|RESERVE,
  10549.      PAGE_READWRITE)) == NULL) {
  10550.   printf("VirtualAlloc error", GetLastError());
  10551.   }
  10552.   /* Create an expandable heap starting with the block declared earlier */
  10553.   if (NULL == (myheap = _ucreate(initial_block, 65536, _BLOCK_CLEAN,
  10554.                  _HEAP_REGULAR, get_fn, release_fn))) {
  10555.    puts("_ucreate failed.");
  10556.    exit(EXIT_FAILURE);
  10557.   }
  10558.   if (0 != _uopen(myheap)) {
  10559.    puts("_uopen failed.");
  10560.    exit(EXIT_FAILURE);
  10561.   }
  10562.  
  10563.   /* Force user heap to grow */
  10564.   ptr = _umalloc(myheap, 100000);
  10565.  
  10566.   _uclose(myheap);
  10567.  
  10568.   if (0 != _udestroy(myheap, _FORCE)) {
  10569.    puts("_udestroy failed.");
  10570.    exit(EXIT_FAILURE);
  10571.   }
  10572.   if(FALSE == VirtualFree( initial_block, 0, MEM_RELEASE)){
  10573.   printf("VirtualAlloc error", GetLastError());
  10574.   }
  10575.   return 0;
  10576. }
  10577.  
  10578.  
  10579. ΓòÉΓòÉΓòÉ 15.2.7. A More Complex Example Featuring Shared Memory ΓòÉΓòÉΓòÉ
  10580.  
  10581. The following program shows how you might implement a heap shared between a 
  10582. parent and several child processes. 
  10583.  
  10584. Example of a User Heap - Parent Process shows the parent process, which creates 
  10585. the shared heap. First the main program calls the init function to allocate 
  10586. shared memory from the operating system (using CreateFileMapping) and name the 
  10587. memory so that other processes can use it by name. The init function then 
  10588. creates and opens the heap. The loop in the main program performs operations on 
  10589. the heap, and also starts other processes. The program then calls the term 
  10590. function to close and destroy the heap. 
  10591.  
  10592. Note:  Sharing memory across processes in Windows/NT and Windows/95 is 
  10593. accomplished by using Win32 File API's, using the system paging file as the 
  10594. shared file. If you wish to use the C library heap functions then you must also 
  10595. ensure that the memory to be shared is allocated at the same address in all 
  10596. processes which will be sharing the heap. 
  10597.  
  10598.  
  10599. ΓòÉΓòÉΓòÉ 15.2.7.1. Example of a User Heap - Parent Process ΓòÉΓòÉΓòÉ
  10600.  
  10601.  
  10602. /* The following program shows how you might implement
  10603.  a heap shared between a parent and several child processes.
  10604.  
  10605.  Example of a Shared User Heap - Parent Process shows the parent
  10606.  process, which creates the shared heap. First
  10607.  the main program calls the init function to allocate shared memory from the operating system (using
  10608.  CreateFileMapping) and name the memory so that other processes can use it by name. The init function
  10609.  then creates and opens the heap. The loop in the main program performs operations on the heap, and also
  10610.  starts other processes. The program then calls the term function to close and destroy the heap.
  10611.  
  10612.  Note: Sharing memory accross processes in Windows/NT and Windows/95 is accomplished
  10613.  by using Win32 File API's, using the system paging file as the shared file. If you wish to use
  10614.  the C library heap functions then you must also ensure that the memory to be shared is allocated
  10615.  at the same address in all processes which will be sharing the heap.
  10616.  
  10617.  */
  10618.  
  10619.  #include <umalloc.h>
  10620.  #include <stdio.h>
  10621.  #include <stdlib.h>
  10622.  #include <string.h>
  10623.  #include <windows.h>
  10624.  #include <winbase.h>
  10625.  
  10626.  #define PAGING_FILE  0xFFFFFFFF
  10627.  #define MEMORY_SIZE  65536
  10628.  #define BASE_MEM   (VOID*)0x01000000
  10629.  
  10630.  static HANDLE hFile;    /* Handle to memory file            */
  10631.  static void*  hMap;     /* Handle to allocated memory          */
  10632.  
  10633.  typedef struct mem_info {
  10634.   void  * pBase;
  10635.   Heap_t  pHeap;
  10636.  } MEM_INFO_T;
  10637.  
  10638.  /*------------------------------------------------------------------------*/
  10639.  /* inithp:                                 */
  10640.  /* Function to create and open the heap with a named shared memory object */
  10641.  /*------------------------------------------------------------------------*/
  10642.  static Heap_t inithp(size_t heap_size)
  10643.  {
  10644.   MEM_INFO_T info;            /* Info structure        */
  10645.  
  10646.   /* Allocate shared memory from the system by creating a shared memory  */
  10647.   /* pool basing it out of the system paging (swapper) file.       */
  10648.  
  10649.   hFile = CreateFileMapping( (HANDLE) PAGING_FILE,
  10650.                 NULL,
  10651.                 PAGE_READWRITE,
  10652.                 0,
  10653.                 heap_size + sizeof(Heap_t),
  10654.                 "MYNAME_SHAREMEM" );
  10655.   if (hFile == NULL) {
  10656.    return NULL;
  10657.   }
  10658.  
  10659.   /* Map the file to this process' address space, starting at an address  */
  10660.   /* that should also be available in child processe(s)          */
  10661.  
  10662.   hMap = MapViewOfFileEx( hFile, FILE_MAP_WRITE, 0, 0, 0, BASE_MEM );
  10663.  
  10664.   info.pBase = hMap;
  10665.   if (info.pBase == NULL) {
  10666.    return NULL;
  10667.   }
  10668.  
  10669.   /* Create a fixed sized heap.  Put the heap handle as well as the    */
  10670.   /* base heap address at the beginning of the shared memory.       */
  10671.  
  10672.   info.pHeap = _ucreate((char *)info.pBase + sizeof(info),
  10673.            heap_size - sizeof(info),
  10674.            !_BLOCK_CLEAN,
  10675.            _HEAP_SHARED | _HEAP_REGULAR,
  10676.            NULL, NULL);
  10677.  
  10678.    if (info.pBase == NULL) {
  10679.     return NULL;
  10680.    }
  10681.  
  10682.   memcpy(info.pBase, info, sizeof(info));
  10683.  
  10684.   if (_uopen(info.pHeap)) {       /* Open heap and check result   */
  10685.     return NULL;
  10686.   }
  10687.  
  10688.   return info.pHeap;
  10689.  
  10690.  }
  10691.  
  10692.  /*------------------------------------------------------------------------*/
  10693.  /* termhp:                                 */
  10694.  /* Function to close and destroy the heap                 */
  10695.  /*------------------------------------------------------------------------*/
  10696.  static int termhp(Heap_t uheap)
  10697.  {
  10698.   if (_uclose(uheap))            /* close heap         */
  10699.     return 1;
  10700.   if (_udestroy(uheap, _FORCE))       /* force destruction of heap */
  10701.     return 1;
  10702.  
  10703.   UnmapViewOfFile(hMap);           /* return memory to system  */
  10704.   CloseHandle(hFile);
  10705.  
  10706.   return 0;
  10707.  }
  10708.  
  10709.  /*------------------------------------------------------------------------*/
  10710.  /* main:                                  */
  10711.  /* Main function to test creating, writing to and destroying a shared   */
  10712.  /* heap.                                  */
  10713.  /*------------------------------------------------------------------------*/
  10714.  int main(void)
  10715.  {
  10716.   int i, rc;               /* Index and return code      */
  10717.   Heap_t uheap;             /* heap to create         */
  10718.   void *init_block;           /* initial block to use      */
  10719.   char *p;                /* for allocating from heap    */
  10720.  
  10721.   /*                                    */
  10722.   /* call init function to create and open the heap            */
  10723.   /*
  10724.   uheap = inithp(MEMORY_SIZE);
  10725.   if (uheap == NULL)           /* check for success        */
  10726.     return 1;              /* if failure, return non zero   */
  10727.  
  10728.   /*                                    */
  10729.   /* perform operations on uheap                      */
  10730.   /*                                    */
  10731.   for (i = 1; i <= 5; i++)
  10732.   {
  10733.     p = _umalloc(uheap, 10);      /* allocate from uheap       */
  10734.     if (p == NULL)
  10735.      return 1;
  10736.     memset(p, 'M', _msize(p));     /* set all bytes in p to 'M'    */
  10737.     p = realloc(p,50);         /* reallocate from uheap      */
  10738.     if (p == NULL)
  10739.      return 1;
  10740.     memset(p, 'R', _msize(p));     /* set all bytes in p to 'R'    */
  10741.   }
  10742.  
  10743.   /*                                    */
  10744.   /* Start a second process which accesses the heap            */
  10745.   /*                                    */
  10746.   if (system("memshr2.exe"))
  10747.    return 1;
  10748.  
  10749.   /*                                    */
  10750.   /* Take a look at the memory that we just wrote to. Note that memshr.c  */
  10751.   /* and memshr2.c should have been compiled specifying the /Tm+ flag.   */
  10752.   /*                                    */
  10753.   #ifdef DEBUG
  10754.    _udump_allocated(uheap, -1);
  10755.   #endif
  10756.  
  10757.   /*                                    */
  10758.   /* call term function to close and destroy the heap           */
  10759.   /*                                    */
  10760.   rc = termhp(uheap);
  10761.  
  10762.   #ifdef DEBUG
  10763.    printf("memshr ending... rc = %d\n", rc);
  10764.   #endif
  10765.  
  10766.   return rc;
  10767. }
  10768.  
  10769. Example of a Shared User Heap- Child Process shows the process started by the 
  10770. loop in the parent process. This process uses OpenFileMapping to access the 
  10771. shared memory by name, then extracts the heap handle for the heap created by 
  10772. the parent process. The process then opens the heap, makes it the default heap, 
  10773. and performs some operations on it in the loop. After the loop, the process 
  10774. replaces the old default heap, closes the user heap, and ends. 
  10775.  
  10776.  
  10777. ΓòÉΓòÉΓòÉ 15.2.7.2. Example of a Shared User Heap- Child Process ΓòÉΓòÉΓòÉ
  10778.  
  10779. /* Example of a Shared User Heap - Child Process shows
  10780.   the process started by the loop in the parent process.
  10781.   This process uses OpenFileMapping to access the shared memory
  10782.   by name, then extracts the heap handle for the heap created
  10783.   by the parent process. The process then opens the heap,
  10784.   makes it the default heap, and performs some operations
  10785.   on it in the loop. After the loop, the process replaces
  10786.   the old default heap, closes the user heap, and ends.
  10787.  
  10788.  
  10789.  */
  10790.  
  10791.  #include <umalloc.h>
  10792.  #include <stdio.h>
  10793.  #include <stdlib.h>
  10794.  #include <string.h>
  10795.  #include <windows.h>
  10796.  #include <winbase.h>
  10797.  
  10798.  static HANDLE hFile;    /* Handle to memory file            */
  10799.  static void*  hMap;     /* Handle to allocated memory          */
  10800.  
  10801.  typedef struct mem_info {
  10802.   void  * pBase;
  10803.   Heap_t  pHeap;
  10804.  } MEM_INFO_T;
  10805.  
  10806.  /*------------------------------------------------------------------------*/
  10807.  /* inithp:  Subprocess Version                       */
  10808.  /* Function to create and open the heap with a named shared memory object */
  10809.  /*------------------------------------------------------------------------*/
  10810.  static Heap_t inithp(void)
  10811.  {
  10812.  
  10813.   MEM_INFO_T info;            /* Info structure        */
  10814.  
  10815.   /* Open the shared memory file by name.  The file is based on the    */
  10816.   /* system paging (swapper) file.                    */
  10817.  
  10818.   hFile = OpenFileMapping(FILE_MAP_WRITE, FALSE, "MYNAME_SHAREMEM");
  10819.  
  10820.   if (hFile == NULL) {
  10821.    return NULL;
  10822.   }
  10823.  
  10824.   /* Figure out where to map this file by looking at the address in the  */
  10825.   /* shared memory where the memory was mapped in the parent process.   */
  10826.  
  10827.   hMap = MapViewOfFile( hFile, FILE_MAP_WRITE, 0, 0, sizeof(info) );
  10828.  
  10829.   if (hMap == NULL) {
  10830.    return NULL;
  10831.   }
  10832.  
  10833.   /* Extract the heap and base memory address from shared memory      */
  10834.  
  10835.   memcpy(info, hMap, sizeof(info));
  10836.   UnmapViewOfFile(hMap);
  10837.  
  10838.   hMap = MapViewOfFileEx( hFile, FILE_MAP_WRITE, 0, 0, 0, info.pBase );
  10839.  
  10840.   if (_uopen(info.pHeap)) {      /* Open heap and check result    */
  10841.     return NULL;
  10842.   }
  10843.  
  10844.   return info.pHeap;
  10845.  }
  10846.  
  10847.  /*------------------------------------------------------------------------*/
  10848.  /* termhp:                                 */
  10849.  /* Function to close my view of the heap                  */
  10850.  /*------------------------------------------------------------------------*/
  10851.  static int termhp(Heap_t uheap)
  10852.  {
  10853.   if (_uclose(uheap))            /* close heap         */
  10854.     return 1;
  10855.  
  10856.   UnmapViewOfFile(hMap);           /* return memory to system  */
  10857.   CloseHandle(hFile);
  10858.  
  10859.   return 0;
  10860.  }
  10861.  
  10862.  /*------------------------------------------------------------------------*/
  10863.  /* main:                                  */
  10864.  /* Main function to test creating, writing to and destroying a shared   */
  10865.  /* heap.                                  */
  10866.  /*------------------------------------------------------------------------*/
  10867.  int main(void)
  10868.  {
  10869.   int rc, i;            /* for return code, loop iteration   */
  10870.   Heap_t uheap, oldheap;      /* heap to create, old default heap  */
  10871.   char *p;             /* for allocating from the heap    */
  10872.  
  10873.   /*                                   */
  10874.   /* Get the heap storage from the shared memory             */
  10875.   /*                                   */
  10876.   uheap = inithp();
  10877.   if (uheap == NULL)
  10878.    return 1;
  10879.  
  10880.   /*                                   */
  10881.   /* Register uheap as default runtime heap, save old default      */
  10882.   /*                                   */
  10883.   oldheap = _udefault(uheap);
  10884.   if (oldheap == NULL) {
  10885.     return termhp(uheap);
  10886. }
  10887.  
  10888.   /*                                   */
  10889.   /* Perform operations on uheap                     */
  10890.   /*                                   */
  10891.   for (i = 1; i <= 5; i++)
  10892.   {
  10893.     p = malloc(10);   /* malloc uses default heap, which is now uheap*/
  10894.     memset(p, 'M', _msize(p));
  10895.   }
  10896.  
  10897.   /*                                   */
  10898.   /* Replace original default heap and check result           */
  10899.   /*                                   */
  10900.   if (uheap != _udefault(oldheap)) {
  10901.     return termhp(uheap);
  10902. }
  10903.  
  10904.   /*                                   */
  10905.   /* Close my views of the heap                     */
  10906.   /*                                   */
  10907.   rc = termhp(uheap);
  10908.  
  10909.   #ifdef DEBUG
  10910.    printf("Returning from memshr2 rc = %d\n", rc);
  10911.   #endif
  10912.   return rc;
  10913.  
  10914.  }
  10915.  
  10916.  
  10917. ΓòÉΓòÉΓòÉ 15.3. Debugging Your Heaps ΓòÉΓòÉΓòÉ
  10918.  
  10919. VisualAge for C++ provides two sets of functions for debugging your memory 
  10920. problems: 
  10921.  
  10922.    1. Debug Memory Management Functions 
  10923.  
  10924.    2. Heap-Checking Functions 
  10925.  
  10926.    3. Which Should I Use? 
  10927.  
  10928.  
  10929. ΓòÉΓòÉΓòÉ 15.3.1. Debug Memory Management Functions ΓòÉΓòÉΓòÉ
  10930.  
  10931. Debug versions of the heap-specific memory management functions are provided, 
  10932. just as they are for the regular versions. Each debug version performs the same 
  10933. function as its non-debug counterpart.  In addition, the debug version calls 
  10934. _uheap_check to check the heap used in the call, and records the file and line 
  10935. number where the memory was allocated or freed.  You can then use 
  10936. _dump_allocated or _dump_allocated_delta to display information about currently 
  10937. allocated memory blocks. Information is printed to stderr; you can change the 
  10938. destination with the _set_crt_msg_handle function. 
  10939.  
  10940. You can use debug memory management functions for any type of heap, including 
  10941. shared memory. To use the debug versions, specify the Debug Memory compiler 
  10942. option, /Tm. The VisualAge for C++ compiler then maps all calls to memory 
  10943. management functions (regular or heap-specific) to the corresponding debug 
  10944. version. 
  10945.  
  10946. Note:  If you parenthesize the name of a memory management function, the 
  10947. function is not mapped to the debug version. This does not apply to the C++ new 
  10948. and delete functions, which are mapped to their debug versions regardless of 
  10949. parentheses. 
  10950.  
  10951.  
  10952. ΓòÉΓòÉΓòÉ 15.3.1.1. Skipping Heap Checks ΓòÉΓòÉΓòÉ
  10953.  
  10954. As stated above, each debug function calls _heap_check (or _uheap_check) to 
  10955. check the heap.  Although this is useful, it can also increase your program's 
  10956. memory requirements and decrease its execution speed. 
  10957.  
  10958. To reduce the overhead of checking the heap on every debug memory management 
  10959. function, you can control how often the functions check the heap with the 
  10960. CPP_HEAP_SKIP environment variable. This is not required in most applications 
  10961. unless the application is extremely memory intensive. 
  10962.  
  10963. Set CPP_HEAP_SKIP with the SET command, like any other environment variable. 
  10964. You can set it either in CONFIG.SYS, from the command line, or in your project. 
  10965. The syntax for CPP_HEAP_SKIP is: 
  10966.  
  10967.   SET CPP_HEAP_SKIP= increment, [start]
  10968.  
  10969. increment specifies how often you want the debug functions to check the heap. 
  10970. In the above statement, the comma is optional. The start parameter is also 
  10971. optional; you can use it to start skipping heap checks after start calls to 
  10972. debug functions. 
  10973.  
  10974. When you use start parameter to start skipping heap checks, you are trading off 
  10975. heap checks that are done implicitly against program execution speed.  You 
  10976. should therefore start with a small increment (like 5) and slowly increase 
  10977. until the application is usable. 
  10978.  
  10979. For example, if you specify: 
  10980.  
  10981.   SET CPP_HEAP_SKIP= 10
  10982.  
  10983. then every tenth debug memory function call performs a heap check.  If you 
  10984. specify: 
  10985.  
  10986.   SET CPP_HEAP_SKIP= 5, 100
  10987.  
  10988. then after 100 debug memory function calls, only every fifth call performs a 
  10989. heap check. Other than the heap check, the debug functions behave exactly the 
  10990. same as usual. 
  10991.  
  10992.  
  10993. ΓòÉΓòÉΓòÉ 15.3.2. Heap-Checking Functions ΓòÉΓòÉΓòÉ
  10994.  
  10995. VisualAge for C++ also provides some new functions for validating user heaps: 
  10996. _uheapchk, _uheapset, and _uheap_walk (Each of these functions has a 
  10997. non-heap-specific version that validates the default heap.) 
  10998.  
  10999. Both _uheapchk and _uheapset check the specified heap for minimal consistency; 
  11000. _uheapchk checks the entire heap, while _uheapset checks only the free memory. 
  11001. _uheapset also sets the free memory in the heap to a value you specify. 
  11002. _uheap_walk traverses the heap and provides information about each allocated or 
  11003. freed object to a callback function that you provide.  You can then use the 
  11004. information however you like. 
  11005.  
  11006. These heap-checking functions are defined in <umalloc.h> (the regular versions 
  11007. are also in <malloc.h>). They are not controlled by a compiler option, so you 
  11008. can use them in your program at any time. 
  11009.  
  11010.  
  11011. ΓòÉΓòÉΓòÉ 15.3.3. Which Should I Use? ΓòÉΓòÉΓòÉ
  11012.  
  11013. Both sets of debugging functions have their benefits and drawbacks.  Which you 
  11014. choose to use depends on your program, your problems, and your preference. 
  11015.  
  11016. The debug memory management functions provide detailed information about all 
  11017. allocation requests you make with them in your program. You don't need to 
  11018. change any code to use the debug versions; you need only specify the /Tm 
  11019. compiler option. However, because only calls that have been mapped to debug 
  11020. versions provide any information, you may have to rebuild many or all of your 
  11021. program's modules, which can be time-consuming. 
  11022.  
  11023. On the other hand, the heap-checking functions perform more general checks on 
  11024. the heap at specific points in your program. You have greater control over 
  11025. where the checks the occur. The heap-checking functions also provide 
  11026. compatibility with other compilers that offer these functions. You only have to 
  11027. rebuild the modules that contain the heap-checking calls. However, you have to 
  11028. change your source code to include these calls, which you will probably want to 
  11029. remove in your final code. Also, the heap-checking functions only tell you if 
  11030. the heap is consistent or not; they do not provide the details that the debug 
  11031. memory management functions do. 
  11032.  
  11033. What you may choose to do is add calls to heap-checking functions in places you 
  11034. suspect possible memory problems. If the heap turns out to be corrupted, at 
  11035. that point you may want to rebuild with the /Tm option. 
  11036.  
  11037. Note:  When the debug memory option /Tm is specified, code is generated to 
  11038. pre-initialize the local variables for all functions.  This makes it much more 
  11039. likely that uninitialized local variables will be found during the normal debug 
  11040. cycle rather than much later (usually when the code is optimized). 
  11041.  
  11042. Regardless of which debugging functions you choose, your program requires 
  11043. additional memory to maintain internal information for these functions. If you 
  11044. are using fixed-size heaps, you may have to increase the heap size in order to 
  11045. use the debugging functions. 
  11046.  
  11047. For more information on the debug memory management functions and how to use 
  11048. them, see Debug Functions. 
  11049.  
  11050.  
  11051. ΓòÉΓòÉΓòÉ 16. Casting with Run Time Type Information ΓòÉΓòÉΓòÉ
  11052.  
  11053. Run-Time Type Information, often abbreviated as RTTI, is an extension made by 
  11054. the ANSI/ISO standard committee to the C++ language. One may classify 
  11055. extensions to the language as either minor (those extensions which simply 
  11056. provide a more convenient way of implementing traditional designs) or major 
  11057. (extensions which fundamentally affect the organization of programs). By such a 
  11058. categorization, RTTI would be considered a major extension - similar in impact 
  11059. to templates, exceptions and name spaces. 
  11060.  
  11061. But why was such an extension to the language necessary? The main problem RTTI 
  11062. sought to address was the difficulty encountered by builders and users of major 
  11063. C++ libraries. A mechanism for extending base classes provided in libraries was 
  11064. clearly needed. However, the RTTI mechanisms implemented by builders of the 
  11065. major C++ libraries were incompatible.  In practice, this meant it could be 
  11066. difficult, if not impossible to use more than one library for a given program 
  11067. or to use the same program with different libraries without major changes to 
  11068. the program. Given that one of the goals of the C++ language was to support the 
  11069. reuse of code and the building of programs from parts, the incompatibilities of 
  11070. the RTTI mechanisms used internally by the various C++ libraries presented a 
  11071. fundamental challenge to the stated purpose of C++.  Clearly, a 
  11072. language-supported mechanism was needed. 
  11073.  
  11074. What should the language supported solution look like? It was recognized that 
  11075. the run time type information would be important to some but of little use to 
  11076. others.  No one would argue that providing a consistent, compatible 
  11077. implementation through the C++ language support was goodness and light  for 
  11078. those who needed it - provided it was harmless  to those who did not require 
  11079. it.  That is, the language extension should not impose undesirable overhead 
  11080. costs or changes to previous, reasonable programs. 
  11081.  
  11082. What was the final RTTI implementation design? You could take it or leave it, 
  11083. your use of the mechanism had to be explicitly stated. Should you decide to use 
  11084. it, there are three parts to the support, each corresponding to increasing user 
  11085. involvement and knowledge of the language's RTTI implementation. The part of 
  11086. the mechanism which requires the least user involvement and knowledge also 
  11087. serves the majority of needs.  This is the part of the RTTI construct which 
  11088. users should focus on - dynamic_cast. 
  11089.  
  11090. The parts of the C++ language support for RTTI are: 
  11091.  
  11092.  dynamic_cast operator 
  11093.     This operator combines type-checking and casting in one operation. It 
  11094.     verifies the requested cast is valid and actually performs the cast only if 
  11095.     it is valid. 
  11096.  
  11097.  typeid operator 
  11098.     This operator returns the run-time type of an object. If the operand 
  11099.     provided to the typeid operator is the name of a type, the operator returns 
  11100.     an object that identifies it. If the operand provided is an expression, 
  11101.     typeid returns the type of the object that the expression denotes. 
  11102.  
  11103.  type_info class 
  11104.     This class describes the RTTI available and is used to define the type 
  11105.     returned by the typeid operator. This class provides to users the 
  11106.     possibility of shaping and extending RTTI to suit their own needs. This 
  11107.     ability is of most interest to implementers of object I/O systems such as 
  11108.     debuggers or database systems. 
  11109.  
  11110.  
  11111. ΓòÉΓòÉΓòÉ 16.1. C++ Language Defined RTTI ΓòÉΓòÉΓòÉ
  11112.  
  11113.  
  11114. ΓòÉΓòÉΓòÉ 16.1.1. The dynamic_cast Operator ΓòÉΓòÉΓòÉ
  11115.  
  11116. A dynamic cast expression is used to cast a base class pointer to a derived 
  11117. class pointer (referred to as downcasting.) 
  11118.  
  11119. The dynamic_cast operator makes downcasting much safer than conventional static 
  11120. casting. It obtains a pointer to an object of a derived class given a pointer 
  11121. to a base class of that object. The operator dynamic_cast returns the pointer 
  11122. only if the specific derived class actually exists. If not, it returns zero. 
  11123.  
  11124. Dynamic casts have the form: 
  11125.  
  11126. >>ΓöÇΓöÇdynamic_castΓöÇΓöÇΓöÉΓöÇΓöÇtype_nameΓöÇΓöÇ>ΓöÇΓöÇ(ΓöÇΓöÇexpressionΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ><
  11127.  
  11128. The operator converts the expression to the desired type type_name. The 
  11129. type_name can be a pointer or a reference to a class type. If the cast to 
  11130. type_name fails, the value of the expression is zero. 
  11131.  
  11132.  
  11133. ΓòÉΓòÉΓòÉ 16.1.1.1. Dynamic Casts with Pointers ΓòÉΓòÉΓòÉ
  11134.  
  11135. A dynamic cast using pointers is used to get a pointer to a derived class in 
  11136. order to use some detail of the derived class that is not otherwise available. 
  11137. For example, 
  11138.  
  11139. class employee {
  11140. public:
  11141.   virtual int salary();
  11142. };
  11143.  
  11144. class manager : public employee {
  11145. public:
  11146.   int salary();
  11147.   virtual int bonus();
  11148. };
  11149.  
  11150. In this class hierarchy, dynamic casts can be used to include the 
  11151. manager::bonus() function in the manager's salary calculation but not in the 
  11152. calculation for a regular employee. The dynamic_cast operator uses a pointer to 
  11153. the base class employee and gets a pointer to the derived class manager in 
  11154. order to use the bonus member function. 
  11155.  
  11156. void payroll::calc (employee *pe) {
  11157.   // employee salary calculation
  11158.   if (manager *pm = dynamic_cast<manager*>(pe)) {
  11159.      // use manager::bonus()
  11160.   }
  11161.   else {
  11162.      // use employee's member functions
  11163.   }
  11164. }
  11165.  
  11166. If pe actually points to a manager object at run time, the dynamic cast is 
  11167. successful, pm is initialized to a pointer to a manager, and the bonus function 
  11168. is used. If not, pm is initialized to zero and only the functions in the the 
  11169. employee base class are used. 
  11170.  
  11171. Note:  In this example, dynamic casts are needed only if the base class 
  11172. employee and its derived classes are not available to users (as in part of a 
  11173. library where it is undesirable to modify the source code.) Otherwise, adding 
  11174. new virtual functions and providing derived classes with specialized 
  11175. definitions for those functions is a better choice to solve this problem. 
  11176.  
  11177.  
  11178. ΓòÉΓòÉΓòÉ 16.1.1.2. Dynamic Casts with References ΓòÉΓòÉΓòÉ
  11179.  
  11180. The dynamic_cast operator can also be used to cast to reference types. This is 
  11181. because C++ reference casts are similar to pointer casts: they can be used to 
  11182. cast from references to base class objects to references to derived class 
  11183. objects. 
  11184.  
  11185. In dynamic casts to reference types, type_name represents a type and expression 
  11186. represents a reference. The operator converts the expression to the desired 
  11187. type type_name&. 
  11188.  
  11189. Because there is no such thing as a zero reference, it is not possible to 
  11190. verify the success of a dynamic cast using reference types by comparing the 
  11191. result (the reference that results from the dynamic cast) with zero. A failing 
  11192. dynamic cast to a reference type throws a bad_cast exception. 
  11193.  
  11194. A dynamic cast with a reference is a good way to test for a coding assumption. 
  11195. The employee example above using reference casts is: 
  11196.  
  11197. void payroll::calc (employee &re) {
  11198.   // employee salary calculation
  11199.   try {
  11200.    manager &rm = dynamic_cast<manager&>(re);
  11201.    // use manager::bonus()
  11202.   }
  11203.   catch (bad_cast) {
  11204.    // use employee's member functions
  11205.   }
  11206. }
  11207.  
  11208. Note:  This example is only intended to illustrate the dynamic_cast operator 
  11209. used as a test. This example does not demonstrate good programming style, since 
  11210. it uses exceptions to control execution flow. Using dynamic_cast with pointers 
  11211. as shown above is a better choice. 
  11212.  
  11213.  
  11214. ΓòÉΓòÉΓòÉ 16.1.2. The typeid Operator ΓòÉΓòÉΓòÉ
  11215.  
  11216. The typeid operator identifies the exact type of an object given a pointer to a 
  11217. base class. It is typically used to gain access to information needed to 
  11218. perform some operation where no common interface can be assumed for every 
  11219. object manipulated by the system. For example, object I/O and database systems 
  11220. often need to perform services on objects where no virtual function is 
  11221. available to do so. The typeid operator enables this. 
  11222.  
  11223. A typeid operation has the following form: 
  11224.  
  11225. >>ΓöÇΓöÇtypeidΓöÇΓöÇ(ΓöÇΓöÇΓö¼ΓöÇtype_nameΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ><
  11226.         ΓööΓöÇexpressionΓöÇΓöÿ
  11227.  
  11228. The result of a typeid operation has type const type_info&. 
  11229.  
  11230. The following table summarizes the results if various typeid operations. 
  11231.  
  11232.  Operand                         typeid Returns 
  11233.  type_name                       A reference to a type_info object that 
  11234.                                  represents it. 
  11235.  expression                      A reference to a type_info that represents the 
  11236.                                  type of the expression. 
  11237.  Reference to a polymorphic type The type_info for the complete object referred 
  11238.                                  to. 
  11239.  Pointer to a polymorphic type   The dynamic type of the complete object 
  11240.                                  pointed to. If the pointer is zero, the typeid 
  11241.                                  expression throws the bad_typeid exception. 
  11242.  Nonpolymorphic type             The type_info that represents the static type 
  11243.                                  of the expression. The expression is not 
  11244.                                  evaluated. 
  11245.  
  11246.  The following examples use the typeid operator in expressions that compare the 
  11247.  runtime type of objects in the employee class hierarchy: 
  11248.  
  11249.   // ...
  11250.   employee *pe = new manager;
  11251.   employee& re = *pe;
  11252.   // ...
  11253.     typeid(pe) == typeid(employee*)   //  1. True - not a polymorphic type
  11254.     typeid(&re) == typeid(employee*)   //  2. True - not a polymorphic type
  11255.     typeid(*pe) == typeid(manager)    //  3. True - *pe represents a polymorphic type
  11256.     typeid(re) == typeid(manager)    //  4. True - re represents the object manager
  11257.  
  11258.     typeid(pe) == typeid(manager*)    //  5. False - static type of pe returned
  11259.     typeid(pe) == typeid(employee)    //  6. False - static type of pe returned
  11260.     typeid(pe) == typeid(manager)    //  7. False - static type of pe returned
  11261.  
  11262.     typeid(*pe) == typeid(employee)   //  8. False - dynamic type of expression is manager
  11263.     typeid(re) == typeid(employee)    //  9. False - re actually represents manager
  11264.     typeid(&re) == typeid(manager*)   // 10. False - manager* not the static type of re
  11265.   // ...
  11266.  
  11267.  In comparison 1, pe is a pointer (i.e. not a polymorphic type); therefore, the 
  11268.  expression typeid(pe) returns the static type of pe, which is equivalent to 
  11269.  employee*. 
  11270.  
  11271.  Similarly, re in comparison 2 represents the addess of the object referred to 
  11272.  (i.e. not a polymorphic type); therefore, the expression typeid(re) returns 
  11273.  the static type of re, which is a pointer to employee. 
  11274.  
  11275.  The type returned by typeid represents the dynamic type of the expression only 
  11276.  when the expression represents a polymorphic type, as in comparisons 3 and 4. 
  11277.  
  11278.  Comparisons 5, 6, and 7 are false because it is the type of the expression 
  11279.  (pe) that is examined, not the type of the object pointed to by pe. 
  11280.  
  11281.  Note that these examples do not directly manipulate type_info objects. Using 
  11282.  the typeid operator with builtin types requires interaction with type_info 
  11283.  objects. 
  11284.  
  11285.  For example: 
  11286.  
  11287.   int i;
  11288.   // ...
  11289.     typeid(i) == typeid(int)   // True
  11290.     typeid(8) == typeid(int)   // True
  11291.   // ...
  11292.  
  11293.  The class type_info is described in The type_info Class. 
  11294.  
  11295.  
  11296. ΓòÉΓòÉΓòÉ 16.1.3. The type_info Class ΓòÉΓòÉΓòÉ
  11297.  
  11298. To use the typeid operator in Runtime Type Identification (RTTI) you must 
  11299. include the C++ standard header <typeinfo.h> This header defines the following 
  11300. classes: 
  11301.  
  11302.  type_info   Describes the RTTI available to the implementation. It is a 
  11303.              polymorphic type that supplies comparison and collation operators 
  11304.              and provides a member function that returns the name of the type 
  11305.              represented. 
  11306.  
  11307.              The copy constructor and the assignment operator for the class 
  11308.              type_info are private; objects of this type cannot be copied. 
  11309.  
  11310.  bad_cast    Defines the type of objects thrown as exceptions to report dynamic 
  11311.              cast expressions that have failed. 
  11312.  
  11313.  bad_typeid  Defines the type of objects thrown as exceptions to report a null 
  11314.              pointer in a typeid expression. 
  11315.  
  11316.  
  11317. ΓòÉΓòÉΓòÉ 16.1.4. Using RTTI in Constructors and Destructors ΓòÉΓòÉΓòÉ
  11318.  
  11319. The typeid and dynamic_cast operators can be used in constructors or 
  11320. destructors, or in functions called from a constructor or destructor. 
  11321.  
  11322. If the operand of dynamic_cast used refers to an object under construction or 
  11323. destruction, typeid returns the type_info representing the class of the 
  11324. constructor or destructor. 
  11325.  
  11326. If the operand of dynamic_cast refers to an object under construction or 
  11327. destruction, the object is considered to be a complete object that has the type 
  11328. of the constructor or destructor's class. 
  11329.  
  11330. The result of the typeid and dynamic_cast operations is undefined if the 
  11331. operand refers to an object under construction or destruction, and the static 
  11332. type of the operand is not an object of the constructor or destructor's class 
  11333. or one of its bases. 
  11334.  
  11335.  
  11336. ΓòÉΓòÉΓòÉ 16.2. VisualAge for C++ Extensions to RTTI ΓòÉΓòÉΓòÉ
  11337.  
  11338. The design of the VisualAge for C++ extended_type_info class was to provide 
  11339. support for implementing a persistent object store. The basic operations that 
  11340. must be supported are: 
  11341.  
  11342.      allocation of memory of an object 
  11343.  
  11344.      allocation of memory for an array of objects 
  11345.  
  11346.      initial construction of an object 
  11347.  
  11348.      initial construction of an array of objects 
  11349.  
  11350.      copy construction of an object 
  11351.  
  11352.      copy constuction of an array of objects 
  11353.  
  11354.  Additional operations for destroy and deallocation of memory are also provided 
  11355.  in the event that an exception occurs during construction.  These operations 
  11356.  are: 
  11357.  
  11358.      destruction of an object 
  11359.      destruction of an array of objects 
  11360.      deallocation of memory for an object 
  11361.      deallocation of memory for an array of objects 
  11362.  
  11363.  
  11364. ΓòÉΓòÉΓòÉ 16.2.1. The extended_type_info Class ΓòÉΓòÉΓòÉ
  11365.  
  11366. The class definitions are: 
  11367.  
  11368. class extended_type_info : public type_info {
  11369.  public:
  11370.   ~extended_type_info();
  11371.  
  11372.   virtual size_t size() const=0;
  11373.  
  11374.   virtual void* create(void* at) const=0;  //object
  11375.   virtual void* create(void* at, size_t count) const=0; // array
  11376.  
  11377.   virtual void* copy (void* to, const void* from) const=0;  //object
  11378.   virtual void* copy (void* to, const void* from, size_t count) const=0;
  11379. //array
  11380.  
  11381.   virtual void* destroy(void* at) const=0;  //object
  11382.   virtual void* destroy(void* at, size_t count) const=0;  //array
  11383.  
  11384.   virtual void* allocObject() const=0;  //object
  11385.   virtual void* allocArray(size_t count) const=0;  //array
  11386.  
  11387.   virtual void* deallocObject(void* at) const=0;  //object
  11388.   virtual void* deallocArray(void* at, size_t count) const=0;  //array
  11389.  };
  11390.  
  11391. Explanation of terms: 
  11392.  
  11393.  size() 
  11394.     Size of the type represented by the extended_type_info object. 
  11395.  
  11396.  create(void*) 
  11397.     This function is called to create an object of the type represented by the 
  11398.     extended_type_info object at the storage location pointed to by at. 
  11399.  
  11400.  create(void*, size_t) 
  11401.     This function is called to create an array of objects of the type 
  11402.     represented by the extended_type_info object at the storage location 
  11403.     pointed to by at. If any exceptions are thrown during construction, 
  11404.     create() will destroy the array elements that were already constructed 
  11405.     before rethrowing the exception. 
  11406.  
  11407.  copy(void*, const void*) 
  11408.     This function is called to copy an object of the type represented by the 
  11409.     extended_type_info object into the storage location pointed to by to, using 
  11410.     the value of the object referred to by from. 
  11411.  
  11412.  copy(void*, const void*, size_t) 
  11413.     This function is called to copy an array of objects of the type represented 
  11414.     by the extended_type_info object into the storage location pointed to by 
  11415.     to, using the value of the object referred to by from. If any exceptions 
  11416.     are thrown during construction, copy() will destroy the array elements that 
  11417.     were already constructed before rethrowing the exception. 
  11418.  
  11419.  destroy(void*) 
  11420.     This function is called to destroy an object of the type represented by the 
  11421.     extended_type_info object at the storage location pointed to by at. 
  11422.  
  11423.  destroy(void*, size_t) 
  11424.     This function is called to destroy an array of objects of the type 
  11425.     represented by the extended_type_info object at the storage location 
  11426.     pointed to by at. If any exceptions are thrown during destruction, 
  11427.     destroy() will destroy the remaining array elements that were already 
  11428.     constructed before rethrowing the exception. If another exception is 
  11429.     encountered during the destruction of the remaining elements, destroy() 
  11430.     will call terminate(). 
  11431.  
  11432.  allocObject() 
  11433.     This function is called to allocate memory for an object of the type 
  11434.     represented by the extended_type_info object. No initialization is 
  11435.     performed. The user is expected to use the create(void*) or copy(void*, 
  11436.     const void*) function to initialize the new memory. 
  11437.  
  11438.  allocArray(size_t) 
  11439.     This function is called to allocate memory for an array of objects of the 
  11440.     type represented by the extended_type_info object. No initialization is 
  11441.     performed. The user is expected to use the create(void*, size_t) or 
  11442.     copy(void*, const void*, size_t) function to initialize the new memory. 
  11443.  
  11444.  deallocObject(void*) 
  11445.     This function is called to deallocate an object of the type represented by 
  11446.     the extended_type_info object. No destruction is performed beforehand. The 
  11447.     user is expected to use the destroy(void*) to terminate the object before 
  11448.     deallocating the memory. 
  11449.  
  11450.  deallocArray(void*, size_t) 
  11451.     This function is called to deallocate an array of objects of the type 
  11452.     represented by the extended_type_info object. No destruction is performed 
  11453.     beforehand. The user is expected to use the destroy(void*, size_t) to 
  11454.     terminate an array before deallocating the memory. 
  11455.  
  11456.  linkageInfo() 
  11457.     This function returns the mangled name of the class type. 
  11458.  
  11459.  
  11460. ΓòÉΓòÉΓòÉ 17. Porting Programs from VisualAge for C++ for OS/2 ΓòÉΓòÉΓòÉ
  11461.  
  11462. This chapter describes how to port existing source code from VisualAge for C++ 
  11463. for OS/2 Version 3.0 to IBM VisualAge for C++ for Windows. It documents those 
  11464. differences between the two versions of VisualAge for C++ that require you to 
  11465. change your code or the way you compile it. It does not describe differences 
  11466. that IBM VisualAge for C++ for Windows handles transparently for you (for 
  11467. example, through predefined macros, environment variables, or option defaults.) 
  11468.  
  11469. It is common to speak about portability as a desirable quality for a 
  11470. programming language or for code produced by a particular compiler. Portability 
  11471. can be divided into two categories: 
  11472.  
  11473.    1. Source code portability - The ability to take a program that can be 
  11474.       compiled, linked, and run on one platform with one compiler and compile, 
  11475.       link, and run it on another platform. There are two kinds of problems 
  11476.       associated with source code portability in C and C++: 
  11477.           Platform-specific differences - variations that are a direct result 
  11478.            of the characteristics of the platform. 
  11479.           Implementation-specific differences - variations that are a result 
  11480.            of behavior that is left unspecified in the C or C++ language 
  11481.            definition. 
  11482.    2. Binary portability - The ability to share binary files (for example, 
  11483.       .EXEs, .DLLs, repository files used by product tools, or user data files) 
  11484.       across different platforms. 
  11485.  
  11486.  VisualAge for C++ does not provide binary portability of generated code or the 
  11487.  data files used by its tools, unless explicitly indicated in these manuals. 
  11488.  
  11489.  
  11490. ΓòÉΓòÉΓòÉ 17.1. General Porting Guidelines ΓòÉΓòÉΓòÉ
  11491.  
  11492. This section describes what is meant by the term portability, and gives some 
  11493. general guidelines for making your programs portable. 
  11494.  
  11495. Sometimes it is impossible to avoid using nonportable constructs. In addition, 
  11496. there are some situations where you may want to use nonportable constructs: 
  11497.  
  11498.      To make your code more efficient 
  11499.  
  11500.      To take advantage of a particular system capability (such as record input 
  11501.       and output) 
  11502.  
  11503.      For code that is only going to be run on one platform. 
  11504.  
  11505.      For code that will have a short lifespan. If you want to write portable 
  11506.       code, you must make an initial investment of time and effort, and this 
  11507.       investment may not be worthwhile if the code is going to be discarded 
  11508.       soon after it is written. 
  11509.  
  11510.      In code that will only be moved among specific platforms, where you may 
  11511.       take advantage of constructs that are not generally portable but are 
  11512.       portable between the platforms that you are using. 
  11513.  
  11514.  To make it easier to move nonportable code from one platform to another: 
  11515.  
  11516.      Isolate code that is not portable in separate compilation units. This 
  11517.       will make it easier for you to identify the code that needs to be changed 
  11518.       before a program can be moved from one platform to another. 
  11519.  
  11520.      Use conditional compilation. You can use conditional compilation to 
  11521.       determine the IBM C product that is being used, and make any necessary 
  11522.       adjustments to your program. 
  11523.  
  11524.      When you are documenting your code, identify nonportable constructs and 
  11525.       include some kind of justification for them. For example, if you decide 
  11526.       to use nonportable constructs to make your code more efficient, mention 
  11527.       this in the documentation. 
  11528.  
  11529.  The C and C++ constructs that are described in the ANSI C definition and the 
  11530.  ANSI C++ Working Paper are portable. Some non-ANSI constructs available in 
  11531.  VisualAge for C++ are not portable, and you should not include them in code 
  11532.  that is meant to be portable. 
  11533.  
  11534.  Different platforms use different methods to represent and manipulate 
  11535.  floating-point numbers. Do not expect a floating-point operation to have 
  11536.  exactly the same result on all platforms. 
  11537.  
  11538.  The sizes of the C data types are not the same in all platforms. A program is 
  11539.  not portable if it depends on a value of a given type being a particular size. 
  11540.  
  11541.  Some platforms align the members within structures, unions, and C++ classes in 
  11542.  different ways. Portable code should not rely on a particular alignment of the 
  11543.  members within a structure. In addition, portable code should not rely on a 
  11544.  structure or union taking up a particular amount of storage. 
  11545.  
  11546.  Various platforms have different rules for the length of identifiers and for 
  11547.  the characters that can make up identifiers. This means that a valid 
  11548.  identifier on one platform may not be valid on another platform. Two 
  11549.  identifiers that are distinct on one platform may not be distinct on another 
  11550.  platform. 
  11551.  
  11552.  
  11553. ΓòÉΓòÉΓòÉ 17.1.1. Porting Quick Tips ΓòÉΓòÉΓòÉ
  11554.  
  11555. The following lists some general rules of thumb for porting your C and C++ code 
  11556. across platforms and migrating C source to C++. They are not specific to OS/2 
  11557. to Windows portability, but apply more broadly to cross-platform and 
  11558. cross-vendor portability. 
  11559.  
  11560.  
  11561. ΓòÉΓòÉΓòÉ 17.1.1.1. Porting across Platforms and Implementations ΓòÉΓòÉΓòÉ
  11562.  
  11563.      Make your code as compliant as possible to ANSI/ISO C and C++ 
  11564.  
  11565.      Use the /Wpor option for portability guidance 
  11566.  
  11567.      Make internal identifiers no more than 31 characters and external 
  11568.       identifiers no more than 8 characters 
  11569.  
  11570.      Some systems are not case-sensitive. Don't give two external identifiers 
  11571.       the same spelling. The names walrus, WalRus, and WALRUS, may be same on 
  11572.       some systems. 
  11573.  
  11574.      Watch translation limits. Know the maximum: 
  11575.  
  11576.         -  number of function arguments 
  11577.         -  number of aggregate members 
  11578.         -  number of characters in strings 
  11579.         -  nesting depth for aggregates for your environment. Use the 
  11580.       "Translation Limits" section of ANSI/ISO-IEC 9899-1990[1992] as a guide. 
  11581.  
  11582.      Adhere to value-preserving rules for integral promotion. (Some compilers 
  11583.       use the sign-preserving rules.) All IBM compilers use the 
  11584.       value-preserving rules as default. 
  11585.  
  11586.      Make macro definitions less than 2043 bytes before expansion and less 
  11587.       than 1019 bytes after expansion. 
  11588.  
  11589.      Be aware of which environments support multithreading or multitasking. 
  11590.  
  11591.      Don't depend on a particular range of values for numerical types. 
  11592.  
  11593.      Don't depend on packed structures and unions. 
  11594.  
  11595.      Don't depend on the ordering of bytes within words. The function 
  11596.  
  11597.               int f() {
  11598.                 int i = 0x01020304;
  11599.               return *(char*) &i;
  11600.               }
  11601.  
  11602.       will return 4 on a little-endian processor (e.g. Intel x86) and 1 on a 
  11603.       big-endian processor (e.g. IBM Risc System/6000). 
  11604.  
  11605.      Group together structure and union members that have the same alignment. 
  11606.  
  11607.      Put structure and union members with the strictest alignment at the 
  11608.       beginning of the structure. 
  11609.  
  11610.      Always use prototyped functions. (C++ functions must have prototypes.) 
  11611.  
  11612.      Avoid assignments in function arguments. (The order of evaluation of 
  11613.       function arguments varies across compilers.) 
  11614.  
  11615.      The default for character types is unsigned. (use #pragma chars or the 
  11616.       appropriate option to change this) 
  11617.  
  11618.      Do not use bitfields bigger than 32 bits. 
  11619.  
  11620.      Make bitfields unsigned int. 
  11621.  
  11622.      Don't depend on an int, long int, and short int being the same size. 
  11623.  
  11624.      Don't depend on a particular search sequence for include files. (Use the 
  11625.       /I option to specify it explicitly.) 
  11626.  
  11627.      The envp argument to main isn't supported on all compilers. 
  11628.  
  11629.      The order that C++ class members are allocated varies by implementation. 
  11630.       The IBM C++ compilers allocate members in the order they are declared. 
  11631.  
  11632.  
  11633. ΓòÉΓòÉΓòÉ 17.1.1.2. Porting between C and C++ ΓòÉΓòÉΓòÉ
  11634.  
  11635.      Do not take the address of main(). 
  11636.  
  11637.      Always provide return values for functions. 
  11638.  
  11639.      Always declare a return type for functions. (C++ requires a return value 
  11640.       for a function unless it has a void return type.) 
  11641.  
  11642.      Leave space for the trailing '\0' in character arrays. For example: 
  11643.  
  11644.               char v[3] = "abc"; // OK in ANSI C, wrong in C++
  11645.  
  11646.      Character constants are type char in C++ and type int in C. 
  11647.  
  11648.      Always initialize const objects. (C++ const objects must be initialized.) 
  11649.  
  11650.      Define all globals only once. 
  11651.  
  11652.      Don't define types in function return or argument types. For example: 
  11653.  
  11654.               void print(struct X { int i;} x); // OK in C, wrong in C++
  11655.  
  11656.      Don't declare functions with empty argument lists. For the declaration 
  11657.  
  11658.               int f();
  11659.       C++ treats this as a function that takes no arguments. C treats it as a 
  11660.       function that takes any number and type of arguments. 
  11661.  
  11662.      Avoid anonymous unions. They behave differently in C and C++: 
  11663.  
  11664.         -  In C they are simply unions without declarators 
  11665.  
  11666.         -  in C++ they cannot have declarators - they are unions without a 
  11667.            class name. They cannot have member functions. 
  11668.  
  11669.      Watch the name space of typedefs: structure tag names and typedef names 
  11670.       are in the same name space in C++, different in C. 
  11671.  
  11672.      Watch assignments of enumerations; they must be the same type in C++. 
  11673.  
  11674.      Don't jump over declarations containing initializations. This is an error 
  11675.       in C++: 
  11676.  
  11677.               goto skiplabel;  // error - jumped over declaration
  11678.                       // and initialization of i
  11679.               int i = 3;
  11680.               skiplabel: i = 4;
  11681.  
  11682.       Be careful of this in switch statements that have declarations in the 
  11683.       body. All declarations that contain initializers must be contained in an 
  11684.       inner block that is completely bypassed by the transfer of control. 
  11685.  
  11686.      Always assign void pointers only to other void pointers. C allows void 
  11687.       pointers to be assigned to any other pointer types, but C++ doesn't. 
  11688.  
  11689.      Don't take the address of register objects (OK in C, error in C++) 
  11690.  
  11691.      If you use overloaded functions, treat char, unsigned char, and signed 
  11692.       char as distinct types. 
  11693.  
  11694.  
  11695. ΓòÉΓòÉΓòÉ 17.2. Operating System Differences ΓòÉΓòÉΓòÉ
  11696.  
  11697. The following table summarizes the main differences between the OS/2 operating 
  11698. systems and the various Windows platforms. 
  11699.  
  11700. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  11701. Γöé           Γöé OS/2   Γöé WINDOWS  Γöé WINDOWS  Γöé WIN32S  Γöé
  11702. Γöé           Γöé WARP   Γöé 95    Γöé NT V3.51 Γöé     Γöé
  11703. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11704. Γöé FILE MANAGER     Γöé DeskTop  Γöé all new  Γöé like   Γöé like   Γöé
  11705. Γöé           Γöé      Γöé      Γöé Windows  Γöé Windows Γöé
  11706. Γöé           Γöé      Γöé      Γöé V3.1   Γöé V3.1   Γöé
  11707. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11708. Γöé PROGRAM MANAGER   Γöé DeskTop  Γöé all new  Γöé like   Γöé like   Γöé
  11709. Γöé           Γöé      Γöé      Γöé Windows  Γöé Windows Γöé
  11710. Γöé           Γöé      Γöé      Γöé V3.1   Γöé V3.1   Γöé
  11711. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11712. Γöé APPLICATION SHELL  Γöé DeskTop  Γöé like   Γöé not    Γöé no    Γöé
  11713. Γöé           Γöé      Γöé OS/2   Γöé until   Γöé     Γöé
  11714. Γöé           Γöé      Γöé (drag   Γöé Windows  Γöé     Γöé
  11715. Γöé           Γöé      Γöé and    Γöé NT V3.52 Γöé     Γöé
  11716. Γöé           Γöé      Γöé drop)   Γöé      Γöé     Γöé
  11717. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11718. Γöé SECURITY       Γöé yes    Γöé no    Γöé yes    Γöé no    Γöé
  11719. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11720. Γöé MULTITHREADING    Γöé yes    Γöé limited  Γöé yes    Γöé no    Γöé
  11721. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11722. Γöé UNICODE       Γöé no    Γöé no    Γöé yes    Γöé no    Γöé
  11723. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11724. Γöé HPFS/NTFS      Γöé yes    Γöé no    Γöé yes    Γöé no    Γöé
  11725. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11726. Γöé NESTED FOLDERS    Γöé yes    Γöé yes    Γöé not    Γöé no    Γöé
  11727. Γöé           Γöé      Γöé      Γöé until   Γöé     Γöé
  11728. Γöé           Γöé      Γöé      Γöé Windows  Γöé     Γöé
  11729. Γöé           Γöé      Γöé      Γöé NT V3.52 Γöé     Γöé
  11730. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11731. Γöé LONG FILE NAMES   Γöé yes    Γöé yes    Γöé yes    Γöé no    Γöé
  11732. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  11733. Γöé NOTE:  VisualAge for C++ does not support Unicode.       Γöé
  11734. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  11735.  
  11736.  
  11737. ΓòÉΓòÉΓòÉ 17.3. Porting Your OS/2 Code ΓòÉΓòÉΓòÉ
  11738.  
  11739. Porting your OS/2 code to a Windows platform is best done in two phases: 
  11740.  
  11741.    1. Make your code independent of the operating system. This can be done 
  11742.       while the code is still on the OS/2 platform. 
  11743.    2. Compile on a 32-bit Windows platform (Windows 95 or Windows NT). 
  11744.  
  11745.  
  11746. ΓòÉΓòÉΓòÉ 17.3.1. Phase 1: Make Your Code Operating System Independent ΓòÉΓòÉΓòÉ
  11747.  
  11748.    1. Remove OS/2 toolkit dependencies by: 
  11749.  
  11750.           Using standard C types. 
  11751.  
  11752.            Not only does the OS/2 toolkit define the function prototypes for 
  11753.            APIs but it also defines a number of types such as ushort and bool 
  11754.            that need to be changed to their standard C equivalents such as 
  11755.            unsigned short. 
  11756.  
  11757.           Using standard C functions. 
  11758.  
  11759.            Convert DOS calls to their equivalent standard C library function. 
  11760.            For example, replace DosOpen() with fopen(), DosAllocMem() with 
  11761.            malloc(), and so on. 
  11762.  
  11763.    2. Use the IBM Open Class User Interface Classes. 
  11764.  
  11765.       They provide source portability of user-interface code, but to take 
  11766.       advantage of this, you might need to convert some existing code from C to 
  11767.       C++. 
  11768.  
  11769.       Any parts that will eventually contain C++ code (i.e. calls to ICLUI) 
  11770.       need to be compilable as C++. This can be done by specifying the /Tdp 
  11771.       compiler option. Remember that C++ is a little stricter about casting 
  11772.       pointers and parameter passing. 
  11773.  
  11774.       Replace all GUI code and some Operating System functions such as threads 
  11775.       with IBM Open Class UI classes. 
  11776.  
  11777.       In particular, all windows and dialogs need to be converted. Define a 
  11778.       generic dialog and inherit from it to take advantage of object oriented 
  11779.       code reuse. 
  11780.  
  11781.    3. Isolate Operating System dependent code. 
  11782.  
  11783.       Any OS/2 API remaining that has no equivalent in IBM Open Class or the 
  11784.       standard C library needs to be isolated by using conditional compilation 
  11785.       directives 
  11786.  
  11787.             #if __OS2__
  11788.               // OS/2 APIs
  11789.             #elif __WINDOWS__
  11790.               // Windows APIs
  11791.             #endif
  11792.  
  11793.       If possible, put all such calls into one module. 
  11794.  
  11795.       Known APIs, headers, and functions that fall into this category are: 
  11796.  
  11797.           Shared memory APIs 
  11798.           Semaphores APIs 
  11799.           Extended attributes. 
  11800.           <os2.h> header 
  11801.           DosSearchFilePath(), DosFindFirst(), DosFindNext() 
  11802.           xxxCtryInfo() 
  11803.           GetDBCSEv() 
  11804.           NLSUpperChar() 
  11805.           WinSetPointer() 
  11806.           xxxCursorBlinkRate() 
  11807.  
  11808.  
  11809. ΓòÉΓòÉΓòÉ 17.3.2. Phase 2: Move to the Windows Platform ΓòÉΓòÉΓòÉ
  11810.  
  11811. Move your platform-independent code to the Windows platform: 
  11812.  
  11813.    1. Compile your application resources 
  11814.  
  11815.    2. Compile and link your program 
  11816.  
  11817.  
  11818. ΓòÉΓòÉΓòÉ 17.3.3. Library Functions ΓòÉΓòÉΓòÉ
  11819.  
  11820. The following C library functions are not supported in IBM VisualAge for C++ 
  11821. for Windows: 
  11822.  
  11823.      wait 
  11824.      _getTIBValue 
  11825.      __parmdwords 
  11826.  
  11827.  The command.com on Windows 95 only returns a 0 return code. As a result, the C 
  11828.  runtime always returns 0 from a system() function call. Code that uses 
  11829.  system() for error checking should take this into account for Windows 95. 
  11830.  
  11831.  On OS/2 the file handles returned by operating-system APIs are the same as the 
  11832.  runtime handles. You could, to a certain extent, mix the two kinds of calls, 
  11833.  for example, by opening a file with DosOpen and then writing into it with the 
  11834.  write library function using the file handle that the API returned. On Windows 
  11835.  platforms this is not possible. 
  11836.  
  11837.  Refer to the IBM VisualAge for C++ for Windows C Library Reference for more 
  11838.  information. 
  11839.  
  11840.  
  11841. ΓòÉΓòÉΓòÉ 17.3.4. Stream I/O ΓòÉΓòÉΓòÉ
  11842.  
  11843. Win32s does not implement the concept of a console, unlike OS/2, Windows NT, or 
  11844. Windows 95. Any output directed to stdout in your OS/2 code (for example, 
  11845. through printf and cout) is lost. This is similar to the PM requirement that 
  11846. applications must display text using PM APIs and controls, not with printf. 
  11847.  
  11848. To redirect input, output, and error handles in the Win32 environment, 
  11849. VisualAge for C++ provides a special object -- redirect.obj.  (It is in the 
  11850. same directory as SETARGV.OBJ. It needs to be linked in explicitly using the 
  11851. /NOE linker option.) 
  11852.  
  11853. Redirecting Standard Streams describes redirect.obj For more information about 
  11854. input and output, refer to Performing I/O Using Standard Streams. 
  11855.  
  11856.  
  11857. ΓòÉΓòÉΓòÉ 17.4. Compiler Tools Differences ΓòÉΓòÉΓòÉ
  11858.  
  11859. For more information about the following VisualAge for C++ tools refer to the 
  11860. IBM VisualAge for C++ for Windows User's Guide. 
  11861.  
  11862.  
  11863. ΓòÉΓòÉΓòÉ 17.4.1. WorkFrame ΓòÉΓòÉΓòÉ
  11864.  
  11865.      No project inheritance or Tool Setup is available. Actions (tools), and 
  11866.       types are defined in the product solution file, which is called 
  11867.       vacpp.iws. 
  11868.  
  11869.      WorkFrame does not support user-defined types. 
  11870.  
  11871.      Environment variables can be defined through the Project Settings 
  11872.       notebook. 
  11873.  
  11874.      Options defined by using the option dialogs are stored on a per-project 
  11875.       basis in the options file for the project. The options file is called 
  11876.       *.iwo. 
  11877.  
  11878.       You can access the option dialogs using the Options menu pulldown in a 
  11879.       project view. If you delete the options file, you can recover by using 
  11880.       the editor to create a new options file, with the same name containing 
  11881.       just a '*'. Then use the options dialogs to reset your options for the 
  11882.       project. 
  11883.  
  11884.       Other project specific information e.g. project settings, is kept on a 
  11885.       per-project basis in the project's project file i.e. in the *.iwp file. 
  11886.  
  11887.      No drag and drop is available 
  11888.  
  11889.      A details view of the project is not available - only icon and tree 
  11890.       views. 
  11891.  
  11892.      Monitored actions are implemented through the Editor rather than 
  11893.       WorkFrame. The monitor is an Editor monitor, not a WorkFrame monitor. 
  11894.  
  11895.  Note:  You should not directly change the WorkFrame configuration files, such 
  11896.  as the *.iws, *.iwp, and *.iwo files. 
  11897.  
  11898.  
  11899. ΓòÉΓòÉΓòÉ 17.4.2. Editor ΓòÉΓòÉΓòÉ
  11900.  
  11901. To enter characters using the Alt key + numeric pad, use Alt + 0 and then type 
  11902. Alt + the character you want. 
  11903.  
  11904. When using a batch file to invoke LPEX, for example IEDIT or LXPM, LPEX accepts 
  11905. a maximum of 9 arguments. To enter more arguments, use the program name, for 
  11906. example, start EVFXLXPM. 
  11907.  
  11908.  
  11909. ΓòÉΓòÉΓòÉ 17.4.3. Data Access Builder ΓòÉΓòÉΓòÉ
  11910.  
  11911. The IBM VisualAge for C++ for Windows Data Access Builder has the following 
  11912. differences from the VisualAge for C++ for OS/2 Data Access Builder: 
  11913.  
  11914.      Data Access Builder code generated in VisualAge for C++ for OS/2 V3.0 is 
  11915.       not portable to IBM VisualAge for C++ for Windows. It must be regenerated 
  11916.       using the .DAX file created from saving the VisualAge for C++ for OS/2 
  11917.       session. The class interface is preserved, so no source code modification 
  11918.       is required in your application. 
  11919.  
  11920.      The naming convention of the generated files has changed. Generated files 
  11921.       for C++ classes are no long suffixed with v. Generated files for SOM 
  11922.       classes are no long suffixed with i. 
  11923.  
  11924.       You must change the references to generated file names in your existing 
  11925.       .hpp and .mak files. To do this, you can either: 
  11926.  
  11927.         -  manually rename the files, or, 
  11928.         -  change the File stem on the Names page of the class settings 
  11929.            notebook. 
  11930.  
  11931.      The VisualAge for C++ for OS/2 .DAX file does not save information 
  11932.       pertaining to whether SOM or C++ parts were generated. A warning is 
  11933.       issued indicating that the .DAX file is in VisualAge for C++ for OS/2 
  11934.       format when used in IBM VisualAge for C++ for Windows. 
  11935.  
  11936.      The VisualAge for C++ for OS/2 release supported two versions of DB2/2. 
  11937.       However, in IBM VisualAge for C++ for Windows, only DB2/NT is available. 
  11938.       Tables or views saved in .DAX files are assumed to be available in DB2/NT 
  11939.       V2.1. 
  11940.  
  11941.      If the classes contained in the migrated .DAX file were generated, they 
  11942.       are marked as generated when loaded. If the generated files do not 
  11943.       physically exist on the hard drive in the working directory, the source 
  11944.       file cannot be viewed until the class has been regenerated. 
  11945.  
  11946.      In the VisualAge for C++ for OS/2 release, the source code language type 
  11947.       was not decided until code generation. However, in IBM VisualAge for C++ 
  11948.       for Windows, the decisions for both source code language type and access 
  11949.       mode type are determined when the class is created. When a migrated .DAX 
  11950.       file is loaded, any classes that do not have generated code are assigned 
  11951.       the following default values: 
  11952.  
  11953.         -  source code language type - Visual Builder parts 
  11954.         -  access method type - embedded SQL 
  11955.  
  11956.       However, if the default values are not appropriate, they can be changed 
  11957.       using a conversion utility, idatacvt. This utility converts the old files 
  11958.       to the new format while giving you control over the language type and 
  11959.       access method. If you use the /p option, you can make decisions on a 
  11960.       class-by-class and table-by-table basis. Otherwise, your language type 
  11961.       and access method type choices will apply to all classes, table and views 
  11962.       in the entire .DAX file. Type idatacvt /? for syntax information. 
  11963.  
  11964.      The naming convention of the exception classes has changed. However, you 
  11965.       are not required to make any specific changes to existing applications. 
  11966.  
  11967.       All exception classes are automatically redefined when they are invoked. 
  11968.       For example, IDSAccessError, is converted to IDAException the first time 
  11969.       the exception is thrown. 
  11970.  
  11971.       See the idsexc.hpp file for the naming convention changes between the 
  11972.       previous release and this release. 
  11973.  
  11974.      The signature of the constructor for the exception objects has changed. 
  11975.       This signature must be changed. Otherwise compile errors occur. 
  11976.  
  11977.       The signature changed from: 
  11978.  
  11979.              IDSAccessError(
  11980.                 const char* a,
  11981.                 unsigned long b = 0,
  11982.                 Severity c = IException::unrecoverable,
  11983.                 struct sqlca* sqlca_p=0
  11984.                );
  11985.  
  11986.       to: 
  11987.  
  11988.              IDAException(
  11989.                 const char* a,
  11990.                 unsigned long b = 0,
  11991.                 Severity c = IException::unrecoverable,
  11992.                 long anSQLCODE = 0,
  11993.                 char* anSQLSTATE = 0
  11994.                );
  11995.  
  11996.      For exceptions thrown, the entire SQLCA structure is not provided in IBM 
  11997.       VisualAge for C++ for Windows, only SQLSTATE and SQLCODE. 
  11998.  
  11999.      The signature of the getSqlca member and _get_Sqlca have changed. In the 
  12000.       previous release, this member returned a reference to struct sqlca const. 
  12001.       In this release, this member returns new structure struct DA_sqlca. 
  12002.  
  12003.       The signature changed from: 
  12004.  
  12005.              struct sqlca const&getSqlca() const;
  12006.  
  12007.       to: 
  12008.  
  12009.              struct DA_sqlca getSqlca() const;
  12010.  
  12011.  
  12012. ΓòÉΓòÉΓòÉ 17.4.4. Visual Builder ΓòÉΓòÉΓòÉ
  12013.  
  12014. The Visual Builder User's Guide describes the differences between VisualAge for 
  12015. C++ for OS/2 Visual Builder and IBM VisualAge for C++ for Windows Visual 
  12016. Builder. Refer to it for detailed information about porting your OS/2 Visual 
  12017. Builder applications for use with IBM VisualAge for C++ for Windows. 
  12018.  
  12019.  
  12020. ΓòÉΓòÉΓòÉ 17.4.5. Compiler Options ΓòÉΓòÉΓòÉ
  12021.  
  12022. Several VisualAge for C++ for OS/2 compiler option defaults have changed for 
  12023. IBM VisualAge for C++ for Windows. tszie=22 compact. 
  12024.  
  12025.  Windows Default OS/2 Default 
  12026.  
  12027.  /Gf+      /Gf- 
  12028.  
  12029.  /qtune=blend /G3 (equivalent to /qtune=386) 
  12030.  
  12031.  /Sp8      /Sp4 
  12032.  
  12033.  /Ss+      /Ss- 
  12034.  
  12035.  /qlonglong /qnolonglong 
  12036.  
  12037.  To produce code that is fully ANSI-compliant, the following options are 
  12038.  required: 
  12039.  
  12040.      /Sa 
  12041.      /Ss- (for C only) 
  12042.      /Gf- 
  12043.      /qnolonglong 
  12044.  
  12045.  The following OS/2 options are not supported on Windows platforms. Using them 
  12046.  generates a warning: 
  12047.  
  12048.      /Gk 
  12049.      /Gp 
  12050.      /Gr 
  12051.      /Gt 
  12052.      /Gv 
  12053.      /Tl 
  12054.  
  12055.  
  12056. ΓòÉΓòÉΓòÉ 17.4.6. Linker ΓòÉΓòÉΓòÉ
  12057.  
  12058. The linker defaults to SUBSYSTEM:windows,4.0. 
  12059.  
  12060. The IBM VisualAge for C++ for Windows linker has a different command-line 
  12061. format from the VisualAge for C++ for OS/2 linker: 
  12062.  
  12063.      The linker command-line interface is free format only 
  12064.      Many of the commands that were previously specified in a .DEF file can 
  12065.       now be done on the command line. (For example, HEAP, STACK, DATA, CODE.) 
  12066.      The linker does not accept .DEF files. 
  12067.      The linker binds resources into executables directly, through .RES files 
  12068.      OS/2 import libraries cannot be used. You must use ILIB on the Windows 
  12069.       platform to generate an import library. 
  12070.      There is no support for 16 bit code. 
  12071.      Data sections for DLLs are now not-shared by default. 
  12072.      /DATA and /CODE flags are added to the set of default attributes. The 
  12073.       linker defaults are: 
  12074.  
  12075.              /CODE:RX (read, execute)
  12076.              /DATA:RW (read, write)
  12077.  
  12078.      Command line options override the options in the .directives section of 
  12079.       an object file. 
  12080.      You must supply an import library (.LIB) when linking to resolve an 
  12081.       import. 
  12082.      The options /PACKCODE, /NOPACKCODE, /PACKDATA, and /NOPACKDATAT, are not 
  12083.       supported. The linker always packs code segments and data segments. 
  12084.      The linker generates PE-Image files (not LX). 
  12085.      The linker accepts only IBM VisualAge for C++ for Windows objects, not 
  12086.       VisualAge for C++ for OS/2 objects. 
  12087.      The linker cannot generate .VDD or .PDD files. 
  12088.      The linker accepts COFF objects and libraries 
  12089.      The linker accepts OMF objects and libraries 
  12090.      All data items declared with the const keyword are placed in a segment 
  12091.       that has the default attributes RS (Read-only and Shared). 
  12092.  
  12093.  The Windows platforms treat section names that contain $ in a special way. 
  12094.  Section names that are identical before the $ are grouped together in the same 
  12095.  segment and ordered lexically by the suffix. 
  12096.  
  12097.  If you want to change the attributes of such a section with the linker option 
  12098.  /SECTION:<name>,<attrs>, specifying one of the grouped sections and not 
  12099.  others, will cause an error. You may change attributes for all of the grouped 
  12100.  sections by specifying the section name without the suffix. 
  12101.  
  12102.  For example, instead of /SECTION:shared$3,rws, use /SECTION:shared$,rws. 
  12103.  
  12104.  
  12105. ΓòÉΓòÉΓòÉ 17.4.7. ILIB Utility ΓòÉΓòÉΓòÉ
  12106.  
  12107. There is no IMPLIB utility in IBM VisualAge for C++ for Windows. The function 
  12108. of IMPLIB in VisualAge for C++ for OS/2 is now performed through ILIB, which 
  12109. generates both import libraries and static libraries. (On OS/2, imports were 
  12110. done by IMPLIB.) 
  12111.  
  12112. ILIB has a free format and a fixed format command line. There are additional 
  12113. command-line options for ILIB to generate import libraries (/gi) and for 
  12114. generating .DEF files (/gd). ILIB generates both COFF and OMF static libraries, 
  12115. depending on the object types passed in. It accepts PE-I DLLs, and COFF 
  12116. objects, along with OMF objects. 
  12117.  
  12118. Specifying the /gi option, and passing a .DEF file to ILIB generates an import 
  12119. library and an export object. Both of these are used in the link step. 
  12120.  
  12121. ILIB uses #pragma export to generate the import library and the export object. 
  12122.  
  12123.  
  12124. ΓòÉΓòÉΓòÉ 17.4.8. Performance Execution Trace Analyzer ΓòÉΓòÉΓòÉ
  12125.  
  12126. The VisualAge for C++ for OS/2 cppopa3.obj file is called cppwpa3.obj file in 
  12127. IBM VisualAge for C++ for Windows. 
  12128.  
  12129. The intercept files are named differently: 
  12130.  
  12131.  File        Becomes 
  12132.  kernel32.lib kernel32.dll 
  12133.  user32.lib  user32.dll 
  12134.  gdi32.lib   gdi32.dll. 
  12135.  
  12136.  The .LIB files are the Performance Analyzer's import libraries for the 
  12137.  corresponding DLLs. These DLLs contain system API entry points that are traced 
  12138.  by the Performance Analyzer. 
  12139.  
  12140.  If you are running a multi-threaded application that creates threads after 
  12141.  existing threads of execution have been terminated, the operating system may 
  12142.  reuse the thread numbers that corresponded to the terminated threads. If this 
  12143.  occurs, the Performance Analyzer may report fewer threads than were actually 
  12144.  executed. 
  12145.  
  12146.  If the object file containing the first executable function is not traceable, 
  12147.  part or all of your application will run before the Trace Generation window is 
  12148.  displayed. If this is the case, the Performance Analyzer will run to the first 
  12149.  traceable function, halt execution, and then display the Trace Generation 
  12150.  window. 
  12151.  
  12152.  
  12153. ΓòÉΓòÉΓòÉ 17.4.9. Browser ΓòÉΓòÉΓòÉ
  12154.  
  12155. The IBM VisualAge for C++ for Windows Browser has the following differences 
  12156. from the VisualAge for C++ for OS/2 Browser: 
  12157.  
  12158.      You can use PDB files generated by the VisualAge for C++ for OS/2 version 
  12159.       3.0 product in IBM VisualAge for C++ for Windows Browser. You cannot use 
  12160.       PDB files generated by Windows C++ and use them on OS/2, nor can you use 
  12161.       PDL, PDE, or PDD files across systems. 
  12162.  
  12163.      If you browse a program that contains .OBJ files created from C source 
  12164.       files, the Browser Files Dialog informs you that the .PDB files for the C 
  12165.       files cannot be found. Ignore this message and select the Load button. 
  12166.  
  12167.      If you choose to Generate Browser information, the compiler creates a PDB 
  12168.       file even if the compilation fails. The file sometimes contains incorrect 
  12169.       data. The browser cannot always detect this problem. 
  12170.  
  12171.      In the list of file names that are fully-qualified, the list contains the 
  12172.       names after compilation and not necessarily the names on your system. For 
  12173.       example, if you List All Files in any of the VisualAge for C++ libraries, 
  12174.       the files may appear to be located in F:\IBMCPPW If the browser cannot 
  12175.       find the files, it searches the path defined in the Browser Settings 
  12176.       notebook. 
  12177.  
  12178.      The browser loads all the information from a program (.EXE or DLL), 
  12179.       including information from any .LIB files used. If the project that 
  12180.       builds the .EXE or DLL does not contain the project that builds the .LIB 
  12181.       file, the Refresh function in the Browser cannot refresh the information 
  12182.       and the information is not displayed. 
  12183.  
  12184.      If you load some browser information with QuickBrowse and some with 
  12185.       compiler-generated .PDB files, you sometimes get the message 
  12186.  
  12187.              An error occurred while loading the file filename.pdb.
  12188.  
  12189.       Either delete the .PDB files and load only QuickBrowse information, or 
  12190.       rebuild your project to generate .PDB files for all of your source files. 
  12191.       If the problem persists, contact VisualAge for C++ Service and Support. 
  12192.  
  12193.      QuickBrowse does not correctly identify SOM classes. 
  12194.  
  12195.  The Save Graph function saves the image to a platform-specific bitmap format, 
  12196.  which is not portable across platforms. 
  12197.  
  12198.  
  12199. ΓòÉΓòÉΓòÉ 17.5. National Characteristics ΓòÉΓòÉΓòÉ
  12200.  
  12201.  
  12202. ΓòÉΓòÉΓòÉ 17.5.1. iconv ΓòÉΓòÉΓòÉ
  12203.  
  12204. The iconv shipped with VisualAge for C++ for OS/2 does not support DBCS code 
  12205. pages. A new version of iconv is supported by IBM VisualAge for C++ for 
  12206. Windows. The iconv APIs are the same, but some of the behavior is slightly 
  12207. different. 
  12208.  
  12209.  
  12210. ΓòÉΓòÉΓòÉ 17.5.2. Code Pages ΓòÉΓòÉΓòÉ
  12211.  
  12212. In general, the code pages supported by IBM VisualAge for C++ for Windows are 
  12213. the same as those supported by the Windows platforms. Note the following: 
  12214.  
  12215.      IBM code page 932 is also known as Shift-JIS. 
  12216.      IBM code page 949 is also known as KS-Code. 
  12217.      IBM code pade 1381 is used in mainland China (PRC) and Singapore. It is 
  12218.       known as GB-Code and subsumes code page 936 
  12219.      IBM code pade 950 is used in Taiwan (ROC) and Hong Kong. It is known as 
  12220.       Big-5. 
  12221.      IBM code pade 874 conforms to the Thai national standard TIS 620-2533 
  12222.       (1989). 
  12223.  
  12224.  
  12225. ΓòÉΓòÉΓòÉ 17.5.3. Locale ΓòÉΓòÉΓòÉ
  12226.  
  12227. For more information about national language programming, refer to Introduction 
  12228. to Locale. 
  12229.  
  12230.  
  12231. ΓòÉΓòÉΓòÉ 17.6. Application Resources ΓòÉΓòÉΓòÉ
  12232.  
  12233. While controls on OS/2 and Windows NT can have resource ids up to xFFFF. On 
  12234. Windows 95, controls can only have ids up to x7FFF; beyond that, the operating 
  12235. system loader will refuse to load the application. It will run, however, on 
  12236. Windows NT. 
  12237.  
  12238.  
  12239. ΓòÉΓòÉΓòÉ 17.6.1. Resource Statements ΓòÉΓòÉΓòÉ
  12240.  
  12241. The following table maps the resources available in OS/2 to their equivalents 
  12242. on the Windows platforms. Where there is a matching statement for a particular 
  12243. type of control it is listed. Cases that require special coding are referred to 
  12244. by the generally known name for the control and are denoted with an asterisk 
  12245. (*). 
  12246.  
  12247. Refer to the Presentation Manager Programmer's Reference and the online Windows 
  12248. API reference, WIN32.HLP, for details on styles and functions for each control. 
  12249.  
  12250.     hyphen=no
  12251.     scale='0.8'
  12252.     frame=rules
  12253.     rules=horiz.
  12254. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  12255. Γöé RESOURCE  Γöé OS/2 WARP  Γöé NT 3.51   Γöé WIN95    Γöé WIN32S   Γöé
  12256. Γöé CONTROL   Γöé       Γöé       Γöé       Γöé       Γöé
  12257. Γöé TYPE    Γöé       Γöé       Γöé       Γöé       Γöé
  12258. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12259. Γöé Acceler-  Γöé ACCELTABLE Γöé ACCELER-  Γöé ACCELER-  Γöé ACCELER-  Γöé
  12260. Γöé ator Table Γöé       Γöé ATORS    Γöé ATORS    Γöé ATORS    Γöé
  12261. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12262. Γöé Associ-   Γöé ASSOCTABLE Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12263. Γöé ation    Γöé       Γöé       Γöé       Γöé       Γöé
  12264. Γöé Table for  Γöé       Γöé       Γöé       Γöé       Γöé
  12265. Γöé files    Γöé       Γöé       Γöé       Γöé       Γöé
  12266. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12267. Γöé Automatic  Γöé AUTOCHECKBOΓöé AUTOCHECKBOΓöé AUTOCHECKBOΓöé AUTOCHECKBOΓöé
  12268. Γöé check-box  Γöé       Γöé       Γöé       Γöé       Γöé
  12269. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12270. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12271. Γöé Automatic  Γöé AUTORADIOBUΓöéTAUTORADIOBUΓöéTAUTORADIOBUΓöéTAUTORADIOBUΓöéTON
  12272. Γöé radio-   Γöé       Γöé       Γöé       Γöé       Γöé
  12273. Γöé button   Γöé       Γöé       Γöé       Γöé       Γöé
  12274. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12275. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12276. Γöé Bit map   Γöé BITMAP   Γöé BITMAP   Γöé BITMAP   Γöé BITMAP   Γöé
  12277. Γöé resource  Γöé       Γöé       Γöé       Γöé       Γöé
  12278. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12279. Γöé Check-box  Γöé CHECKBOX  Γöé CHECKBOX  Γöé CHECKBOX  Γöé CHECKBOX  Γöé
  12280. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12281. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12282. Γöé Character- Γöé N/A     Γöé CHARACTER- Γöé CHARACTER- Γöé CHARACTER- Γöé
  12283. Γöé istics for Γöé       Γöé ISTICS   Γöé ISTICS   Γöé ISTICS   Γöé
  12284. Γöé resources  Γöé       Γöé       Γöé       Γöé       Γöé
  12285. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12286. Γöé Code-page  Γöé CODEPAGE  Γöé LANGUAGE  Γöé LANGUAGE  Γöé LANGUAGE  Γöé
  12287. Γöé setting   Γöé       Γöé       Γöé       Γöé       Γöé
  12288. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12289. Γöé Combina-  Γöé COMBOBOX  Γöé COMBOBOX  Γöé COMBOBOX  Γöé COMBOBOX  Γöé
  12290. Γöé tion box  Γöé       Γöé       Γöé       Γöé       Γöé
  12291. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12292. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12293. Γöé Container  Γöé CONTAINER  Γöé LIST VIEW* Γöé LIST VIEW* Γöé LIST VIEW* Γöé
  12294. Γöé control   Γöé       Γöé TREE-VIEW* Γöé TREE-VIEW* Γöé TREE-VIEW* Γöé
  12295. Γöé with    Γöé       Γöé HEADER*   Γöé HEADER*   Γöé HEADER*   Γöé
  12296. Γöé details   Γöé       Γöé DRAGLIST*  Γöé DRAGLIST*  Γöé DRAGLIST*  Γöé
  12297. Γöé view and  Γöé       Γöé       Γöé       Γöé       Γöé
  12298. Γöé tree view. Γöé       Γöé       Γöé       Γöé       Γöé
  12299. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12300. Γöé Custom   Γöé CONTROL   Γöé CONTROL   Γöé CONTROL   Γöé CONTROL   Γöé
  12301. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12302. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12303. Γöé Control   Γöé CTLDATA   Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12304. Γöé data for a Γöé       Γöé       Γöé       Γöé       Γöé
  12305. Γöé custom   Γöé       Γöé       Γöé       Γöé       Γöé
  12306. Γöé dialog   Γöé       Γöé       Γöé       Γöé       Γöé
  12307. Γöé box,    Γöé       Γöé       Γöé       Γöé       Γöé
  12308. Γöé window or  Γöé       Γöé       Γöé       Γöé       Γöé
  12309. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12310. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12311. Γöé Named icon Γöé DEFAULTICONΓöé N/A     Γöé N/A     Γöé N/A     Γöé
  12312. Γöé file defi- Γöé       Γöé       Γöé       Γöé       Γöé
  12313. Γöé nition   Γöé       Γöé       Γöé       Γöé       Γöé
  12314. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12315. Γöé Default   Γöé DEFPUSHBUTTΓöéNDEFPUSHBUTTΓöéNDEFPUSHBUTTΓöéNDEFPUSHBUTTΓöéN
  12316. Γöé pushbutton Γöé       Γöé       Γöé       Γöé       Γöé
  12317. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12318. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12319. Γöé Dialog box Γöé DIALOG   Γöé DIALOG   Γöé DIALOG   Γöé DIALOG   Γöé
  12320. Γöé definition Γöé       Γöé       Γöé       Γöé       Γöé
  12321. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12322. Γöé Dialog box Γöé DLGINCLUDE Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12323. Γöé include   Γöé       Γöé       Γöé       Γöé       Γöé
  12324. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12325. Γöé Entry-   Γöé EDITTEXT  Γöé EDITTEXT  Γöé EDITTEXT  Γöé EDITTEXT  Γöé
  12326. Γöé field    Γöé ENTRYFIELD Γöé       Γöé       Γöé       Γöé
  12327. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12328. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  12329. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  12330. Γöé RESOURCE  Γöé OS/2 WARP  Γöé NT 3.51   Γöé WIN95    Γöé WIN32S   Γöé
  12331. Γöé CONTROL   Γöé       Γöé       Γöé       Γöé       Γöé
  12332. Γöé TYPE    Γöé       Γöé       Γöé       Γöé       Γöé
  12333. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12334. Γöé Font    Γöé FONT    Γöé FONT    Γöé FONT    Γöé FONT    Γöé
  12335. Γöé resource  Γöé       Γöé       Γöé       Γöé       Γöé
  12336. Γöé for an   Γöé       Γöé       Γöé       Γöé       Γöé
  12337. Γöé applica-  Γöé       Γöé       Γöé       Γöé       Γöé
  12338. Γöé tion    Γöé       Γöé       Γöé       Γöé       Γöé
  12339. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12340. Γöé Frame    Γöé FRAME    Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12341. Γöé window   Γöé       Γöé       Γöé       Γöé       Γöé
  12342. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12343. Γöé Group-box  Γöé GROUPBOX  Γöé GROUPBOX  Γöé GROUPBOX  Γöé GROUPBOX  Γöé
  12344. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12345. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12346. Γöé Help items Γöé HELPITEM  Γöé HELPITEM  Γöé HELPITEM  Γöé HELPITEM  Γöé
  12347. Γöé in a help  Γöé       Γöé       Γöé       Γöé       Γöé
  12348. Γöé table    Γöé       Γöé       Γöé       Γöé       Γöé
  12349. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12350. Γöé Help subi- Γöé HELPSUBITEMΓöé HELPSUBITEMΓöé HELPSUBITEMΓöé HELPSUBITEMΓöé
  12351. Γöé tems in a  Γöé       Γöé       Γöé       Γöé       Γöé
  12352. Γöé help table Γöé       Γöé       Γöé       Γöé       Γöé
  12353. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12354. Γöé Help sub-  Γöé HELPSUBTABLΓöé HELPSUBTABLΓöé HELPSUBTABLΓöé HELPSUBTABLΓöé
  12355. Γöé table    Γöé       Γöé       Γöé       Γöé       Γöé
  12356. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12357. Γöé Help table Γöé HELPTABLE  Γöé HELPTABLE  Γöé HELPTABLE  Γöé HELPTABLE  Γöé
  12358. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12359. Γöé List-box  Γöé LISTBOX   Γöé LISTBOX   Γöé LISTBOX   Γöé LISTBOX   Γöé
  12360. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12361. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12362. Γöé Left-    Γöé LTEXT    Γöé LTEXT    Γöé LTEXT    Γöé LTEXT    Γöé
  12363. Γöé aligned   Γöé       Γöé       Γöé       Γöé       Γöé
  12364. Γöé text    Γöé       Γöé       Γöé       Γöé       Γöé
  12365. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12366. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12367. Γöé Menu    Γöé MENU    Γöé MENU    Γöé MENU    Γöé MENU    Γöé
  12368. Γöé resource  Γöé       Γöé MENUEX   Γöé MENUEX   Γöé MENUEX   Γöé
  12369. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12370. Γöé Menu item  Γöé MENUITEM  Γöé MENUITEM  Γöé MENUITEM  Γöé MENUITEM  Γöé
  12371. Γöé for a menu Γöé       Γöé MENUEX   Γöé MENUEX   Γöé MENUEX   Γöé
  12372. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12373. Γöé String   Γöé STRINGTABLEΓöé STRINGTABLEΓöé STRINGTABLEΓöé STRINGTABLEΓöé
  12374. Γöé resources  Γöé MESSAGETABLΓöé MESSAGETABLΓöé MESSAGETABLΓöé MESSAGETABLΓöé
  12375. Γöé for an   Γöé       Γöé       Γöé       Γöé       Γöé
  12376. Γöé applica-  Γöé       Γöé       Γöé       Γöé       Γöé
  12377. Γöé tion    Γöé       Γöé       Γöé       Γöé       Γöé
  12378. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12379. Γöé Multiple  Γöé MLE     Γöé EDITTEXT  Γöé EDITTEXT  Γöé EDITTEXT  Γöé
  12380. Γöé line entry Γöé       Γöé RICHEDIT  Γöé RICHEDIT  Γöé RICHEDIT  Γöé
  12381. Γöé field    Γöé       Γöé       Γöé       Γöé       Γöé
  12382. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12383. Γöé Notebook  Γöé NOTEBOOK  Γöé PROPERTY  Γöé PROPERTY  Γöé PROPERTY  Γöé
  12384. Γöé control   Γöé       Γöé SHEET    Γöé SHEET    Γöé SHEET    Γöé
  12385. Γöé       Γöé       Γöé TABCONTROL Γöé TABCONTROL Γöé TABCONTROl Γöé
  12386. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12387. Γöé Presenta-  Γöé PRESPARAMS Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12388. Γöé tion    Γöé       Γöé       Γöé       Γöé       Γöé
  12389. Γöé parameters Γöé       Γöé       Γöé       Γöé       Γöé
  12390. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12391. Γöé Pushbutton Γöé PUSHBUTTON Γöé PUSHBUTTON Γöé PUSHBUTTON Γöé PUSHBUTTON Γöé
  12392. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12393. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12394. Γöé Radio-   Γöé RADIOBUTTONΓöé RADIOBUTTONΓöé RADIOBUTTONΓöé RADIOBUTTONΓöé
  12395. Γöé button   Γöé       Γöé       Γöé       Γöé       Γöé
  12396. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12397. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12398. Γöé Custom-   Γöé RCDATA   Γöé RCDATA   Γöé RCDATA   Γöé RCDATA   Γöé
  12399. Γöé data or   Γöé       Γöé       Γöé       Γöé       Γöé
  12400. Γöé user-    Γöé       Γöé       Γöé       Γöé       Γöé
  12401. Γöé defined   Γöé       Γöé       Γöé       Γöé       Γöé
  12402. Γöé resources  Γöé       Γöé       Γöé       Γöé       Γöé
  12403. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12404. Γöé Include   Γöé RCINCLUDE  Γöé RCINCLUDE  Γöé RCINCLUDE  Γöé RCINCLUDE  Γöé
  12405. Γöé another   Γöé       Γöé       Γöé       Γöé       Γöé
  12406. Γöé resource  Γöé       Γöé       Γöé       Γöé       Γöé
  12407. Γöé script   Γöé       Γöé       Γöé       Γöé       Γöé
  12408. Γöé file    Γöé       Γöé       Γöé       Γöé       Γöé
  12409. Γöé within   Γöé       Γöé       Γöé       Γöé       Γöé
  12410. Γöé current   Γöé       Γöé       Γöé       Γöé       Γöé
  12411. Γöé resource  Γöé       Γöé       Γöé       Γöé       Γöé
  12412. Γöé file    Γöé       Γöé       Γöé       Γöé       Γöé
  12413. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12414. Γöé Custom   Γöé RESOURCE  Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12415. Γöé resources  Γöé       Γöé       Γöé       Γöé       Γöé
  12416. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  12417. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  12418. Γöé RESOURCE  Γöé OS/2 WARP  Γöé NT 3.51   Γöé WIN95    Γöé WIN32S   Γöé
  12419. Γöé CONTROL   Γöé       Γöé       Γöé       Γöé       Γöé
  12420. Γöé TYPE    Γöé       Γöé       Γöé       Γöé       Γöé
  12421. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12422. Γöé Right-   Γöé RTEXT    Γöé RTEXT    Γöé RTEXT    Γöé RTEXT    Γöé
  12423. Γöé aligned   Γöé       Γöé       Γöé       Γöé       Γöé
  12424. Γöé text    Γöé       Γöé       Γöé       Γöé       Γöé
  12425. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12426. Γöé Slider   Γöé SLIDER   Γöé TRACKBAR  Γöé TRACKBAR  Γöé TRACKBAR  Γöé
  12427. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12428. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12429. Γöé Spinbutton Γöé SPINBUTTON Γöé UPDOWN   Γöé UPDOWN   Γöé UPDOWN   Γöé
  12430. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12431. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12432. Γöé Scrollbar  Γöé SCROLLBAR  Γöé SCROLLBAR  Γöé SCROLLBAR  Γöé SCROLLBAR  Γöé
  12433. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12434. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12435. Γöé Three    Γöé CHECKBOX  Γöé STATE3   Γöé STATE3   Γöé STATE3   Γöé
  12436. Γöé state    Γöé       Γöé       Γöé       Γöé       Γöé
  12437. Γöé check-box  Γöé       Γöé       Γöé       Γöé       Γöé
  12438. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12439. Γöé String   Γöé STRINGTABLEΓöé STRINGTABLEΓöé STRINGTABLEΓöé STRINGTABLEΓöé
  12440. Γöé resources  Γöé       Γöé       Γöé       Γöé       Γöé
  12441. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12442. Γöé Value set  Γöé VALUESET  Γöé N/A     Γöé N/A     Γöé N/A     Γöé
  12443. Γöé control   Γöé       Γöé       Γöé       Γöé       Γöé
  12444. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12445. Γöé Toolbar   Γöé Use IBM   Γöé TOOLBAR   Γöé TOOLBAR   Γöé TOOLBAR   Γöé
  12446. Γöé       Γöé Open Class Γöé       Γöé       Γöé       Γöé
  12447. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12448. Γöé Progress  Γöé Use IBM   Γöé PROGRESS  Γöé PROGRESS  Γöé PROGRESS  Γöé
  12449. Γöé Indicator  Γöé Open Class Γöé       Γöé       Γöé       Γöé
  12450. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12451. Γöé Informa-  Γöé Use IBM   Γöé STATUSBAR  Γöé STATUSBAR  Γöé STATUSBAR  Γöé
  12452. Γöé tion Area  Γöé Open Class Γöé       Γöé       Γöé       Γöé
  12453. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12454. Γöé Flyover   Γöé Use IBM   Γöé TOOLTIPS  Γöé TOOLTIPS  Γöé TOOLTIPS  Γöé
  12455. Γöé help    Γöé Open Class Γöé       Γöé       Γöé       Γöé
  12456. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  12457.  
  12458.  
  12459. ΓòÉΓòÉΓòÉ 17.6.1.1. Resource Control Notes ΓòÉΓòÉΓòÉ
  12460.  
  12461.  
  12462. Association Table for files 
  12463.  
  12464. This is not available on Windows platforms. 
  12465. Code-page setting 
  12466.  
  12467. The CODEPAGE ID in OS/2 is not the same as the LANGUAGE ID on Windows 
  12468. platforms. Refer to the Resource Script Language Reference for details. 
  12469. Container controls with details view and tree view 
  12470.  
  12471. For Windows platforms, these must be defined as custom controls with class 
  12472. WC_LISTVIEW, WC_TREEVIEW or WC_HEADER. To create a list with draggable items 
  12473. you have to create a standard list box and call draglist functions. Refer to 
  12474. WIN32.HLP for more detailed information on styles and function. 
  12475. Help items in a help table 
  12476.  
  12477. On Windows platforms, resource type HELPTABLE and HELPSUBTABLE are supported. 
  12478. However, the keyword HELPITEM and HELPSUBITEM are not supported. The body 
  12479. syntax for HELPTABLE and HELPSUBTABLE follows the RCDATA syntax. 
  12480. String resources for an application 
  12481.  
  12482. OS/2 provides utilities MKMSGF and MSGBIND for more comprehensive message 
  12483. definition. On the Windows platforms, use MC. See the section on message 
  12484. definition, compilation and binding for more details on the differences between 
  12485. the two methods. Typically applications use STRINGTABLE for strings. 
  12486. Multiple line entry field 
  12487.  
  12488. For the Windows platforms, the RichEdit control has to be defined as a custom 
  12489. control with class RICHEDIT. See WIN32.HLP for more detailed information on 
  12490. styles and function. 
  12491. Notebook control 
  12492.  
  12493. For the Windows platforms, the notebook itself is coded as a dialog box. 
  12494. Property sheet functions can then be used to display the dialog box and boxes 
  12495. as a notebook and subsequent pages. The Tab Control can be used as well to 
  12496. display this type of control. Refer to WIN32.HLP for more detailed information 
  12497. on styles and function. 
  12498. Slider control 
  12499.  
  12500. For the Windows platforms, these have to be defined as custom controls with 
  12501. class TRACKBAR_CLASS. Refer to WIN32.HLP for more detailed information on 
  12502. styles and function. 
  12503. Spinbutton control 
  12504.  
  12505. For the Windows platforms, this has to be defined as a custom control with 
  12506. class UPDOWN_CLASS. Refer WIN32.HLP for more detailed information on styles and 
  12507. function. 
  12508. Scrollbar control 
  12509.  
  12510. For OS/2 this is defined as a custom control with class ws_scrollbar. 
  12511. Toolbar 
  12512.  
  12513. Use IBM Open Class to code Toolbars in OS/2 and the Windows platforms. For the 
  12514. Windows platforms, you can specify this as a custom control with class 
  12515. TOOLBARCLASSNAME. 
  12516. Progress Indicator 
  12517.  
  12518. Use IBM Open Class to code progress indicators in OS/2 and the Windows 
  12519. platforms. For the Windows platforms, you can specify this as a custom control 
  12520. with class PROGRESS_CLASS. 
  12521. Information Area 
  12522.  
  12523. Use IBM Open Class to code information areas in OS/2 and the Windows platforms. 
  12524. For the Windows platforms, you can specify this as a custom control with class 
  12525. STATUSCLASSNAME. 
  12526. Flyover help 
  12527.  
  12528. Use IBM Open Class to code flyover help in OS/2 and the Windows platforms. For 
  12529. the Windows platforms, you can specify this as a custom control with class 
  12530. TOOLTIPS_CLASS. 
  12531.  
  12532. Note:  The VisualAge for C++ Resource Workshop can only load OS/2 bitmaps. The 
  12533. format of OS/2 icons, fonts, and cursors is incompatible. You can use the 
  12534. ibmpcni.exe image conversion utility to convert icons, bitmaps, and cursors 
  12535. between OS/2 format and Windows format. (The command-line version of this 
  12536. utility is ibmpcnv.exe.) 
  12537.  
  12538. There is no tool for converting dialog boxes. Instead you should use multicell 
  12539. canvases (IMultiCellCanvas), which allow automatic resizing and repositioning 
  12540. of their child windows. Because default fonts vary from system to system, you 
  12541. should also use multicell canvases for automatic setting of fonts in controls. 
  12542.  
  12543. See the IBM VisualAge for C++ for Windows User's Guide for more information 
  12544. about ibmpcni.exe and ibmpcnv.exe. 
  12545.  
  12546.  
  12547. ΓòÉΓòÉΓòÉ 17.6.2. Resource Compiler ΓòÉΓòÉΓòÉ
  12548.  
  12549. On the Windows platforms, the linker is used to bind resources into the 
  12550. executable. The .RES file created by the VisualAge for C++ resource compiler is 
  12551. handled by VisualAge for C++ linker. 
  12552.  
  12553. The OS/2 resource compiler allows: 
  12554.  
  12555.      Packing within a 64K boundary 
  12556.      Codepage specification 
  12557.      Compression (2 algorithms) 
  12558.      Country code specification 
  12559.  
  12560.  The IRC resource complier allows: 
  12561.  
  12562.      Renaming the output file 
  12563.      Verbose mode for tracing execution 
  12564.      Ignoring INCLUDE environment variable to set include path 
  12565.  
  12566.  The resource compiler command-line options are different between the OS/2 
  12567.  resource compiler and the IBM VisualAge for C++ for Windows resource compiler: 
  12568.  
  12569.  
  12570. ΓòÉΓòÉΓòÉ 17.6.2.1. OS/2 Resource Compiler Command-Line Options ΓòÉΓòÉΓòÉ
  12571.  
  12572.  -d          Define macro to preprocessor 
  12573.  -i          Include file path 
  12574.  -r          Create a .RES file (compile only) 
  12575.  -p          Pack - 386 resources will not cross 64K boundaries 
  12576.  -cp (or -k) DBCS code page or lead byte information 
  12577.  -x (1|2)    Exepack: compress resources, using method 1 or method 2 
  12578.  -cc         Country code 
  12579.  -h          Help 
  12580.  
  12581.  
  12582. ΓòÉΓòÉΓòÉ 17.6.2.2. IRC Compiler Command-Line Options ΓòÉΓòÉΓòÉ
  12583.  
  12584.  -fo         Set output file name 
  12585.  -r          Compile only (for OS/2 compatibility only - ignored ) 
  12586.  -v          Verbose 
  12587.  -i          Include path 
  12588.  -d          Define macro 
  12589.  -x          Ignore INCLUDE environment variable 
  12590.  -h          Help 
  12591.  
  12592.  The syntax of Windows resource compiler files is different from OS/2 resource 
  12593.  compiler files. In the IBM VisualAge for C++ for Windows resource compiler: 
  12594.  
  12595.      & is used instead of ~ for menu mnemonics 
  12596.      No id is allowed on menu bar separator lines 
  12597.      The order of icon, bitmap, cursor, and font parameters is different 
  12598.  
  12599.  For example, 
  12600.  
  12601.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  12602.   Γöé OS/2 RESOURCE COMPILER FILE   Γöé IRC RESOURCE COMPILER FILE   Γöé
  12603.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  12604.   Γöé   ICON 1000 "MYICON.ICO"   Γöé   1000 ICON "MYICON.ICO"   Γöé
  12605.   Γöé   BITMAP 1001 "MYBMP.BMP"   Γöé   1001 BITMAP "MYBMP.BMP"  Γöé
  12606.   Γöé   MENU 2000 {         Γöé   2000 MENU {        Γöé
  12607.   Γöé     SUBMENU "~File:", 2001  Γöé     POPUP "&File", 2001   Γöé
  12608.   Γöé     {            Γöé     {            Γöé
  12609.   Γöé      MENUITEM "~Load...", Γöé002    MENUITEM "&Load...". Γöé002
  12610.   Γöé     }            Γöé     }            Γöé
  12611.   Γöé   }              Γöé   }             Γöé
  12612.   Γöé   ACCELTABLE 3000       Γöé   3000 ACCELERATORS     Γöé
  12613.   Γöé   BEGIN            Γöé   BEGIN           Γöé
  12614.   Γöé    VK_F3, 3001, VIRTUALKEY  Γöé    VK_F3, 3001, VIRTUALKEY Γöé
  12615.   Γöé   END             Γöé   END            Γöé
  12616.   Γöé   STRINGTABLE LOADONCALL   Γöé   STRINGTABLE LOADONCALL   Γöé
  12617.   Γöé   {              Γöé   {             Γöé
  12618.   Γöé    4000, "Ordinary String"  Γöé    4000, "Ordinary String" Γöé
  12619.   Γöé    40001, "~Mnemonic String" Γöé    4001, "&Mnemonic String"Γöé
  12620.   Γöé   }              Γöé   }             Γöé
  12621.   Γöé   HELPTABLE 5000       Γöé   5000 HELPTABLE       Γöé
  12622.   Γöé   BEGIN            Γöé   BEGIN           Γöé
  12623.   Γöé    HELPITEM 100, 200, 300  Γöé    100, 200, 300      Γöé
  12624.   Γöé   END             Γöé   END            Γöé
  12625.   Γöé   HELPSUBTABLE 5100      Γöé   5100 HELPSUBTABLE     Γöé
  12626.   Γöé   BEGIN            Γöé   BEGIN           Γöé
  12627.   Γöé    HELPSUBITEM 400, 500   Γöé    400, 500         Γöé
  12628.   Γöé   END             Γöé   END            Γöé
  12629.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  12630.  
  12631.  You can use the irccnv.exe utility to move resource compiler files between 
  12632.  OS/2 format and Windows format. 
  12633.  
  12634.  
  12635. ΓòÉΓòÉΓòÉ 17.6.3. Information Presentation Facility (IPF) ΓòÉΓòÉΓòÉ
  12636.  
  12637. Use the Information Presentation Facility (IPF) help compiler ipfc.exe, and the 
  12638. online viewer iview.exe to compile and display online help defined in IPF 
  12639. format. 
  12640.  
  12641. IPF for the Windows platforms accepts OS/2 IPF binary files, but with some 
  12642. limitations due to the different code pages supported. It does the necessary 
  12643. conversion from the codepage used by the OS/2 IPF binary files. When a 
  12644. character available on the OS/2 codepage is not found in the Windows ANSI 
  12645. codepage, that character is mapped to a space. 
  12646.  
  12647. Unlike OS/2 where F1 is in the window default procedure, applications running 
  12648. on the Windows platforms have to trap F1 keystrokes by processing the VK_F1 key 
  12649. when the WM_KEYDOWN message is received by the application's window default 
  12650. procedure. 
  12651.  
  12652. For more information about application resources and using the resource 
  12653. compiler, refer to the IBM VisualAge for C++ for Windows User's Guide. 
  12654.  
  12655.  
  12656. ΓòÉΓòÉΓòÉ 17.7. Module Definition Files ΓòÉΓòÉΓòÉ
  12657.  
  12658. .DEF files are not compatible between the OS/2 and Windows platforms. 
  12659.  
  12660. You should use CPPFILT to generate the .DEF file. If you choose to generate the 
  12661. .DEF file yourself, and you are not passing objects to ILIB, you must decorate 
  12662. the external name according to linkage convention the function uses. All 
  12663. external data is prefixed with a leading underscore. ILIB will add export data 
  12664. for any variable declared with with a #pragma export directive. 
  12665.  
  12666. For example, if the following is specified: 
  12667.  
  12668.   foo1 is _Optlink linkage
  12669.   foo2 is  __cdecl linkage
  12670.   bar is __stdcall linkage
  12671.   bar2 is an external data object
  12672.  
  12673. The EXPORTS in the .DEF file must be specified as follows if you use ILIB to 
  12674. create an import library from the .DEF file and no objects are passed: 
  12675.  
  12676.   EXPORTS
  12677.    ?foo1
  12678.    _bar@4
  12679.    _foo2
  12680.    _bar2
  12681.  
  12682. Refer to Creating a Module Definition File for more information. 
  12683.  
  12684.  
  12685. ΓòÉΓòÉΓòÉ 17.8. Dynamic Link Libraries ΓòÉΓòÉΓòÉ
  12686.  
  12687. There are two ways to build a DLL. One way requires changes to your source code 
  12688. and the other way does not. 
  12689.  
  12690.  
  12691. ΓòÉΓòÉΓòÉ 17.8.1. Building a DLL - Method 1 Source Code Changes ΓòÉΓòÉΓòÉ
  12692.  
  12693.    1. Code your DLL source files using _Export, __declspec(dllexport), or 
  12694.       #pragma export. 
  12695.  
  12696.    2. Compile and link the object modules using icc. At least one file must be 
  12697.       compiled with /Ge-. 
  12698.  
  12699.       Note:  ILINK requires that an export (.EXP) file be provided with object 
  12700.       files to build a DLL. If you use icc to link your DLL and supply only the 
  12701.       object files and a .DEF file as input, icc detects the absence of an .EXP 
  12702.       file and automatically invokes ILIB with the object files and DEF file to 
  12703.       build the EXP file. Then icc invokes ILINK with the object files and .EXP 
  12704.       file to build the DLL. 
  12705.  
  12706.    3. Include the ILIB-generated import library when you link a module which 
  12707.       calls the DLL. 
  12708.  
  12709.  
  12710. ΓòÉΓòÉΓòÉ 17.8.2. Building a DLL - Method 2 No Source Code Changes ΓòÉΓòÉΓòÉ
  12711.  
  12712.    1. Code your DLL source files. 
  12713.  
  12714.    2. Compile the source code. At least one file must be compiled with /Ge-. 
  12715.  
  12716.    3. Create a .DEF file using CPPFILT. Run CPPFILT on the objects to produce 
  12717.       an export listing, using the /B and /P options. Comment out or remove any 
  12718.       function names in the CPPFILT output that you do not want to export. 
  12719.       Create a skeleton .DEF file with a LIBRARY and an EXPORTS statement. 
  12720.       Imbed the edited CPPFILT output under the EXPORTS statement. 
  12721.  
  12722.    4. Invoke ILIB with the /geni option and pass it the DEF file. ILIB 
  12723.       generates a .LIB import library and an .EXP export object. 
  12724.  
  12725.    5. Link the DLL and include the EXP object. 
  12726.  
  12727.       Note:  ILINK requires that an export (.EXP) file be provided with object 
  12728.       files to build a DLL. If you use icc to link your DLL and supply only the 
  12729.       object files and a .DEF file as input, icc detects the absence of an .EXP 
  12730.       file and automatically invokes ILIB with the object files and DEF file to 
  12731.       build the .EXP file. Then icc invokes ILINK with the object files and 
  12732.       .EXP file to build the DLL. 
  12733.  
  12734.    6. Include the ILIB-generated import library when you link a module which 
  12735.       calls the DLL. 
  12736.  
  12737.  You should use CPPFILT to generate the .DEF file. If you choose to hand-code 
  12738.  the .DEF file yourself, and you are not passing objects to ILIB, you must 
  12739.  decorate the external name according to the linkage convention used by the 
  12740.  variable or function. ILIB will add export data for any variable declared with 
  12741.  a #pragma export directive. 
  12742.  
  12743.  You must mark data imports by _Import or __declspec(dllimport). Code is 
  12744.  generated more efficiently if you also do this for function imports. 
  12745.  
  12746.  IBM VisualAge for C++ for Windows provides a new option, /qautoimported, to 
  12747.  help you port your OS/2 code. 
  12748.  
  12749.  The default is /qnoautoimported. The compiler generates code assuming that all 
  12750.  external data references are imports from a DLL, even if they are defined 
  12751.  locally in another compilation unit. This eliminates the need for you to 
  12752.  explicitly mark your data imports and and helps speed up your porting effort. 
  12753.  
  12754.  The /qautoimported option does not affect external functions. 
  12755.  
  12756.  Note:  The /qautoimported option results in slightly larger executables and 
  12757.  less optimal code. It should not be used for production-level code. More 
  12758.  efficient code is generated if imports are marked explicitly with the _Import 
  12759.  or __declspec(dllimport) specifiers. 
  12760.  
  12761.  The #pragma import preprocessor directive is not supported in IBM VisualAge 
  12762.  for C++ for Windows, so you cannot use it to avoid having to use a .LIB file. 
  12763.  If you try to use #pragma import, you receive an warning message that says 
  12764.  #pragma import is not supported and you should use the _Import keyword or the 
  12765.  __declspec(dllimport) keyword instead. 
  12766.  
  12767.  An external pointer cannot be initialized with the address of an imported C 
  12768.  variable. This is allowed in C++. Both C and C++ allow a function pointer to 
  12769.  be statically initialized to the address of an imported function. 
  12770.  
  12771.  For more information about dynamic link libraries, refer to Building Dynamic 
  12772.  Link Libraries. 
  12773.  
  12774.  
  12775. ΓòÉΓòÉΓòÉ 17.9. Calling Conventions ΓòÉΓòÉΓòÉ
  12776.  
  12777. Calling between 32-bit and 16-bit code is not supported. The linker does not 
  12778. support 16-bit code. 
  12779.  
  12780. The keywords used in the following function calling conventions are reserved by 
  12781. the compiler, but the calling conventions themselves are not supported by IBM 
  12782. VisualAge for C++ for Windows 
  12783.  
  12784.      _Pascal 
  12785.      _Far32 _Pascal 
  12786.      _Far16 _Cdecl 
  12787.      _Far16 _Pascal 
  12788.      _Far16 _Fastcall 
  12789.  Using the keywords as calling conventions causes a warning to be issued, and 
  12790.  the default linkage, _Optlink, is used. 
  12791.  
  12792.  The _Seg16 specifier is not supported for declaring segmented pointers. 
  12793.  
  12794.  The _System calling convention is equivalent to __stdcall, but is treated as a 
  12795.  distinct linkage convention. 
  12796.  
  12797.  At link time, function names are decorated according to the linkage convention 
  12798.  specified. The following decorations are used: 
  12799.  
  12800.  Linkage Convention      Name Decoration 
  12801.  
  12802.  _Optlink                Function names are decorated with a question mark 
  12803.                          prefix (?) when they appear in object modules. For 
  12804.                          example, a function named fred in the source program 
  12805.                          will appear as ?fred in the object. 
  12806.  
  12807.  __stdcall and _System   Function names are decorated with an underscore prefix 
  12808.                          (_), and a suffix which consists of an at sign (@), 
  12809.                          followed by the number of bytes of parameters (in 
  12810.                          decimal). Parameters of less than four bytes are 
  12811.                          rounded up to four bytes. Structure sizes are also 
  12812.                          rounded up to a multiple of four bytes. For example, a 
  12813.                          function fred prototyped as follows: 
  12814.  
  12815.                                                     int fred(int, int, short);
  12816.  
  12817.                          would appear as: 
  12818.  
  12819.                                                     _fred@12
  12820.  
  12821.                          in the object module. 
  12822.  
  12823.  __cdecl                  Function names are decorated with an underscore 
  12824.                          prefix (_) when they appear in object modules. For 
  12825.                          example, a function named fred in the source program 
  12826.                          will appear as _fred in the object. 
  12827.  
  12828.  Hand-coded .DEF files passed to ILIB without the corresponding objects must 
  12829.  specify the fully-decorated name. You should prepare your .DEF files with 
  12830.  CPPFILT or pass objects to ILIB. Avoid hand-coding .DEF files. 
  12831.  
  12832.  For more information about calling conventions, refer to Calling Conventions. 
  12833.  
  12834.  
  12835. ΓòÉΓòÉΓòÉ 17.10. Device Drivers ΓòÉΓòÉΓòÉ
  12836.  
  12837. The /Gv+ and /Gr+ options are not supported because VisualAge for C++ does not 
  12838. support 16-bit device drivers. 
  12839.  
  12840.  
  12841. ΓòÉΓòÉΓòÉ 17.11. Tiled Memory Support ΓòÉΓòÉΓòÉ
  12842.  
  12843. This support is provided on VisualAge for C++ for OS/2 to allow coexistence of 
  12844. 16-bit code. NT does not support 64K segments, and therefore, the runtime does 
  12845. not support tiled memory. The VisualAge for C++ for OS/2 /Gt option is not 
  12846. supported. 
  12847.  
  12848. For more information about memory management, refer to Managing Memory. 
  12849.  
  12850.  
  12851. ΓòÉΓòÉΓòÉ 17.12. IBM Open Class Library ΓòÉΓòÉΓòÉ
  12852.  
  12853. The "Open Class Library Portability Tables" in the Open Class Library User's 
  12854. Guide summarize the portability of the IBM Open Class Library. 
  12855.  
  12856.  
  12857. ΓòÉΓòÉΓòÉ 17.12.1. Application Support Class Library ΓòÉΓòÉΓòÉ
  12858.  
  12859. IErrorInfo in has been renamed to IBaseErrorInfo in IBM VisualAge for C++ for 
  12860. Windows. This is because the former is the same as a OLE-related class. 
  12861.  
  12862. Predefined macros redefine IErrorInfo to IBaseErrorInfo if you do not use OLE. 
  12863. If your program does use OLE, it must use IBaseErrorInfo. 
  12864.  
  12865. The American National Standard for Information Systems C++ Working Paper, 
  12866. requires compilers to have a built-in operator[](char *, int) that participates 
  12867. fully in overload resolution and discourages class libraries from providing 
  12868. their own operator char*(). 
  12869.  
  12870. The IString class has both char(*) operator and an index operator that takes 
  12871. unsigned int as the parameter. This creates ambiguity during the resolution of 
  12872. index operator from IString and the compiler built-in index operator. 
  12873.  
  12874. The IString class provides an additional index that takes signed integer. This 
  12875. provides unambiguous resolution of the index operator from IString does not 
  12876. conflict with the built-in index operator on character strings. 
  12877.  
  12878. The IString class has both const and non-const versions of unsigned index 
  12879. operator; both of these versions are also implemented for the signed index 
  12880. operator. 
  12881.  
  12882. The following member functions have been added to the IString class: 
  12883.  
  12884. char
  12885.  &operator []   ( signed  index );
  12886.  
  12887. const char
  12888.  &operator []   ( signed  index ) const;
  12889.  
  12890. C and C++ allow the index value to be a floating point number. Because the 
  12891. compiler converts the floating point number to an integer, the compiler cannot 
  12892. disambiguate between signed or unsigned version of the index operator from 
  12893. IString. If your code uses a floating-point number as an index for IString, you 
  12894. should type cast the floating point to integer while indexing IString to 
  12895. resolve this problem. 
  12896.  
  12897.  
  12898. ΓòÉΓòÉΓòÉ 17.12.2. Win32s Support Restrictions ΓòÉΓòÉΓòÉ
  12899.  
  12900.      Multimedia classes are not supported on Win32s. 
  12901.  
  12902.      PM-compatible versions of Spinbutton, Notebook, and Container are not 
  12903.       supported on Win32s. 
  12904.  
  12905.      Compound Document Framework applications do not run on Win32s. 
  12906.  
  12907.  
  12908. ΓòÉΓòÉΓòÉ 17.12.3. Default Coordinate System ΓòÉΓòÉΓòÉ
  12909.  
  12910. The default coordinate system of an application has been modified to use the 
  12911. native coordinate system, instead of always using 
  12912. ICoordinateSystem::originLowerLeft. Applications that need to maintain the OS/2 
  12913. look and feel will need to specifically call: 
  12914.  
  12915.  ICoordinateSystem::setApplicationOrientation(
  12916.                 ICoordinateSystem::originLowerLeft );
  12917.  
  12918.  
  12919. ΓòÉΓòÉΓòÉ 17.12.4. Choosing Windows Style or OS/2 Style Controls ΓòÉΓòÉΓòÉ
  12920.  
  12921. New style bits allow you to choose the style of the controls that the classes 
  12922. implement. You can choose either a PM-compatible control to look like OS/2, or 
  12923. a Windows 95 control. The default is set to implement the controls for Windows 
  12924. 95. To implement the OS/2 style you need to specify this style explicitly. 
  12925.  
  12926. We recommend you code the style using conditional compilation directives (#if 
  12927. or #ifdef), so that you can experiment and change the style without changing 
  12928. your source code. 
  12929.  
  12930. The following classes are affected: 
  12931.  
  12932.      IContainerControl, 
  12933.      INotebook, 
  12934.      IProgressIndicator and its derived classes 
  12935.      IBaseSpinButton and its derived classes. 
  12936.  
  12937.  An additional style bit allows you to choose either native Windows help or the 
  12938.  IPF-style help for the IHelpWindow class. 
  12939.  
  12940.  For more information about the IBM Open Class Library, refer to the IBM 
  12941.  VisualAge for C++ for Windows Open Class Library User's Guide and the IBM 
  12942.  VisualAge for C++ for Windows Open Class Library Reference. 
  12943.  
  12944.  
  12945. ΓòÉΓòÉΓòÉ 17.13. C and C++ Language Implementation ΓòÉΓòÉΓòÉ
  12946.  
  12947.  
  12948. ΓòÉΓòÉΓòÉ 17.13.1. External Identifiers ΓòÉΓòÉΓòÉ
  12949.  
  12950. There is no limit for the number of characters in an identifier. However, only 
  12951. the first several characters of identifiers may be significant. The number of 
  12952. significant characters for external identifiers is different between VisualAge 
  12953. for C++ for OS/2 and IBM VisualAge for C++ for Windows. 
  12954.  
  12955.  Identifier                  Maximum Number of Significant Characters 
  12956.  External data objects       255 after name decoration for linkage conventions 
  12957.                              (254 characters before name decoration for linkage 
  12958.                              conventions) 
  12959.  External function names     255 after name decoration for linkage conventions 
  12960.                              (243 characters before name decoration for 
  12961.                              __stdcall linkage convention, and 254 characters 
  12962.                              before name decoration for other linkage 
  12963.                              conventions) 
  12964.  
  12965.  
  12966. ΓòÉΓòÉΓòÉ 17.13.2. Keywords ΓòÉΓòÉΓòÉ
  12967.  
  12968. For compatibility with Microsoft Visual C++, the VisualAge for C++ compiler 
  12969. reserves the following keywords in extended mode only: 
  12970.  
  12971. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  12972. Γöé _asm      Γöé _except     Γöé _int16     Γöé _stdcall    Γöé
  12973. Γöé __asm     Γöé _finally    Γöé _int32     Γöé _try      Γöé
  12974. Γöé _cdecl     Γöé _inline     Γöé _int64     Γöé        Γöé
  12975. Γöé _declspec   Γöé _int8      Γöé _leave     Γöé        Γöé
  12976. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  12977.  
  12978. The Microsoft Visual C++ __declspec(naked) specifier is not supported by 
  12979. VisualAge for C++. A warning is issued if it is used. 
  12980.  
  12981. The _asm and __asm keywords are recognized by VisualAge for C++ in extended 
  12982. mode only. However, no code is generated for the inlined assembler instructions 
  12983. and a warning is issued. 
  12984.  
  12985.  
  12986. ΓòÉΓòÉΓòÉ 17.13.3. Structure and Union Alignment ΓòÉΓòÉΓòÉ
  12987.  
  12988. The default structure alignment on Windows platforms is 8 bytes instead of 4 
  12989. bytes on OS/2. Use the _Packed keyword in C, or the #pragma pack directive in C 
  12990. and C++ to adjust the alignment of structures and unions. 
  12991.  
  12992. You can also use the /Sp option to change the default packing. You should use 
  12993. the /Sp4 option for your Windows code to achieve the same alignment as on OS/2. 
  12994.  
  12995.  
  12996. ΓòÉΓòÉΓòÉ 17.13.4. Bit Fields ΓòÉΓòÉΓòÉ
  12997.  
  12998. In general, the binary representation of bit fields is quite different between 
  12999. OS/2 and the Windows platforms. 
  13000.  
  13001. Windows bitfields are aligned according to their type. A char bitfield is 
  13002. 1-byte aligned, a short is 2-byte aligned, and so on. On OS/2 they were placed 
  13003. in the smallest possible container and aligned according to that container 
  13004. size. For example: 
  13005.  
  13006.   struct str {
  13007.    char a;
  13008.    int b:7;
  13009.   };
  13010.  
  13011. On OS/2, b is char-aligned, because the alignment of the strictest member is 
  13012. char. On Windows, b is int-aligned because its type is int. In IBM VisualAge 
  13013. for C++ for Windows, bitfields are not allowed to cross container boundaries. 
  13014. VisualAge for C++ for OS/2 permits this. 
  13015.  
  13016. On Windows, bit fields of types with different size do not share containers. 
  13017. Bit fields also do not share their containers with with regular members. For 
  13018. example, 
  13019.  
  13020.    struct str {
  13021.     int  a:6;
  13022.     char b:3;
  13023.    };
  13024.  
  13025. has size of 8, and 
  13026.  
  13027.    struct str {
  13028.     int a:4;
  13029.     char b;
  13030.    };
  13031.  
  13032. also has size of 8. 
  13033.  
  13034. Another way to help achieve binary compatibility is by using zero-width bit 
  13035. fields to force alignment. These bit fields must be of types with the same 
  13036. size. In some cases it might be very difficult to create C or C++ source for a 
  13037. bitfield that would result in equivalent binary representations in both IBM 
  13038. VisualAge for C++ for Windows and VisualAge for C++ for OS/2. 
  13039.  
  13040. One way to force alignment compatibility is to change bit fields to unions with 
  13041. the same intergral type. For example, this structure is not binary compatible 
  13042. between Windows and OS/2: 
  13043.  
  13044.    struct st {
  13045.     char a;
  13046.     int  i1 : 5;
  13047.     int  i2 : 30;
  13048.     short b;
  13049.    };
  13050.  
  13051. But the following structure is binary compatible: 
  13052.  
  13053.    struct st {
  13054.     char a;
  13055.     union {
  13056.      int dummy[2];
  13057.      struct {
  13058.       int i1 : 5;
  13059.       int i2 : 30;
  13060.      };
  13061.     };
  13062.     short b;
  13063.    };
  13064.  
  13065. A full discussion of binary compatibility of bitfields is beyond the scope of 
  13066. this chapter. 
  13067.  
  13068.  
  13069. ΓòÉΓòÉΓòÉ 17.13.5. Pragmas ΓòÉΓòÉΓòÉ
  13070.  
  13071. The following VisualAge for C++ for OS/2 pragmas are not supported by IBM 
  13072. VisualAge for C++ for Windows: 
  13073.  
  13074.      checkout 
  13075.      import 
  13076.      stack16 
  13077.      seg16 
  13078.      linkage with the following subspecifiers: 
  13079.         -  far16 cdecl 
  13080.         -  far16 fastcall 
  13081.         -  far16 pascal 
  13082.         -  pascal 
  13083.  
  13084.  A warning is issued if any of these pragmas are used. 
  13085.  
  13086.  The following Microsoft Visual C++ #pragma directives are not supported by 
  13087.  VisualAge for C++: 
  13088.  
  13089.      function 
  13090.      intrinsic 
  13091.      inline_depth 
  13092.      warning 
  13093.  
  13094.  
  13095. ΓòÉΓòÉΓòÉ 17.13.5.1. #pragma pack ΓòÉΓòÉΓòÉ
  13096.  
  13097. Default packing is on 4-byte boundaries for VisualAge for C++ for OS/2, and 
  13098. 8-byte boundaries in IBM VisualAge for C++ for Windows, which is also the 
  13099. default for Microsoft Visual C++. 
  13100.  
  13101.  
  13102. ΓòÉΓòÉΓòÉ 17.13.5.2. #pragma export ΓòÉΓòÉΓòÉ
  13103.  
  13104. ILIB accepts #pragma export to generate information for import libraries and 
  13105. export objects. For exported functions, You should use the _Export keyword or 
  13106. the __declspec(dllexport) keyword instead. For exported data, you must use the 
  13107. _Export keyword or the __declspec(dllexport) keyword. 
  13108.  
  13109.  
  13110. ΓòÉΓòÉΓòÉ 17.13.5.3. #pragma import ΓòÉΓòÉΓòÉ
  13111.  
  13112. The #pragma import directive is not supported in IBM VisualAge for C++ for 
  13113. Windows. The compiler accepts the #pragma import directive, but issues a 
  13114. warning to use the _Import keyword or the __declspec(dllimport) keyword 
  13115. instead. 
  13116.  
  13117. The VisualAge for C++ linker does not recognize #pragma import; you must supply 
  13118. an import library. 
  13119.  
  13120.  
  13121. ΓòÉΓòÉΓòÉ 17.13.6. Operator Overloading ΓòÉΓòÉΓòÉ
  13122.  
  13123. The ANSI C++ working group has made the following clarifications of how and 
  13124. which built-in operators should participate in the operator overload resolution 
  13125. process: 
  13126.  
  13127.      All appropriate built-in operators that are specified in section 13.6 of 
  13128.       the September 1995 ANSI draft participate in the process. 
  13129.  
  13130.      If you are using binary operators with pointer operands, the pointer 
  13131.       operands must point to the same data type. 
  13132.  
  13133.      The compiler distinguishes between integral/arithmetic and promoted 
  13134.       integral/arithmetic type operands. 
  13135.  
  13136.      The compiler only chooses the user-defined operator[] function for the 
  13137.       subscripting expression x[y], if the overload resolution process chooses 
  13138.       it as the best function match over the builtin operator. 
  13139.  
  13140.      For builtin assignment operators, conversions of the left operand are 
  13141.       restricted as follows: 
  13142.  
  13143.         -  No temporary objects are introduced to hold the left operand. 
  13144.         -  No user-defined conversions are applied to achieve a type match with 
  13145.            the left operand. 
  13146.  
  13147.  For more information about the IBM VisualAge for C++ for Windows C and C++ 
  13148.  language implementation, refer to the IBM VisualAge for C++ for Windows 
  13149.  Language Reference. 
  13150.  
  13151.  
  13152. ΓòÉΓòÉΓòÉ 17.14. Portability Books ΓòÉΓòÉΓòÉ
  13153.  
  13154.  
  13155. ΓòÉΓòÉΓòÉ 17.14.1. C and C++ Standards ΓòÉΓòÉΓòÉ
  13156.  
  13157. At this time, a standard for the C++ language comparable to the C standards is 
  13158. in development by a committee of the American National Standards Institute 
  13159. (ANSI). The IBM IBM VisualAge for C++ for Windows compiler is based on their 
  13160. current working paper, Working Paper for Draft Proposed American National 
  13161. Standard for Information Systems-Programming Language C++ (X3J16/95-0087) 
  13162.  
  13163. The VisualAge for C++ compiler adheres to most, but not all, aspects of the 
  13164. language specified in the ANSI/ISO C++ working paper dated April 28, 1995. 
  13165.  
  13166.  ANSI/ISO-IEC 9899-1990[1992] 
  13167.            Presents the ANSI/ISO standard for the C language. This document has 
  13168.            officially replaced American National Standard for Information 
  13169.            Systems-Programming Language C (X3.159-1989) as the ANSI C standard, 
  13170.            and is technically equivalent to ANSI X3.159-1989. 
  13171.  
  13172.  ISO/IEC 9899:1990(E) 
  13173.            Presents the International Standards Organization (ISO) standard for 
  13174.            the C language. 
  13175.  
  13176.  Federal Information Processing Standards Publication C (FIPS PUB 160) 
  13177.            Presents the Federal Information Processing Standard (FIPS) for the 
  13178.            C language. 
  13179.  
  13180.  VisualAge for C++ supports most, but not all, of the changes adopted into the 
  13181.  C Standard by ISO/IEC 9899:1990/Amendment 1:1994. 
  13182.  
  13183.  
  13184. ΓòÉΓòÉΓòÉ 17.14.2. Other Portability References ΓòÉΓòÉΓòÉ
  13185.  
  13186. Many commercial books have been written about C and C++ portability and 
  13187. cross-platform programming. You may find the following books useful. We do not 
  13188. specifically recommend either of these books, and other publications may be 
  13189. available in your locality. 
  13190.  
  13191.      Anthony S. Glad. Cross-Platform Software Development. New York: Van 
  13192.       Nostrand Reinhold, 1995. (ISBN 0-442-01812-6) 
  13193.  
  13194.      Mark R. Horton. Portable C Software. Englewood Cliffs: Prentice-Hall, 
  13195.       1990. (ISBN 0-138-68050-7) 
  13196.  
  13197.  
  13198. ΓòÉΓòÉΓòÉ 18. The IBM System Object Model ΓòÉΓòÉΓòÉ
  13199.  
  13200. The IBM System Object Model (SOM) provides a common programming interface for 
  13201. building and using objects.  SOM improves your C++ programming productivity in 
  13202. two ways: 
  13203.  
  13204.      If you develop or maintain libraries of C++ classes and methods that are 
  13205.       used by other application developers, SOM allows you to release new 
  13206.       versions of a library without requiring users of the library to recompile 
  13207.       their applications. 
  13208.      SOM lets you make your C++ classes and objects accessible to programs 
  13209.       written in other languages, and to write C++ programs that use classes 
  13210.       and objects created using other SOM-supported languages. 
  13211.  
  13212.  You can make classes and methods in existing C++ programs SOM-accessible 
  13213.  without having to rewrite class and method definitions. Although SOM imposes 
  13214.  some restrictions on C++ coding conventions, you should be able to convert 
  13215.  most C++ programs for SOM support with minimal effort. VisualAge for C++ can 
  13216.  convert existing C++ classes to SOM classes. This method of creating SOM 
  13217.  classes is sometimes referred to as the Direct-to-SOM or DTS method, and a 
  13218.  Direct-to-SOM or DTS class is one that has been converted to SOM by the 
  13219.  compiler. 
  13220.  
  13221.  For information on how you can have the compiler convert classes to SOM, see 
  13222.  Converting C++ Programs to SOM Using SOMAsDefault and Creating SOM-Compliant 
  13223.  Programs by Inheriting from SOMObject. 
  13224.  
  13225.  The following topics are described in this chapter: 
  13226.  
  13227.      An overview of SOM 
  13228.      SOM and binary compatibility of C++ libraries 
  13229.      SOM and interlanguage sharing of objects and methods 
  13230.      Differences between SOM and C++ 
  13231.      Converting C++ programs to SOM using the SOMAsDefault pragma 
  13232.      Creating SOM-compliant programs by inheriting from SOMObject 
  13233.      Pragmas for using SOM. 
  13234.  This chapter does not describe the entire scope of SOM.  For more detail on 
  13235.  SOM, see the online SOM Programming Guide and the online SOM Programming 
  13236.  Reference. 
  13237.  
  13238.  
  13239. ΓòÉΓòÉΓòÉ 18.1. What is SOM? ΓòÉΓòÉΓòÉ
  13240.  
  13241. SOM defines an interface between programs, or between libraries and programs, 
  13242. so that an object's interface is separated from its implementation.  SOM allows 
  13243. classes of objects to be defined in one programming language and used in 
  13244. another, and it allows libraries of such classes to be updated without 
  13245. requiring client code to be recompiled. 
  13246.  
  13247. A SOM library consists of a set of classes, methods, static functions, and data 
  13248. members.  Programs that use a SOM library can create objects of the types 
  13249. defined in the library, use the methods defined for an object type, and derive 
  13250. subclasses from SOM classes, even if the language of the program accessing the 
  13251. SOM library does not support class typing.  A SOM library and the programs that 
  13252. use objects and methods of that library need not be written in the same 
  13253. programming language.  SOM also minimizes the impact of revisions to libraries. 
  13254. If a SOM library is changed to add new classes or methods, or to change the 
  13255. internal implementation of classes or methods, you can still run a program that 
  13256. uses that library without recompiling. This is not the case for all other C++ 
  13257. libraries, which in some cases require recompilation of all programs that use 
  13258. them whenever the libraries themselves are changed. 
  13259.  
  13260. SOM provides an Application Programming Interface (API) that gives programs 
  13261. access to information about a SOM class or SOM object.  Any SOM class inherits 
  13262. a set of virtual methods that can be used, for example, to find the class name 
  13263. of an object, or to determine whether a particular method is available for an 
  13264. object. These API functions are fully described in the online SOM Programming 
  13265. Guide. 
  13266.  
  13267. You can make your C++ classes and methods SOM-accessible in one of two ways: 
  13268. by using pragmas to direct the compiler in generating a SOM interface for your 
  13269. code, or by explicitly deriving your classes from SOMObject.  Both of these 
  13270. techniques are described later in this chapter. In both cases, VisualAge for 
  13271. C++ can also generate Interface Definition Language (IDL) files which are 
  13272. required to make your C++ SOM classes accessible to non-C++ programs. For 
  13273. further details see Understanding the Interface Definition Language (IDL). 
  13274.  
  13275. Once you have a SOM-compliant version of your library, you can add methods, 
  13276. types, and subtypes to that library, or change the implementation of methods, 
  13277. without requiring programs that use your library to be recompiled.  These 
  13278. programs need only be recompiled if they themselves are modified, for example 
  13279. to make use of newly defined types or methods.  See SOM and Upward Binary 
  13280. Compatibility of Libraries for further details. 
  13281.  
  13282.  
  13283. ΓòÉΓòÉΓòÉ 18.1.1. SOM and CORBA ΓòÉΓòÉΓòÉ
  13284.  
  13285. SOM complies with the Common Object Request Broker Architecture (CORBA) 
  13286. standard defined by the Object Management Group. CORBA is an industry-wide 
  13287. standard for the management of objects across heterogeneous, distributed 
  13288. systems. 
  13289.  
  13290.  
  13291. ΓòÉΓòÉΓòÉ 18.1.2. The Cost of Using SOM ΓòÉΓòÉΓòÉ
  13292.  
  13293. SOM is a powerful tool, but the flexibility that it gives you comes at a price. 
  13294. A program that is SOM-enabled may run more slowly than an equivalent one in 
  13295. native C++. You should weigh the many benefits of SOM against the possible 
  13296. effect it may have on the performance of your program. 
  13297.  
  13298.  
  13299. ΓòÉΓòÉΓòÉ 18.1.3. SOM and DSOM ΓòÉΓòÉΓòÉ
  13300.  
  13301. Distributed SOM (DSOM) is an extension of SOM that permits the creation of 
  13302. client programs capable of calling the methods of remote SOM objects. Such 
  13303. method calls are entirely transparent to both the client and the server. When 
  13304. you compile your C++ classes with SOM support, those classes can be used in 
  13305. DSOM applications. 
  13306.  
  13307. For further details on DSOM, see Using SOM Classes in DSOM Applications. 
  13308.  
  13309.  
  13310. ΓòÉΓòÉΓòÉ 18.2. What is DTS? ΓòÉΓòÉΓòÉ
  13311.  
  13312. If you are an experienced SOM programmer who has used earlier versions of SOM 
  13313. from C or C++ programs, you know that SOM defines bindings for those languages. 
  13314. The language bindings consist of a number of macros plus structure or class 
  13315. definitions in header files with the extensions .h and .ih (for C) and .xh and 
  13316. .xih (for C++). They are generated for a particular SOM class by running the 
  13317. SOM Compiler sc.exe on the .idl file for that class interface. The bindings can 
  13318. be used with a wide range of C and C++ compilers and do not require special 
  13319. compiler support. 
  13320.  
  13321. Direct-to-SOM (DTS) is a new and much more flexible way of using SOM in a C++ 
  13322. program. DTS class definitions resemble regular C++ classes, and you can either 
  13323. write them directly or use sc.exe to generate them into files with an .hh 
  13324. extension from existing IDL. DTS C++ class definitions can only be used with 
  13325. C++ compilers like VisualAge for C++ that support DTS. 
  13326.  
  13327. DTS provides the same access to SOM functionality that the C++ bindings do but, 
  13328. in addition, DTS supports far more of the C++ language. DTS supports member 
  13329. operators, conversion functions, user-defined new and delete operators, 
  13330. function overloading, stack local SOM objects, and first-class source debugging 
  13331. support for SOM classes. You can write and subclass your DTS classes directly 
  13332. and may never need to write a line of IDL. 
  13333.  
  13334. VisualAge for C++ supports DTS C++, but still can be used with C and C++ 
  13335. bindings. SOM DLLs and EXEs can interoperate freely whether constructed using C 
  13336. bindings, C++ bindings, or DTS C++. 
  13337.  
  13338. Warning: Within one single C++ compilation, it is not possible to use both C++ 
  13339. bindings and DTS. A useful rule of thumb is that if you include any .xh header 
  13340. files in your compilation, you must not also include any .hh files, or use the 
  13341. SOMAsDefault pragma or the /Ga option. 
  13342.  
  13343.  
  13344. ΓòÉΓòÉΓòÉ 18.3. Interface Definition Language ΓòÉΓòÉΓòÉ
  13345.  
  13346. The Interface Definition Language (IDL) is a language-independent notation for 
  13347. specifying the interfaces of SOM objects. It is required for implementing DSOM 
  13348. classes, and when making your C++ SOM classes accessible from other languages. 
  13349. VisualAge for C++ generates an IDL description of your SOM classes for you. For 
  13350. more information about IDL, see the online SOM Programming Guide. 
  13351.  
  13352.  
  13353. ΓòÉΓòÉΓòÉ 18.4. SOM and Upward Binary Compatibility of Libraries ΓòÉΓòÉΓòÉ
  13354.  
  13355. This section is intended for programmers who are developing or maintaining 
  13356. libraries containing C++ class and object definitions. This section does not 
  13357. describe how to write programs that use a SOM-compliant library. 
  13358.  
  13359. When you make changes to a SOM library that contains C++ class and method 
  13360. definitions, programs that use your library may or may not need to be 
  13361. recompiled in order to work with the new version of the library. Changes to 
  13362. your library that may not require recompilation of client programs include: 
  13363.  
  13364.      Adding new classes, including base classes 
  13365.      Adding new methods or data members to existing classes 
  13366.      Changing or removing private methods or data members from classes 
  13367.      Changing the internal implementation of public or protected methods 
  13368.      Moving member functions from a derived class to a base class. 
  13369.  For more detail on such changes, see the online SOM Programming Guide and the 
  13370.  online SOM Programming Reference. 
  13371.  
  13372.  If you change your library only in the ways described above, and you follow 
  13373.  the rules described in Release Order of SOM Objects, you can provide the new 
  13374.  library to your users in binary form, and their programs will work with the 
  13375.  new library without needing to be recompiled, or even relinked if the library 
  13376.  is a dynamically linked library. 
  13377.  
  13378.  Changes to your library that will require recompilation of client programs 
  13379.  include: 
  13380.  
  13381.      Removing classes 
  13382.      Removing public data members, methods, or static member functions from 
  13383.       existing classes. 
  13384.  
  13385.  In the context of the above list, removing also includes renaming. Renaming an 
  13386.  item from a library is equivalent to removing the item and adding a new item 
  13387.  with the same characteristics.  If you use the SOMMethodName or SOMClassName 
  13388.  pragmas to provide a SOM name for a C++ method or class, changing the SOM name 
  13389.  has the same effect as renaming the C++ method or class name. 
  13390.  
  13391.  Adding the SOMMethodName or SOMNoMangling pragmas for a method also changes 
  13392.  the SOM name from that supplied by the compiler to that specified by the 
  13393.  pragma.  If there is any likelihood of non-C++ programs using your SOM 
  13394.  classes, use these pragmas for your initial implementation. 
  13395.  
  13396.  The remainder of this section describes details of how SOM provides upward 
  13397.  binary compatibility of libraries. You do not need to know this information to 
  13398.  create or maintain SOM-compliant libraries, but the information will help you 
  13399.  understand when and why certain SOM pragmas are used (specifically, 
  13400.  SOMReleaseOrder and SOMClassVersion). 
  13401.  
  13402.  
  13403. ΓòÉΓòÉΓòÉ 18.4.1. Release Order of SOM Objects ΓòÉΓòÉΓòÉ
  13404.  
  13405. SOM achieves binary compatibility by arranging all the components of a class 
  13406. into ordered lists, locating them by their position in a list, and by enforcing 
  13407. rules to ensure that the ordering of the lists never changes.  There are three 
  13408. lists maintained for each class. Two lists are for instance data, and one is 
  13409. for member functions. 
  13410.  
  13411. The first list is for public instance data.  The ordering in this list is the 
  13412. declaration order of the public instance data in the class. The corresponding 
  13413. rule that preserves this order and ensures binary upward compatibility is that 
  13414. the declaration order must not change, and that new public data members must be 
  13415. added after all preexisting public members. 
  13416.  
  13417. The second list is for protected and private instance data. This list is 
  13418. ordered and the order preserved in exactly the same manner as for the public 
  13419. instance data list. 
  13420.  
  13421. Adding new public or protected data members only forces you to recompile 
  13422. clients that need to use the new data. 
  13423.  
  13424. Deleting or reordering public data members will break binary compatibility, and 
  13425. require recompilation of all clients and derived classes.  Deleting or 
  13426. reordering protected data members will require recompilation of derived 
  13427. classes, but not of clients since they did not have access to the protected 
  13428. data. 
  13429.  
  13430. The third ordered list is a list of all member functions introduced by the 
  13431. class (both static and nonstatic), plus any static data members in the class. 
  13432.  
  13433. Virtual functions that override virtual functions in base classes do not appear 
  13434. in this list, but do appear in the list belonging to the base class that 
  13435. introduced them.  As a special case of this rule, a class's default 
  13436. constructor, copy constructor, destructor, and default assignment operator are 
  13437. all treated as overrides of virtual functions introduced by SOMObject, and so 
  13438. do not appear in the derived class's list. 
  13439.  
  13440. This third list, called the "release order", is determined in one of two ways. 
  13441. The simpler way is the declaration order of the member functions and static 
  13442. data members, and the resulting compatibility rule is that once again new 
  13443. members must be added after all others in the class declaration. Note that for 
  13444. the purposes of this rule, attributes created using the SOMAttribute pragma 
  13445. behave as though declarations of the _get and _set methods appeared in place of 
  13446. the data declaration. See The SOMAttribute Pragma and set and get Methods for 
  13447. Attribute Class Members for more information. 
  13448.  
  13449. Note also that this third list contains all member functions and static data 
  13450. members, whether their access is public, protected, or private.  This sometimes 
  13451. makes the compatibility rule overly constraining to a class designer, who may 
  13452. prefer to group the member function declarations logically or by access, or 
  13453. even to omit private methods from the class declaration provided to clients of 
  13454. the class. For this reason, VisualAge for C++ provides a pragma that can be 
  13455. used to explicitly specify the release order for a class.  If the 
  13456. SOMReleaseOrder pragma is used for a class, then the declaration order of 
  13457. member functions is no longer significant, and the compatibility rule is 
  13458. changed to require that new members be added at the end of the pragma. 
  13459.  
  13460. // Original Class Definition:
  13461. #pragma SOMAsDefault(on) // define ensuing classes as SOM
  13462. class Bicycle {
  13463.  public:
  13464.    int Model;
  13465.    static int Count;
  13466.    Bicycle(); // defined elsewhere
  13467.    void showBicycle(); // defined elsewhere
  13468. #pragma SOMAttribute(Model,publicdata)
  13469. #pragma SOMReleaseOrder( \
  13470.   Model, \
  13471.   Count,\
  13472.   showBicycle())
  13473. };
  13474. #pragma SOMAsDefault(pop) // resume prior setting of SOMAsDefault
  13475.  
  13476. In the revised version below, new methods and static data members are specified 
  13477. after the existing methods, within the SOMReleaseOrder pragma.  Whether you 
  13478. place the declarations for the new methods and static data members before or 
  13479. after existing ones is not important, as long as you use SOMReleaseOrder to 
  13480. maintain the positions of existing functions in the release order: 
  13481.  
  13482. // Revision:
  13483. #pragma SOMAsDefault(on)
  13484. class Bicycle {
  13485.  public:
  13486.    int Model;
  13487.    static int Count;
  13488.    static int NumberSold;
  13489.    Bicycle();
  13490.    void showBicycle();
  13491.    int sellBicycle(int); // defined elsewhere
  13492. #pragma SOMAttribute(Model,publicdata)
  13493. #pragma SOMReleaseOrder( \
  13494.   Model, \
  13495.   Count, \
  13496.   showBicycle(), \
  13497.   NumberSold, \
  13498.   sellBicycle(int))
  13499. };
  13500. #pragma SOMAsDefault(pop)
  13501.  
  13502. Note that in the example above, it is not necessary to specify the argument 
  13503. type (int) for sellBicycle().  If sellBicycle() were overloaded with multiple 
  13504. argument types (for example, sellBicycle(int) and sellBicycle(int,char*)), you 
  13505. would need to specify both overloads of the function in SOMReleaseOrder. 
  13506.  
  13507. You can use the /Fr (give the release order of a class) option to have the 
  13508. compiler generate a #pragma SOMReleaseOrder for a class.  For further details 
  13509. see The SOMReleaseOrder Pragma. 
  13510.  
  13511.  
  13512. ΓòÉΓòÉΓòÉ 18.4.1.1. Default Release Order Rules ΓòÉΓòÉΓòÉ
  13513.  
  13514. If you do not specify a release order for a class, the compiler orders methods 
  13515. (including the get and set methods of SOM attributes) in the order of their 
  13516. appearance within the class definition. 
  13517.  
  13518. As long as you follow the guidelines given in this section (do not remove any 
  13519. public or protected methods or data members, and do not reorder previously 
  13520. released methods or static data members), you can provide new releases of your 
  13521. library and the programs that use that library will not need to be recompiled. 
  13522. Even if you are providing the library only to C++ programs and do not require 
  13523. SOM's ability to allow cross-language sharing of class and method definitions, 
  13524. this freedom from recompilation gives you more room to make minor adjustments 
  13525. or major enhancements to your library, and it decreases the resistance that 
  13526. those using the library might otherwise have to installing new versions of the 
  13527. library. 
  13528.  
  13529.  
  13530. ΓòÉΓòÉΓòÉ 18.4.2. Version Control for SOM Libraries and Programs ΓòÉΓòÉΓòÉ
  13531.  
  13532. The release order of a class's data members, methods, and static member 
  13533. functions enables SOM client programs to work with new versions of SOM 
  13534. libraries without being recompiled.  This means that a library can be 
  13535. recompiled after client programs have already been compiled and linked to an 
  13536. earlier version of the library.  However, problems can occur if a program is 
  13537. compiled to one version of the library, and then a lower or backlevel version 
  13538. of the library is substituted. SOM implements a form of version control that 
  13539. can detect this situation. 
  13540.  
  13541. The following scenario illustrates how version control works with SOM: 
  13542.  
  13543.    1. A SOM library containing a new version of the Bicycle class is compiled. 
  13544.       The "version" of the class is major version 1, minor version 5 (or, for 
  13545.       simplicity, version 1.5).  This version is assigned within the class 
  13546.       definition, using the SOMClassVersion pragma. 
  13547.  
  13548.    2. A program that uses the SOM library's definition of class Bicycle is then 
  13549.       compiled.  The compiler determines that the version of Bicycle the 
  13550.       program was compiled to is version 1.5.  The program runs successfully 
  13551.       with this version of the library. 
  13552.  
  13553.    3. A new version of the SOM library becomes available, and class Bicycle is 
  13554.       now at version 1.6.  The program that was compiled to version 1.5 still 
  13555.       works, because SOM libraries are upward compatible. 
  13556.  
  13557.    4. The program that uses the Bicycle class is copied to a different system, 
  13558.       and class Bicycle in the SOM library on that system is at version 1.3. 
  13559.  
  13560.    5. When the program using Bicycle is loaded, the SOM runtime determines that 
  13561.       a backlevel version of a Bicycle is being constructed, and it issues a 
  13562.       warning message and ends the program. (If class version control were not 
  13563.       used, the results of this run of the program would be unpredictable.) 
  13564.  
  13565.  SOM verifies that the major version is the same for a client and the objects 
  13566.  it tries to create.  When a SOM class increases its major version number, SOM 
  13567.  assumes that an incompatible change has occurred. 
  13568.  
  13569.  You can use version control to ensure that programs do not experience 
  13570.  unpredictable behavior as a result of using backlevel definitions of classes 
  13571.  when more recent versions of those classes were expected. 
  13572.  
  13573.  Note:  Currently the SOM runtime only tests for a compatible version of a 
  13574.         class the first time an object of that class is instantiated.  This can 
  13575.         lead to problems in programs consisting of multiple compilation units, 
  13576.         in which the uses of an object in one compilation unit expect a 
  13577.         different version from the uses of that object in another compilation 
  13578.         unit. 
  13579.  
  13580.  The following scenario illustrates the problem: 
  13581.  
  13582.    1. A program requests an instance of a SOM class MyClass at version 1 
  13583.       release 3.  The SOM runtime determines that the current version of 
  13584.       MyClass is version 1 release 4, so the object is created successfully. 
  13585.  
  13586.    2. Another compilation unit within the program requests an instance of 
  13587.       MyClass at version 1 release 5 (because that compilation unit was 
  13588.       compiled later than the first compilation unit). The SOM runtime does not 
  13589.       check for version compatibility, because it already did so when the first 
  13590.       MyClass instance was created.  As a result, a program expecting at least 
  13591.       version 1 release 5 of a class is given an object of an earlier (and 
  13592.       possibly incompatible) version of that class. 
  13593.  
  13594.  If you update the version of a SOM class and recompile one of its clients, you 
  13595.  should recompile all the clients of its class to avoid the problem described 
  13596.  above. 
  13597.  
  13598.  
  13599. ΓòÉΓòÉΓòÉ 18.4.3. Recompilation Requirements for SOM Programs ΓòÉΓòÉΓòÉ
  13600.  
  13601. When you make changes to a SOM class, the type of change determines what parts 
  13602. of your program and its client code require recompilation. The following tables 
  13603. show the major types of changes you can make to a SOM class, and what code must 
  13604. be recompiled when you make any such change. 
  13605.  
  13606. Note: 
  13607.  
  13608.    1. Changing the signature or name of a method, or the name of a data member, 
  13609.       or changing the access from private to protected/public or back, is 
  13610.       equivalent to deleting one method or data member and adding another. 
  13611.  
  13612.    2. These tables list the access levels in the first column and the 
  13613.       compilation units that need to be recompiled for adding, changing, and 
  13614.       deleting elements in the second, third, and fourth columns, respectively. 
  13615.       For example, for a private method, the entry under Adding is "Class, 
  13616.       added method". This means that you have to recompile the compilation unit 
  13617.       where the class is defined and, if it is a different compilation unit, 
  13618.       the compilation unit where the new method is defined. 
  13619.  
  13620.    3. Classes that have all member functions declared inline are considered to 
  13621.       be declarations according to the rules of C++. These "declarations" can 
  13622.       appear in several different compilation units.  If you change a member of 
  13623.       such a class, the "class" entry in these tables means that you must 
  13624.       recompile the compilation unit where the SOMBuildClass structures are 
  13625.       created.  See The SOMDefine Pragma for more details. 
  13626.  
  13627.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  13628.   Γöé Table 8. Recompilation Required for Method Changes       Γöé
  13629.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13630.   Γöé ACCESS Γöé ADDING      Γöé CHANGING THE   Γöé DELETING     Γöé
  13631.   Γöé     Γöé          Γöé IMPLEMENTATION  Γöé         Γöé
  13632.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13633.   Γöé privateΓöé Class, added   Γöé Class, changed  Γöé Class      Γöé
  13634.   Γöé     Γöé method      Γöé method      Γöé         Γöé
  13635.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13636.   Γöé pro-  Γöé Class, added   Γöé Class, changed  Γöé Class, friends, Γöé
  13637.   Γöé tected Γöé method      Γöé method      Γöé subclasses    Γöé
  13638.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13639.   Γöé public Γöé Class, added   Γöé Class, changed  Γöé Class, friends, Γöé
  13640.   Γöé     Γöé method      Γöé method      Γöé subclasses, all Γöé
  13641.   Γöé     Γöé          Γöé          Γöé clients that   Γöé
  13642.   Γöé     Γöé          Γöé          Γöé referenced    Γöé
  13643.   Γöé     Γöé          Γöé          Γöé method      Γöé
  13644.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  13645.  
  13646.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  13647.   Γöé Table 9. Recompilation Required for Data Member Changes     Γöé
  13648.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13649.   Γöé ACCESS Γöé ADDING      Γöé CHANGING THE   Γöé DELETING     Γöé
  13650.   Γöé     Γöé          Γöé TYPE       Γöé         Γöé
  13651.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13652.   Γöé privateΓöé Class, methods  Γöé Class, methods  Γöé Class, methods  Γöé
  13653.   Γöé     Γöé using new data,  Γöé using changed   Γöé that used data, Γöé
  13654.   Γöé     Γöé friends      Γöé data, friends   Γöé friends     Γöé
  13655.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13656.   Γöé pro-  Γöé Class, methods  Γöé Class, methods  Γöé Class, methods  Γöé
  13657.   Γöé tected Γöé using new data,  Γöé using changed   Γöé that used data, Γöé
  13658.   Γöé     Γöé friends      Γöé data, all sub-  Γöé all subclasses  Γöé
  13659.   Γöé     Γöé          Γöé classes and    Γöé and friends   Γöé
  13660.   Γöé     Γöé          Γöé friends      Γöé         Γöé
  13661.   Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  13662.   Γöé public Γöé Class, methods  Γöé Class, methods  Γöé Class, friends, Γöé
  13663.   Γöé     Γöé using new data,  Γöé using changed   Γöé subclasses, all Γöé
  13664.   Γöé     Γöé friends      Γöé data, all sub-  Γöé clients that   Γöé
  13665.   Γöé     Γöé          Γöé classes and    Γöé referenced the  Γöé
  13666.   Γöé     Γöé          Γöé friends      Γöé data       Γöé
  13667.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  13668.  
  13669.  Note:  Friends are assumed to have intimate knowledge of the implementation of 
  13670.  a class.  Because this knowledge includes knowledge of private data, friends 
  13671.  are assumed to be created using the same language and compiler as the classes 
  13672.  they are friends of, and they require recompilation whenever the class 
  13673.  requires recompilation. 
  13674.  
  13675.  
  13676. ΓòÉΓòÉΓòÉ 18.5. SOM and Interlanguage Sharing of Objects and Methods ΓòÉΓòÉΓòÉ
  13677.  
  13678. You can share C++ classes with other programming languages either by using the 
  13679. SOMAsDefault pragma for those classes, or by deriving the classes from 
  13680. SOMObject.  In either case, SOM restricts you from using certain C++ coding 
  13681. practices.  These are documented in Differences between SOM and C++. This 
  13682. section outlines some of the issues you have to keep in mind if you want to 
  13683. share SOM objects with other languages. See the SOMObjects Developer Toolkit 
  13684. Publications for more details and for information on accessing SOM classes and 
  13685. methods from different programming languages. For more information on the 
  13686. individual  SOM-related pragmas, see the descriptions in Pragmas for Using SOM. 
  13687.  
  13688.  
  13689. ΓòÉΓòÉΓòÉ 18.5.1. SOM Requires a Default Constructor with No Arguments ΓòÉΓòÉΓòÉ
  13690.  
  13691. One restriction SOM imposes that primarily affects interlanguage sharing of SOM 
  13692. objects, is the requirement that all classes have a default constructor that 
  13693. takes no arguments.  In C++ you can declare a class with no default 
  13694. constructor: 
  13695.  
  13696. class X {
  13697.  public:
  13698.   int Xdata;
  13699.   X(int a) {Xdata=a;};
  13700. };
  13701.  
  13702. When you compile a C++ client program that tries to call a nonexistent default 
  13703. constructor, VisualAge for C++ issues a compile-time error, even when the SOM 
  13704. class the client is using was compiled separately. If you declare an  X with 
  13705. the statement X b;, given the above class definition (regardless of whether or 
  13706. not it is a SOM class), the compiler issues an error. However, if the class is 
  13707. a SOM class, the compiler must anticipate potential calls to a nonexistent 
  13708. default constructor by SOM clients other than those compiled by VisualAge for 
  13709. C++. Rather than generate an arbitrary default constructor (one whose behavior 
  13710. may or may not be the desired behavior for the class), the compiler generates 
  13711. one that results in a runtime error whenever it is called. Note that this 
  13712. behavior makes the class unusable with DSOM, which requires a valid default 
  13713. constructor. 
  13714.  
  13715. In the following example, the defined class does not have a no-argument 
  13716. constructor.  However, it has a constructor that has all default arguments: 
  13717.  
  13718. class X {
  13719.  public:
  13720.   int Xdata;
  13721.   X(int a=3) {Xdata=a;};
  13722. };
  13723.  
  13724. VisualAge for C++ generates two constructors for X if class X is a SOM class: a 
  13725. constructor that takes an integer argument whose value is assigned to Xdata, 
  13726. and a constructor that takes no argument and assigns the value 3 to Xdata. 
  13727.  
  13728. Note that it is possible for client code written in another language to 
  13729. construct an object of a class that does not have a default constructor, 
  13730. provided the client code first calls SOMNewNoInit or SOMRenewNoInit for the 
  13731. object, and then invokes the constructor. 
  13732.  
  13733.  
  13734. ΓòÉΓòÉΓòÉ 18.5.2. Accessing Special Member Functions from Other Languages ΓòÉΓòÉΓòÉ
  13735.  
  13736. In C++ you can define an operator== for a class, then use the == operator to 
  13737. determine whether two objects of the class are equal.  Not all languages 
  13738. support this concept of operator overloading.  In order for programs not 
  13739. written in C++ to be able to access special member functions such as overloaded 
  13740. operators, you must provide names with which these functions can be called from 
  13741. non-C++ programs. The compiler uses these names to generate appropriate IDL 
  13742. definitions for these operators. You can rename class operators using the 
  13743. SOMMethodName pragma. The following class definition provides SOM names through 
  13744. which non-C++ programs can access the operators of the class: 
  13745.  
  13746. #include <som.h>
  13747. class Bicycle:  public SOMObject {
  13748.  public:
  13749.    int model;
  13750.    Bicycle();
  13751.    int operator==(Bicycle& const b) const;
  13752.    int operator <(Bicycle& const b) const;
  13753.    int operator >(Bicycle& const b) const;
  13754.    Bicycle& operator =(Bicycle& const b);
  13755. #pragma SOMMethodName(operator==(),"BicycleEquality")
  13756. #pragma SOMMethodName(operator <(),"BicycleLessThan")
  13757. #pragma SOMMethodName(operator >(),"BicycleGreaterThan")
  13758. #pragma SOMMethodName(operator=(),"BicycleAssign")
  13759. };
  13760.  
  13761. Non-C++ programs can then call these special member functions by referring to 
  13762. their SOM names (BicycleEquality and so on). 
  13763.  
  13764.  
  13765. ΓòÉΓòÉΓòÉ 18.5.3. Assignment Methods ΓòÉΓòÉΓòÉ
  13766.  
  13767. The compiler provides four SOM assignment methods for a SOM class by default, 
  13768. one of which is called when the compiler encounters an assignment operator.  If 
  13769. you define an operator= for a class, the compiler does not generate any 
  13770. assignment methods, in which case calls using the SOM method names will call 
  13771. the appropriate user-defined assignment operator. 
  13772.  
  13773. The SOM assignment methods have the following SOM names and prototypes: 
  13774.  
  13775.   SOMObject *somDefaultAssign(somAssignCtrl *, SOMObject *)
  13776.   SOMObject *somDefaultConstAssign(somAssignCtrl *, SOMObject *)
  13777.   SOMObject *somDefaultVAssign(somAssignCtrl *, SOMObject *)
  13778.   SOMObject *somDefaultConstVAssign(somAssignCtrl *, SOMObject *)
  13779.  
  13780. The somAssignCtrl parameter allows SOM to handle base class assignment to 
  13781. ensure that each base is only assigned once when a base class appears multiple 
  13782. times in an inheritance hierarchy.  A user-defined operator= method does not 
  13783. give you this capability. Therefore, if you code your own assignment method in 
  13784. a class that has multiple parents (not including SOMObject), you should use the 
  13785. SOM assignment methods rather than operator= to ensure correct results. Note 
  13786. that, except when an operator= method is defined, the compiler generates SOM 
  13787. assignment methods for any that are not user-defined. 
  13788.  
  13789. You should place any user-defined assignment methods (operator=) in the release 
  13790. order for the class. You do not need to put compiler-defined assignment methods 
  13791. into the release order unless you want to take their address. Do not put the 
  13792. SOM assignment methods in the release order, because they are introduced in 
  13793. SOMObject. 
  13794.  
  13795. If you want to define a class that can be used by a client either as a C++ 
  13796. class or as a SOM class using the SOM assignment methods, define both the 
  13797. operator= functions and the SOM assignment methods, using conditional 
  13798. compilation to determine which are included in the class definition. 
  13799.  
  13800. All operators you provide for a class, except for the default assignment 
  13801. operator, must be given SOM names using the SOMMethodName pragma, if you want 
  13802. them to be easily callable from non-C++ programs.  Otherwise, their names will 
  13803. be "mangled" by the compiler. This includes the new and delete operators, if 
  13804. you define them at the class level.  You need to specify a SOM name for 
  13805. non-default constructors, because they are overloaded versions of the default 
  13806. constructor. You cannot use SOMMethodName to specify a SOM name for the default 
  13807. constructor or the destructor.  The compiler automatically gives these 
  13808. functions the names somDefaultInit and somDestruct. 
  13809.  
  13810.  
  13811. ΓòÉΓòÉΓòÉ 18.5.3.1. Invoking Constructors from Other Languages ΓòÉΓòÉΓòÉ
  13812.  
  13813. Given a default constructor of the form: 
  13814.  
  13815. ClassName();
  13816.  
  13817. VisualAge for C++ generates a function with the following signature for use by 
  13818. non-C++ programs: 
  13819.  
  13820. void somDefaultInit(this, Environment*, InitVector*);
  13821.  
  13822. The non-C++ program must ensure that the vector pointer and the environment 
  13823. pointer are correctly set or are NULL.  (You should always use a NULL value; 
  13824. the compiler may use a non-NULL value in some cases, but user code that passes 
  13825. a non-NULL value will behave unpredictably.) The presence or absence of the 
  13826. environment pointer is dictated by the callstyle of the class. (See IDL and 
  13827. OIDL Callstyles for further details.) The bindings generated by the SOM 
  13828. compiler normally ensure that the pointers are correctly set or are NULL. 
  13829.  
  13830. Copy constructors have one of the following names generated for them: 
  13831.  
  13832.       somDefaultCopyInit 
  13833.       somDefaultConstCopyInit 
  13834.       somDefaultVCopyInit 
  13835.       somDefaultConstVCopyInit 
  13836.  
  13837.  Other nondefault constructors are given a mangled name unless you supply a SOM 
  13838.  name using the SOMMethodName pragma. 
  13839.  
  13840.  When invoking a nondefault constructor from outside of C++, you should first 
  13841.  create the object using SOMNewNoInit or SOMRenewNoInit, and then invoke the 
  13842.  constructor.  If you use SOMNew or SOMRenew and then invoke the constructor, 
  13843.  you will end up initializing the same object twice. 
  13844.  
  13845.  
  13846. ΓòÉΓòÉΓòÉ 18.5.4. set and get Methods for Attribute Class Members ΓòÉΓòÉΓòÉ
  13847.  
  13848. SOM supports two types of data members: attributes and instance variables. 
  13849. Depending upon the pragma setting, the compiler generates default get and set 
  13850. methods for these attributes if you do not supply your own. If you specify 
  13851. #pragma SOMAttribute(readonly) for an attribute, no set method is generated or 
  13852. definable. An attribute is a nonstatic data member for which you have specified 
  13853. #pragma SOMAttribute. SOM predefines methods to set and get the value of 
  13854. attributes. Attributes have the following properties: 
  13855.  
  13856.      Attributes are the only way of accessing data in classes used in DSOM 
  13857.       applications. 
  13858.  
  13859.      If you fail to declare an attribute and attempt to directly access 
  13860.       instance data in a remote object, you will receive runtime error 20109 
  13861.       from SOM, and a message resembling the following: 
  13862.  
  13863.              somDataResolve error: class <X_Proxy> is abstract with respect to <X>
  13864.  
  13865.      Attributes allow the class implementor to add instrumentation or other 
  13866.       side effects to data access by explicitly defining the _get and _set 
  13867.       methods with the desired function. 
  13868.  
  13869.      You do not need to define methods to set or get the value of an 
  13870.       attribute.  This is done automatically by the compiler.  You can override 
  13871.       these methods where the automatically defined method does not provide the 
  13872.       required functionality. 
  13873.  
  13874.      The names of the set and get methods are consistent and predictable:  for 
  13875.       an attribute j, the methods are _set_j() and _get_j(). (For C++ programs 
  13876.       using the attributes, you can get or set the attributes using the 
  13877.       attribute names rather than the get and set methods.) 
  13878.  
  13879.      You can identify whether the compiler should automatically generate get 
  13880.       or set methods for an attribute, or whether to use a user-defined get or 
  13881.       set method. 
  13882.  
  13883.  Get and set methods have the following signatures for scalars, arrays, and 
  13884.  structs/unions/classes: 
  13885.  
  13886.   // when 'indirect' attribute is not used with SOMAttribute pragma:
  13887.   T _get_var() const;        // scalar var of type T - get
  13888.   void _set_var(T);         // scalar var of type T - set
  13889.  
  13890.   T& _get_var() const;        // scalar var of type T - get, when
  13891.                    // SOMAttribute(...,indirect) is
  13892.                    // specified
  13893.  
  13894.   void _set_var(const T&);      // scalar var of type T - set, when
  13895.                    // SOMAttribute(...,indirect) is
  13896.                    // specified
  13897.  
  13898.   T* _get_var() const;        // arrays of var of type T - get
  13899.   void _set_var(const T*);
  13900.                    // arrays of var of type T - set
  13901.  
  13902.   T _get_var() const;        // structs/unions/classes of type T
  13903.                    // - get
  13904.  
  13905.   void _set_var(const T&);      // structs/unions/classes of type T
  13906.                    // - set
  13907.  
  13908.  Note that pointers are used rather than references, for arrays of T.  This is 
  13909.  done because the interface treats the type as a pointer to the first array 
  13910.  element rather than as a pointer to the entire array. 
  13911.  
  13912.  You do not need to declare the get and set methods for an attribute in your 
  13913.  class declaration, if you choose to have the compiler automatically generate 
  13914.  them for you.  The compiler treats the get and set methods for an attribute as 
  13915.  being declared whether it encounters a declaration or not. The SOMAttribute 
  13916.  pragma determines whether the get and set methods are defined by the compiler, 
  13917.  provided by the programmer, or, in the case of the set method, not provided at 
  13918.  all. If the SOMAttribute is not used, attributes are not created. 
  13919.  
  13920.  See The SOMAttribute Pragma for further information on attributes. 
  13921.  
  13922.  
  13923. ΓòÉΓòÉΓòÉ 18.6. Understanding the Interface Definition Language (IDL) ΓòÉΓòÉΓòÉ
  13924.  
  13925. The Interface Definition Language (IDL) is a facility for defining the 
  13926. interface of SOM classes. IDL provides a CORBA-compliant description of a SOM 
  13927. class. When you compile a SOM-enabled C++ program with VisualAge for C++, the 
  13928. compiler can generate IDL definitions for SOM classes the program defines. If 
  13929. you are writing code in another language and you want to create objects of 
  13930. those SOM classes, you normally use an .idl file to generate a header file for 
  13931. your program so that the SOM classes you use are visible to the compiler in 
  13932. question. The sc translator uses the .idl file to generate the necessary 
  13933. bindings for the other language, and also to load the Interface Repository 
  13934. (IR), which is used by DSOM. 
  13935.  
  13936. If you are creating SOM classes and you anticipate that all users of your 
  13937. classes will be coding only in C++, you do not need to consider the impact of 
  13938. IDL on how you code and on what pragmas you use. However, if there is any 
  13939. likelihood of non-C++ programs using your SOM classes, you need to understand 
  13940. the connections between IDL and VisualAge for C++. 
  13941.  
  13942. If you are writing code to work with an existing SOM interface, you may start 
  13943. out with IDL interfaces. You can use the SOM compiler from the SOMObjects 
  13944. Developer Toolkit to create a C++ .hh file from the IDL definitions. 
  13945.  
  13946. The remainder of this section explains those connections. 
  13947.  
  13948.  
  13949. ΓòÉΓòÉΓòÉ 18.6.1. Generating IDL for C++ SOM Classes ΓòÉΓòÉΓòÉ
  13950.  
  13951. To generate IDL for a C++ SOM class, you should first ensure that the SOM class 
  13952. is declared in a .hh file (as opposed to the usual .h file used for C++ class 
  13953. declarations). This .hh file can be included by C++ source files that use the 
  13954. class, just as .h files can.  When you want to generate the IDL for a class, 
  13955. compile the .hh file itself, rather than the C++ source files that include it. 
  13956. The compiler will produce a .IDL file containing the class IDL definition.  You 
  13957. do not need to specify any SOM-related options for the IDL to be generated. 
  13958.  
  13959. You can use #pragma SOMIDLTypes within your .hh files to group types together. 
  13960. See The SOMIDLTypes Pragma for further details. 
  13961.  
  13962.  
  13963. ΓòÉΓòÉΓòÉ 18.6.2. IDL Types and C++ Types ΓòÉΓòÉΓòÉ
  13964.  
  13965. IDL names for the following built-in C++ types are identical to those types' 
  13966. C++ names: 
  13967.  
  13968.      short, unsigned short, long 
  13969.      float, double 
  13970.      char 
  13971.  
  13972.  The following C++ types are mapped to the IDL types indicated: 
  13973.  
  13974.      signed char is mapped to octet 
  13975.      unsigned char is mapped to char 
  13976.      int is mapped to long 
  13977.      long double is mapped to double 
  13978.      unsigned int is mapped to unsigned long 
  13979.      wchar_t maps to unsigned short 
  13980.      char* maps to string when it is a parameter, otherwise it maps to char* 
  13981.      Enumerated types are mapped to integer constants. 
  13982.      long double (80 bits in size) and long long both map to SOMForeign.. 
  13983.  
  13984.  
  13985. ΓòÉΓòÉΓòÉ 18.6.3. IDL Names and C++ SOM Pragmas ΓòÉΓòÉΓòÉ
  13986.  
  13987. If you do not use any of the SOM pragmas SOMMethodName, SOMClassName, or 
  13988. SOMNoMangling, the names of SOM class methods and class templates are mangled 
  13989. by VisualAge for C++. These mangled names are the names that appear in the 
  13990. program's .idl file, and these names are likely to be long and difficult to 
  13991. understand. Although you can access SOM classes and their methods using these 
  13992. mangled names, this practice is error-prone and unnecessarily complicated.  You 
  13993. can use the above pragmas to make the SOM names for your classes more 
  13994. understandable. 
  13995.  
  13996. IDL requires that class and method names be distinct and case-insensitive. 
  13997. VisualAge for C++ normally ensures this by mangling class and method names. 
  13998. Mangling encodes case differences, and also reflects argument types of 
  13999. overloaded methods in their SOM names. 
  14000.  
  14001. If you use the SOMClassName pragma to attach a SOM name to a class, make sure 
  14002. that the name you select is unique without regard to case.  If you use the 
  14003. SOMNoMangling pragma for a class or a range of classes, method names in those 
  14004. classes are not mangled, which creates conflicts between any names that differ 
  14005. only in case, and between different overloads of functions. You can use the 
  14006. SOMMethodName pragma to correct this situation, by associating SOM names with 
  14007. individual methods. 
  14008.  
  14009.      IDL matches methods by their names only.  It does not support method 
  14010.       overloading.  This means that you must differentiate overloaded methods 
  14011.       of a class by using the SOMMethodName pragma on overloaded methods. 
  14012.  
  14013.      IDL is case-insensitive.  If you define a C++ method print to print an 
  14014.       object, and a C++ method of the same class called prInt to print an 
  14015.       integer data member of that object, their IDL names will be the same if 
  14016.       you use the SOMNoMangling pragma, unless you rename one of the methods 
  14017.       using the SOMMethodName pragma. 
  14018.  
  14019.      If you use the SOMNoMangling pragma for a class or a range of classes, 
  14020.       method names in those classes are not mangled. This can result in 
  14021.       multiple overloaded functions mapping to the same name.  The compiler 
  14022.       detects such conflicts and issues an error message.  You can use 
  14023.       SOMMethodName to resolve these conflicts. 
  14024.  
  14025.      Changing the IDL name of a method can break binary compatibility because 
  14026.       IDL matches methods by name only. 
  14027.  
  14028.  
  14029. ΓòÉΓòÉΓòÉ 18.6.4. IDL and OIDL Callstyles ΓòÉΓòÉΓòÉ
  14030.  
  14031. The Common Object Request Broker Architecture (CORBA) defines an implied second 
  14032. parameter of type Environment* for SOM methods and static member functions. 
  14033. This parameter can be used to pass extra information between SOM methods and 
  14034. clients, such as exception information indicating that a SOM method could not 
  14035. be called. In initial releases, SOM did not support this second parameter. 
  14036. This can result in compatibility problems because new code may have the extra 
  14037. parameter while old code, including such classes as SOMObject and SOMClass, may 
  14038. not.  The presence or absence of this second parameter in a class method or 
  14039. static member function is referred to as the method or function's callstyle. 
  14040. The new callstyle with the Environment* parameter is referred to as the IDL 
  14041. callstyle, while the old callstyle without that parameter is referred to as the 
  14042. OIDL callstyle (for "Old IDL"). 
  14043.  
  14044. To preserve binary compatibility with old SOM application code, SOM now 
  14045. supports both callstyles.  This leads to a model where some methods in a 
  14046. program may expect environment pointers, while others may not. 
  14047.  
  14048. The callstyle is determined on a class-by-class basis.  For a given class, 
  14049. either all methods introduced by that class will expect an environment 
  14050. parameter, or none will. 
  14051.  
  14052. Note:  The callstyle of an inherited method is the callstyle of the class in 
  14053. which the method is defined, not the callstyle of the inheriting class. 
  14054.  
  14055. You can specify the callstyle for a class using the SOMCallStyle pragma.  By 
  14056. default, all classes will have the IDL callstyle. 
  14057.  
  14058.  
  14059. ΓòÉΓòÉΓòÉ 18.6.4.1. Callstyles and Pointer-to-Member ΓòÉΓòÉΓòÉ
  14060.  
  14061. You cannot assign the address of an IDL-callstyle method to a pointer to an 
  14062. OIDL-callstyle method, or vice versa.  Whether a pointer to member is an IDL- 
  14063. or OIDL-callstyle pointer depends on the class the pointer to member is 
  14064. declared in.  If the declaring class uses IDL callstyle, the pointer to member 
  14065. can only point to IDL-callstyle methods; otherwise it can only point to 
  14066. OIDL-callstyle methods. Note that conflicts between callstyles are unlikely to 
  14067. occur, because IDL is the default callstyle. 
  14068.  
  14069.  
  14070. ΓòÉΓòÉΓòÉ 18.6.5. The Environment pointer ΓòÉΓòÉΓòÉ
  14071.  
  14072. Methods with callstyle IDL receive an extra parameter called the Environment 
  14073. pointer. This parameter is defined by CORBA, and is intended to communicate 
  14074. exceptional return codes from the method to its caller. Since most SOM users 
  14075. don't make use of the Environment parameter, Direct-to-SOM implements it in a 
  14076. way that allows you to ignore it, but also permits you to get access to it and 
  14077. manipulate it when you need to. 
  14078.  
  14079. Every call to an IDL callstyle method is modified by the compiler to add an 
  14080. extra parameter called  "__SOMEnv". This name is looked up using the usual 
  14081. scoping rules, so if you write: 
  14082.  
  14083.     void myfunc(Obj *p)
  14084.     {
  14085.       Environment *__SOMEnv = SOM_CreateLocalEnvironment();
  14086.  
  14087.       p->DoSomething();
  14088.  
  14089.       SOM_DestroyLocalEnvironment(__SOMEnv);
  14090.     }
  14091.  
  14092. and DoSomething is an IDL callstyle method, it will be passed the __SOMEnv 
  14093. defined in the local scope. 
  14094.  
  14095. DTS also adds __SOMEnv to the formal parameter list of defined IDL callstyle 
  14096. methods, so the Environment parameter passed from the caller is available 
  14097. within the method. This also implies that, if you don't define your own 
  14098. __SOMEnv inside the method, DTS will by default pass  on the received 
  14099. Environment to any IDL style methods called. 
  14100.  
  14101. DTS also defines a global __SOMEnv, which will be passed to any methods called 
  14102. from within procedures or OIDL style methods, unless it is hidden by one you 
  14103. define yourself. 
  14104.  
  14105.  
  14106. ΓòÉΓòÉΓòÉ 18.6.6. C++ Limitations to IDL ΓòÉΓòÉΓòÉ
  14107.  
  14108. When IDL is generated for a C++ class, the bodies of inline functions are not 
  14109. emitted in the IDL.  As a result, if you later translate the IDL file back to a 
  14110. C++ header file, inline function definitions become function declarations with 
  14111. no function body. 
  14112.  
  14113. VisualAge for C++ does not support inlining of C++ member functions when IDL is 
  14114. generated, and all member functions of SOM classes are called out-of-line. 
  14115. Because inlining may be supported in the future, you should consider the bodies 
  14116. of public inline functions to be a part of the public interface of a class if 
  14117. you are concerned about upward binary compatibility of your classes. 
  14118.  
  14119. IDL supports only declarations, not definitions.  For example, static data 
  14120. member definitions are not emitted in the IDL.  You should define static data 
  14121. members in the class implementation instead. 
  14122.  
  14123.  
  14124. ΓòÉΓòÉΓòÉ 18.7. Differences between SOM and C++ ΓòÉΓòÉΓòÉ
  14125.  
  14126. SOM imposes a slightly different view of object orientation on its classes than 
  14127. does C++.  This section describes differences between the object-oriented 
  14128. features of C++ and those supported by SOM. The following topics are discussed: 
  14129.  
  14130.      Initializer lists 
  14131.      Function overloading 
  14132.      Data member offsets 
  14133.      Casting to pointer-to-SOM-object 
  14134.      Down-casting Pointers to Virtual Base Classes 
  14135.      Multiple inheritance of a base class 
  14136.      Local classes 
  14137.      Abstract classes 
  14138.      Metaclasses 
  14139.      sizeof 
  14140.      Instance data 
  14141.      Templates 
  14142.      Memory management 
  14143.      Data members implemented as attributes 
  14144.  
  14145.  
  14146. ΓòÉΓòÉΓòÉ 18.7.1. Initializer Lists and Constructors ΓòÉΓòÉΓòÉ
  14147.  
  14148. You cannot use an initializer list to initialize an object of a SOM class, 
  14149. because all SOM classes have constructors, and C++ language rules do not allow 
  14150. classes with constructors to be initialized in this way. 
  14151.  
  14152.  
  14153. ΓòÉΓòÉΓòÉ 18.7.2. Function Overloading ΓòÉΓòÉΓòÉ
  14154.  
  14155. C++ lets you define multiple methods within a class that have the same name, 
  14156. but different combinations of arguments.  These arguments are collectively 
  14157. known as a method's signature, and a class that defines multiple instances of a 
  14158. method with different signatures is said to overload that method.  A class can 
  14159. overload static member functions as well as methods. 
  14160.  
  14161. SOM does not support the C++ concept of function overloading, either for 
  14162. methods or for static member functions.  By default VisualAge for C++ generates 
  14163. mangled names for all overloaded functions so that different overloads can be 
  14164. distinguished. If both your SOM classes and the programs that use them are 
  14165. coded in C++, you can easily overload functions because the compiler uses this 
  14166. consistent name-mangling scheme to resolve overloaded calls.  However, if you 
  14167. plan to make your SOM classes accessible to programs written in languages other 
  14168. than C++, you should not rely on C++ name mangling, because the mangled names 
  14169. are often difficult to understand. Instead, you should provide SOM with a 
  14170. function name to call for each signature of an overloaded function.  You do 
  14171. this using the SOMMethodName pragma. The following example shows three 
  14172. declarations of method add() for a class, and three SOMMethodName pragmas that 
  14173. make all three methods clearly accessible to SOM programs written in other 
  14174. languages: 
  14175.  
  14176. class Bicycle : public SOMObject {
  14177.  public:
  14178.    // ...
  14179.    void add(Bicycle& const);
  14180.    void add(int);
  14181.    void add();
  14182. #pragma SOMMethodName(add(Bicycle& const),"AddBike")
  14183. #pragma SOMMethodName(add(int),"AddInt")
  14184. #pragma SOMMethodName(add(),"AddVoid")
  14185. };
  14186.  
  14187. You could avoid the above SOMMethodName pragmas by relying on the C++ mangling 
  14188. scheme, but this would make client code more difficult to write or maintain. 
  14189. For example, the following function in C++: 
  14190.  
  14191. x::operator=(const volatile x);
  14192.  
  14193. is mangled to the following: 
  14194.  
  14195. dts____as__frxzvx
  14196.  
  14197. For classes in which the SOMNoMangling pragma is in effect, you must use the 
  14198. SOMMethodName pragma for all but one of the overloaded versions of a given 
  14199. method or static function.  For the sake of code clarity you should use the 
  14200. SOMMethodName pragma to rename all signatures of a function that is overloaded. 
  14201.  
  14202.  
  14203. ΓòÉΓòÉΓòÉ 18.7.3. Calling Methods Through a NULL Pointer ΓòÉΓòÉΓòÉ
  14204.  
  14205. Some implementations of C++ allow you to call nonvirtual functions through a 
  14206. NULL pointer.  You cannot do this in SOM-enabled C++ programs.  If you call a 
  14207. nonvirtual function through a NULL pointer in a SOM-enabled C++ program, the 
  14208. program may compile successfully but it will not run correctly.  For example, 
  14209. the call to the virtual function vf() below causes a trap in both native C++ 
  14210. and SOM-enabled C++, while the call to the nonvirtual function nvf() causes a 
  14211. trap only in SOM-enabled C++: 
  14212.  
  14213.   class A {
  14214.    public:
  14215.      void nvf();
  14216.      virtual void vf();
  14217.   } *a = NULL;
  14218.  
  14219.   void hoo(){
  14220.     a->nvf();   // OK in C++, traps in DTS C++
  14221.     a->vf();   // Traps in both because virtual.
  14222.   }
  14223.  
  14224.  
  14225. ΓòÉΓòÉΓòÉ 18.7.4. Data Member Offsets ΓòÉΓòÉΓòÉ
  14226.  
  14227. C++ lets you determine the offset of data members into an object.  An 
  14228. expression such as: 
  14229.  
  14230.   int ((char*)&Instance.Member - (char*)&Instance);
  14231.  
  14232. can be used in C++ to determine how far into an instance Instance the member 
  14233. Member is located. This syntax is also supported in SOM.  However, the result 
  14234. of the expression may not be identical for subclasses.  Given: 
  14235.  
  14236.  class Base : public SOMObject { public: int i; } B;
  14237.  class Derived : public Base { /* ... */ } D;
  14238.  #define MyOffset(Obj,Member) int((char*)&Obj.Member - (char*)&Obj)
  14239.  
  14240. the equality MyOffset(B,i) == MyOffset(D,i) may or may not hold, depending on 
  14241. how SOM determines the data reordering scheme for each class. 
  14242.  
  14243. The offsets of data members into an object are contiguous within each 
  14244. access-specifier (public, protected or private), and are assigned to each block 
  14245. in the order of declaration. 
  14246.  
  14247.  
  14248. ΓòÉΓòÉΓòÉ 18.7.5. Casting to Pointer-to-SOM-Object ΓòÉΓòÉΓòÉ
  14249.  
  14250. The structure of SOM objects requires that the memory layout of the instance 
  14251. begin with a pointer to an appropriate method table. This differs from normal 
  14252. C++ objects in which no such pointer is allocated unless the class has virtual 
  14253. functions.  The result of this difference is that it is not generally possible 
  14254. to treat arbitrary storage as a SOM object. In particular, casting 0 to a 
  14255. pointer to a SOM object is not recommended. You can get unexpected results when 
  14256. a SOM pointer is cast to a non-SOM pointer. See Determining which new and 
  14257. delete Operators Are Used for an example of such unexpected results. 
  14258.  
  14259.  
  14260. ΓòÉΓòÉΓòÉ 18.7.6. Down-casting Pointers to Virtual Base Classes ΓòÉΓòÉΓòÉ
  14261.  
  14262. Pointers to a virtual base can be explicitly cast to a derived base.  This is 
  14263. allowed in both native C++ and SOM-enabled C++ but the mechanisms are 
  14264. different. The following example illustrates this difference between native and 
  14265. SOM-enabled C++: 
  14266.  
  14267.   #include <som.h>
  14268.  
  14269.   struct vbstruct : public virtual SOMObject {
  14270.   #pragma SOMDefine(*)
  14271.   };
  14272.  
  14273.   void main() {
  14274.     SOMObject *p = new vbstruct; // always legal
  14275.     vbstruct *q;
  14276.     q = (vbstruct *) p;      // legal for SOM, not for non-SOM
  14277.     q = dynamic_cast<vbstruct *>(p); // legal for SOM and non-SOM
  14278.     q = p;            // always illegal (need a cast)
  14279.   }
  14280.  
  14281.  
  14282. ΓòÉΓòÉΓòÉ 18.7.7. Multiple Inheritance of a Base Class ΓòÉΓòÉΓòÉ
  14283.  
  14284. SOM does not implement multiple occurrences of the same nonvirtual base.  For 
  14285. example: 
  14286.  
  14287. #ifdef __SOM_ENABLED__
  14288. class A : public SOMObject { /* ... */ };
  14289. #else
  14290. class A { /* ... */ };
  14291. #endif
  14292. class B : public A { /* ... */ };
  14293. class C : public A { /* ... */ };
  14294. class MyClass : public B, C { /* ... */ };
  14295.  
  14296. The compiler issues an error for the definition of class MyClass if class A is 
  14297. a SOM class. If class A is not a SOM class, the program compiles without an 
  14298. error. 
  14299.  
  14300. Note:  The compiler cannot warn you about multiple inheritance errors in SOM 
  14301.        programs when different classes in an inheritance graph are separately 
  14302.        changed and recompiled.  In the following example, assume that each 
  14303.        struct is declared in a separate file and compiled on its own: 
  14304.  
  14305.                 struct s   {};
  14306.                 struct a:s  {}; // based on s
  14307.                 struct b   {};
  14308.                 struct d:a,b {}; // based on a, b, and s
  14309.  
  14310. If the file containing struct b is changed to: 
  14311.  
  14312.   struct b:s  {}; // based on s
  14313.  
  14314. and recompiled individually, the compiler will not warn you of the error, and 
  14315. programs using struct d may behave unpredictably. 
  14316.  
  14317.  
  14318. ΓòÉΓòÉΓòÉ 18.7.8. Local Classes ΓòÉΓòÉΓòÉ
  14319.  
  14320. Local, non-file-scope classes may not be SOM classes. However, a local, 
  14321. non-file-scope class may have a nested class that is a SOM class. In the 
  14322. following example the declaration of class CantBeFromSOM causes a compiler 
  14323. error because it only has the scope of main: 
  14324.  
  14325. class IsFromSOM: SOMObject { /* ... */ };
  14326. void main() {
  14327.   class IsntFromSOM { /* ... */ };
  14328.   class CantBeFromSOM: SOMObject { /* ... */ };
  14329.   }
  14330.  
  14331.  
  14332. ΓòÉΓòÉΓòÉ 18.7.9. Abstract Classes ΓòÉΓòÉΓòÉ
  14333.  
  14334. An abstract class is a class with one or more pure virtual functions.  Abstract 
  14335. C++/SOM classes are supported. If the abstract class does not define a default 
  14336. constructor, VisualAge for C++ prevents calls to the constructor from other C++ 
  14337. programs. The IDL generated by VisualAge for C++ also prevents calls to a 
  14338. nonexistent abstract class constructor from programs written in other 
  14339. languages. 
  14340.  
  14341. As usual with C++, you can provide your own method bodies for pure virtual 
  14342. member functions.  If you do this the method bodies must be provided in the 
  14343. same file as the definition of the first member that is not inline, or in the 
  14344. same file as a SOMDefine directive. 
  14345.  
  14346.  
  14347. ΓòÉΓòÉΓòÉ 18.7.10. Classes as Objects ΓòÉΓòÉΓòÉ
  14348.  
  14349. In native C++, a class is a syntactic entity that exists only at compile time; 
  14350. it has no representation outside of the source code that defines it.  A C++ 
  14351. class cannot be an object, and a C++ object cannot be a class.  The strict 
  14352. distinction between classes and objects does not hold for SOM.  A SOM class 
  14353. always exists at runtime, and is itself a SOM object. 
  14354.  
  14355. Because SOM classes are runtime objects, they can provide a number of services 
  14356. to client objects.  For example, a SOM class can respond to specific inquiries 
  14357. regarding the interface of its instances; each SOM class includes a method 
  14358. named somSupportsMethod, which when invoked with any string returns a Boolean 
  14359. value indicating whether the string represents a method supported by instances 
  14360. of the class. SOM class objects can also provide information to clients such as 
  14361. its name, the names of its base classes, the size of its instances, the number 
  14362. of methods it supports, and whether a provided SOM object is an instance of the 
  14363. class. 
  14364.  
  14365. The SOMObjects Toolkit documentation describes a method for extracting the 
  14366. class object of a class, where an object of that class already exists.  For 
  14367. example, you can call obj->somGetClass(), to extract the class object for 
  14368. object obj. 
  14369.  
  14370. Where you need to name the class object but you do not have an instance of it, 
  14371. the Toolkit allows you to code the class name, preceded by an underscore.  For 
  14372. example: 
  14373.  
  14374.   SOMObject* anotherObj;
  14375.   anotherObj->somIsInstanceOf(_Foo); // toolkit syntax
  14376.  
  14377. This syntax is not supported with DTS classes, because it imposes on the user's 
  14378. identifier space as defined by ANSI.  Instead, VisualAge for C++ introduces a 
  14379. static member to each class it converts to a SOM class: 
  14380.  
  14381. SOMClass * const __ClassObject
  14382.  
  14383. This static member cannot be added to the release order for the class. You can 
  14384. use the following syntax in place of the toolkit syntax shown above, for DTS 
  14385. classes: 
  14386.  
  14387.   anotherObj->somIsInstanceOf(Foo::__ClassObject);
  14388.  
  14389. Although you can refer to this member as className::__ClassObject from within a 
  14390. C++ program, it is not a "real" data member in that it does not exist in 
  14391. memory.  The compiler resolves references to this member to a pointer to the 
  14392. class object for className. 
  14393.  
  14394.  
  14395. ΓòÉΓòÉΓòÉ 18.7.11. Metaclasses ΓòÉΓòÉΓòÉ
  14396.  
  14397. A SOM class is also an instance of a class, because all SOM classes are 
  14398. objects.  A class whose instances are other classes is called a metaclass.  A 
  14399. metaclass definition specifies the interface of a class, just as a class 
  14400. definition specifies the interface of an object. The SOM metaclass has no 
  14401. conceptual equivalent in C++.  The SOM metaclass exists at runtime, is capable 
  14402. of providing specific services to client code, and may be used as a parent of 
  14403. other metaclasses. For more details on the concept of metaclasses, see the 
  14404. online SOM Programming Guide. 
  14405.  
  14406. When you create a class in SOM, the appropriate metaclass is created 
  14407. automatically if you do not specify one. You can also explicitly create your 
  14408. own metaclasses. You can create a metaclass by deriving from SOMClass, so that 
  14409. your metaclass can perform functions such as keeping track of what SOM classes 
  14410. have been constructed in a program.  (A SOMClass object is constructed for 
  14411. every SOM class used by a program, the first time an object of that class is 
  14412. constructed.)  To create a metaclass, follow these steps: 
  14413.  
  14414.    1. Derive a new class from SOMClass, which is declared in som.h. 
  14415.    2. Associate this new class with the instance class via the SOMMetaClass 
  14416.       pragma. 
  14417.  
  14418.  For example: 
  14419.  
  14420.   #include <som.h>
  14421.  
  14422.   class MyMeta : public SOMClass { /* ... */ };
  14423.   class MyClass : public SOMObject {
  14424.     // ...
  14425.     #pragma SOMMetaClass(*,MyMeta)
  14426.   };
  14427.  
  14428.  Note:  The compiler does not distinguish between metaclasses and other 
  14429.  classes.  For SOM to function correctly, you should derive all metaclasses 
  14430.  from SOMClass. 
  14431.  
  14432.  
  14433. ΓòÉΓòÉΓòÉ 18.7.12. offsetof macro ΓòÉΓòÉΓòÉ
  14434.  
  14435. The offsetof macro does not work as well with SOM classes as it does with 
  14436. regular C++ classes. Its value is determined at runtime, as the relative 
  14437. positioning of the data "blocks" introduced by each base are not known until 
  14438. then. This means that offsetof is not a reliable way to determine the position 
  14439. of a member within a subclass. The value of the offsetof macro for a member of 
  14440. a base cannot be assumed to be correct for subclasses of that base. 
  14441.  
  14442.  
  14443. ΓòÉΓòÉΓòÉ 18.7.13. sizeof operator ΓòÉΓòÉΓòÉ
  14444.  
  14445. The sizeof operator works differently for SOM objects than for non-SOM objects. 
  14446. The sizeof operator indicates the size in bytes of the object it is applied to. 
  14447. For non-SOM objects, this size is determined at compile time, and can therefore 
  14448. be used in expressions evaluated at compile time. For SOM objects, sizeof 
  14449. returns a value that is determined at runtime. This means that you cannot apply 
  14450. the sizeof operator to SOM objects in situations where the value must be 
  14451. determinable at compile time, such as array bounds (for static initializers), 
  14452. case expressions, bit field lengths, and enumerator initializers. For example, 
  14453. the following uses of sizeof will cause compilation errors: 
  14454.  
  14455. class MyClass {
  14456.   public:
  14457.    int i:sizeof(Buffer);
  14458. };
  14459. enum { E = sizeof(MyClass) } x;
  14460. try  Buffer myBuffer[sizeof(Buffer)]; // Buffer is a SOM class
  14461. switch(/* ... */) {
  14462.   case sizeof(Buffer): break;
  14463. }
  14464.  
  14465.  
  14466. ΓòÉΓòÉΓòÉ 18.7.14. Instance Data ΓòÉΓòÉΓòÉ
  14467.  
  14468. SOM supports both static data members and arrays. An array of SOM objects is 
  14469. represented as a pointer to an array of SOM object instances. 
  14470.  
  14471.  
  14472. ΓòÉΓòÉΓòÉ 18.7.15. Templates ΓòÉΓòÉΓòÉ
  14473.  
  14474. You instantiate a template class as with native C++. If you want to avoid 
  14475. compiler mangling of template names, you should also supply a SOM name for any 
  14476. instantiation of a template class. For example: 
  14477.  
  14478. typedef Stack<int> IntStack;
  14479. #pragma SOMClassName(Stack<int>, "IntStack")
  14480. IntStack MyIntStack;
  14481.  
  14482. This declares an object MyIntStack of type Stack<int>.  This could also be 
  14483. coded as: 
  14484.  
  14485. Stack<int> MyIntStack;
  14486. #pragma SOMClassName(Stack<int>, "IntStack")
  14487.  
  14488. You can achieve the same effect by coding: 
  14489.  
  14490. #pragma define(Stack<int>) // instantiates class Stack<int> from template
  14491. #pragma SOMClassName(Stack<int>, "IntStack")
  14492.  
  14493. Note that the first argument of the SOMClassName pragma (the class to be 
  14494. renamed) must be the template class with its type argument, rather than the 
  14495. typedef. 
  14496.  
  14497. If you plan to make a template class accessible to non-C++ programs, you must 
  14498. define an implementation of the template class for each type that will be 
  14499. requested by those programs. You can do this either with the SOMDefine pragma, 
  14500. or by instantiating the template within the C++ program. For example: 
  14501.  
  14502. typedef Stack<int>   IntStack;   // assume Stack is a SOM class
  14503. typedef Stack<double> DoubleStack; // template
  14504. typedef Stack<char>  CharStack;
  14505. typedef Stack<float>  FloatStack;
  14506. // ...
  14507. IntStack i;             // makes IntStack available
  14508.                   // to non-C++ programs
  14509. #pragma SOMDefine(Stack<double>)  // makes DoubleStack available
  14510. #pragma SOMDefine(CharStack)    // makes CharStack available
  14511.                   // FloatStack is not available
  14512.  
  14513. You should then use the SOMClassName pragma to provide SOM names to the 
  14514. template instantiations, so that the compiler does not generate mangled names 
  14515. for those instantiations. 
  14516.  
  14517. When using templates to implement SOM classes, do not include information 
  14518. dependent upon the instantiation type within the class description.  For 
  14519. example, the following code produces a runtime error because the SOMAttribute 
  14520. pragma is processed for both implementations, and each one is incorrect for the 
  14521. other implementation: 
  14522.  
  14523. #include <som.hh>
  14524.  
  14525. template <class T, int S = 5>      // default arg value
  14526. class D : public SOMObject {
  14527.  public:
  14528.    T Velocity;
  14529.  #pragma SOMAttribute(D<int>::Velocity, readonly)
  14530.  #pragma SOMAttribute(D<int, 9>::Velocity, readonly)
  14531. };
  14532.  
  14533. #pragma define(D<int>)
  14534. #pragma define(D<int, 9>)
  14535.  
  14536. Instead, use a single SOMAttribute pragma for each attribute within a template 
  14537. class.  For the above example, the pragma would appear as: 
  14538.  
  14539.   #pragma SOMAttribute(Velocity, readonly)
  14540.  
  14541. In cases within the class description where a class name is expected, such as 
  14542. the SOMNoMangling or SOMNoDataDirect pragmas, you should use an asterisk (*) 
  14543. for the class name. 
  14544.  
  14545.  
  14546. ΓòÉΓòÉΓòÉ 18.7.15.1. Methods of Template Classes ΓòÉΓòÉΓòÉ
  14547.  
  14548. Methods of a template can be renamed using the SOMMethodName pragma. You do not 
  14549. need to rename template methods, but if you plan to make your SOM classes 
  14550. available to non-C++ programs, you can make the interface to your classes 
  14551. simpler by renaming methods.  If you do not rename template methods, the 
  14552. compiler mangles their names, and the mangled names are difficult to remember 
  14553. and are likely to lead to typographical errors. 
  14554.  
  14555. You should use the SOMMethodName pragma to rename the methods of a template 
  14556. class for each type you plan to instantiate the template with from a non-C++ 
  14557. program. For example, if you define a template class: 
  14558.  
  14559. template class <T> class MyTemplate {
  14560.   public:
  14561.    T dataMember;
  14562.    void Push(T item);
  14563.   };
  14564.  
  14565. and you anticipate your template being used with types int and double, you 
  14566. should add pragmas such as the following to the C++ program: 
  14567.  
  14568. #pragma SOMMethodName(MyTemplate<int>::Push(int),"PushInt")
  14569. #pragma SOMMethodName(MyTemplate<double>::Push(double),"PushDouble")
  14570.  
  14571.  
  14572. ΓòÉΓòÉΓòÉ 18.7.16. Memory Management ΓòÉΓòÉΓòÉ
  14573.  
  14574. This section describes how memory is allocated to SOM objects, and tells you 
  14575. how to use the new and delete  operators for memory allocation. 
  14576.  
  14577.  
  14578. ΓòÉΓòÉΓòÉ 18.7.16.1. Heap and Stack Memory Allocation ΓòÉΓòÉΓòÉ
  14579.  
  14580. C++ programs can store objects in two different areas of memory, known as the 
  14581. stack and the heap.  The stack and the heap are implemented by software. They 
  14582. are distinguished by the fact that objects stored on the stack are 
  14583. automatically deleted when the function or block within which they were created 
  14584. passes out of scope, while objects stored on the heap must be explicitly 
  14585. deleted. 
  14586.  
  14587. Objects allocated with the new operator are placed on the heap, including SOM 
  14588. objects. Automatic objects are usually allocated in the current stack frame. 
  14589. SOM objects that are declared as having automatic duration, rather than as 
  14590. pointers to objects, are usually allocated on the current stack frame. As with 
  14591. normal C++, the new operator is not called for automatic duration operators. 
  14592.  
  14593.  
  14594. ΓòÉΓòÉΓòÉ 18.7.16.2. Overloading the new and delete Operators ΓòÉΓòÉΓòÉ
  14595.  
  14596. You can overload the new and delete operators either on a class-specific basis 
  14597. or globally.  Because most programs will contain a mixture of SOM and non-SOM 
  14598. objects, the compiler provides two different paths for memory allocation and 
  14599. deallocation using new and delete, one for SOM objects and one for non-SOM 
  14600. objects. 
  14601.  
  14602. You can have multiple, distinguished versions of operator new within a class. 
  14603. The operator delete is restricted to one version per class. 
  14604.  
  14605. SOM accepts an additional parameter to an operator new for a SOM class, which 
  14606. points to the class's class object.  An operator new for a SOM class has one of 
  14607. the following forms: 
  14608.  
  14609.   void *operator new (size_t InstanceSize);
  14610.   void *operator new (SOMClass* ObjClass, size_t InstanceSize);
  14611.  
  14612. The SOM version of the global operator new has the form: 
  14613.  
  14614.   void *operator ::new (SOMClass* ObjClass, size_t InstanceSize);
  14615.  
  14616. You can use the SOMClass* parameter, in both class and global definitions of 
  14617. operator new, to have a pointer to the object's class object passed to the 
  14618. operator. For any class that is a SOM class, the compiler passes this parameter 
  14619. whether you specify it in the operator's declaration or not. You do not specify 
  14620. this argument when invoking new, so there is no way for a call to new to 
  14621. specify its own value for the SOMClass* argument. 
  14622.  
  14623. You cannot have both types of operator new within a class.  You can have both 
  14624. types of global operator new. Note that even if you use placement arguments in 
  14625. an operator new, the SOMClass argument is always the first argument. 
  14626.  
  14627. The SOMClass* argument appears first because this allows the compiler to 
  14628. differentiate between a SOM operator new and a non-SOM operator new that takes 
  14629. a SOMClass* as an argument.  You can use the SOMClass* argument, for example, 
  14630. to print the class name, by calling thisClass->somGetName() where thisClass is 
  14631. a pointer to a SOM class. 
  14632.  
  14633. The delete operator for SOM classes has the same form as for other C++ classes. 
  14634. For a given class, you can have at most one of the following forms of operator 
  14635. delete: 
  14636.  
  14637.   void operator delete(void*);
  14638.   void operator delete(void*, size_t);
  14639.   void operator delete(SOMObject*, size_t);
  14640.  
  14641. For the sake of easily maintained code, you should always include the size_t 
  14642. argument, whether you use it or not, because it allows you to later change to 
  14643. an implementation that does use the argument, without requiring client programs 
  14644. to be recompiled. 
  14645.  
  14646. The first argument is a pointer to the object instance being deleted. Because 
  14647. of the way that SOM uninitializes an instance, the first word of the object 
  14648. still points to the object's method table, which in turn points to the class 
  14649. object.  This gives you access to information about the specific class being 
  14650. deleted. 
  14651.  
  14652. You can also code a SOM version of the global delete operator, of the form: 
  14653.  
  14654.   void operator ::delete(SOMObject*, size_t);
  14655.  
  14656. The type of the first argument is SOMObject to distinguish the function 
  14657. signature from the non-SOM global delete operator.  Note that the compiler 
  14658. recognizes such a replacement based on the exact signature.  You must include 
  14659. both arguments in the declaration. 
  14660.  
  14661. By default, this function calls SOMFree to deallocate the SOM object's storage. 
  14662.  
  14663. The following example shows how you can define new and delete operators for a 
  14664. SOM class.  In the example, the new operator increments a counter each time it 
  14665. is called, and then calls the global new operator to allocate storage for the 
  14666. object.  The delete operator decrements the same counter, and then calls the 
  14667. global delete operator to deallocate the storage.  The counter is a static 
  14668. class member that can be accessed to determine how many objects of the class 
  14669. currently have storage allocated to them by new. 
  14670.  
  14671.   #include <som.hh>
  14672.   class A : public SOMObject {
  14673.    public:  void* operator new(SOMClass*, size_t);
  14674.        void  operator delete(SOMObject*);
  14675.  
  14676.        static int howMany; // # of dynamically alloc instances
  14677.   };
  14678.  
  14679.   int A::howMany;
  14680.  
  14681.   void* A::operator new(SOMClass *cls, size_t sz)
  14682.   {
  14683.     howMany++;
  14684.     return ::operator new(cls, sz);
  14685.   }
  14686.  
  14687.   void A::operator delete(SOMObject* obj)
  14688.   {
  14689.     howMany--;
  14690.     ::operator delete(obj);
  14691.   }
  14692.  
  14693.  
  14694. ΓòÉΓòÉΓòÉ 18.7.16.3. Using new.h in C++ SOM Programs ΓòÉΓòÉΓòÉ
  14695.  
  14696. If you normally include new.h in a program to specify that previously allocated 
  14697. storage is to be used when new is invoked, you should include somnew.h instead 
  14698. if the classes that make use of new are SOM classes. 
  14699.  
  14700.  
  14701. ΓòÉΓòÉΓòÉ 18.7.16.4. Determining which new and delete Operators Are Used ΓòÉΓòÉΓòÉ
  14702.  
  14703. If a SOM class has an operator new or an operator delete, these operators are 
  14704. used for all invocations of new or delete regardless of their signatures. If a 
  14705. SOM class does not have an operator new or an operator delete, the SOM version 
  14706. of the global operator is used. 
  14707.  
  14708. Warning: Memory allocated by SOMMalloc can only be freed by SOMFree, and memory 
  14709. allocated by malloc can only be freed by free.  If you use the SOM function for 
  14710. allocating storage for an object, and the non-SOM version for deallocating it 
  14711. (or vice versa), a runtime exception may occur. 
  14712.  
  14713. For example, the following will cause a runtime exception: 
  14714.  
  14715.   class A : public SOMObject {
  14716.    public:
  14717.      operator delete(void* o, size_t s) { ::delete o; )
  14718.   };
  14719.  
  14720. because class A's delete operator will be invoked when an object of class A is 
  14721. deleted.  The first parameter will point to the object to be deleted.  Note 
  14722. that because the first parameter is declared to be of type void*, this 
  14723. invocation implicitly involves converting a SOM pointer (an A*) into a non-SOM 
  14724. pointer (a void*). The subsequent ::delete o therefore uses the global non-SOM 
  14725. delete operator, which calls free, instead of the global SOM delete operator 
  14726. that calls SOMFree. 
  14727.  
  14728.  
  14729. ΓòÉΓòÉΓòÉ 18.7.17. Volatile Objects ΓòÉΓòÉΓòÉ
  14730.  
  14731. The SOM class member functions are not defined to operate on volatile SOM 
  14732. objects.  If you want to use the volatile qualifier with SOM objects, you must 
  14733. supply volatile versions of the SOM class member functions.  In particular, you 
  14734. must supply volatile versions of the four compiler-supplied operator= functions 
  14735. (described in Accessing Special Member Functions from Other Languages). Note 
  14736. that if you supply a const volatile version of a function, you should also 
  14737. supply a const version of the function for the sake of runtime efficiency. 
  14738.  
  14739.  
  14740. ΓòÉΓòÉΓòÉ 18.7.18. Data Members Implemented as Attributes ΓòÉΓòÉΓòÉ
  14741.  
  14742. You cannot take the address of a data member that is implemented as an 
  14743. attribute. 
  14744.  
  14745. If an attribute is made virtual by the SOMAttribute pragma, it will no longer 
  14746. behave like a normal C++ data member.  Because attributes are accessed using 
  14747. get and set methods, making an attribute virtual in fact makes the get and set 
  14748. methods for the attribute virtual, and such virtual methods can be overridden 
  14749. in a derived class. A derived class that overrides these methods can therefore 
  14750. change the type or other characteristics of the data.  This differs from normal 
  14751. C++ behavior in which a derived class cannot override definitions for data 
  14752. members defined in a base class. 
  14753.  
  14754. SOM methods are all implicitly given system linkage.  If the address is taken 
  14755. of a static member function, the resulting pointer value will be a pointer to a 
  14756. function with system linkage. The resulting pointer can only be assigned to a 
  14757. function pointer that also has system linkage. 
  14758.  
  14759.  
  14760. ΓòÉΓòÉΓòÉ 18.8. Converting C++ Programs to SOM Using SOMAsDefault ΓòÉΓòÉΓòÉ
  14761.  
  14762. The easiest way to convert existing classes to SOM classes is to use the 
  14763. SOMAsDefault pragma or the /Ga (enable implicit SOM mode) compiler option to 
  14764. tell the compiler what classes to treat as SOM classes.  Both the pragma and 
  14765. the option include the required SOM header file som.h, and implicitly convert 
  14766. all classes to SOM classes until implicit mode is turned off by a subsequent 
  14767. SOMAsDefault pragma. 
  14768.  
  14769. When you implicitly derive classes from SOMObject, the compiler is said to have 
  14770. "implicit SOM mode" turned on. 
  14771.  
  14772. If your programs do not use any of the C++ features that are not supported by 
  14773. SOM (such as multiple virtual inheritance), you should be able to compile and 
  14774. run them without further change.  See Differences between SOM and C++ for 
  14775. information on C++ features that are not supported or are implemented 
  14776. differently for SOM programs. 
  14777.  
  14778. VisualAge for C++ does not convert structs or classes to SOM classes if they 
  14779. have both of the following characteristics: 
  14780.  
  14781.      They have no user-declared member functions 
  14782.      They have no explicit bases. 
  14783.  
  14784.  Unions cannot be SOM classes. 
  14785.  
  14786.  Non-virtual multiple inheritance is not allowed. Suppose that a class A has 
  14787.  the class B in at least two separate places in its class hierarchy.  If class 
  14788.  B is not a virtual base class, class A cannot be a SOM class. 
  14789.  
  14790.  Note:  Member functions of implicit SOM classes are given SYSTEM linkage. 
  14791.  This means that pointers that are supposed to point at static member functions 
  14792.  of such classes must be explicitly declared SYSTEM. 
  14793.  
  14794.  
  14795. ΓòÉΓòÉΓòÉ 18.9. Creating SOM-Compliant Programs by Inheriting from SOMObject ΓòÉΓòÉΓòÉ
  14796.  
  14797. To make your programs SOM-enabled using this technique, you must first include 
  14798. the following header file in your program, before the first occurrence of a SOM 
  14799. class: 
  14800.  
  14801. #include <som.h>
  14802.  
  14803. Then, if you want to define a class that is SOM-enabled, you must inherit it 
  14804. from SOMObject, or from a class that itself was inherited from SOMObject.  Note 
  14805. that all classes in a class hierarchy must be SOM classes, if any is a SOM 
  14806. class. 
  14807.  
  14808. #include <som.h>
  14809. class MyClass : SOMObject { /* ... */ };  // both these classes
  14810. class SubClass : MyClass { /* ... */ };  // are SOM-enabled
  14811.  
  14812. class EnclosingClass { SubClass a; };   // NOT SOM-enabled
  14813.  
  14814. Note that SOMObject has the special property of always being virtual. 
  14815.  
  14816.  
  14817. ΓòÉΓòÉΓòÉ 18.10. Creating Shared Class Libraries with SOM ΓòÉΓòÉΓòÉ
  14818.  
  14819. When you create a shared class library that contains SOM-enabled classes, you 
  14820. must export the following three symbols for each SOM-enabled class, in order to 
  14821. be able to use that class: 
  14822.  
  14823.      SOMClassNameClassData 
  14824.      SOMClassNameCClassData 
  14825.      SOMClassNameNewCLass 
  14826.  
  14827.  You do this by adding each name to its own line in an exports file. 
  14828.  
  14829.  DLLs that are to be dynamically loaded using methods supported by the SOM 
  14830.  Class Manager, such as SOMClassMgr::somFindClsInFile(), should also export an 
  14831.  entry point called SOMInitModule that calls the compiler-defined NewClass 
  14832.  function for each class defined in the DLL. For a DLL defining a single class 
  14833.  whose SOM name is SOMX, this entry point could be written as: 
  14834.  
  14835.    void _Export _System SOMInitModule(long, long, char*)
  14836.    {
  14837.     SOMXNewClass(SOMX_MajorVersion, SOMX_MinorVersion);
  14838.    }
  14839.  
  14840.  For more information about SOMInitModule, see the SOMObjects Developer Toolkit 
  14841.  Publications. 
  14842.  
  14843.  
  14844. ΓòÉΓòÉΓòÉ 18.11. Using SOM Classes in DSOM Applications ΓòÉΓòÉΓòÉ
  14845.  
  14846. Distributed SOM, or DSOM, allows remote objects to appear local to a client 
  14847. program.  Remote objects are implemented "under the covers" by the DSOM 
  14848. runtime.  Remote objects are dynamically subclassed, and must always be treated 
  14849. as possible subclasses.  This means that you must handle DSOM objects using 
  14850. pointer notation. 
  14851.  
  14852. You cannot create or delete DSOM objects with the new and delete operators 
  14853. described in this book. For methods of creating DSOM objects, see the 
  14854. SOMObjects Developer Toolkit Publications. 
  14855.  
  14856. You cannot access data directly for a DSOM object, because the object may 
  14857. reside on a different system. You must use the get and set methods instead. 
  14858. This means you must use the SOMAttribute pragma for all data you want to make 
  14859. accessible through DSOM. For a SOM class to be usable as a DSOM class, #pragma 
  14860. SOMNoDataDirect(on) must be set for the class (the /Gb compiler option sets 
  14861. this pragma on at the start of the compilation unit). For further details see 
  14862. The SOMNoDataDirect Pragma. 
  14863.  
  14864. In DSOM, static data members are local to the current process, they are not 
  14865. managed remotely.  DSOM classes must also have a default constructor. 
  14866.  
  14867.  
  14868. ΓòÉΓòÉΓòÉ 18.12. System Object Model (SOM) Options ΓòÉΓòÉΓòÉ
  14869.  
  14870. This section describes the compiler options available for SOM support in 
  14871. VisualAge for C++. The following options are described: 
  14872.  
  14873.       /Fr 
  14874.       /Fs 
  14875.       /Ga 
  14876.       /Gb 
  14877.       /Gz 
  14878.       /Xs 
  14879.       /qsomvolattr 
  14880.  
  14881.  SOM options that affect the same settings as SOM pragmas are effective except 
  14882.  when overridden by those pragmas.  For example, the /Ga compiler option, which 
  14883.  causes all classes to implicitly derive from SOMObject, turns the SOMAsDefault 
  14884.  pragma on at the start of the translation unit.  This pragma remains in effect 
  14885.  until a #pragma SOMAsDefault(off|pop) is encountered in the translation unit. 
  14886.  See Conventions Used by the SOM Pragmas for more information on the 
  14887.  relationship between SOM pragma settings and SOM options. 
  14888.  
  14889.  In addition to the compiler options, the compiler defines a macro, 
  14890.  __SOM_ENABLED__, whose value corresponds to the level of SOM support provided 
  14891.  by the compiler.  If SOM support is not provided for a particular release of 
  14892.  the compiler, __SOM_ENABLED__ is not predefined. 
  14893.  
  14894.  The macro's value is a positive integer constant.  For the first 
  14895.  SOM-supporting release of VisualAge for C++, the level of SOM supported is SOM 
  14896.  2.1, so the macro has the value 210. 
  14897.  
  14898.  
  14899. ΓòÉΓòÉΓòÉ 18.12.1. /Ga ΓòÉΓòÉΓòÉ
  14900.  
  14901.   Syntax:
  14902.                                                                                   Default:
  14903.  
  14904.   /Ga[+|-]
  14905.                                                                                   /Ga-
  14906.  
  14907.  This option turns on implicit SOM mode, and also causes the file som.h to be 
  14908.  included. It is equivalent to placing #pragma SOMAsDefault(on) at the start of 
  14909.  the translation unit. 
  14910.  
  14911.  All classes are implicitly derived from SOMObject until a #pragma 
  14912.  SOMAsDefault(off) is encountered. 
  14913.  
  14914.  For further details see The SOMAsDefault Pragma. 
  14915.  
  14916.  
  14917. ΓòÉΓòÉΓòÉ 18.12.2. /Gb ΓòÉΓòÉΓòÉ
  14918.  
  14919.   Syntax:
  14920.                                                                                   Default:
  14921.  
  14922.   /Gb[+|-]
  14923.                                                                                   /Gb-
  14924.  
  14925.  This option instructs the compiler to disable direct access to attributes. 
  14926.  Instead, the  get and set methods are used.  This is equivalent to specifying 
  14927.  #pragma SOMNoDataDirect(on) as the first line of the translation unit. 
  14928.  
  14929.  For further details see The SOMNoDataDirect Pragma. 
  14930.  
  14931.  
  14932. ΓòÉΓòÉΓòÉ 18.12.3. /Gz ΓòÉΓòÉΓòÉ
  14933.  
  14934.   Syntax:
  14935.                                                                                   Default:
  14936.  
  14937.   /Gz[+|-]
  14938.                                                                                   /Gz-
  14939.  
  14940.  Use this option to initialize SOM classes at their point of first use during 
  14941.  the execution of your program. 
  14942.  
  14943.  By default, all SOM classes statically used in your program are initialized at 
  14944.  static initialization time. This makes your program smaller, but may result in 
  14945.  the initialization of classes that are not dynamically used. 
  14946.  
  14947.  With any setting of this option, any reference to a static member of a SOM 
  14948.  class will cause the class to be initialized. 
  14949.  
  14950.  
  14951. ΓòÉΓòÉΓòÉ 18.12.4. /Xs ΓòÉΓòÉΓòÉ
  14952.  
  14953.   Syntax:
  14954.                                                                                   Default:
  14955.  
  14956.   /Xs<directory|->
  14957.                                                                                   /Xs-
  14958.  
  14959.  Use this option to exclude files in the specified directories when implicit 
  14960.  SOM mode is turned on (when classes are implicitly derived from SOM). The 
  14961.  syntax of this option is: 
  14962.  
  14963.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  14964.   Γöé                                 Γöé
  14965.   Γöé      ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ                     Γöé
  14966.   Γöé            Γöé                     Γöé
  14967.   Γöé >>ΓöÇΓöÇ/XsΓöÇΓöÇΓöÇΓöÇdirectoryΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  14968.   Γöé                                 Γöé
  14969.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  14970.  where directory is the name of the directory or directories you want to 
  14971.  exclude. Directory names are separated with a semicolon (;). 
  14972.  
  14973.  This option is useful for mixing implicit SOM mode with existing include files 
  14974.  that include declarations of classes you do not want to be implicit SOM 
  14975.  classes. 
  14976.  
  14977.  
  14978. ΓòÉΓòÉΓòÉ 18.12.5. /Fr ΓòÉΓòÉΓòÉ
  14979.  
  14980.   Syntax:
  14981.                                                                                   Default:
  14982.  
  14983.   /Fr<classname>
  14984.                                                                                   None
  14985.  
  14986.  Use this option to have the compiler write the release order of the specified 
  14987.  class to standard output.  The release order is written in the form of a 
  14988.  SOMReleaseOrder pragma.  You can capture the output from this option when 
  14989.  developing new SOM classes, and include the pragma in the class definition. 
  14990.  The syntax of the option is: 
  14991.  
  14992.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  14993.   Γöé                                 Γöé
  14994.   Γöé >>ΓöÇΓöÇ/FrΓöÇΓöÇC++ClassNameΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  14995.   Γöé                                 Γöé
  14996.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  14997.  
  14998.  For further details see Release Order of SOM Objects and The SOMReleaseOrder 
  14999.  Pragma. 
  15000.  
  15001.  
  15002. ΓòÉΓòÉΓòÉ 18.12.6. /Fs ΓòÉΓòÉΓòÉ
  15003.  
  15004.   Syntax:
  15005.                                                                                   Default:
  15006.  
  15007.   /Fs[+|-|file|
  15008.   directory]
  15009.                                                                                   /Fs-
  15010.  
  15011.  Use this option to have the compiler generate an IDL file if a file with an 
  15012.  .hh extension is explicitly specified on the command line. The syntax of the 
  15013.  option is: 
  15014.  
  15015.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15016.   Γöé                                 Γöé
  15017.   Γöé >>ΓöÇΓöÇ/FsΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15018.   Γöé      Γö£ΓöÇ + ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                     Γöé
  15019.   Γöé      Γö£ΓöÇ Γö┤ ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                     Γöé
  15020.   Γöé      Γö£ΓöÇfilenameΓöÇΓöÇΓöñ                     Γöé
  15021.   Γöé      ΓööΓöÇdirectoryΓöÇΓöÿ                     Γöé
  15022.   Γöé                                 Γöé
  15023.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15024.  where: 
  15025.  
  15026.       /Fs<+> specifies that an IDL file will be created for every .hh file that 
  15027.       is specified on the command line and is in the current directory.  This 
  15028.       is the default. 
  15029.  
  15030.       /Fs filename.ext is like /Fs +, but the IDL file that is created will 
  15031.       have the specified filename.  If you do not specify an ext, the extension 
  15032.       will be idl. 
  15033.  
  15034.       /Fs directory_name is like /Fs +, but the IDL file that is created will 
  15035.       be put in the directory directory_name rather than the current directory. 
  15036.       directory_name must end with a backslash "\". 
  15037.  
  15038.       /Fs- specifies that no IDL file should be created. 
  15039.  
  15040.  
  15041. ΓòÉΓòÉΓòÉ 18.12.7. /qsomvolattr ΓòÉΓòÉΓòÉ
  15042.  
  15043.   Syntax:
  15044.                                                                                   Default:
  15045.  
  15046.   /qsomvolattr[+|-]
  15047.                                                                                   /qsomvolattr-
  15048.  
  15049.  The syntax of this option is: 
  15050.  
  15051.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15052.   Γöé                                 Γöé
  15053.   Γöé >>ΓöÇΓöÇ/qsomvolattrΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15054.   Γöé                                 Γöé
  15055.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15056.  
  15057.  Use /qsomvolattr+ to specify that attribute prototypes should be generated 
  15058.  with the volatile qualifier. 
  15059.  
  15060.  By default, attribute prototypes are not declared volatile. 
  15061.  
  15062.  
  15063. ΓòÉΓòÉΓòÉ 18.13. Macros Defined for SOM ΓòÉΓòÉΓòÉ
  15064.  
  15065. VisualAge for C++ predefines the __SOM_ENABLED__ macro with a positive integer 
  15066. value, to indicate the level of SOM support provided. Currently the value for 
  15067. __SOM_ENABLED__ is 210, which indicates that the level of SOM support described 
  15068. in this chapter is available.  If __SOM_ENABLED__ is not defined or has a zero 
  15069. value, SOM is not supported by the version of the compiler on which the program 
  15070. is being compiled. 
  15071.  
  15072.  
  15073. ΓòÉΓòÉΓòÉ 18.14. Pragmas for Using SOM ΓòÉΓòÉΓòÉ
  15074.  
  15075. This section describes the pragmas available for SOM support on VisualAge for 
  15076. C++.  See the previous sections for background information on the reasons and 
  15077. uses for the pragmas. 
  15078.  
  15079. Note:  The SOM pragmas are case-insensitive.  They are shown here in a 
  15080. mixed-case format to make them easier to read.  You can use any combination of 
  15081. upper- and lowercase letters for the pragma names and for the on, off and pop 
  15082. arguments. However, you must still enter C++ tokens such as class, method, and 
  15083. data member names exactly as they are declared in your program. 
  15084.  
  15085.  
  15086. ΓòÉΓòÉΓòÉ 18.14.1. Conventions Used by the SOM Pragmas ΓòÉΓòÉΓòÉ
  15087.  
  15088. Some of the SOM pragmas use certain conventions to specify the scope to which 
  15089. the pragma applies.  This section explains those conventions. 
  15090.  
  15091.  
  15092. ΓòÉΓòÉΓòÉ 18.14.1.1. Pragmas Containing on | off | pop ΓòÉΓòÉΓòÉ
  15093.  
  15094. SOM pragmas containing an argument of on, off, or pop implement a 
  15095. stack-modelled approach to setting their option.  The arguments do the 
  15096. following: 
  15097.  
  15098.  on   Pushes the prior state (on or off) of the pragma onto the pragma's 
  15099.       "stack", and turns the setting on. 
  15100.  off  Pushes the prior state of the pragma onto the pragma's "stack", and turns 
  15101.       the setting off. 
  15102.  pop  Restores the most recently saved state from the pragma's "stack". 
  15103.  
  15104.  The following example shows the effect of the SOMAsDefault pragma with 
  15105.  different settings: 
  15106.  
  15107.     // ...  SOMAsDefault is off, or ON if program compiled with /Ga
  15108.  
  15109.     #pragma SOMAsDefault(on)
  15110.     // ...  SOMAsDefault now on
  15111.  
  15112.     #pragma SOMAsDefault(pop)
  15113.     // ...  SOMAsDefault now off, or ON if program compiled with /Ga
  15114.  
  15115.     #pragma SOMAsDefault(off)
  15116.     // ...  SOMAsDefault now off
  15117.  
  15118.     #pragma SOMAsDefault(pop)
  15119.     // ...  SOMAsDefault now off, or ON if program compiled with /Ga
  15120.  
  15121.  It is recommended that on or off be used only at the beginning of a block, and 
  15122.  pop only at the end of the block.  This ensures that default settings are 
  15123.  preserved around your own settings. 
  15124.  
  15125.  If you pop a pragma more times than you push it with on or off, the results 
  15126.  are unpredictable. 
  15127.  
  15128.  
  15129. ΓòÉΓòÉΓòÉ 18.14.1.2. Pragmas Containing an Asterisk (*) ΓòÉΓòÉΓòÉ
  15130.  
  15131. Certain SOM pragmas accept either a C++ class name or an asterisk (*) as one of 
  15132. their arguments.  You can use the asterisk to indicate that the class the 
  15133. pragma applies to is the class within which the pragma occurs.  For example: 
  15134.  
  15135.   #pragma SOMAsDefault(on)
  15136.   class A {
  15137.    //...
  15138.   #pragma SOMClassVersion(*,3,1)
  15139.   // Version number applies to class A
  15140.   }
  15141.  
  15142.   Class B {
  15143.    // ...
  15144.   #pragma SOMClassVersion(B,3,3)
  15145.   // Could have specified * instead of B
  15146.   }
  15147.  
  15148.   #pragma SOMClassVersion(*,2,5)
  15149.   // Error - not in the scope of any class!
  15150.  
  15151.  
  15152. ΓòÉΓòÉΓòÉ 18.14.2. The SOM Pragma ΓòÉΓòÉΓòÉ
  15153.  
  15154. This pragma causes the compiler to recognize the SOMObject class as the special 
  15155. base for all SOM classes. 
  15156.  
  15157. Note:  The compiler still requires a full declaration for SOMObject. Therefore, 
  15158.        you must include the header file containing this declaration. 
  15159.  
  15160.  There should only be one occurrence of this pragma, and it should be placed in 
  15161.  the same header file in which SOMObject is declared. 
  15162.  
  15163.  The syntax of the pragma is: 
  15164.  
  15165.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15166.   Γöé                                 Γöé
  15167.   Γöé >>ΓöÇΓöÇ#pragma SOMΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15168.   Γöé                                 Γöé
  15169.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15170.  
  15171.  
  15172. ΓòÉΓòÉΓòÉ 18.14.3. The SOMAsDefault Pragma ΓòÉΓòÉΓòÉ
  15173.  
  15174. The setting of this pragma determines how the compiler should treat classes 
  15175. that are not explicitly derived from SOMObject. When the pragma is in effect, 
  15176. all non-local classes are implicitly derived from SOMObject.  When the pragma 
  15177. is not in effect, classes must be explicitly derived from SOMObject in order to 
  15178. be supported for use by SOM programs. 
  15179.  
  15180. The syntax of the pragma is as follows: 
  15181.  
  15182. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15183. Γöé                                 Γöé
  15184. Γöé >>ΓöÇΓöÇ#pragma SOMAsDefault(ΓöÇΓöÇΓö¼ΓöÇonΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15185. Γöé               Γö£ΓöÇoffΓöÇΓöñ               Γöé
  15186. Γöé               ΓööΓöÇpopΓöÇΓöÿ               Γöé
  15187. Γöé                                 Γöé
  15188. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15189.  
  15190. The on argument saves the current setting, and turns SOMAsDefault on.  The off 
  15191. argument saves the current setting, and turns SOMAsDefault off.  The pop 
  15192. setting restores the most recently saved but still unrestored setting. See 
  15193. Pragmas Containing on | off | pop for more information on how to use these 
  15194. arguments. 
  15195.  
  15196. When this pragma is turned on for the first time in a compilation unit, it also 
  15197. causes the som.h header file to be included if it has not already been 
  15198. included. 
  15199.  
  15200. The /Ga compiler option provides the same effect as setting #pragma 
  15201. SOMAsDefault(on) at the start of the translation unit. 
  15202.  
  15203.  
  15204. ΓòÉΓòÉΓòÉ 18.14.4. The SOMAttribute Pragma ΓòÉΓòÉΓòÉ
  15205.  
  15206. Use this pragma to specify that a data member is an attribute, and to 
  15207. communicate IDL information regarding the implementation of attributes. For an 
  15208. explanation of how attributes are used, see set and get Methods for Attribute 
  15209. Class Members. The syntax of the pragma is: 
  15210.  
  15211. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15212. Γöé                                 Γöé
  15213. Γöé >>ΓöÇΓöÇ#pragma SOMAttribute(ΓöÇΓöÇDataMemberΓöÇΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15214. Γöé                                 Γöé
  15215. Γöé   ΓöîΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ                    Γöé
  15216. Γöé              Γöé                    Γöé
  15217. Γöé >ΓöÇΓöÇΓöÇΓö¼ΓöÇindirectΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö┤ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15218. Γöé   Γö£ΓöÇnodataΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15219. Γöé   Γö£ΓöÇnogetΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15220. Γöé   Γö£ΓöÇnosetΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15221. Γöé   Γö£ΓöÇprivatedataΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15222. Γöé   Γö£ΓöÇprotectedataΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15223. Γöé   Γö£ΓöÇpublicdataΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15224. Γöé   Γö£ΓöÇreadonlyΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ                    Γöé
  15225. Γöé   ΓööΓöÇvirtualaccessorsΓöÇΓöÿ                    Γöé
  15226. Γöé                                 Γöé
  15227. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15228.  
  15229. The pragma must appear within the class definition or declaration in which the 
  15230. data member is defined. Each attribute in a class must be defined in its own 
  15231. pragma. You can only make a non-static data member into an attribute. The 
  15232. member cannot be a reference to an abstract class because the _get/_set 
  15233. functions have to operate on values. The keywords have the following effects: 
  15234.  
  15235.  indirect        The interface (prototype) for the get and set methods of this 
  15236.                  attribute must use one level of indirection for both the 
  15237.                  argument to be set and the return from the get.  This means 
  15238.                  that if the type is normally passed and returned by value, it 
  15239.                  will have its address returned instead. For example, T 
  15240.                  _get_X() actually returns *T, and _set_X(T) actually accepts 
  15241.                  *T as argument. indirect is ignored for structs and arrays. 
  15242.  
  15243.  nodata          The compiler does not allocate any instance data corresponding 
  15244.                  to this attribute, and does not generate definitions for the 
  15245.                  get and set methods.  This means that you must define these 
  15246.                  methods yourself and allocate any instance data these methods 
  15247.                  require. nodata implies that there is no way for C++ code to 
  15248.                  take the address of this variable. The compiler issues an 
  15249.                  error message when you attempt to do this. 
  15250.  
  15251.                  You must write and declare the corresponding get and set 
  15252.                  functions, _get_variable and _set_variable, where variable is 
  15253.                  the attribute's name. 
  15254.  
  15255.  noget           The compiler does not generate a body for the attribute's get 
  15256.                  method. You must provide a body for the get method. 
  15257.  
  15258.  noset           The compiler does not generate a body for the attribute's set 
  15259.                  method. You must provide a body for the set method. This 
  15260.                  qualifier is ignored if the attribute is const. 
  15261.  
  15262.  privatedata     The compiler defines instance data for the member class and 
  15263.                  gives it private access.  This is the default. 
  15264.  
  15265.  protectedata    The instance data for the member class has protected access. 
  15266.  
  15267.  publicdata      The instance data for the member class has public access. 
  15268.  
  15269.  readonly        The attribute is not allowed to have a set method.  The 
  15270.                  compiler does not generate one.  If you provide one, the 
  15271.                  compiler flags it as an error. 
  15272.  
  15273.  virtualaccessors The _get/_set methods will be virtual functions. By default, 
  15274.                  _get and _set are nonvirtual functions. 
  15275.  
  15276.  The access for the _get/_set methods is the same as the access for the data 
  15277.  member.  For example, access for the _get/_set methods of a protected data 
  15278.  member are protected.  By default, access to the data itself is private unless 
  15279.  you specify otherwise with one of the protecteddata or publicdata keywords. If 
  15280.  you do not use the SOMAttribute pragma, the data member is not an attribute. 
  15281.  Attribute qualifiers nodata, privatedata, protectedata and publicdata are 
  15282.  mutually exclusive. It is an error for the access of an attribute's instance 
  15283.  data to be greater than the access of the attribute.  For example, it is an 
  15284.  error for a private attribute to have public instance data. 
  15285.  
  15286.  If you do not use the SOMNoDataDirect pragma, access to data members uses 
  15287.  direct access if the user code has access to the instance data. 
  15288.  
  15289.   When SOMNoDataDirect is used, the _get/_set methods are used.  The access for 
  15290.  the _get/_set methods is the same as the access for the data member. For 
  15291.  example, access for a protected data member's _get and _set methods would be 
  15292.  protected. 
  15293.  
  15294.  The nodata attribute modifier and the SOMNoDataDirect pragma have different 
  15295.  effects, although their names are similar. 
  15296.  
  15297.  Normally, the compiler creates instance data in the class to implement an 
  15298.  attribute, and generates definitions for get and set methods that access this 
  15299.  "backing" data.  The access class of the methods is that of the attribute, but 
  15300.  the backing data is private.  You can override this with the publicdata or 
  15301.  protectedata modifiers. 
  15302.  
  15303.  If you do not specify other modifiers or pragmas, then uses of the attribute 
  15304.  are compiled either into direct accesses of the backing data, or into calls to 
  15305.  the get and set methods. The compiler determines whether the code using the 
  15306.  attribute can "see" the backing data, according to the usual C++ access rules. 
  15307.  Because members and friend functions of a class do have access to its private 
  15308.  data, they directly access any backing data for attributes of that class. 
  15309.  Methods in derived classes only have access to public and protected members of 
  15310.  a base class, so can only access backing data that is public or protected. 
  15311.  Private backing data in a base class is not accessible, so uses of public or 
  15312.  protected attributes with private backing data must call _get and _set. 
  15313.  
  15314.  When you add the nodata modifier to an attribute, the compiler no longer 
  15315.  automatically creates backing data, and only declares the get and set methods. 
  15316.  You must supply definitions for them.  Also, uses of the attribute will always 
  15317.  be compiled into get or set calls. 
  15318.  
  15319.  When you use the SOMNoDataDirect pragma on a class, it does not affect the 
  15320.  generation of methods or backing data, but it does affect how uses of the 
  15321.  attribute are compiled. SOMNoDataDirect is an indication to the compiler that 
  15322.  instances of the class may be proxies for remote objects built by DSOM. DSOM. 
  15323.  Because direct data access is not possible for remote objects, the compiler 
  15324.  must then generate _get/_set calls for all attribute uses, unless the object 
  15325.  is known to be local.  The only object that can be safely assumed local is the 
  15326.  object pointed to by this, so direct data access only happens for accesses 
  15327.  through the this pointer.  This condition is imposed in addition to the access 
  15328.  checks described above. 
  15329.  
  15330.  
  15331. ΓòÉΓòÉΓòÉ 18.14.5. The SOMCallStyle Pragma ΓòÉΓòÉΓòÉ
  15332.  
  15333. Use this pragma to specify the callstyle of the class within which the pragma 
  15334. occurs.  The syntax of this pragma is: 
  15335.  
  15336. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15337. Γöé                                 Γöé
  15338. Γöé >>ΓöÇΓöÇ#pragma SOMCallStyle(ΓöÇΓöÇΓö¼ΓöÇOIDLΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15339. Γöé               ΓööΓöÇIDLΓöÇΓöÇΓöÿ               Γöé
  15340. Γöé                                 Γöé
  15341. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15342.  
  15343. The OIDL option indicates that the callstyle of methods introduced by the class 
  15344. does not include the Environment* argument, while the IDL option indicates that 
  15345. the callstyle does include the Environment* argument.  The default is for IDL 
  15346. callstyle to be used. 
  15347.  
  15348. For further details see IDL and OIDL Callstyles. 
  15349.  
  15350.  
  15351. ΓòÉΓòÉΓòÉ 18.14.6. The SOMClassInit Pragma ΓòÉΓòÉΓòÉ
  15352.  
  15353. Use this pragma to specify a function that the SOM runtime is to invoke during 
  15354. creation of the class object for the named class. The syntax of this pragma is: 
  15355.  
  15356. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15357. Γöé                                 Γöé
  15358. Γöé >>ΓöÇΓöÇ#pragma SOMClassInit(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15359. Γöé               ΓööΓöÇC++ClassNameΓöÇΓöÿ           Γöé
  15360. Γöé                                 Γöé
  15361. Γöé >ΓöÇΓöÇC++PrototypeΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15362. Γöé                                 Γöé
  15363. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15364.  
  15365. The asterisk indicates that the pragma applies to the innermost enclosing class 
  15366. within which the pragma is found. 
  15367.  
  15368. The C++Prototype is a C++ function prototype without the return type.  For 
  15369. example, the function double sqrt(double) would appear as sqrt(double) in this 
  15370. pragma. 
  15371.  
  15372. A class object is created for a class when the first object of that class is 
  15373. created.  The function called after the class object is created must have the 
  15374. following form: 
  15375.  
  15376.   void FunctionName(SOMClass*);
  15377.  
  15378. The name of the function is not significant.  Once you have declared or defined 
  15379. this function, you can associate it with the class constructor for a class 
  15380. using the pragma: 
  15381.  
  15382.   #pragma SOMClassInit(FunctionName)
  15383.  
  15384. You do not need to use this pragma unless you want to define a function to be 
  15385. called when the class object is created. 
  15386.  
  15387.  
  15388. ΓòÉΓòÉΓòÉ 18.14.7. The SOMClassName Pragma ΓòÉΓòÉΓòÉ
  15389.  
  15390. Use this pragma to specify SOM names for C++ classes and template classes.  You 
  15391. should keep in mind that naming in SOM is not case sensitive, so any names you 
  15392. supply through SOMClassName should be distinguishable from other names 
  15393. regardless of case.  In addition, the Common Object Request Broker Architecture 
  15394. (CORBA) requires that names begin with a letter of the alphabet. 
  15395.  
  15396. If you do not use the SOMClassName pragma, and the SOMNoMangling pragma is not 
  15397. in effect for the class, the compiler mangles the class name, which may make 
  15398. the class difficult to use from non-C++ programs. Mangled names tend to be 
  15399. nonobvious, and accessing them from SOM programs can reduce code readability 
  15400. and increase the likelihood of coding errors. 
  15401.  
  15402. The syntax of the SOMClassName pragma is: 
  15403.  
  15404. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15405. Γöé                                 Γöé
  15406. Γöé >>ΓöÇΓöÇ#pragma SOMClassName(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ,ΓöÇΓöÇ"ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15407. Γöé               ΓööΓöÇC++ClassNameΓöÇΓöÿ           Γöé
  15408. Γöé                                 Γöé
  15409. Γöé >ΓöÇΓöÇNameOfSomClassΓöÇΓöÇ")ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15410. Γöé                                 Γöé
  15411. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15412.  
  15413. The asterisk indicates that the pragma applies to the innermost enclosing class 
  15414. within which the pragma is found. 
  15415.  
  15416. For example: 
  15417.  
  15418.   #pragma SOMAsDefault(on)
  15419.   class MyCppClass { /* ... */ };
  15420.   #pragma SOMClassName(MyCppClass, "MySOMClass")
  15421.   class AnotherClass {
  15422.   #pragma SOMClassName(*,"AnotherSOMClass")
  15423.   //...
  15424.   };
  15425.  
  15426. The requirements for the SOMClassName pragma are: 
  15427.  
  15428.      The class in question must already have been declared when the compiler 
  15429.       encounters the pragma. 
  15430.      The class must be a SOM class. 
  15431.      The SOM class name cannot be the same as a name associated with a 
  15432.       different SOM class.  This means that you cannot write code such as the 
  15433.       following: 
  15434.  
  15435.               class x : SOMObject { int a; };
  15436.               class y : SOMObject { int b; };
  15437.               #pragma SOMClassName(x,"y") // error - there is already a SOM Y class.
  15438.  
  15439.       The compiler will catch this error if the two SOM classes involved are in 
  15440.       the same compilation unit.  If they are in separate compilation units, 
  15441.       the compiler will not issue an error message, and the results of the 
  15442.       program are unpredictable. 
  15443.      The pragma must appear before the compiler needs to access the class to 
  15444.       allocate an instance of the class or one of its subclasses. 
  15445.      If the asterisk (*) is used, the pragma must appear within the 
  15446.       declaration for a SOM class. 
  15447.  
  15448.  Multiple equivalent SOMClassName pragmas are ignored. The compiler issues an 
  15449.  error if it detects multiple SOMClassName pragmas for the same class that are 
  15450.  not equivalent. 
  15451.  
  15452.  
  15453. ΓòÉΓòÉΓòÉ 18.14.8. The SOMClassVersion Pragma ΓòÉΓòÉΓòÉ
  15454.  
  15455. SOM supports explicit version numbering for classes.  The SOM runtime uses this 
  15456. information to ensure that the classes of a SOM library are at least as recent 
  15457. as the version of the library a client program was compiled to.  When you use 
  15458. the SOMClassVersion  pragma, you prevent the compiler from providing version n 
  15459. of a class when a client program was expecting version n+1.  See Version 
  15460. Control for SOM Libraries and Programs for a more in-depth explanation of class 
  15461. versioning.  The syntax of the pragma is: 
  15462.  
  15463. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15464. Γöé                                 Γöé
  15465. Γöé >>ΓöÇΓöÇ#pragma SOMClassVersion(ΓöÇΓöÇΓö¼ΓöÇC++ClassNameΓöÇΓö¼ΓöÇΓöÇ,ΓöÇΓöÇMajorΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15466. Γöé                ΓööΓöÇ*Γö┤Γö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ         Γöé
  15467. Γöé                                 Γöé
  15468. Γöé >ΓöÇΓöÇ,ΓöÇΓöÇMinorΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15469. Γöé                                 Γöé
  15470. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15471.  
  15472. You can use the asterisk (*) to indicate that the pragma applies to the 
  15473. innermost enclosing class within which the pragma occurs. If you use the 
  15474. C++ClassName form of the pragma, the class must already have been declared at 
  15475. the point where the pragma is encountered. 
  15476.  
  15477. In the following example, class Q is given a major version of 3 and a minor 
  15478. version of 2: 
  15479.  
  15480.   #pragma SOMAsDefault(on)
  15481.   class Q {
  15482.    public:
  15483.    //...
  15484.   #pragma SOMClassVersion(*,3,2)
  15485.   };
  15486.   #pragma SOMAsDefault(pop)
  15487.  
  15488. The following considerations apply to this pragma: 
  15489.  
  15490.      Both the major and minor version numbers must be provided, and both must 
  15491.       be positive or zero-valued integers. 
  15492.  
  15493.      The compiler issues an error message if you specify multiple conflicting 
  15494.       SOMClassVersion pragmas for a given class. 
  15495.  
  15496.      The class must already be declared at the point where the pragma is 
  15497.       encountered. 
  15498.  
  15499.      In the absence of a SOMClassVersion pragma for a class, the compiler 
  15500.       assumes zero for both version levels. 
  15501.  
  15502.  The SOM runtime treats a zero version value for a class as indicating that 
  15503.  versions do not matter, and consequently does not check for version 
  15504.  compatibility. 
  15505.  
  15506.  
  15507. ΓòÉΓòÉΓòÉ 18.14.9. The SOMDataName Pragma ΓòÉΓòÉΓòÉ
  15508.  
  15509. Use this pragma to specify SOM names for C++ class data members. You only need 
  15510. to use this pragma if you want access to the class of the applicable data 
  15511. member from non-C++ programs.  If you do not use this pragma or the 
  15512. SOMNoMangling pragma, data member names are mangled by the compiler, and the 
  15513. mangled names can lead to coding errors in the non-C++ programs that attempt to 
  15514. use them (because the names are obscure and typically very long). If the member 
  15515. is an attribute, the member's SOM name is used to form the get and set method 
  15516. names. 
  15517.  
  15518. The syntax of the pragma is: 
  15519.  
  15520. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15521. Γöé                                 Γöé
  15522. Γöé >>ΓöÇΓöÇ#pragma SOMDataName(ΓöÇΓöÇC++DataMemberΓöÇΓöÇ,ΓöÇΓöÇ"SomName"ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15523. Γöé                                 Γöé
  15524. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15525.  
  15526. This pragma may only occur within the body of the corresponding class 
  15527. declaration, and only after the corresponding data member has been declared. 
  15528.  
  15529.  
  15530. ΓòÉΓòÉΓòÉ 18.14.10. The SOMDefine Pragma ΓòÉΓòÉΓòÉ
  15531.  
  15532. Use this pragma in classes you define that have all member functions inline. 
  15533. The pragma is not necessary for classes that have at least one non-inline 
  15534. member function.  This pragma (or the point at which the compiler encounters 
  15535. the definition for the first out-of-line function declared within the class) 
  15536. causes the compiler to emit the SOMBuildClass data structures, which are used 
  15537. by the SOM runtime.  The SOMDefine pragma for a class with all inline functions 
  15538. can occur in any compilation unit, but should only appear once across all 
  15539. compilation units.  The syntax of the pragma is: 
  15540.  
  15541. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15542. Γöé                                 Γöé
  15543. Γöé >>ΓöÇΓöÇ#pragma SOMDefine(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15544. Γöé             Γö£ΓöÇonΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ            Γöé
  15545. Γöé             Γö£ΓöÇoffΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ            Γöé
  15546. Γöé             Γö£ΓöÇpopΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ            Γöé
  15547. Γöé             ΓööΓöÇC++ClassNameΓöÇΓöÿ            Γöé
  15548. Γöé                                 Γöé
  15549. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15550.  
  15551. You can use the asterisk (*) to indicate that the pragma applies to the 
  15552. innermost enclosing class within which the pragma occurs. This version of the 
  15553. pragma does not apply to nested classes of the class where the pragma occurs. 
  15554.  
  15555. For the C++ClassName version, the name of the specified class must be visible 
  15556. at the point where the pragma is encountered. 
  15557.  
  15558. The on, off, and pop settings are independent of the asterisk setting.  Use 
  15559. them to control the default over specific ranges of source. (See Pragmas 
  15560. Containing on | off | pop for information on how to use these arguments.) 
  15561.  
  15562. If a SOMDefine(*) pragma occurs within the body of a class, that class will be 
  15563. defined (assuming it has no out-of-line functions) regardless of the current 
  15564. value set by on/off/pop. 
  15565.  
  15566. Classes that have all member functions defined inline are considered 
  15567. declarations by the C++ language rules.  This means that such classes can be 
  15568. "declared" in several compilation units. Normally, the compiler would have to 
  15569. create a class structure and its data and method tables each time it encounters 
  15570. such a class.  When you use the SOMDefine pragma, you allow the compiler to 
  15571. create only one copy of the class structure, which can reduce your program's 
  15572. storage requirements and improve performance. 
  15573.  
  15574. This pragma is ignored if the class has any out-of-line member functions. 
  15575.  
  15576.  
  15577. ΓòÉΓòÉΓòÉ 18.14.11. The SOMIDLDecl Pragma ΓòÉΓòÉΓòÉ
  15578.  
  15579. Use the SOMIDLDecl pragma to override the IDL declaration that the compiler 
  15580. would otherwise generate for the named type or member function to which the 
  15581. pragma applies.  You can use this pragma to include information related to IDL 
  15582. contexts and IDL exceptions, or to fine-tune translations between char* and 
  15583. string types. The syntax of the pragma is: 
  15584.  
  15585. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15586. Γöé                                 Γöé
  15587. Γöé >>ΓöÇΓöÇ#pragma SOMIDLDecl(ΓöÇΓöÇΓö¼ΓöÇCΓöîΓöÉTypeNameΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15588. Γöé              ΓööΓöÇCΓööΓöÿPrototypeΓöÇΓöÿ            Γöé
  15589. Γöé                                 Γöé
  15590. Γöé >ΓöÇΓöÇ"IDLDeclaration"ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15591. Γöé                                 Γöé
  15592. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15593.  
  15594. The type or member function named must be defined before the pragma is 
  15595. encountered.  For type names, the sequence %N within the string is replaced by 
  15596. the name of the type. 
  15597.  
  15598. The C++Prototype is a C++ function prototype without the return type.  For 
  15599. example, the function double sqrt(double) would appear as sqrt(double) in this 
  15600. pragma. If the prototype has a trailing const, you must include this in the 
  15601. prototype. 
  15602.  
  15603. The following example shows a use of this pragma.  Here the pragma redeclares 
  15604. one of the char* arguments of method P as type string, while keeping the other 
  15605. as type char*, and indicates that the method may raise exception exc1. 
  15606.  
  15607. typedef int type1;
  15608. #pragma SOMIDLDecl (type1, "typedef foobar type1");
  15609.  
  15610. class T : public SOMObject {
  15611.   public:
  15612.    void P(char*, char*);
  15613.    #pragma SOMMethodName(P,"P")
  15614.    #pragma SOMIDLDecl(P, "void P(string, char*) raises(exc1)")
  15615.    // ...
  15616.   };
  15617.  
  15618.  
  15619. ΓòÉΓòÉΓòÉ 18.14.12. The SOMIDLPass Pragma ΓòÉΓòÉΓòÉ
  15620.  
  15621. Use the SOMIDLPass pragma to emit arbitrary text to IDL. The syntax of the 
  15622. pragma is: 
  15623.  
  15624. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15625. Γöé                                 Γöé
  15626. Γöé >>ΓöÇΓöÇ#pragma SOMIDLPass(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ"ΓöÇΓöÇLabelΓöÇΓöÇ","ΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15627. Γöé              ΓööΓöÇC++ClassNameΓöÇΓöÿ            Γöé
  15628. Γöé                                 Γöé
  15629. Γöé >ΓöÇΓöÇStringToEmitΓöÇΓöÇ")ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15630. Γöé                                 Γöé
  15631. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15632.  
  15633. The Label field indicates where in the IDL file for a class the string is to be 
  15634. emitted to.  The possible labels are described below.  The pragma accepts any 
  15635. combination of upper- and lowercase characters for a label: 
  15636.  
  15637.  Begin                 Text is emitted at the start of the IDL file, just after 
  15638.                        the controlling #ifdef and #define pair of directives. 
  15639.  
  15640.  End                   Text is emitted at the end of the IDL file, just before 
  15641.                        the controlling #endif directive. 
  15642.  
  15643.  Implementation-Begin  Text is emitted right after the opening brace of 
  15644.                        implementation {. 
  15645.  
  15646.  Implementation-End    Text is emitted just before the closing brace of the 
  15647.                        implementation section. 
  15648.  
  15649.  Interface-Begin       Text is emitted at the start of the interface section 
  15650.                        for the class, right after the opening { brace. 
  15651.  
  15652.  Interface-End         Text is emitted at the end of the interface section of 
  15653.                        the class, immediately before the implementation 
  15654.                        section. 
  15655.  
  15656.  Other text            The compiler ignores a SOMIDLPass pragma whose label 
  15657.                        does not match one of the above.  No warning is given. 
  15658.  
  15659.  The following class definition shows uses of the SOMIDLPass pragma: 
  15660.  
  15661.   class T : public SOMObject {
  15662.      public: boolean somRespondsTo(somId);
  15663.      #pragma SOMIDLTypes(*, boolean, somId)
  15664.      #pragma SOMIDLPass(*,"Begin", "//Top")
  15665.      #pragma SOMIDLPass(*,"End", "//End")
  15666.      #pragma SOMIDLPass(*,"Interface-Begin", "//Int Begin")
  15667.      #pragma SOMIDLPass(*,"Interface-End", "//Int End")
  15668.      #pragma SOMIDLPass(*,"Implementation-Begin", "//Imp Begin")
  15669.      #pragma SOMIDLPass(*,"Implementation-End", "//Imp End")
  15670.     };
  15671.     #pragma SOMIDLPass(T,"Interface-Begin", "//Int Begin 2")
  15672.     #pragma SOMIDLPass(T,"Interface-End", "//Int End 2")
  15673.     #pragma SOMIDLPass(T,"Implementation-Begin", "// ** Imp Begin 2")
  15674.  
  15675.  This example causes IDL to be emitted that looks like the following: 
  15676.  
  15677.   #ifndef T__IDL__
  15678.   #define T__IDL__
  15679.  
  15680.   // Top
  15681.   #include <som.h>
  15682.  
  15683.   typedef int boolean;
  15684.   typedef void* somId;
  15685.  
  15686.   interface T : SOMObject {
  15687.     // Int Begin
  15688.     // Int Begin 2
  15689.     void f();
  15690.     // Int End
  15691.     // Int End 2
  15692.     Implementation {
  15693.      // Imp Begin
  15694.      // ** Imp Begin 2
  15695.      somRespondsTo : override;
  15696.      // ...
  15697.      // Imp End
  15698.     };
  15699.   };
  15700.  
  15701.   // End
  15702.  
  15703.  SOMIDLPass pragmas are cumulative; each one adds to the text emitted for the 
  15704.  class.  The relative order of the pragmas are retained. 
  15705.  
  15706.  
  15707. ΓòÉΓòÉΓòÉ 18.14.13. The SOMIDLTypes Pragma ΓòÉΓòÉΓòÉ
  15708.  
  15709. Use the SOMIDLTypes pragma to list types that you want the compiler to emit 
  15710. when it generates IDL for the specified class.  The syntax of the pragma is: 
  15711.  
  15712. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15713. Γöé                                 Γöé
  15714. Γöé                       ΓöîΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ    Γöé
  15715. Γöé                             Γöé    Γöé
  15716. Γöé >>ΓöÇΓöÇ#pragma SOMIDLTypes(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇtypeNameΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15717. Γöé              ΓööΓöÇC++ClassNameΓöÇΓöÿ           Γöé
  15718. Γöé                                 Γöé
  15719. Γöé >ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15720. Γöé                                 Γöé
  15721. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15722.  
  15723. The asterisk indicates that the pragma applies to the innermost enclosing class 
  15724. within which the pragma is found. 
  15725.  
  15726. The following directive: 
  15727.  
  15728.   #pragma SOMIDLTypes(MyClass, size_t, AnotherType)
  15729.  
  15730. Would ensure that size_t and AnotherType are emitted whenever IDL is emitted 
  15731. for class MyClass. 
  15732.  
  15733. Uses of this pragma for a given class are cumulative.  This means that each 
  15734. such pragma for a class adds the specified types to the list for the class, and 
  15735. the order in which the types are emitted is the same as the order in which they 
  15736. are encountered. By default (i.e., if no SOMIDLTypes pragma is specified), only 
  15737. the class itself is emitted. 
  15738.  
  15739. Note:  When the compiler encounters a SOMIDLTypes pragma for a type that is 
  15740. defined in a nested include file, it generates only an #include of the IDL file 
  15741. corresponding to that nested include file. In other words, classes and typedefs 
  15742. defined in nested include files are not generated directly in the IDL file. 
  15743. Note that the IDL for the nested include file must be generated separately, 
  15744. because the compiler only generates IDL for declarations in the file being 
  15745. compiled. 
  15746.  
  15747.  
  15748. ΓòÉΓòÉΓòÉ 18.14.14. The SOMMetaClass Pragma ΓòÉΓòÉΓòÉ
  15749.  
  15750. Use this pragma if you want to identify a particular class for SOM to use as 
  15751. the metaclass of a SOM-enabled C++ class.  For more information on SOM 
  15752. metaclasses, see Metaclasses. The syntax of the pragma is: 
  15753.  
  15754. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15755. Γöé                                 Γöé
  15756. Γöé >>ΓöÇΓöÇ#pragma SOMMetaClass(ΓöÇΓöÇΓö¼ΓöÇC++ClassNameΓöÇΓö¼ΓöÇΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15757. Γöé               ΓööΓöÇ*Γö┤Γö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ           Γöé
  15758. Γöé                                 Γöé
  15759. Γöé >ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15760. Γöé   Γö£ΓöÇ"SOMClassName"ΓöÇΓöÇΓöÇΓöñ                     Γöé
  15761. Γöé   ΓööΓöÇC++MetaClassNameΓöÇΓöÿ                     Γöé
  15762. Γöé                                 Γöé
  15763. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15764.  
  15765. The C++ClassName indicates what class is to have the specified metaclass as its 
  15766. metaclass.  This form of the pragma can occur at any scope.  The names of all 
  15767. specified C++ classes must be visible. 
  15768.  
  15769. An asterisk (*) in the first position indicates that the innermost enclosing 
  15770. class within which the pragma occurs is the class that will have the specified 
  15771. metaclass. An asterisk in the second position indicates that the innermost 
  15772. enclosing class within which the pragma occurs is the class that will be the 
  15773. metaclass for the specified class. You should never use the asterisk in both 
  15774. positions at once; this may cause the program to enter an infinite loop when an 
  15775. object of the class is created.  In the following example, class Mountain is 
  15776. given a metaclass of Rock, and class Tree is given a metaclass of Plant: 
  15777.  
  15778.   class Mountain: public SOMObject { // ...
  15779.    #pragma SOMMetaClass(*,Rock)
  15780.   }
  15781.   class Plant: public SOMObject { // ...
  15782.    #pragma SOMMetaClass(Tree,*)
  15783.   }
  15784.   class Loop: public SOMObject { // ...
  15785.    #pragma SOMMetaClass(*,*) // Error - will loop infinitely
  15786.   }
  15787.  
  15788. In the version of the pragma that takes a SOM class name as the metaclass, the 
  15789. SOM class name must be enclosed in double quotation marks.  In the version that 
  15790. takes a C++ class name as the metaclass, the metaclass must not be enclosed in 
  15791. double quotation marks. 
  15792.  
  15793. In the absence of a SOMMetaClass pragma, the compiler operates as if SOMClass 
  15794. was specified as the metaclass. 
  15795.  
  15796. The compiler issues an error message if you use multiple inequivalent 
  15797. SOMMetaClass pragmas for a class. 
  15798.  
  15799.  
  15800. ΓòÉΓòÉΓòÉ 18.14.15. The SOMMethodAppend ΓòÉΓòÉΓòÉ
  15801.  
  15802. Use the SOMMethodAppend pragma to generate the IDL "context" and "raises" 
  15803. strings for methods.  The syntax of the pragma is: 
  15804.  
  15805. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15806. Γöé                                 Γöé
  15807. Γöé >>ΓöÇΓöÇ#pragma SOMMethodAppend(ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15808. Γöé                                 Γöé
  15809. Γöé >ΓöÇΓöÇC++FunctionPrototypeLessReturn,"string"ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15810. Γöé                                 Γöé
  15811. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15812.  
  15813. The contents of the string will be collected and emitted at the end of the IDL 
  15814. for the function.  The "context" information will be used for CORBA contexts 
  15815. and exceptions.  If the pragma is used more than once for a given method, the 
  15816. strings will be concatenated. 
  15817.  
  15818. The following example illustrates how this pragma is used.  Given: 
  15819.  
  15820.   class X : public SOMObject {
  15821.     void MyNewMethod(int, float);
  15822.     #pragma SOMNoMangling(*)
  15823.     #pragma SOMMethodAppend(MyNewMethod, "raises(\"this, that\")")
  15824.     #pragma SOMMethodAppend(MyNewMethod, "context(\"something\")")
  15825.   };
  15826. the following fragment of IDL will be produced: 
  15827.  
  15828.  void MyNewMethod(in long p__arg1, in float p__arg2)
  15829.   raises("this","that") context("something");
  15830.  
  15831.  
  15832. ΓòÉΓòÉΓòÉ 18.14.16. The SOMMethodName Pragma ΓòÉΓòÉΓòÉ
  15833.  
  15834. Use this pragma to specify SOM names for C++ methods and operators. You only 
  15835. need to use this pragma if you want access to the class of the applicable 
  15836. method from non-C++ programs.  If you do not use this pragma or the 
  15837. SOMNoMangling pragma, method names are mangled by the compiler, and the mangled 
  15838. names can lead to coding errors in the non-C++ programs that attempt to use 
  15839. them (because the names are obscure and typically very long). 
  15840.  
  15841. The syntax of the pragma is: 
  15842.  
  15843. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15844. Γöé                                 Γöé
  15845. Γöé >>ΓöÇΓöÇ#pragma SOMMethodName(ΓöÇΓöÇΓö¼ΓöÇCΓöîΓöÉPrototypeΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  15846. Γöé               ΓööΓöÇCΓööΓöÿFunctionNameΓöÇΓöÿ         Γöé
  15847. Γöé                                 Γöé
  15848. Γöé >ΓöÇΓöÇ"SomMethodName"ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15849. Γöé                                 Γöé
  15850. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15851.  
  15852. The C++Prototype is a C++ function prototype without the return type.  For 
  15853. example, the function double sqrt(double) would appear as sqrt(double) in this 
  15854. pragma. If the prototype has a trailing const, you must include this in the 
  15855. prototype. 
  15856.  
  15857. The C++FunctionName is an unambiguous C++ function name (one that is not 
  15858. overloaded within the class).  You do not include the function's signature.  If 
  15859. you use this version of the pragma for a function that has more than one 
  15860. overloaded version in a class, the compiler issues an error message. 
  15861.  
  15862. If you do not need to access the class from non-C++ programs, you do not need 
  15863. to use either SOMMethodName or SOMNoMangling for the class. 
  15864.  
  15865. Note:  These pragmas change the SOM name of a method.  As discussed in SOM and 
  15866. Upward Binary Compatibility of Libraries, renaming an item is equivalent to 
  15867. removing it and adding a new item with the same characteristics. If there is a 
  15868. possibility that you will access the class from non-C++ programs, use the 
  15869. SOMMethodName or SOMNoMangling pragmas in your initial implementation. 
  15870.  
  15871. You can use a combination of SOMMethodName and SOMNoMangling to give unmangled 
  15872. names to methods of a class that non-C++ programs will access.  The 
  15873. SOMNoMangling pragma (see The SOMNoMangling Pragma) specifies that the C++ name 
  15874. of a method becomes the SOM name of that method.  As long as the method is not 
  15875. an overloaded method or an operator other than the default assignment operator, 
  15876. SOMNoMangling makes the method accessible to non-C++ programs by its C++ name 
  15877. after folding all letters to lowercase. The following example shows a class 
  15878. declaration with a combination of SOMNoMangling and SOMMethodName pragmas: 
  15879.  
  15880.   #pragma SOMAsDefault(on)
  15881.   class Address {
  15882.    public:
  15883.      char* Street;
  15884.      int  Phone;
  15885.   #pragma SOMNoMangling(on)
  15886.      int  call();  // remains as call
  15887.      void  print(); // remains as print
  15888.   #pragma SOMNoMangling(pop)
  15889.      void  update(char* street);
  15890.   #pragma SOMMethodName(update(char),"updatestreet")
  15891.            // becomes updatestreet
  15892.      void  update(int phone);
  15893.   #pragma SOMMethodName(update(int),"updatephone")
  15894.            // becomes updatephone
  15895.   };
  15896. #pragma SOMAsDefault(pop)
  15897.  
  15898. The example uses SOMNoMangling to cause the C++ methods call and print to be 
  15899. given SOM names identical to their C++ method names.  The example then 
  15900. explicitly renames the different overloads of update using SOMMethodName, so 
  15901. that calls to those methods from non-C++ programs can be resolved. 
  15902.  
  15903. You should keep in mind that naming in SOM is not case sensitive, so any names 
  15904. you supply through SOMMethodName should be distinguishable from other names 
  15905. regardless of case.  In addition, the Common Object Request Broker Architecture 
  15906. (CORBA) requires that names begin with an alphabetic character.  If you use the 
  15907. SOMMethodName pragma on a method, make sure the SOM name starts with an 
  15908. alphabetic character. 
  15909.  
  15910. The requirements for the SOMMethodName pragma are: 
  15911.  
  15912.      The pragma must occur in the compilation unit that defines the class (the 
  15913.       compilation unit that contains a SOMDefine pragma or the first noninline 
  15914.       function for the class). 
  15915.  
  15916.      The method must already have been declared at the point where the pragma 
  15917.       is encountered. 
  15918.  
  15919.      The class must be a SOM class. 
  15920.  
  15921.      You cannot rename two method signatures in a class to the same name.  The 
  15922.       compiler issues an error if you attempt this. 
  15923.  
  15924.      The name of the member function within the SOMMethodName pragma must be 
  15925.       fully qualified if the pragma occurs outside of the class declaration. 
  15926.       For example, function clear() of class Buffer must be specified as 
  15927.       Buffer::clear(). 
  15928.  
  15929.      A method may only be renamed in conjunction with the class that 
  15930.       introduces it.  This means that you cannot rename a function func() in 
  15931.       subclass B of class A, if func() was introduced by A. 
  15932.  
  15933.      You cannot rename a method to _get_X() or _set_X(), where X is the name 
  15934.       of an attribute for that class.  For example, you cannot do the 
  15935.       following: 
  15936.  
  15937.               class MyClass : SOMObject {
  15938.                public:
  15939.                  int i;
  15940.                  int foo();
  15941.               #pragma SOMAttribute(i)
  15942.               #pragma SOMMethodName(foo(),"_get_i") // error
  15943.                };
  15944.  
  15945.       because the SOMAttribute pragma predefines a get and set method for i. 
  15946.       If i were a member of a base class of MyClass rather than of MyClass 
  15947.       itself, the above SOMMethodName pragma would work, but the compiler would 
  15948.       resolve all calls to _get_i()  by calling the get method of the base 
  15949.       class, rather than by calling foo(). 
  15950.  
  15951.  The compiler generates an error message if more than one version of an 
  15952.  overloaded SOM function is found and no SOMMethodName pragma has been used to 
  15953.  rename versions of the function. The error occurs whenever the compiler 
  15954.  detects a version of the function with a signature different from that of the 
  15955.  first instantiated version. The error refers to name clashes.  You can avoid 
  15956.  this error by using SOMMethodName before any overload of a function other than 
  15957.  the first is used. 
  15958.  
  15959.  Note that different instantiations of templates used as SOM classes may have 
  15960.  different names for a method, if SOMMethodName is used on the method for a 
  15961.  given instantiation of the template.  For example: 
  15962.  
  15963.     template class A<T> : public SOMObject {
  15964.      public:
  15965.        Print();
  15966.     };
  15967.     #pragma SOMMethodName(A<int>::Print,"PrintInt")
  15968.     #pragma SOMMethodName(A<char*>::Print,"PrintString")
  15969.  
  15970.  
  15971. ΓòÉΓòÉΓòÉ 18.14.16.1. SOMMethodName and Inheritance ΓòÉΓòÉΓòÉ
  15972.  
  15973. If you rename a method of a class using the SOMMethodName pragma, a method of a 
  15974. derived class, with the same method signature, has the same SOM method name as 
  15975. specified by the pragma. 
  15976.  
  15977.  
  15978. ΓòÉΓòÉΓòÉ 18.14.17. The SOMNoDataDirect Pragma ΓòÉΓòÉΓòÉ
  15979.  
  15980. Use this pragma to have the compiler use get/set methods for instance data 
  15981. access.  See set and get Methods for Attribute Class Members for further 
  15982. details. 
  15983.  
  15984. The syntax of the pragma is: 
  15985.  
  15986. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  15987. Γöé                                 Γöé
  15988. Γöé >>ΓöÇΓöÇ#pragma SOMNoDataDirect(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  15989. Γöé                Γö£ΓöÇonΓöÇΓöÇΓöñ              Γöé
  15990. Γöé                Γö£ΓöÇoffΓöÇΓöñ              Γöé
  15991. Γöé                ΓööΓöÇpopΓöÇΓöÿ              Γöé
  15992. Γöé                                 Γöé
  15993. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  15994.  
  15995. When this pragma is in effect, all public data members can be accessed by get 
  15996. and set methods only, except as specified below. When the pragma is not in 
  15997. effect, nonprivate data members can be accessed directly, or by the get and set 
  15998. methods. However, if a data member has #pragma SOMAttribute(nodata) set, the 
  15999. data member can only be accessed by the get and set methods. 
  16000.  
  16001. Direct access may be used by the following functions, regardless of the setting 
  16002. of this pragma: 
  16003.  
  16004.      Methods of the class (methods can access their own instance data directly 
  16005.       through the this pointer) 
  16006.      Methods of subclasses, again through the this pointer. 
  16007.  
  16008.  Friend classes and methods may use direct access if the pragma is explicitly 
  16009.  turned on within the class declaration (using #pragma SOMNoDataDirect(*)).  If 
  16010.  the pragma is turned on implicitly (using #pragma SOMNoDataDirect(on)), friend 
  16011.  classes and methods must use the get and set methods. 
  16012.  
  16013.  The asterisk (*) indicates that the pragma applies to the innermost enclosing 
  16014.  class within which the pragma occurs.  The asterisk version of the pragma 
  16015.  temporarily overrides any setting obtained by using the on, off, or pop 
  16016.  arguments for the pragma, but only for the class in which it occurs.  It has 
  16017.  no effect on nested classes. 
  16018.  
  16019.  The on, off, and pop arguments are not allowed within the scope of a class. 
  16020.  See Pragmas Containing on | off | pop for more information on how these 
  16021.  arguments are used. 
  16022.  
  16023.  The /Gb compiler option is equivalent to specifying #pragma 
  16024.  SOMNoDataDirect(on) at the beginning of the compilation unit. 
  16025.  
  16026.  If this pragma is in effect when an instance of a SOM class is used by client 
  16027.  code, all SOM object data accesses via pointer or reference (other than those 
  16028.  that use the this pointer) are done indirectly. SOM object data member 
  16029.  accesses done through local or global SOM objects may be done directly. 
  16030.  
  16031.  
  16032. ΓòÉΓòÉΓòÉ 18.14.18. The SOMNoMangling Pragma ΓòÉΓòÉΓòÉ
  16033.  
  16034. Use this pragma to tell the compiler not to mangle the C++ names of methods, 
  16035. static member functions, or instance data when creating SOM names or generating 
  16036. IDL. The syntax of the pragma is: 
  16037.  
  16038. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  16039. Γöé                                 Γöé
  16040. Γöé >>ΓöÇΓöÇ#pragma SOMNoMangling(ΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  16041. Γöé               Γö£ΓöÇonΓöÇΓöÇΓöñ               Γöé
  16042. Γöé               Γö£ΓöÇoffΓöÇΓöñ               Γöé
  16043. Γöé               ΓööΓöÇpopΓöÇΓöÿ               Γöé
  16044. Γöé                                 Γöé
  16045. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  16046.  
  16047. See Conventions Used by the SOM Pragmas for information on how to use the 
  16048. pragma's arguments.  Note that, when the asterisk (*) is used in the pragma, 
  16049. settings of the pragma via on, off, or pop are ignored, but only for the class 
  16050. in which the pragma appears with the asterisk.  This applies even if on, off, 
  16051. or pop are used within the class itself.  However, the asterisk version does 
  16052. not affect nested classes. 
  16053.  
  16054. When the pragma is in effect, the compiler does the following: 
  16055.  
  16056.      Generates lowercase versions of declared method names, with no mangling 
  16057.       applied.  This means that method names do not identify their arguments 
  16058.       and class. 
  16059.      Detects clashes of generated names within a class.  This means that two 
  16060.       overloaded versions of method f, for example f(int) and f(double), result 
  16061.       in a compiler error message.  To correct such a situation, you can use 
  16062.       the SOMMethodName pragma on all but one of the conflicting methods. 
  16063.  
  16064.  Note: 
  16065.  
  16066.    1. The pragma does not apply to compiler-generated functions, which continue 
  16067.       to use mangled names. 
  16068.  
  16069.    2. User-written member functions that begin with an underscore (except _get 
  16070.       and _set members) are always mangled. 
  16071.  
  16072.    3. It is an error to remap two different C++ signatures to the same SOM 
  16073.       name.  This can happen, for example, in a class with overloaded methods 
  16074.       where SOMNoMangling is in effect.  In such cases, you should use a 
  16075.       SOMMethodName pragma to rename all but one of the overloaded methods.  A 
  16076.       SOMMethodName pragma always takes precedence over a SOMNoMangling pragma. 
  16077.  
  16078.  The pragma only applies to methods introduced by a class, not to inherited 
  16079.  methods.  If SOMNoMangling is in effect when the compiler encounters a base 
  16080.  class, the methods of the base class will have unmangled names, as will 
  16081.  methods with the same signatures in any derived class, regardless of the state 
  16082.  of SOMNoMangling in the derived class. 
  16083.  
  16084.  In the following example, MyNewMethod receives a SOM name of mynewmethod, 
  16085.  rather than the mangled version VisualAge for C++ would normally generate: 
  16086.  
  16087.     #pragma SOMNoMangling(off)
  16088.     // ...
  16089.     class X : public SOMObject {
  16090.     #pragma SOMNoMangling(*) // overrides SOMNoMangling(off)
  16091.                 // for entire class
  16092.       // ...
  16093.       void MyNewMethod(int, float);
  16094.     };
  16095.  
  16096.  
  16097. ΓòÉΓòÉΓòÉ 18.14.19. The SOMNonDTS Pragma ΓòÉΓòÉΓòÉ
  16098.  
  16099. Important 
  16100.  
  16101. This pragma is not intended to be used by programmers. Do not use this pragma 
  16102. in your programs, or the results will be unpredictable. 
  16103.  
  16104. This pragma is automatically inserted in generated .hh files to inform the 
  16105. compiler that the class it applies to was originally a SOM class, and not a C++ 
  16106. class converted to a SOM class by the VisualAge for C++. 
  16107.  
  16108.  
  16109. ΓòÉΓòÉΓòÉ 18.14.20. The SOMReleaseOrder Pragma ΓòÉΓòÉΓòÉ
  16110.  
  16111. Use the SOMReleaseOrder pragma to make your SOM classes upward binary 
  16112. compatible (so that client programs can use newer versions of your library 
  16113. without having to recompile their source code each time you issue a new version 
  16114. of the library).  When you extend a class, you can only achieve binary 
  16115. compatibility for users of the class if any added functions or data members are 
  16116. placed at the end of the release order list specified in the pragma. See 
  16117. Release Order of SOM Objects if you want a better understanding of how release 
  16118. order is used to ensure upward binary compatibility. 
  16119.  
  16120. The syntax of the pragma is: 
  16121.  
  16122. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  16123. Γöé                                 Γöé
  16124. Γöé >>ΓöÇΓöÇpragma SOMReleaseOrder(ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ> Γöé
  16125. Γöé                                 Γöé
  16126. Γöé   ΓöîΓöÇ,ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ        Γöé
  16127. Γöé                         Γöé        Γöé
  16128. Γöé >ΓöÇΓöÇΓöÇΓö¼ΓöÇ*ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö┤ΓöÇΓöÇ)ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  16129. Γöé   Γö£ΓöÇStaticDataMemberΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ         Γöé
  16130. Γöé   ΓööΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓö¼ΓöÇAttributeΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÿ         Γöé
  16131. Γöé    ΓööΓöÇ ! ΓöÇΓöÿ  Γö£ΓöÇCΓöîΓöÉMemberFunctionPrototypeΓöÇΓöñ          Γöé
  16132. Γöé         Γö£ΓöÇCΓööΓöÿUnambiguousFunctionNameΓöÇΓöñ          Γöé
  16133. Γöé         ΓööΓöÇ"SOMMethodName"ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ          Γöé
  16134. Γöé                                 Γöé
  16135. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  16136.  
  16137. The pragma must appear within the body of the class declaration. It contains a 
  16138. comma-separated list of release order elements. A release order element may be 
  16139. any of the following: 
  16140.  
  16141.      An asterisk (*).  The asterisk reserves a slot in the release order so 
  16142.       that you can later add a member function or data member at that position 
  16143.       in the list, without requiring client programs to be recompiled. You can 
  16144.       also reserve slots for things like private members that you do not want 
  16145.       to expose to client code. 
  16146.  
  16147.      An attribute.  This uses two slots in the release order, one for the 
  16148.       attribute's get method, and one for its set method.  Both slots are used 
  16149.       even for const data members, which do not have a set method, so that you 
  16150.       can later change the method to non-const without breaking binary 
  16151.       compatibility. Regardless of whether you define get and set methods or 
  16152.       let the compiler generate them for you, you can place either the data 
  16153.       member name, or the get and set method names, in the release order. (You 
  16154.       cannot specify both the data member name and the set and get methods.) 
  16155.       For new classes, you should use the data member name, for the sake of 
  16156.       code readability and to ensure that the get and set methods for an 
  16157.       attribute are always consecutive in the release order. For older SOM 
  16158.       classes where you did not allocate consecutive slots for the get and set 
  16159.       methods in the class's release order, you must continue to specify each 
  16160.       method separately in the correct order. 
  16161.  
  16162.      A static data member name.  This uses one slot, for a pointer to the 
  16163.       static data member. 
  16164.  
  16165.      A C++ member function prototype, excluding the return type. This uses one 
  16166.       slot, for a pointer to the function. See below for information on the use 
  16167.       of the exclamation point (!). Note that if the function is not overloaded 
  16168.       within the class you can use the unambiguous function name (see below). 
  16169.  
  16170.      An unambiguous function name (one that is not overloaded by the class in 
  16171.       question or any of its bases). 
  16172.  
  16173.      A SOM method name, enclosed in quotation marks.  This is equivalent to 
  16174.       specifying the C++ member function name, except that you must specify the 
  16175.       simple SOM method name without specifying argument types.  See below for 
  16176.       information on the use of the exclamation point. 
  16177.  
  16178.  
  16179. ΓòÉΓòÉΓòÉ 18.14.20.1. Elements Preceded by ! ΓòÉΓòÉΓòÉ
  16180.  
  16181. Release order elements preceded by an exclamation point (!) let you assert that 
  16182. a member function is to have a slot reserved for it even if the member function 
  16183. was inherited from a base class.  The "!" helps the compiler diagnose 
  16184. unexpected base class evolutions.  This can occur when a base class later 
  16185. introduces a virtual method whose signature matches one that is currently 
  16186. introduced by this class.  If the method is found in the class's release order 
  16187. without the "!", the compiler issues an error message. If you precede the 
  16188. method with "!", you are asserting to the compiler that you are aware of the 
  16189. method's having moved upward in the inheritance structure.  VisualAge for C++ 
  16190. preserves binary compatibility in such situations, if you use the "!". 
  16191.  
  16192. The following examples show two versions of a class hierarchy. In the first 
  16193. version, method aMethod() is a member of class Derived: 
  16194.  
  16195.   class Base : public SOMObject {
  16196.     };
  16197.  
  16198.   class Derived : public Base {
  16199.     public:
  16200.      void aMethod();
  16201.     #pragma SOMReleaseOrder(aMethod())
  16202.     };
  16203.  
  16204. This version compiles successfully, because aMethod() is found in the release 
  16205. order of the class that introduced it. Later, a version of aMethod() is added 
  16206. to Base: 
  16207.  
  16208.   class Base : public SOMObject {
  16209.    public:
  16210.      virtual void aMethod();
  16211.     };
  16212.  
  16213.   class Derived : public Base {
  16214.     public:
  16215.      void aMethod();
  16216.     #pragma SOMReleaseOrder(aMethod())
  16217.     };
  16218.  
  16219. A compilation error occurs for this version, because the release order for 
  16220. class Derived contains a method that is no longer introduced by the class (it 
  16221. is now introduced by Base). The compiler considers this an error because the 
  16222. SOMReleaseOrder pragma does not make the inheritance of aMethod() from class 
  16223. Base explicit.  To solve this problem, change the release order pragma to: 
  16224.  
  16225.   #pragma SOMReleaseOrder(!aMethod())
  16226.  
  16227. This informs the compiler that the programmer coding class Derived is aware of 
  16228. the addition of aMethod() to class Base.  The program then compiles 
  16229. successfully. 
  16230.  
  16231.  
  16232. ΓòÉΓòÉΓòÉ 18.14.20.2. Other Requirements ΓòÉΓòÉΓòÉ
  16233.  
  16234. This pragma may only appear within the body of the corresponding class 
  16235. definition.  Only one such pragma is allowed per class.  If you do not provide 
  16236. a release order, the compiler will assume a release order matching the order of 
  16237. declaration within the class body.  Although you can avoid having to specify a 
  16238. release order by always placing new methods and data members below existing 
  16239. ones in the private and protected/public sections of the class definition, use 
  16240. of the SOMReleaseOrder  pragma is strongly recommended for accuracy and code 
  16241. readability. 
  16242.  
  16243. Items in the release order list must have been declared prior to the pragma, 
  16244. and must appear only once in the list. 
  16245.  
  16246. If a SOMReleaseOrder pragma is given for a class, it must list all the methods 
  16247. and data members introduced by that class. (Compiler-generated methods, such as 
  16248. the four default assignment operators that the compiler provides if you do not 
  16249. define any, must also be listed, if you want to take their address.) The 
  16250. compiler issues a warning message when it encounters a partial list. 
  16251.  
  16252. You can use the /Fr option to have the compiler generate a #pragma 
  16253. SOMReleaseOrder for a class. The release order includes compiler-defined 
  16254. methods.  By default the compiler places methods it generates at the end of the 
  16255. release order. For further details see The SOMReleaseOrder Pragma. 
  16256.  
  16257.  
  16258. ΓòÉΓòÉΓòÉ 18.14.20.3. Templates and Release Orders ΓòÉΓòÉΓòÉ
  16259.  
  16260. Because the SOMReleaseOrder pragma must occur within the declaration for a 
  16261. class, you cannot declare different release orders for different instantiations 
  16262. of a template class.  If you rename methods of a template instantiation using 
  16263. SOMMethodName, you must still indicate the original C++ name of each method in 
  16264. the release order within the template class.  If you want to provide two 
  16265. different release orders for different instantiations of a template, you must 
  16266. make one of the classes a subclass of the template. You can then declare a 
  16267. different release order for that class, using the "!" to indicate your 
  16268. awareness that member functions are derived from a base class. 
  16269.  
  16270.  
  16271. ΓòÉΓòÉΓòÉ 19. ANSI Notes on Implementation-Defined Behavior ΓòÉΓòÉΓòÉ
  16272.  
  16273. The VisualAge for C++ product supports the requirements of the American 
  16274. National Standard for Information Systems / International Standards 
  16275. Organization - Programming Language C standard, ANSI/ISO 9899-1990[1992]. It 
  16276. also supports the IBM SAA C standards as documented in the Language Reference. 
  16277.  
  16278. As yet, there is no ANSI/ISO standard for the C++ language. However, an ISO 
  16279. committee is currently working on such a definition. The Working Paper for 
  16280. Draft Proposed American National Standard for Information Systems - Programming 
  16281. Language C++, ANSI X3J16/95-0001, is the base document for ongoing 
  16282. standardization of the language. The VisualAge for C++ compiler continues to 
  16283. implement extensions and clarifications of the language as they become 
  16284. available. This appendix describes how VisualAge for C++ behaves where the ANSI 
  16285. C Standard describes behavior as implementation-defined. These behaviors can 
  16286. affect your writing of portable code. 
  16287.  
  16288.  
  16289. ΓòÉΓòÉΓòÉ 19.1. Implementation-Defined Behavior Common to Both C and C++ ΓòÉΓòÉΓòÉ
  16290.  
  16291. The following sections describe how the VisualAge for C++ product defines the 
  16292. behavior classified as implementation-defined in the ANSI C Standard. 
  16293.  
  16294.      Identifiers 
  16295.      Characters 
  16296.      Strings 
  16297.      Integers 
  16298.      Floating-Point Values 
  16299.      Arrays and Pointers 
  16300.      Registers 
  16301.      Qualifiers 
  16302.      Declarators 
  16303.      Statements 
  16304.      Preprocessor Directives 
  16305.      Library Functions 
  16306.      Error Handling 
  16307.      Signals 
  16308.      Translation Limits 
  16309.      Streams and Files 
  16310.      Memory Management 
  16311.      Environment 
  16312.      Localization 
  16313.      Time 
  16314.  
  16315.  
  16316. ΓòÉΓòÉΓòÉ 19.1.1. Identifiers ΓòÉΓòÉΓòÉ
  16317.  
  16318.      The number of significant characters in an identifier with no external 
  16319.       linkage is 255. 
  16320.  
  16321.      The number of significant characters in an identifier with external 
  16322.       linkage is 255. 
  16323.  
  16324.      The VisualAge for C++ compiler truncates all external names to 255 
  16325.       characters. This 255 limit includes any characters prepended by the 
  16326.       compiler to the name to designate linkage. 
  16327.  
  16328.      Case sensitivity: the case of identifiers is respected unless you link 
  16329.       using the /IGNORECASE option of ILINK. 
  16330.  
  16331.  
  16332. ΓòÉΓòÉΓòÉ 19.1.2. Characters ΓòÉΓòÉΓòÉ
  16333.  
  16334.      A character is represented by 8 bits, as defined by the CHAR_BIT macro in 
  16335.       <limits.h>. 
  16336.  
  16337.      The same code page is used for the source and execution set. (Source 
  16338.       characters and strings do not need to be mapped to the execution 
  16339.       character set.) 
  16340.  
  16341.      When an integer character constant contains a character or escape 
  16342.       sequence that is not represented in the basic execution character set, 
  16343.       the char is assigned the character after the backslash, and a warning is 
  16344.       issued. For example, '\q' is interpreted as the character 'q'. 
  16345.  
  16346.      When a wide character constant contains a character or escape sequence 
  16347.       that is not represented in the extended execution character set, the 
  16348.       wchar_t is assigned the character after the backslash, and a warning is 
  16349.       issued. 
  16350.  
  16351.      When an integer character constant contains more than one character, the 
  16352.       last 4 bytes represent the character constant. 
  16353.  
  16354.      When a wide character constant contains more than one multibyte 
  16355.       character, the last wchar_t value represents the character constant. 
  16356.  
  16357.      The default behavior for char is unsigned. 
  16358.  
  16359.      Any sequential spaces in your source program are interpreted as one 
  16360.       space. 
  16361.  
  16362.      All spaces are retained for the listing file. 
  16363.  
  16364.  
  16365. ΓòÉΓòÉΓòÉ 19.1.3. Strings ΓòÉΓòÉΓòÉ
  16366.  
  16367.      VisualAge for C++ compiler provides the following additional sequence 
  16368.       forms for strtod, strtol, and strtoul functions in locales other than the 
  16369.       C locale: 
  16370.  
  16371.                inf     infinity     nan
  16372.  
  16373.       All of these sequences are not case sensitive. 
  16374.  
  16375.      When you use DBCS (with the /Sn compiler option), a hexadecimal character 
  16376.       that is a valid first byte of a double-byte character is treated as a 
  16377.       double-byte character inside a string. A 0 is appended to the character 
  16378.       that ends the string. Double-byte characters in strings must appear in 
  16379.       pairs. 
  16380.  
  16381.  
  16382. ΓòÉΓòÉΓòÉ 19.1.4. Integers ΓòÉΓòÉΓòÉ
  16383.  
  16384. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  16385. Γöé Table 10. Integer Storage and Range     Γöé
  16386. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16387. Γöé Type       Γöé Amount  Γöé Range (in   Γöé
  16388. Γöé         Γöé of    Γöé <LIMITS.H>)  Γöé
  16389. Γöé         Γöé Storage  Γöé        Γöé
  16390. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16391. Γöé signed short   Γöé 2 bytes  Γöé -32768 to   Γöé
  16392. Γöé         Γöé      Γöé 32767     Γöé
  16393. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16394. Γöé unsigned short  Γöé 2 bytes  Γöé 0 to 65535   Γöé
  16395. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16396. Γöé signed int    Γöé 4 bytes  Γöé -2147483648  Γöé
  16397. Γöé         Γöé      Γöé to 2147483647 Γöé
  16398. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16399. Γöé unsigned int   Γöé 4 bytes  Γöé 0 to      Γöé
  16400. Γöé         Γöé      Γöé 4294967295   Γöé
  16401. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16402. Γöé signed long   Γöé 4 bytes  Γöé -2147483648  Γöé
  16403. Γöé         Γöé      Γöé to 2147483647 Γöé
  16404. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16405. Γöé unsigned long  Γöé 4 bytes  Γöé 0 to      Γöé
  16406. Γöé         Γöé      Γöé 4294967295   Γöé
  16407. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16408. Γöé NOTE:  Do not use the values in this table Γöé
  16409. Γöé as numbers in a source program.  Use the  Γöé
  16410. Γöé macros defined in <LIMITS.H> to represent  Γöé
  16411. Γöé these values.                Γöé
  16412. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  16413.  
  16414.      When you convert an integer to a signed char, the least-significant byte 
  16415.       of the integer represents the char. 
  16416.  
  16417.      When you convert an integer to a short signed integer, the 
  16418.       least-significant 2 bytes of the integer represents the short int. 
  16419.  
  16420.      When you convert an unsigned integer to a signed integer of equal length, 
  16421.       if the value cannot be represented, the magnitude is preserved and the 
  16422.       sign is not. 
  16423.  
  16424.      When bitwise operations (OR, AND, XOR) are performed on a signed int, the 
  16425.       representation is treated as a bit pattern. 
  16426.  
  16427.      The remainder of integer division is negative if exactly one operand is 
  16428.       negative. 
  16429.  
  16430.      When either operand of the divide operator is negative, the result is 
  16431.       truncated to the integer value and the sign will be negative. 
  16432.  
  16433.      The result of a bitwise right shift of a negative signed integral type is 
  16434.       sign extended. 
  16435.  
  16436.      The result of a bitwise right shift of a non-negative signed integral 
  16437.       type or an unsigned integral type is the same as the type of the left 
  16438.       operand. 
  16439.  
  16440.  
  16441. ΓòÉΓòÉΓòÉ 19.1.5. Floating-Point Values ΓòÉΓòÉΓòÉ
  16442.  
  16443. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  16444. Γöé Table 11. Floating Point            Γöé
  16445. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16446. Γöé Type   Γöé Amount of  Γöé Range of Exponents   Γöé
  16447. Γöé      Γöé Storage   Γöé (base 10) (in      Γöé
  16448. Γöé      Γöé       Γöé <FLOAT.H>)       Γöé
  16449. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16450. Γöé "float"  Γöé 4 bytes   Γöé "-37" to "38"      Γöé
  16451. Γöé (IEEE   Γöé       Γöé             Γöé
  16452. Γöé 32-bit)  Γöé       Γöé             Γöé
  16453. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16454. Γöé "double" Γöé 8 bytes   Γöé "-307" to "308"     Γöé
  16455. Γöé (IEEE   Γöé       Γöé             Γöé
  16456. Γöé 64-bit)  Γöé       Γöé             Γöé
  16457. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  16458. Γöé "long   Γöé 16 bytes  Γöé "-4931" to "4932"    Γöé
  16459. Γöé double"  Γöé       Γöé             Γöé
  16460. Γöé (IEEE   Γöé       Γöé             Γöé
  16461. Γöé 80-bit)  Γöé       Γöé             Γöé
  16462. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  16463.  
  16464.      When an integral number is converted to a floating-point number that 
  16465.       cannot exactly represent the original value, it is truncated to the 
  16466.       nearest representable value. 
  16467.  
  16468.      When a floating-point number is converted to a narrower floating-point 
  16469.       number, it is rounded to the nearest representable value. 
  16470.  
  16471.  
  16472. ΓòÉΓòÉΓòÉ 19.1.6. Arrays and Pointers ΓòÉΓòÉΓòÉ
  16473.  
  16474.      The type of the integer required to hold the maximum size of an array 
  16475.       (the type of the sizeof operator, size_t) is unsigned int. 
  16476.  
  16477.      The type of the integer required to hold the difference between two 
  16478.       pointers to elements of the same array (ptrdiff_t) is int. 
  16479.  
  16480.      When you cast a pointer to an integer or an integer to a pointer, the bit 
  16481.       patterns are preserved. 
  16482.  
  16483.  
  16484. ΓòÉΓòÉΓòÉ 19.1.7. Registers ΓòÉΓòÉΓòÉ
  16485.  
  16486.      The VisualAge for C++ compiler optimizes register use and does not 
  16487.       respect the register storage class specifier. 
  16488.  
  16489.      In C programs, you cannot take the address of an object with a register 
  16490.       storage class. This restriction does not apply to C++ programs. 
  16491.  
  16492.  
  16493. ΓòÉΓòÉΓòÉ 19.1.8. Structures, Unions, Enumerations, Bit-Fields ΓòÉΓòÉΓòÉ
  16494.  
  16495.      If a member of a union object is accessed using a member of a different 
  16496.       type, the result is undefined. 
  16497.  
  16498.      If a structure is not packed, padding is added to align the structure 
  16499.       members on their natural boundaries and to end the structure on its 
  16500.       natural boundary. The alignment of the structure or union is that of its 
  16501.       strictest member. If the length of the structure is greater than a 
  16502.       doubleword, the structure is doubleword-aligned.  The alignment of the 
  16503.       individual members is not changed. Packed structures are not padded. See 
  16504.       Mapping for more information. 
  16505.  
  16506.      The default type of an integer bit field is unsigned int. 
  16507.  
  16508.      Bit fields are allocated from low memory to high memory, and the bytes 
  16509.       are reversed. For more information, see Mapping. 
  16510.  
  16511.      Bit fields can cross storage unit boundaries. 
  16512.  
  16513.      The maximum bit field length is 32 bits. If a series of bit fields does 
  16514.       not add up to the size of an int, padding may take place. 
  16515.  
  16516.      A bit field cannot have type long double. 
  16517.  
  16518.      The expression that defines the value of an enumeration constant cannot 
  16519.       have type long double. 
  16520.  
  16521.      An enumeration can have the type char, short, or long and be either 
  16522.       signed or unsigned, depending on its smallest and largest values. 
  16523.  
  16524.       In C++, enumerations are a distinct type, and although they may be the 
  16525.       same size as a data type such as char, they are not considered to be of 
  16526.       that type. 
  16527.  
  16528.  
  16529. ΓòÉΓòÉΓòÉ 19.1.9. Qualifiers ΓòÉΓòÉΓòÉ
  16530.  
  16531.      All access to an object that has a type that is qualified as volatile is 
  16532.       retained. 
  16533.  
  16534.  
  16535. ΓòÉΓòÉΓòÉ 19.1.10. Declarators ΓòÉΓòÉΓòÉ
  16536.  
  16537.      There is no VisualAge for C++ limit for the maximum number of declarators 
  16538.       (pointer, array, function) that can modify an arithmetic, structure, or 
  16539.       union type. The only constraint is your system resources. 
  16540.  
  16541.  
  16542. ΓòÉΓòÉΓòÉ 19.1.11. Statements ΓòÉΓòÉΓòÉ
  16543.  
  16544.      Because the case values must be integers and cannot be duplicated, the 
  16545.       maximum number of case values in a switch statement is 4294967296. 
  16546.  
  16547.  
  16548. ΓòÉΓòÉΓòÉ 19.1.12. Preprocessor Directives ΓòÉΓòÉΓòÉ
  16549.  
  16550.      The value of a single-character constant in a constant expression that 
  16551.       controls conditional inclusion matches the value of the character 
  16552.       constant in the execution character set. 
  16553.  
  16554.      Such a constant can have a negative value. 
  16555.  
  16556.      For the method of searching system include source files (specified within 
  16557.       angle brackets) see the User's Guide. 
  16558.  
  16559.      User include files can be specified in double quotation marks, for 
  16560.       example "myheader.h".  For the method of searching user include files, 
  16561.       see the User's Guide. 
  16562.  
  16563.      For the mapping between the name specified in the include directive and 
  16564.       the external source file name, see the User's Guide. 
  16565.  
  16566.      For the behavior of each #pragma directive, see the online or hardcopy 
  16567.       Language Reference. 
  16568.  
  16569.      The __DATE__ and __TIME__ macros are always defined as the system date 
  16570.       and time. 
  16571.  
  16572.  
  16573. ΓòÉΓòÉΓòÉ 19.1.13. Library Functions ΓòÉΓòÉΓòÉ
  16574.  
  16575.      In extended mode (the default) and for all C++ programs, the NULL macro 
  16576.       is defined to be 0.  For all other language levels, NULL is defined to 
  16577.       be:  ((void *)0). 
  16578.  
  16579.      When assert is executed, if the expression is false, the diagnostic 
  16580.       message written by the assert macro has the format: 
  16581.  
  16582.              Assertion failed:  expression, file file_name, line line_number
  16583.  
  16584.      To create a table of the characters set up by the CTYPE functions, use 
  16585.       the program in C Program to Print out CTYPE Characters.  The columns are 
  16586.       organized by function as follows: 
  16587.  
  16588.       (Column 1)         The hexadecimal value of the character 
  16589.       AN                 isalnum 
  16590.       A                  isalpha 
  16591.       C                  iscntrl 
  16592.       D                  isdigit 
  16593.       G                  isgraph 
  16594.       L                  islower 
  16595.       (Column 8)         isprint 
  16596.       PU                 ispunct 
  16597.       S                  isspace 
  16598.       PR                 isprint 
  16599.       U                  isupper 
  16600.       X                  isxdigit 
  16601.  
  16602.      The value returned by all math functions after a domain error (EDOM) is a 
  16603.       NaN. 
  16604.  
  16605.      The value errno is set to on underflow range errors is ERANGE. 
  16606.  
  16607.      If you call the fmod function with 0 as the second argument, fmod returns 
  16608.       0 and a domain error. 
  16609.  
  16610.  
  16611.   C Program to Print out CTYPE Characters
  16612.  
  16613.   #include <stdio.h>
  16614.   #include <ctype.h>
  16615.  
  16616.   int main(void)
  16617.   {
  16618.     int ch;
  16619.  
  16620.     for (ch = 0; ch <= 0xff; ch++)
  16621.      {
  16622.      printf("%#04X ", ch);
  16623.      printf("%3s ", isalnum(ch)  ? "AN" : " ");
  16624.      printf("%2s ", isalpha(ch)  ? "A"  : " ");
  16625.      printf("%2s",  iscntrl(ch)  ? "C"  : " ");
  16626.      printf("%2s",  isdigit(ch)  ? "D"  : " ");
  16627.      printf("%2s",  isgraph(ch)  ? "G"  : " ");
  16628.      printf("%2s",  islower(ch)  ? "L"  : " ");
  16629.      printf("%c",  isprint(ch)  ? ch  : ' ');
  16630.      printf("%3s",  ispunct(ch)  ? "PU" : " ");
  16631.      printf("%2s",  isspace(ch)  ? "S"  : " ");
  16632.      printf("%3s",  isprint(ch)  ? "PR" : " ");
  16633.      printf("%2s",  isupper(ch)  ? "U"  : " ");
  16634.      printf("%2s",  isxdigit(ch) ? "X"  : " ");
  16635.  
  16636.      putchar('\n');
  16637.      }
  16638.      return 0;
  16639.   }
  16640.  
  16641.  
  16642. ΓòÉΓòÉΓòÉ 19.1.14. Error Handling ΓòÉΓòÉΓòÉ
  16643.  
  16644.      See the online Language Reference for a list of the runtime messages 
  16645.       generated for perror and strerror. Note that the value of errno is not 
  16646.       generated with the message. 
  16647.  
  16648.      See the online Language Reference for the lists of the messages provided 
  16649.       with VisualAge for C++ compiler. 
  16650.  
  16651.      Messages are classified as shown by the following table: 
  16652.  
  16653.       Type of Message        Return Code :*. 
  16654.  
  16655.       Information            0 
  16656.  
  16657.       Warning                0 
  16658.  
  16659.       Error                  12 
  16660.  
  16661.       Severe error           16 or 20 or 99 
  16662.  
  16663.      Use the /Wn compile-time option to control the level of messages 
  16664.       generated.  There is also a /Wgrp compiler option that provides 
  16665.       programming-style diagnostics to aid you in determining possible 
  16666.       programming errors. See the User's Guide for further information on this 
  16667.       compiler option. 
  16668.  
  16669.  
  16670. ΓòÉΓòÉΓòÉ 19.1.15. Signals ΓòÉΓòÉΓòÉ
  16671.  
  16672.      The set of signals for the signal function and the parameters and usage 
  16673.       of each signal are described in Signal and Windows Exception Handling and 
  16674.       in the C Library Reference under signal. 
  16675.  
  16676.      SIG_DFL is the default signal, and the default action taken is 
  16677.       termination. 
  16678.  
  16679.      If the equivalent of signal(sig, SIG_DFL); is not executed at the 
  16680.       beginning of signal handler, no signal blocking is performed. 
  16681.  
  16682.      Whenever you leave a signal handler, it is reset to SIG_DFL. 
  16683.  
  16684.  
  16685. ΓòÉΓòÉΓòÉ 19.1.16. Translation Limits ΓòÉΓòÉΓòÉ
  16686.  
  16687. The VisualAge for C++ compiler can translate and compile programs with the 
  16688. following limits: 
  16689.  
  16690.  Nesting levels of: 
  16691.  
  16692.    Compound statements                        No limit 
  16693.  
  16694.    Iteration control                          No limit 
  16695.  
  16696.    Selection control                          No limit 
  16697.  
  16698.    Conditional inclusion                      No limit 
  16699.  
  16700.    Parenthesized declarators                  No limit 
  16701.  
  16702.    Parenthesized expression                   No limit 
  16703.  
  16704.  Number of pointer, array and function declarators modifying an arithmetic, a 
  16705.  structure, a union, and incomplete type declaration No limit 
  16706.  
  16707.  Significant initial characters in: 
  16708.  
  16709.    Internal identifiers                       255 
  16710.  
  16711.    Macro names                                No limit 
  16712.  
  16713.    External identifiers                       255 
  16714.  
  16715.  Number of: 
  16716.  
  16717.    External identifiers in a translation unit    1024 
  16718.  
  16719.    Identifiers with block scope in one block     No limit 
  16720.  
  16721.    Macro identifiers simultaneously declared in a translation unit No limit 
  16722.  
  16723.    Parameters in one function definition         255 
  16724.  
  16725.    Arguments in a function call                  255 
  16726.  
  16727.    Parameters in a macro definition              No limit 
  16728.  
  16729.    Parameters in a macro invocation              No limit 
  16730.  
  16731.    Characters in a logical source line           No limit 
  16732.  
  16733.    Characters in a string literal                No limit 
  16734.  
  16735.    Size of an object (in bytes)                  LONG_MAX 
  16736.  
  16737.    Nested #include files                         127(C),255(C++) 
  16738.  
  16739.    Levels in nested structure or union           No limit 
  16740.  
  16741.    Enumeration constants in an enumeration       4294967296 distinct values 
  16742.  
  16743.  
  16744. ΓòÉΓòÉΓòÉ 19.1.17. Streams and Files ΓòÉΓòÉΓòÉ
  16745.  
  16746.      The last line of a text stream does not require a terminating new-line 
  16747.       character. 
  16748.  
  16749.      Space characters that are written out to a text stream immediately before 
  16750.       a new-line character appear when read. 
  16751.  
  16752.      If Ctrl-Z is found and all remaining source characters to end-of-file are 
  16753.       whitespace, Ctrl-Z is silently ignored.  Subsequent Cntrl-Z's are 
  16754.       considered to be whitespace in this case. 
  16755.  
  16756.       If Ctrl-Z is found ina string or Lstring, it is taken to be part of the 
  16757.       string. 
  16758.  
  16759.       Any other Ctrl-Z is an illegal charater.  An error message is printed and 
  16760.       the character is ignored. 
  16761.  
  16762.      There is no limit to the number of null characters that can be appended 
  16763.       to the end of a binary stream. 
  16764.  
  16765.      The file position indicator of an append mode stream is positioned at the 
  16766.       end of the file. 
  16767.  
  16768.      When a file is opened in write mode, the file is truncated. If the file 
  16769.       does not exist, it is created. 
  16770.  
  16771.      A file of zero length does exist. 
  16772.  
  16773.      For the rules for composing a valid file name, refer to the documentation 
  16774.       for the Windows operating system. 
  16775.  
  16776.      For reading, the same file can be simultaneously opened multiple times; 
  16777.       for writing or appending, the file can be opened only once. 
  16778.  
  16779.      When the remove function is used on an open file, remove fails. 
  16780.  
  16781.      When you use the rename function to rename a file to a name that exists 
  16782.       prior to the function call, rename fails. 
  16783.  
  16784.      Temporary files may not be removed if the program terminates abnormally. 
  16785.  
  16786.      When the tmpnam function is called more than TMP_MAX times, tmpnam fails 
  16787.       and returns NULL, and sets errno to ENOGEN. 
  16788.  
  16789.      The output of %p conversion in the fprintf function is equivalent to %x. 
  16790.  
  16791.      The input of %p conversion in the fscanf function is the same as is 
  16792.       expected for %x. 
  16793.  
  16794.      A '-' character that is neither the first nor the last character in the 
  16795.       fscanf scan list (%[characters]) is considered to be part of the scan 
  16796.       list. 
  16797.  
  16798.      The possible values of errno on failure of fgetpos are EERRSET, ENOSEEK, 
  16799.       and EBADPOS. 
  16800.  
  16801.      The possible values of errno on failure of ftell are EERRSET, ENOSEEK, 
  16802.       EBADPOS, and ENULLFCB. 
  16803.  
  16804.  
  16805. ΓòÉΓòÉΓòÉ 19.1.18. Memory Management ΓòÉΓòÉΓòÉ
  16806.  
  16807.      If the size requested is 0, the calloc, malloc, and realloc functions all 
  16808.       return a NULL pointer. In the case of realloc, the pointer passed to the 
  16809.       function is also freed. 
  16810.  
  16811.  
  16812. ΓòÉΓòÉΓòÉ 19.1.19. Environment ΓòÉΓòÉΓòÉ
  16813.  
  16814.      You can pass arguments to main through argv, argc, and envp. 
  16815.  
  16816.      If a standard stream is redirected to a file, the stream is fully 
  16817.       buffered, with the exception of stderr, which is line buffered.  If the 
  16818.       standard stream is attached to a character device, it is line buffered. 
  16819.  
  16820.      When the abort function is called, all open files are closed by the 
  16821.       operating system.  The buffers are not flushed.  Any memory files 
  16822.       belonging to the process are discarded. 
  16823.  
  16824.      When the abort function is called, the return code of 3 is returned to 
  16825.       the host environment. 
  16826.  
  16827.      When a program ends successfully and calls the exit function with the 
  16828.       argument 0 or EXIT_SUCCESS, all buffers are flushed, all files are 
  16829.       closed, all storage is released, and the argument is returned. 
  16830.  
  16831.      When a program ends unsuccessfully and calls the exit function with the 
  16832.       argument EXIT_FAILURE, all buffers are flushed, all files are closed, all 
  16833.       storage is released, and the argument is returned. 
  16834.  
  16835.      If the argument passed to the exit function is other than 0, EXIT_FAILURE 
  16836.       or EXIT_SUCCESS, all buffers are flushed, all files are closed, all 
  16837.       storage is released, and the argument is returned. 
  16838.  
  16839.      For the set of environmental names, see Setting Runtime Environment 
  16840.       Variables and the User's Guide. 
  16841.  
  16842.      For the method of altering the environment list obtained by a call to the 
  16843.       getenv function, see the putenv function in the C Library Reference. 
  16844.  
  16845.      For the format and mode of execution of a string on a call to the system 
  16846.       function, see the C Library Reference under system. 
  16847.  
  16848.  
  16849. ΓòÉΓòÉΓòÉ 19.1.20. Localization ΓòÉΓòÉΓòÉ
  16850.  
  16851.      A call to setlocale(LC_ALL, "") sets the environment to the C default 
  16852.       locale. 
  16853.  
  16854.  
  16855. ΓòÉΓòÉΓòÉ 19.1.21. Time ΓòÉΓòÉΓòÉ
  16856.  
  16857.      The local time zone and daylight saving time zone are EST and EDT. See 
  16858.       Setting Runtime Environment Variables and the tzset function in the C 
  16859.       Library Reference for more information on specifying the time zone. 
  16860.  
  16861.      The era for the clock function starts when the program is started by 
  16862.       either a call from the operating system or a call to system. 
  16863.  
  16864.  
  16865. ΓòÉΓòÉΓòÉ 19.2. C++-Specific Implementation-Defined Behavior ΓòÉΓòÉΓòÉ
  16866.  
  16867. The following sections describe how the VisualAge for C++ product defines the 
  16868. behavior classified as implementation-defined in the ANSI C++ Working Paper. 
  16869.  
  16870.  
  16871. ΓòÉΓòÉΓòÉ 19.2.1. Classes, Structures, Unions, Enumerations, Bit Fields ΓòÉΓòÉΓòÉ
  16872.  
  16873.      Class members are allocated in the order declared; access specifiers have 
  16874.       no effect on the order of allocation. 
  16875.  
  16876.      Padding is added to align class members on their natural boundaries and 
  16877.       to end the class on its natural boundary. 
  16878.  
  16879.      An int bit field behaves as an unsigned int for function overloading. 
  16880.  
  16881.  
  16882. ΓòÉΓòÉΓòÉ 19.2.2. Linkage Specifications ΓòÉΓòÉΓòÉ
  16883.  
  16884.      The valid values for the string literal in a linkage specification are: 
  16885.  
  16886.       "C++"          Default 
  16887.  
  16888.       "C"            C language linkage 
  16889.  
  16890.       BUILTIN        builtin linkage 
  16891.  
  16892.       SYSTEM         system linkage 
  16893.  
  16894.       CDECL          Win32 cdecl linkage 
  16895.  
  16896.       STDCALL        Win32 stdcall linkage 
  16897.  
  16898.  
  16899. ΓòÉΓòÉΓòÉ 19.2.3. Member Access Control ΓòÉΓòÉΓòÉ
  16900.  
  16901.      Class members are allocated in the order declared; access specifiers have 
  16902.       no effect on the order of allocation. 
  16903.  
  16904.  
  16905. ΓòÉΓòÉΓòÉ 19.2.4. Special Member Functions ΓòÉΓòÉΓòÉ
  16906.  
  16907.      Temporary objects are generated under the following circumstances: 
  16908.  
  16909.         -  During reference initialization 
  16910.         -  During evaluation of expressions 
  16911.         -  In type conversions 
  16912.         -  Argument passing 
  16913.         -  Function returns 
  16914.         -  In throw expressions. 
  16915.  
  16916.      Temporary objects exist until there is a break in the flow of control of 
  16917.       the program. They are destroyed on exiting the scope in which the 
  16918.       temporary object was created. 
  16919.  
  16920.  
  16921. ΓòÉΓòÉΓòÉ 19.3. Creating New Headers to Work with Both C and C++ (32-bit) ΓòÉΓòÉΓòÉ
  16922.  
  16923. Follow these guidelines to enable your new header files to work with both C and 
  16924. C++ code: 
  16925.  
  16926.      Rename any C- or C++-specific keywords. A listing of these can be found 
  16927.       in the Language Reference. 
  16928.  
  16929.      Add to the beginning of each header file: 
  16930.  
  16931.               #if __cplusplus
  16932.               extern "C" {
  16933.               #endif
  16934.  
  16935.      Add to the end of each header file: 
  16936.  
  16937.               #if __cplusplus
  16938.               }
  16939.               #endif
  16940.  
  16941.      Do not use _Packed in your code; use #pragma pack instead. 
  16942.  
  16943.      Do not use #pragma linkage in your code; use the linkage convention 
  16944.       keywords instead. 
  16945.  
  16946.      Specify the linkage on any identifiers that are pointers to functions. 
  16947.  
  16948.  
  16949. ΓòÉΓòÉΓòÉ 20. Locale Categories ΓòÉΓòÉΓòÉ
  16950.  
  16951. This appendix provides a listing of the categories which define a locale, the 
  16952. keywords used in each category, and the values which are valid for each 
  16953. keyword. 
  16954.  
  16955.  The following locale categories are described: 
  16956.  
  16957.      LC_CTYPE Category 
  16958.      LC_COLLATE Category 
  16959.      LC_MONETARY Category 
  16960.      LC_NUMERIC Category 
  16961.      LC_TIME Category 
  16962.      LC_MESSAGES Category 
  16963.      LC_TOD Category 
  16964.      LC_SYNTAX Category 
  16965.  
  16966.  
  16967. ΓòÉΓòÉΓòÉ 20.1. LC_CTYPE Category ΓòÉΓòÉΓòÉ
  16968.  
  16969. This category defines character classification, case conversion, and other 
  16970. character attributes. In this category, you can represent a series of 
  16971. characters by using three adjacent periods as an ellipsis symbol (...). An 
  16972. ellipsis is interpreted as including all characters with an encoded value 
  16973. higher than the encoded value of the character preceding the ellipsis and lower 
  16974. than the encoded value following the ellipsis. 
  16975.  
  16976. An ellipsis is valid within a single encoded character set. 
  16977.  
  16978. For example, \x30;...;\x39; includes in the character class all characters with 
  16979. encoded values from \x30 to \x39. 
  16980.  
  16981. The keywords recognized in the LC_CTYPE category are listed below. In the 
  16982. descriptions, the term "automatically included" means that it is not an error 
  16983. either to include or omit any of the referenced characters; they are assumed by 
  16984. default even if the entire keyword is missing and accepted if present. 
  16985.  
  16986. When a character is automatically included, it has an encoded value dependent 
  16987. on the charmap file in effect. If no charmap file is specified, the encoding of 
  16988. the encoded character set IBM-850 is assumed. 
  16989.  
  16990.  copy    Specifies the name of an existing locale to be used as the source for 
  16991.          the definition of this category. If this keyword is specified, no 
  16992.          other keywords are present in this category. If the locale is not 
  16993.          found, an error is reported and no locale output is created. The copy 
  16994.          keyword cannot specify a locale that also specifies the copy keyword 
  16995.          for the same category. 
  16996.  
  16997.  upper   Defines characters to be classified as uppercase letters. No character 
  16998.          defined for the keywords cntrl, digit, punct, or space can be 
  16999.          specified. The uppercase letters A through Z are automatically 
  17000.          included in this class. 
  17001.  
  17002.          The isupper and iswupper functions test for any character and wide 
  17003.          character, respectively, included in this class. 
  17004.  
  17005.  lower   Defines characters to be classified as lowercase letters. No character 
  17006.          defined for the keywords cntrl, digit, punct, or space can be 
  17007.          specified. The lowercase letters a through z are automatically 
  17008.          included in this class. 
  17009.  
  17010.          The islower and iswlower functions test for any character and wide 
  17011.          character, respectively, included in this class. 
  17012.  
  17013.  alpha   Defines characters to be classified as letters. No character defined 
  17014.          for the keywords cntrl, digit, punct, or space can be specified. 
  17015.          Characters classified as either upper or lower are automatically 
  17016.          included in this class. 
  17017.  
  17018.          The isalpha and iswalpha functions test for any character or wide 
  17019.          character, respectively, included in this class. 
  17020.  
  17021.  digit   Defines characters to be classified as numeric digits. Only the digits 
  17022.          0, 1, 2, 3, 4, 5, 6, 7, 8, 9. can be specified.  If they are, they 
  17023.          must be in contiguous ascending sequence by numerical value. The 
  17024.          digits 0 through 9 are automatically included in this class. 
  17025.  
  17026.          The isdigit and iswdigit functions test for any character or wide 
  17027.          character, respectively, included in this class. 
  17028.  
  17029.  space   Defines characters to be classified as whitespace characters. No 
  17030.          character defined for the keywords upper, lower, alpha, digit, or 
  17031.          xdigit can be specified for space. The characters <space>, 
  17032.          <form-feed>, <newline>, <carriage-return>, <horizontal-tab>, and 
  17033.          <vertical-tab>, and any characters defined in the class blank are 
  17034.          automatically included in this class. 
  17035.  
  17036.          The functions isspace and iswspace test for any character or wide 
  17037.          character, respectively, included in this class. 
  17038.  
  17039.  cntrl   Defines characters to be classified as control characters. No 
  17040.          character defined for the keywords upper, lower, alpha, digit, punct, 
  17041.          graph, print, or xdigit can be specified for cntrl. 
  17042.  
  17043.          The functions iscntrl and iswcntrl test for any character or wide 
  17044.          character, respectively, included in this class. 
  17045.  
  17046.  punct   Defines characters to be classified as punctuation characters. No 
  17047.          character defined for the keywords upper, lower, alpha, digit, cntrl, 
  17048.          or xdigit, or as the <space> character, can be specified. 
  17049.  
  17050.          The functions ispunct and iswpunct test for any character or wide 
  17051.          character, respectively, included in this class. 
  17052.  
  17053.  graph   Defines characters to be classified as printing characters, not 
  17054.          including the <space> character. Characters specified for the keywords 
  17055.          upper, lower, alpha, digit, xdigit, and punct are automatically 
  17056.          included. No character specified in the keyword cntrl can be specified 
  17057.          for graph. 
  17058.  
  17059.          The functions isgraph and iswgraph test for any character or wide 
  17060.          character, respectively, included in this class. 
  17061.  
  17062.  print   Defines characters to be classified as printing characters, including 
  17063.          the <space> character. Characters specified for the keywords upper, 
  17064.          lower, alpha, digit, xdigit, punct, and the <space> character are 
  17065.          automatically included. No character specified in the keyword cntrl 
  17066.          can be specified for print. 
  17067.  
  17068.          The functions isprint and iswprint test for any character or wide 
  17069.          character, respectively, included in this class. 
  17070.  
  17071.  xdigit  Defines characters to be classified as hexadecimal digits. Only the 
  17072.          characters defined for the class digit can be specified, in contiguous 
  17073.          ascending sequence by numerical value, followed by one or more sets of 
  17074.          six characters representing the hexadecimal digits 10 through 15, with 
  17075.          each set in ascending order (for example, A, B, C, D, E, F, a, b, c, 
  17076.          d, e, f). The digits 0 through 9, the uppercase letters A through F, 
  17077.          and the lowercase letters a through f are automatically included in 
  17078.          this class. 
  17079.  
  17080.          The functions isxdigit and iswxdigit test for any character or wide 
  17081.          character, respectively, included in this class. 
  17082.  
  17083.  blank   Defines characters to be classified as blank characters. The 
  17084.          characters <space> and <tab> are automatically included in this class. 
  17085.  
  17086.          The functions isblank and iswblank test for any character or wide 
  17087.          character, respectively, included in this class. 
  17088.  
  17089.  toupper Defines the mapping of lowercase letters to uppercase letters. The 
  17090.          operand consists of character pairs, separated by semicolons. The 
  17091.          characters in each character pair are separated by a comma; the pair 
  17092.          is enclosed in parentheses. The first character in each pair is the 
  17093.          lowercase letter, and the second is the corresponding uppercase 
  17094.          letter. Only characters specified for the keywords lower and upper can 
  17095.          be specified for toupper. The lowercase letters a through z, their 
  17096.          corresponding uppercase letters A through Z, are automatically in this 
  17097.          mapping, but only when the toupper keyword is omitted from the locale 
  17098.          definition. 
  17099.  
  17100.          It affects the behavior of the toupper and towupper functions for 
  17101.          mapping characters and wide characters, respectively. 
  17102.  
  17103.  tolower Defines the mapping of uppercase letters to lowercase letters. The 
  17104.          operand consists of character pairs, separated by semicolons. The 
  17105.          characters in each character pair are separated by a comma; the pair 
  17106.          is enclosed by parentheses. The first character in each pair is the 
  17107.          uppercase letter, and the second is its corresponding lowercase 
  17108.          letter. Only characters specified for the keywords lower and upper can 
  17109.          be specified. If the tolower keyword is omitted from the locale 
  17110.          definition, the mapping is the reverse mapping of the one specified 
  17111.          for the toupper. 
  17112.  
  17113.          The tolower keyword affects the behavior of the tolower and towlower 
  17114.          functions for mapping characters and wide characters, respectively. 
  17115.          You do not need to code tolower in your locale. If tolower is not 
  17116.          included in the locale source, then the tolower table is generated as 
  17117.          the mirror image of the toupper table. 
  17118.  
  17119.  You may define additional character classes using your own keywords. A maximum 
  17120.  of 32 classes are supported in total: the 12 standard classes, and up to 20 
  17121.  user-defined classes. The 12 standard classes being composed of the 11 
  17122.  standard classes listed above plus the ALNUM class which contains the total 
  17123.  characters in the ALPHA and DIGIT classes. 
  17124.  
  17125.  The defined classes affect the behavior of wctype and iswctype functions. 
  17126.  
  17127.  Here is an example of the definition of the LC_CTYPE category: 
  17128.  
  17129.  
  17130.     #############
  17131.     LC_CTYPE
  17132.     #############
  17133.     # upper letters are A-Z by default plus the three defined below
  17134.     upper  <A-acute>;<A-grave>;<C-acute>
  17135.  
  17136.     # lower case leters are a-z by default plus the three defined below
  17137.     lower  <a-acute>;<a-grave><c-acute>
  17138.  
  17139.     # space characters are default 6 characters plus the one defined below
  17140.     space  <hyphen-minus>
  17141.  
  17142.     cntrl  <alert>;<backspace>;<tab>;<newline>;<vertical-tab>;\
  17143.         <form-feed>;<carriage-return>;<NUL>;\
  17144.         <SO>;<SI>
  17145.  
  17146.     # default graph, print,punct, digit, xdigit, blank classes
  17147.  
  17148.     # toupper mapping defined only for the following three pairs
  17149.     toupper (<a-acute),<A-acute>);\
  17150.         (<a-grave),<A-grave>);\
  17151.         (<c-acute),<C-acute>);
  17152.  
  17153.     # default upper to lower case mapping
  17154.  
  17155.     # user defined class
  17156.     myclass  <e-ogonek>;<E-ogonek>
  17157.  
  17158.     END LC_CTYPE
  17159.  
  17160.  
  17161. ΓòÉΓòÉΓòÉ 20.2. LC_COLLATE Category ΓòÉΓòÉΓòÉ
  17162.  
  17163. A collation sequence definition defines the relative order between collating 
  17164. elements (characters and multicharacter collating elements) in the locale. This 
  17165. order is expressed in terms of collation values.  It assigns each element one 
  17166. or more collation values (also known as collation weights). The collation 
  17167. sequence definition is used by regular expressions, pattern matching, and 
  17168. sorting and collating functions. The following capabilities are provided: 
  17169.  
  17170.    1. Multicharacter collating elements.  Specification of multicharacter 
  17171.       collating elements (sequences of two or more characters to be collated as 
  17172.       an entity). 
  17173.  
  17174.    2. User-defined ordering of collating elements. Each collating element is 
  17175.       assigned a collation value defining its order in the character (or basic) 
  17176.       collation sequence. This ordering is used by regular expressions and 
  17177.       pattern matching, and unless collation weights are explicitly specified, 
  17178.       also as the collation weight to be used in sorting. 
  17179.  
  17180.    3. Multiple weights and equivalence classes. Collating elements can be 
  17181.       assigned 1 to 6 collating weights for use in sorting. The first weight is 
  17182.       referred to as the primary weight. 
  17183.  
  17184.    4. One-to-many mapping.  A single character is mapped into a string of 
  17185.       collating elements. 
  17186.  
  17187.    5. Many-to-Many substitution.  A string of one or more characters are mapped 
  17188.       to another string (or an empty string).  The character or characters are 
  17189.       ignored for collation purposes. 
  17190.  
  17191.    6. Equivalence class definition.  Two or more collating elements have the 
  17192.       same collation value (primary weight). 
  17193.  
  17194.    7. Ordering by weights.  When two strings are compared to determine their 
  17195.       relative order, the two strings are first broken up into a series of 
  17196.       collating elements.  Each successive pair of elements is compared 
  17197.       according to the relative primary weights for the elements. If they are 
  17198.       equal, and more than one weight is assigned, then the pairs of collating 
  17199.       elements are compared again according to the relative subsequent weights, 
  17200.       until either two collating elements are not equal or the weights are 
  17201.       exhausted. 
  17202.  
  17203.  
  17204. ΓòÉΓòÉΓòÉ 20.2.1. Collating Rules ΓòÉΓòÉΓòÉ
  17205.  
  17206. Collating rules consist of an ordered list of collating order statements, 
  17207. ordered from lowest to highest. The <NUL> character is considered lower than 
  17208. any other character. The ellipsis symbol ("...") is a special collation order 
  17209. statement. It specifies that a sequence of characters collate according to 
  17210. their encoded character values. It causes all characters with values higher 
  17211. than the value of the <collating identifier> in the preceding line, and lower 
  17212. than the value for the <collating identifier> on the following line, to be 
  17213. placed in the character collation order between the previous and the following 
  17214. collation order statements in ascending order according to their encoded 
  17215. character values. 
  17216.  
  17217. The use of the ellipsis symbol ties the definition to a specific coded 
  17218. character set and may preclude the definition from being portable among 
  17219. implementations. 
  17220.  
  17221. The ellipsis symbol must be on a line by itself, not the first or last line, 
  17222. and the preceding and succeeding lines must not specify a weight. 
  17223.  
  17224. A collating order statement describes how a collating identifier is weighted. 
  17225.  
  17226. Each <collating-identifier> consists of a character, <collating-element>, 
  17227. <collating-symbol>, or the special symbol UNDEFINED. The order in which 
  17228. collating elements are specified determines the character order sequence, such 
  17229. that each collating element is considered lower than the elements following it. 
  17230. The <NUL> character is considered lower than any other character. Weights are 
  17231. expressed as characters, <collating-symbol>s, <collating-element>s, or the 
  17232. special symbol IGNORE. A single character, a <collating-symbol>, or a 
  17233. <collating-element> represents the relative position in the character collating 
  17234. sequence of the character or symbol, rather than the character or characters 
  17235. themselves. Thus rather than assigning absolute values to weights, a particular 
  17236. weight is expressed using the relative "order value" assigned to a collating 
  17237. element based on its order in the character collation sequence. 
  17238.  
  17239. A <collating-element> specifies multicharacter collating elements, and 
  17240. indicates that the character sequence specified by the <collating-element> is 
  17241. to be collated as a unit and in the relative order specified by its place. 
  17242.  
  17243. A <collating-symbol> can define a position in the relative order for use in 
  17244. weights. Do not use a <collating-symbol> to specify a weight. 
  17245.  
  17246. The <collating-symbol> UNDEFINED is interpreted as including all characters not 
  17247. specified explicitly. Such characters are inserted in the character collation 
  17248. order at the point indicated by the symbol, and in ascending order according to 
  17249. their encoded character values. If no UNDEFINED symbol is specified, and the 
  17250. current coded character set contains characters not specified in this clause, 
  17251. the LOCALDEF utility issues a warning and places such characters at the end of 
  17252. the character collation order. 
  17253.  
  17254. The syntax for a collation order statement is: 
  17255.  
  17256. <collating-identifier> <weight1>;<weight2>;...;<weightn>
  17257.  
  17258. Collation of two collating identifiers is done by comparing their relative 
  17259. primary weights.  This process is repeated for successive weight levels until 
  17260. the two identifiers are different, or the weight levels are exhausted. The 
  17261. operands for each collating identifier define the primary, secondary, and 
  17262. subsequent relative weights for the collating identifier. Two or more collating 
  17263. elements can be assigned the same weight. If two collating identifiers have the 
  17264. same primary weight, they belong to the same equivalence class. 
  17265.  
  17266. The special symbol IGNORE as a weight indicates that when strings are compared 
  17267. using the weights at the level where IGNORE is specified, the collating element 
  17268. should be ignored, as if the string did not contain the collating element. In 
  17269. regular expressions and pattern matching, all characters that are IGNOREd in 
  17270. their primary weight form an equivalence class. 
  17271.  
  17272. All characters specified by an ellipsis are assigned unique weights, equal to 
  17273. the relative order of the characters. Characters specified by an explicit or 
  17274. implicit UNDEFINED special symbol are assigned the same primary weight (they 
  17275. belong to the same equivalence class). 
  17276.  
  17277. One-to-many mapping is indicated by specifying two or more concatenated 
  17278. characters or symbolic names. For example, if the character "<ezset>" is given 
  17279. the string "<s><s>" as a weight, comparisons are performed as if all 
  17280. occurrences of the character <ezset> are replaced by <s><s> (assuming <s> has 
  17281. the collating weight <s>). If it is desirable to define <ezset> and <s><s> as 
  17282. an equivalence class, then a collating element must be defined for the string 
  17283. "ss". 
  17284.  
  17285. If no weight is specified, the collating identifier is interpreted as itself. 
  17286.  
  17287. For example, the order statement 
  17288.  
  17289. <a>  <a>
  17290.  
  17291. is equivalent to 
  17292.  
  17293. <a>
  17294.  
  17295.  
  17296. ΓòÉΓòÉΓòÉ 20.2.2. Collating Keywords ΓòÉΓòÉΓòÉ
  17297.  
  17298. The following keywords are recognized in a collation sequence definition. 
  17299.  
  17300.  copy 
  17301.      Specifies the name of an existing locale to be used as the source for the 
  17302.      definition of this category. If this keyword is specified, no other 
  17303.      keyword shall be present in this category. If the locale is not found, an 
  17304.      error is reported and no locale output is created. The copy keyword cannot 
  17305.      specify a locale that also specifies the copy keyword for the same 
  17306.      category. 
  17307.  
  17308.  collating-element 
  17309.      Defines a collating-element symbol representing a multicharacter collating 
  17310.      element. This keyword is optional. 
  17311.  
  17312.      In addition to the collating elements in the character set, the 
  17313.      collating-element keyword can be used to define multicharacter collating 
  17314.      elements. The syntax is: 
  17315.  
  17316.           "collating-element %s from %s\n", <collating-element>, <string>
  17317.  
  17318.      The <collating-element> should be a symbolic name enclosed between angle 
  17319.      brackets (< and >), and should not duplicate any symbolic name in the 
  17320.      current charmap file (if any), or any other symbolic name defined in this 
  17321.      collation definition. The string operand is a string of two or more 
  17322.      characters that collate as an entity. A <collating-element> defined with 
  17323.      this keyword is only recognized within the LC_COLLATE category. 
  17324.  
  17325.      For example: 
  17326.  
  17327.           collating-element <ch> from "<c><h>"
  17328.           collating-element <e-acute> from "<acute><e>"
  17329.           collating-element <ll> from "ll"
  17330.  
  17331.  collating-symbol 
  17332.      Defines a collating symbol for use in collation order statements. 
  17333.  
  17334.      The collating-symbol keyword defines a symbolic name that can be 
  17335.      associated with a relative position in the character order sequence. While 
  17336.      such a symbolic name does not represent any collating element, it can be 
  17337.      used as a weight. This keyword is optional. 
  17338.  
  17339.      This construct can define symbols for use in collation sequence 
  17340.      statements, between the order_start and order_end keywords. 
  17341.  
  17342.      The syntax is: 
  17343.  
  17344.           "collating-symbol %s\n", <collating-symbol>
  17345.  
  17346.      The <collating-symbol> must be a symbolic name, enclosed between angle 
  17347.      brackets (< and >), and should not duplicate any symbolic name in the 
  17348.      current charmap file (if any), or any other symbolic name defined in this 
  17349.      collation definition. A <collating-symbol> defined with this keyword is 
  17350.      only recognized within the LC_COLLATE category. 
  17351.  
  17352.      For example: 
  17353.  
  17354.           collating-symbol <UPPER_CASE>
  17355.           collating-symbol <HIGH>
  17356.  
  17357.  substitute 
  17358.      The substitute keyword defines a substring substitution in a string to be 
  17359.      collated. This keyword is optional. The following operands are supported 
  17360.      with the substitute keyword: 
  17361.  
  17362.           "substitute %s with %s\n", <regular-expr>, <replacement>
  17363.  
  17364.      The first operand is treated as a basic regular expression. The 
  17365.      replacement operand consists of zero or more characters and regular 
  17366.      expression back-references (for example, \1 through \9). The 
  17367.      back-references consist of the backslash followed by a digit from 1 to 9. 
  17368.      If the backslash is followed by two or three digits, it is interpreted as 
  17369.      an octal constant. 
  17370.  
  17371.      When strings are collated according to a collation definition containing 
  17372.      substitute statements, the collation behaves as if occurrences of 
  17373.      substrings matching the basic regular expression are replaced by the 
  17374.      replacement string, before the strings are compared based on the specified 
  17375.      collation sequence. Ranges in the regular expression are interpreted 
  17376.      according to the current character collation sequence and character 
  17377.      classes according to the character classification specified by the 
  17378.      LC_CTYPE environment variable at collation time. If more than one 
  17379.      substitute statement is present in the collation definition, the collation 
  17380.      process behaves as if the substitute statements are applied to the strings 
  17381.      in the order they occur in the source definition. The substitution for the 
  17382.      substitute statements are processed before any substitutions for 
  17383.      one-to-many mappings. The support of the "substitute" keyword is an IBM 
  17384.      VisualAge for C++ extension to the POSIX standard. 
  17385.  
  17386.  order_start 
  17387.      Define collating rules. This statement is followed by one or more 
  17388.      collation order statements, assigning character collation values and 
  17389.      collation weights to collating elements. 
  17390.  
  17391.      The order_start keyword must precede collation order entries.  It defines 
  17392.      the number of weights for this collation sequence definition and other 
  17393.      collation rules. 
  17394.  
  17395.      The syntax of the order_start keyword is: 
  17396.  
  17397.           order_start <sort-rule1>;<sort-rule2>;...;<sort-rulen>
  17398.  
  17399.      The operands of the order_start keyword are optional. If present, the 
  17400.      operands define rules to be applied when strings are compared. The number 
  17401.      of operands define how many weights each element is assigned; if no 
  17402.      operands are present, one forward operand is assumed. If any is present, 
  17403.      the first operand defines rules to be applied when comparing strings using 
  17404.      the first (primary) weight; the second when comparing strings using the 
  17405.      second weight, and so on. Operands are separated by semicolons (;). Each 
  17406.      operand consists of one or more collation directives separated by commas 
  17407.      (,). If the number of operands exceeds the limit of 6, the LOCALDEF 
  17408.      utility issues a warning message. 
  17409.  
  17410.      The following directives are supported: 
  17411.  
  17412.      forward 
  17413.               specifies that comparison operations for the weight level proceed 
  17414.               from the start of the string towards its end. 
  17415.  
  17416.      backward 
  17417.               specifies that comparison operations for the weight level proceed 
  17418.               from the end of the string toward its beginning. 
  17419.  
  17420.      no-substitute 
  17421.               no substitution is performed, such that the comparison is based 
  17422.               on collation values for collating elements before any 
  17423.               substitution operations are performed. 
  17424.  
  17425.               Note: 
  17426.  
  17427.                 1. This is an IBM VisualAge for C++ extension to the POSIX 
  17428.                    standard. 
  17429.  
  17430.                 2. When the no-substitute keyword is specified, one-to-many 
  17431.                    mappings are ignored. 
  17432.  
  17433.      position 
  17434.               specifies that comparison operations for the weight level must 
  17435.               consider the relative position of non-IGNOREd elements in the 
  17436.               strings. The string containing a non-IGNOREd element after the 
  17437.               fewest IGNOREd collating elements from the start of the 
  17438.               comparison collates first. If both strings contain a non-IGNOREd 
  17439.               character in the same relative position, the collating values 
  17440.               assigned to the elements determine the order. If the strings are 
  17441.               equal, subsequent non-IGNOREd characters are considered in the 
  17442.               same manner. 
  17443.  
  17444.  order_end 
  17445.      The collating order entries are terminated with an order_end keyword. 
  17446.  
  17447.  Here is an example of an LC_COLLATE category: 
  17448.  
  17449.         LC_COLLATE
  17450.         # ARTIFICIAL COLLATE CATEGORY
  17451.  
  17452.         # collating elements
  17453.    1     collating-element  <ch>  from "<c><h>"
  17454.         collating-element  <Ch>  from "<C><h>"
  17455.         collating-element  <eszet> from "<s><z>"
  17456.  
  17457.         #collating symbols for relative order definition
  17458.  
  17459.         collating-symbol   <LOW>
  17460.    2     collating-symbol   <UPPER-CASE>
  17461.         collating-symbol   <LOWER-CASE>
  17462.         collating-symbol   <NONE>
  17463.  
  17464.    3     order_start forward;backward;forward
  17465.         <NONE>
  17466.  
  17467.    4     <LOW>
  17468.         <UPPER-CASE>
  17469.         <LOWER-CASE>
  17470.  
  17471.    5     UNDEFINED IGNORE;IGNORE;IGNORE
  17472.  
  17473.         <space>
  17474.    6     ...
  17475.         <quotation-mark>
  17476.    7     <a>      <a>;<NONE>;<LOWER-CASE>
  17477.   10     <a-acute>   <a>;<a-acute>;<LOWER-CASE>
  17478.   11     <a-grave>   <a>;<a-grave>;<LOWER-CASE>
  17479.    8     <A>      <a>;<NONE>;<UPPER-CASE>
  17480.   11     <A-acute>   <a>;<a-acute>;<UPPER-CASE>
  17481.   11     <A-grave>   <a>;<a-grave>;<UPPER-CASE>
  17482.   11     <ch>      <ch>;<NONE>;<LOWER-CASE>
  17483.   11     <Ch>      <ch>;<NONE>;<UPPER-CASE>
  17484.    9     <s>      <s>;<s>;<LOWER-CASE>
  17485.   12     <eszet>    "<s><s>";"<eszet><s>";<LOWER-CASE>
  17486.    9     <z>      <z>;<NONE>;<LOWER-CASE>
  17487.         order_end
  17488.  
  17489.  The example is interpreted as follows: 
  17490.  
  17491.  1 collating elements 
  17492.  
  17493.      character <c> followed by <h> collate as one entity named <ch> 
  17494.  
  17495.      character <C> followed by <h> collate as one entity named <Ch> 
  17496.  
  17497.      character <s> followed by <z> collate as one entity named <eszet> 
  17498.  
  17499.  2 collating symbols <LOW>, <UPPER-CASE>, <LOWER-CASE> and <NONE> are defined 
  17500.  to be used in relative order definition 
  17501.  
  17502.  3 up to 3 string comparisons are defined: 
  17503.  
  17504.      first pass starts from the beginning of the strings 
  17505.  
  17506.      second pass starts from the end of the strings, and 
  17507.  
  17508.      third pass starts from the beginning of the strings 
  17509.  
  17510.  4 the collating weights are defined (in 2) such that: 
  17511.  
  17512.      <LOW> collates before <UPPER-CASE>, 
  17513.  
  17514.      <UPPER-CASE> collates before <LOWER-CASE>, 
  17515.  
  17516.      <LOWER-CASE> collates before <NONE>; 
  17517.  
  17518.  5 all characters for which collation is not specified here are ordered after 
  17519.  <NONE>, and before <space> in ascending order according to their encoded 
  17520.  values 
  17521.  
  17522.  6 all characters with an encoded value larger than the encoded value of 
  17523.  <space> and lower than the encoded value of <quotation-mark> in the current 
  17524.  encoded character set, collate in ascending order according to their values; 
  17525.  
  17526.  7 <a> has a: 
  17527.  
  17528.      primary weight of <a>, 
  17529.  
  17530.      secondary weight <NONE>, 
  17531.  
  17532.      tertiary weight of <LOWER-CASE>, 
  17533.  
  17534.  8 <A> has a: 
  17535.  
  17536.      primary weight of <a>, 
  17537.  
  17538.      secondary weight of <NONE>, 
  17539.  
  17540.      tertiary weight of <UPPER-CASE>, 
  17541.  
  17542.  9 the weights of <s> and <z> are determined in a similar fashion to <a> and 
  17543.  <A>. 
  17544.  
  17545.  10 <a-acute> has a: 
  17546.  
  17547.      primary weight of <a>, 
  17548.  
  17549.      secondary weight of <a-acute> itself, 
  17550.  
  17551.      tertiary weight of <LOWER-CASE>, 
  17552.  
  17553.  11 the weights of <a-grave>, <A-acute>, <A-grave>, <ch> and <Ch> are 
  17554.  determined in a similar fashion to <a-acute>. 
  17555.  
  17556.  12 <eszet>  has a: 
  17557.  
  17558.      primary weight determined by replacing each occurence of <eszet> with the 
  17559.       sequence of two <s>'s and using the weight of <s>, 
  17560.  
  17561.      secondary weight determined by replacing each occurence of <eszet> with 
  17562.       the sequence of <eszet> and <s> and using their weights, 
  17563.  
  17564.      tertiary weight is the relative position of <LOWER-CASE>. 
  17565.  
  17566.  
  17567. ΓòÉΓòÉΓòÉ 20.2.3. Comparison of Strings ΓòÉΓòÉΓòÉ
  17568.  
  17569. Compare the strings s1="aAch" and s2="AaCh" using the above LC_COLLATE 
  17570. definition: 
  17571.  
  17572.    1. s1=> "aA<ch>", and s2=> "Aa<Ch>" 
  17573.  
  17574.    2. first pass: 
  17575.  
  17576.         a. substitute the elements of the strings with their primary weights: 
  17577.  
  17578.            s1=> "<a><a><ch>", s2=> "<a><a><ch>" 
  17579.  
  17580.         b. compare the two strings starting with the first element - they are 
  17581.            equal. 
  17582.  
  17583.    3. second pass: 
  17584.  
  17585.         a. substitute the elements of the strings with their secondary weights: 
  17586.  
  17587.            s1=> "<NONE><NONE><NONE>", s2=>"<NONE><NONE><NONE>" 
  17588.  
  17589.         b. compare the two strings from the last element to the first - they 
  17590.            are equal. 
  17591.  
  17592.    4. third pass: 
  17593.  
  17594.         a. substitute the elements of the strings with their third level 
  17595.            weights: 
  17596.  
  17597.            s1=> "<LOWER-CASE><UPPER-CASE><LOWER-CASE>", s2=> 
  17598.            "<UPPER-CASE><LOWER-CASE><UPPER-CASE>", 
  17599.  
  17600.         b. compare the two strings starting from the beginning of the strings: 
  17601.  
  17602.            s2 compares lower than s1, because <UPPER-CASE> is before 
  17603.            <LOWER-CASE>. 
  17604.  
  17605.  Compare the strings s1="a1sz" and s2=>"a2ss": 
  17606.  
  17607.    1. s1=> "a1<eszet>" and s2= "a2ss"; 
  17608.  
  17609.    2. first pass: 
  17610.  
  17611.         a. substitute the elements of the strings with their primary weights: 
  17612.  
  17613.            s1=> "<a><s><s>", s2=> "<a><s><s>" 
  17614.  
  17615.         b. compare the two strings starting with the first element - they are 
  17616.            equal. 
  17617.  
  17618.    3. second pass: 
  17619.  
  17620.         a. substitute the elements of the strings with their secondary weights: 
  17621.  
  17622.            s1=> "<a-acute><eszet><s>", s2=>"<a-grave><s><s>" 
  17623.  
  17624.         b. compare the two strings from the last element to the first - <s> is 
  17625.            before <ezset>. 
  17626.  
  17627.  
  17628. ΓòÉΓòÉΓòÉ 20.3. LC_MONETARY Category ΓòÉΓòÉΓòÉ
  17629.  
  17630. This category defines the rules and symbols used to format monetary quantities. 
  17631. The operands are strings or integers. The following keywords are supported: 
  17632.  
  17633.  copy 
  17634.      Specifies the name of an existing locale to be used as the source for the 
  17635.      definition of this category. If this keyword is specified, no other 
  17636.      keyword should be present in this category. If the locale is not found, an 
  17637.      error is reported and no locale output is created. The copy keyword cannot 
  17638.      specify a locale that also specifies the copy keyword for the same 
  17639.      category. 
  17640.  
  17641.  int_curr_symbol 
  17642.      Specifies the international currency symbol. The operand is a 
  17643.      four-character string, with the first three characters containing the 
  17644.      alphabetic international currency symbol in accordance with those 
  17645.      specified in ISO4217 Codes for the Representation of Currency and Funds. 
  17646.      The fourth character is the character used to separate the international 
  17647.      currency symbol from the monetary quantity. 
  17648.  
  17649.      If not defined, it defaults to the empty string (""). 
  17650.  
  17651.  currency_symbol 
  17652.      Specifies the string used as the local currency symbol. If not defined, it 
  17653.      defaults to the empty string (""). 
  17654.  
  17655.  mon_decimal_point 
  17656.      The string used as a decimal delimiter to format monetary quantities. 
  17657.      If not defined it defaults to the empty string (""). 
  17658.  
  17659.  mon_thousands_sep 
  17660.      Specifies the string used as a separator for groups of digits to the left 
  17661.      of the decimal delimiter in formatted monetary quantities. If not defined, 
  17662.      it defaults to the empty string (""). 
  17663.  
  17664.  mon_grouping 
  17665.      Defines the size of each group of digits in formatted monetary quantities. 
  17666.      The operand is a string representing a sequence of integers separated by 
  17667.      semicolons. Each integer specifies the number of digits in each group, 
  17668.      with the initial integer defining the size of the group immediately 
  17669.      preceding the decimal delimiter, and the following integers defining the 
  17670.      preceding groups. If the last integer is not -1, then the size of the 
  17671.      previous group (if any) is used repeatedly for the rest of the digits. If 
  17672.      the last integer is -1, then no further grouping is performed. If not 
  17673.      defined, mon_grouping defaults to -1 which indicates that no grouping. An 
  17674.      empty string is interpreted as -1. 
  17675.  
  17676.  positive_sign 
  17677.      A string used to indicate a formatted monetary quantity with a 
  17678.      non-negative value. If not defined, it defaults to the empty string (""). 
  17679.  
  17680.  negative_sign 
  17681.      Specifies a string used to indicate a formatted monetary quantity with a 
  17682.      negative value. If not defined, it defaults to the empty string (""). 
  17683.  
  17684.  int_frac_digits 
  17685.      Specifies an integer representing the number of fractional digits (those 
  17686.      to the right of the decimal delimiter) to be displayed in a formatted 
  17687.      monetary quantity using int_curr_symbol. If not defined, it defaults to 
  17688.      -1. 
  17689.  
  17690.  frac_digits 
  17691.      Specifies an integer representing the number of fractional digits (those 
  17692.      to the right of the decimal delimiter) to be displayed in a formatted 
  17693.      monetary quantity using currency_symbol. If not defined, it defaults to 
  17694.      -1. 
  17695.  
  17696.  p_cs_precedes 
  17697.      Specifies an integer set to 1 if the currency_symbol or int_curr_symbol 
  17698.      precedes the value for a non-negative formatted monetary quantity, and set 
  17699.      to 0 if the symbol succeeds the value. If not defined, it defaults to -1. 
  17700.  
  17701.  p_sep_by_space 
  17702.      Specifies an integer set to 0 if no space separates the currency_symbol or 
  17703.      int_curr_symbol from the value for a non-negative formatted monetary 
  17704.      quantity, set to 1 if a space separates the symbol from the value, and set 
  17705.      to 2 if a space separates the symbol and the sign string, if adjacent. If 
  17706.      not defined, it defaults to -1. 
  17707.  
  17708.  n_cs_precedes 
  17709.      An integer set to 1 if the currency_symbol or int_curr_symbol precedes the 
  17710.      value for a negative formatted monetary quantity, and set to 0 if the 
  17711.      symbol succeeds the value. If not defined, it defaults to -1. 
  17712.  
  17713.  n_sep_by_space 
  17714.      An integer set to 0 if no space separates the currency_symbol or 
  17715.      int_curr_symbol from the value for a negative formatted monetary quantity, 
  17716.      set to 1 if a space separates the symbol from the value, and set to 2 if a 
  17717.      space separates the symbol and the sign string, if adjacent. If not 
  17718.      defined, it defaults to -1. 
  17719.  
  17720.  p_sign_posn 
  17721.      An integer set to a value indicating the positioning of the positive_sign 
  17722.      for a non-negative formatted monetary quantity. The following integer 
  17723.      values are recognized: 
  17724.  
  17725.      0        Parentheses surround the quantity and the currency_symbol or 
  17726.               int_curr_symbol. 
  17727.      1        The sign string precedes the quantity and the currency_symbol or 
  17728.               int_curr_symbol. 
  17729.      2        The sign string succeeds the quantity and the currency_symbol or 
  17730.               int_curr_symbol. 
  17731.      3        The sign string immediately precedes the currency_symbol or 
  17732.               int_curr_symbol. 
  17733.      4        The sign string immediately succeeds the currency_symbol or 
  17734.               int_curr_symbol. 
  17735.  
  17736.      The following value may also be specified, though it is not part of the 
  17737.      POSIX standard. 
  17738.  
  17739.      5        Use debit-sign or credit-sign for p_sign_posn or n_sign_posn. If 
  17740.      not defined, it defaults to -1. 
  17741.  
  17742.  n_sign_posn 
  17743.      An integer set to a value indicating the positioning of the negative_sign 
  17744.      for a negative formatted monetary quantity. The recognized values are the 
  17745.      same as for p_sign_posn. If not defined, it defaults to -1. 
  17746.  
  17747.  left_parenthesis 
  17748.      The symbol of the locale's equivalent of ( to form a negative-valued 
  17749.      formatted monetary quantity together with right_parenthesis. If not 
  17750.      defined, it defaults to the the empty string (""). 
  17751.  
  17752.      Note:  This is an IBM-specific extension. 
  17753.  
  17754.  right_parenthesis 
  17755.      The symbol of the locale's equivalent of ) to form a negative-valued 
  17756.      formatted monetary quantity together with left_parenthesis. If not 
  17757.      defined, it defaults to the the empty string (""); 
  17758.  
  17759.      Note:  This is an IBM-specific extension. 
  17760.  
  17761.  debit_sign 
  17762.      The symbol of locale's equivalent of DB to indicate a non-negative-valued 
  17763.      formatted monetary quantity. If not defined, it defaults to the the empty 
  17764.      string (""); 
  17765.  
  17766.      Note:  This is an IBM-specific extension. 
  17767.  
  17768.  credit_sign 
  17769.      The symbol of locale's equivalent of CR to indicate a negative-valued 
  17770.      formatted monetary quantity. If not defined, it defaults to the the empty 
  17771.      string (""); 
  17772.  
  17773.      Note:  This is an IBM-specific extension. 
  17774.  Here is an example of the definition of the LC_MONETARY category: 
  17775.  
  17776.   #############
  17777.   LC_MONETARY
  17778.   #############
  17779.  
  17780.   int_curr_symbol  "<J><P><Y><space>"
  17781.   currency_symbol  "<yen>"
  17782.   mon_decimal_point "<period>"
  17783.   mon_thousands_sep "<comma>"
  17784.   mon_grouping    "3;0"
  17785.   positive_sign   ""
  17786.   negative_sign   "<hyphen-minus>"
  17787.   int_frac_digits  0
  17788.   frac_digits    0
  17789.   p_cs_precedes   1
  17790.   p_sep_by_space   0
  17791.   n_cs_precedes   1
  17792.   n_sep_by_space   0
  17793.   p_sign_posn    1
  17794.   n_sign_posn    1
  17795.   debit_sign     "<D><B>"
  17796.   credit_sign    "<C><R>"
  17797.   left_parenthesis  "<left-parenthesis>"
  17798.   right_parenthesis "<right-parenthesis>"
  17799.  
  17800.   END LC_MONETARY
  17801.  
  17802.  
  17803. ΓòÉΓòÉΓòÉ 20.4. LC_NUMERIC Category ΓòÉΓòÉΓòÉ
  17804.  
  17805. This category defines the rules and symbols used to format non-monetary numeric 
  17806. information. The operands are strings. The following keywords are recognized: 
  17807.  
  17808.  copy 
  17809.      Specifies the name of an existing locale to be used as the source for the 
  17810.      definition of this category. If this keyword is specified, no other 
  17811.      keyword should be present in this category. If the locale is not found, an 
  17812.      error is reported and no locale output is created. The copy keyword cannot 
  17813.      specify a locale that also specifies the copy keyword for the same 
  17814.      category. 
  17815.  
  17816.  decimal_point 
  17817.      Specifies a string used as the decimal delimiter in numeric, non-monetary 
  17818.      formatted quantities. This keyword cannot be omitted and cannot be set to 
  17819.      the empty string. 
  17820.  
  17821.  thousands_sep 
  17822.      Specifies a string containing the symbol that is used as a separator for 
  17823.      groups of digits to the left of the decimal delimiter in numeric, 
  17824.      non-monetary, formatted quantities. 
  17825.  
  17826.  grouping 
  17827.      Defines the size of each group of digits in formatted non-monetary 
  17828.      quantities. The operand is a string representing a sequence of integers 
  17829.      separated by semicolons. Each integer specifies the number of digits in 
  17830.      each group, with the initial integer defining the size of the group 
  17831.      immediately preceding the decimal delimiter, and the following integers 
  17832.      defining the preceding groups. If the last integer is not -1, then the 
  17833.      size of the previous group (if any) is used repeatedly for the rest of the 
  17834.      digits. If the last integer is -1, then no further grouping is performed. 
  17835.      An empty string is interpreted as -1. 
  17836.  Here is an example of how to specify the LC_NUMERIC category: 
  17837.  
  17838.   #############
  17839.   LC_NUMERIC
  17840.   #############
  17841.  
  17842.   decimal_point   "<comma>"
  17843.   thousands_sep   "<space>"
  17844.   grouping      "3;0"
  17845.  
  17846.   END LC_NUMERIC
  17847.  
  17848.  
  17849. ΓòÉΓòÉΓòÉ 20.5. LC_TIME Category ΓòÉΓòÉΓòÉ
  17850.  
  17851. The LC_TIME category defines the interpretation of the field descriptors used 
  17852. for parsing, then formatting, the date and time. Refer to the strftime and 
  17853. strptime functions in the C Library Reference for a description of format 
  17854. specifiers. 
  17855.  
  17856. The following keywords are supported: 
  17857.  
  17858.  copy 
  17859.      Specifies the name of an existing locale to be used as the source for the 
  17860.      definition of this category. If this keyword is specified, no other 
  17861.      keyword should be present in this category. If the locale is not found, an 
  17862.      error is reported and no locale output is created. The copy keyword cannot 
  17863.      specify a locale that also specifies the copy keyword for the same 
  17864.      category. 
  17865.  
  17866.  abday 
  17867.      Defines the abbreviated weekday names, corresponding to the %a field 
  17868.      descriptor. The operand consists of seven semicolon-separated strings. The 
  17869.      first string is the abbreviated name corresponding to Sunday, the second 
  17870.      string corresponds to Monday, and so forth. 
  17871.  
  17872.  day 
  17873.      Defines the full weekday names, corresponding to the %A field descriptor. 
  17874.      The operand consists of seven semicolon-separated strings. The first 
  17875.      string is the full name corresponding to Sunday, the second string to 
  17876.      Monday, and so forth. 
  17877.  
  17878.  abmon 
  17879.      Defines the abbreviated month names, corresponding to the %b field 
  17880.      descriptor. The operand consists of twelve strings separated by 
  17881.      semicolons. The first string is an abbreviated name that corresponds to 
  17882.      January, the second corresponds to February, and so forth. 
  17883.  
  17884.  mon 
  17885.      Defines the full month names, corresponding to the %B field descriptor. 
  17886.      The operand consists of twelve strings separated by semicolons. The first 
  17887.      string is an abbreviated name that corresponds to January, the second 
  17888.      corresponds to February, and so forth. 
  17889.  
  17890.  d_t_fmt 
  17891.      Defines the appropriate date and time representation, corresponding to the 
  17892.      %c field descriptor. The operand consists of a string, which may contain 
  17893.      any combination of characters and field descriptors. 
  17894.  
  17895.  d_fmt 
  17896.      Defines the appropriate date representation, corresponding to the %x field 
  17897.      descriptor. The operand consists of a string, and may contain any 
  17898.      combination of characters and field descriptors. 
  17899.  
  17900.  t_fmt 
  17901.      Defines the appropriate time representation, corresponding to the %X field 
  17902.      descriptor. The operand consists of a string, which may contain any 
  17903.      combination of characters and field descriptors. 
  17904.  
  17905.  am_pm 
  17906.      Defines the appropriate representation of the ante meridian and post 
  17907.      meridian strings, corresponding to the %p field descriptor. The operand 
  17908.      consists of two strings, separated by a semicolon. The first string 
  17909.      represents the ante meridian designation, the last string the post 
  17910.      meridian designation. 
  17911.  
  17912.  t_fmt_ampm 
  17913.      Defines the appropriate time representation in the 12-hour clock format 
  17914.      with am_pm, corresponding to the %r field descriptor. The operand consists 
  17915.      of a string and can contain any combination of characters and field 
  17916.      descriptors. 
  17917.  
  17918.  era 
  17919.      Defines how the years are counted and displayed for each era (or emperor's 
  17920.      reign) in a locale. 
  17921.  
  17922.      No era is needed if the %E field descriptor modifier is not used for the 
  17923.      locale. 
  17924.  
  17925.      For each era, there must be one string in the following format: 
  17926.  
  17927.           direction:offset:start_date:end_date:name:format
  17928.  
  17929.      where 
  17930.  
  17931.      direction 
  17932.               Either a + or - character. The + character indicates the time 
  17933.               axis should be such that the years count in the positive 
  17934.               direction when moving from the starting date towards the ending 
  17935.               date. The - character indicates the time axis should be such that 
  17936.               the years count in the negative direction when moving from the 
  17937.               starting date towards the ending date. 
  17938.  
  17939.      offset 
  17940.               A number of the first year of the era. 
  17941.  
  17942.      start_date 
  17943.               A date in the form yyyy/mm/dd where yyyy, mm and dd are the year, 
  17944.               month and day numbers, respectively, of the start of the era. 
  17945.               Years prior to the year AD 0 are represented as negative numbers. 
  17946.               For example, an era beginning March 5th in the year 100 BC would 
  17947.               be represented as -100/3/5. 
  17948.  
  17949.      end_date 
  17950.               The ending date of the era in the same form as the start_date 
  17951.               above or one of the two special values -* or +*. A value of -* 
  17952.               indicates the ending date of the era extends to the beginning of 
  17953.               time while +* indicates it extends to the end of time. The ending 
  17954.               date may be either before or after the starting date of an era. 
  17955.               For example, the strings for the Christian eras AD and BC would 
  17956.               be: 
  17957.  
  17958.                             +:0:0000/01/01:+*:AD:%EC %Ey
  17959.                             +:1:-0001/12/31:-*:BC:%EC %Ey
  17960.  
  17961.      name 
  17962.               A string representing the name of the era which is substituted 
  17963.               for the %EC field descriptor. 
  17964.  
  17965.      format 
  17966.               A string for formatting the %EY field descriptor. This string is 
  17967.               usually a function of the %EC and %Ey field descriptors. 
  17968.  
  17969.      The operand consists of one string for each era. If there is more than one 
  17970.      era, strings are separated by semicolons. 
  17971.  
  17972.  era_year 
  17973.      Defines the format of the year in alternate era format, corresponding to 
  17974.      the %EY field descriptor. 
  17975.  
  17976.  era_d_fmt 
  17977.      Defines the format of the date in alternate era notation, corresponding to 
  17978.      the %Ex field descriptor. 
  17979.  
  17980.  alt_digits 
  17981.      Defines alternate symbols for digits, corresponding to the %O field 
  17982.      descriptor modifier. The operand consists of semicolon-separated strings. 
  17983.      The first string is the alternate symbol corresponding to zero, the second 
  17984.      string the symbol corresponding to one, and so forth.  A maximum of 100 
  17985.      alternate strings may be specified. The %O modifier indicates that the 
  17986.      string corresponding to the value specified by the field descriptor is 
  17987.      used instead of the value. 
  17988.  
  17989.  
  17990. ΓòÉΓòÉΓòÉ 20.6. LC_MESSAGES Category ΓòÉΓòÉΓòÉ
  17991.  
  17992. The LC_MESSAGES category defines the format and values for positive and 
  17993. negative responses. 
  17994.  
  17995. The following keywords are recognized: 
  17996.  
  17997.  copy 
  17998.      Specifies the name of an existing locale to be used as the source for the 
  17999.      definition of this category. If you specify this keyword, no other keyword 
  18000.      should be present in this category. If the locale is not found, an error 
  18001.      is reported and no locale output is created. The copy keyword cannot 
  18002.      specify a locale that also specifies the copy keyword for the same 
  18003.      category. 
  18004.  
  18005.  yesexpr 
  18006.      The operand consists of an extended regular expression that describes the 
  18007.      acceptable affirmative response to a question that expects an affirmative 
  18008.      or negative response. 
  18009.  
  18010.  noexpr 
  18011.      The operand consists of an extended regular expression that describes the 
  18012.      acceptable negative response to a question that expects an affirmative or 
  18013.      negative response. 
  18014.  Here is an example that shows how to define the LC_MESSAGES category: 
  18015.  
  18016.   #############
  18017.   LC_MESSAGES
  18018.   #############
  18019.   # yes expression is a string that starts with
  18020.   # "SI", "Si" "sI" "si" "s" or "S"
  18021.   yesexpr "<circumflex><left-parenthesis><left-square-bracket><s><S>\
  18022.   <right-square-bracket><left-square-bracket><i><I><right-square-bracket>\
  18023.   <vertical-line><left-square-bracket><s><S><right-square-bracket>\
  18024.   <right-parenthesis>"
  18025.  
  18026.   # no expression is a string that starts with
  18027.   # "NO", "No" "nO" "no" "N" or "n"
  18028.   noexpr "<circumflex><left-parenthesis><left-square-bracket><n><N>\
  18029.   <right-square-bracket><left-square-bracket><o><O><right-square-bracket>\
  18030.   <vertical-line><left-square-bracket><n><N><right-square-bracket>\
  18031.   <right-parenthesis>"
  18032.  
  18033.   END LC_MESSAGES
  18034.  
  18035.  
  18036. ΓòÉΓòÉΓòÉ 20.7. LC_TOD Category ΓòÉΓòÉΓòÉ
  18037.  
  18038. The LC_TOD category defines the rules used to define the beginning, end, and 
  18039. duration of daylight savings time, and the difference between local time and 
  18040. Greenwich Mean time. This is an IBM extension. 
  18041.  
  18042. The following keywords are recognized: 
  18043.  
  18044.  copy 
  18045.      Specifies the name of an existing locale to be used as the source for the 
  18046.      definition of this category. If this keyword is specified, no other 
  18047.      keyword should be present in this category. If the locale is not found, an 
  18048.      error is reported and no locale output is created. The copy keyword cannot 
  18049.      specify a locale that also specifies the copy keyword for the same 
  18050.      category. 
  18051.  
  18052.  timezone_difference 
  18053.      An integer specifying the time zone difference expressed in minutes. If 
  18054.      the local time zone is west of the Greenwich Meridian, this value must be 
  18055.      positive. If the local time zone is east of the Greenwich Meridian, this 
  18056.      value must be negative. An absolute value greater than 1440 (the number of 
  18057.      minutes in a day) for this keyword indicates that the run time library is 
  18058.      to get the time zone difference from the system. 
  18059.  
  18060.  timezone_name 
  18061.      A string specifying the time zone name such as "PST" (Pacific Standard 
  18062.      Time) specified within quotation marks. The default for this field is a 
  18063.      NULL string. 
  18064.  
  18065.  daylight_name 
  18066.      A string specifying the Daylight Saving Time zone name, such as "PDT" 
  18067.      (Pacific Daylight Time), if there is one available.  The string must be 
  18068.      specified within quotation marks. If DST information is not available, 
  18069.      this is set to NULL, which is also the default. This field must be filled 
  18070.      in if DST information as provided by the other fields is to be taken into 
  18071.      account by the mktime and localtime functions. These functions ignore DST 
  18072.      if this field is NULL. 
  18073.  
  18074.  start_month 
  18075.      An integer specifying the month of the year when Daylight Saving Time 
  18076.      comes into effect. This value ranges from 1 through 12 inclusive, with 1 
  18077.      corresponding to January and 12 corresponding to December. If DST is not 
  18078.      applicable to a locale, start_month is set to 0, which is also the 
  18079.      default. 
  18080.  
  18081.  end_month 
  18082.      An integer specifying the month of the year when Daylight Saving Time 
  18083.      ceases to be in effect. The specifications are similar to those for 
  18084.      start_month. 
  18085.  
  18086.  start_week 
  18087.      An integer specifying the week of the month when DST comes into effect. 
  18088.      Acceptable values range from -4 to +4. A value of 4 means the fourth week 
  18089.      of the month, while a value of -4 means fourth week of the month, counting 
  18090.      from the end of the month. Sunday is considered to be the start of the 
  18091.      week. If DST is not applicable to a locale, start_week is set to 0, which 
  18092.      is also the default. 
  18093.  
  18094.  end_week 
  18095.      An integer specifying the week of the month when DST ceases to be in 
  18096.      effect. The specifications are similar to those for start_week. 
  18097.  
  18098.      Note:  The start_week and end_week need not be used. The start_day and 
  18099.      end_day fields can specify either the day of the week or the day of the 
  18100.      month. If day of month is specified, start_week and end_week become 
  18101.      redundant. 
  18102.  
  18103.  start_day 
  18104.      An integer specifying the day of the week or the day of the month when DST 
  18105.      comes into effect. The value depends on the value of start_week. If 
  18106.      start_week is not equal to 0, this is the day of the week when DST comes 
  18107.      into effect. It ranges from 0 through 6 inclusive, with 0 corresponding to 
  18108.      Sunday and 6 corresponding to Saturday. If start_week equals 0, start_day 
  18109.      is the day of the month (for the current year) when DST comes into effect. 
  18110.      It ranges from 1 through to the last day of the month inclusive. The last 
  18111.      day of the month is 31 for January, March, May, July, August, October, and 
  18112.      December. It is 30 for April, June, September, and November. For February, 
  18113.      it is 28 on non-leap years and 29 on leap years. If DST is not applicable 
  18114.      to a locale, start_day is set to 0, which is also the default. 
  18115.  
  18116.  end_day 
  18117.      An integer specifying the day of the week or the day of the month when DST 
  18118.      ceases to be in effect. The specifications are similar to those for 
  18119.      start_day. 
  18120.  
  18121.  start_time 
  18122.      An integer specifying the number of seconds after 12:00 midnight, local 
  18123.      standard time, when DST comes into effect. For example, if DST is to start 
  18124.      at 2:am, start_time is assigned the value 7200; for 12:00 am (midnight), 
  18125.      start_time is 0; for 1:00 am, it is 3600. 
  18126.  
  18127.  end_time 
  18128.      An integer specifying the number of seconds after 12 midnight, local 
  18129.      standard time, when DST ceases to be in effect. The specifications are 
  18130.      similar to those for start_time. 
  18131.  
  18132.  shift 
  18133.      An integer specifying the DST time shift, expressed in seconds.  The 
  18134.      default is 3600, for 1 hour. 
  18135.  
  18136.  uctname 
  18137.      A string specifying the name to be used for Coordinated Universal Time. If 
  18138.      this keyword is not specified, the uctname will default to "UTC". 
  18139.  Here is an example of how to define the LC_TOD category: 
  18140.  
  18141.   #############
  18142.   LC_TOD
  18143.   #############
  18144.   # the time zone difference is 8hrs; the name of the daylight saving
  18145.   # time is PDT, and it starts on the first Sunday of April at
  18146.   # 2:00AM and ends on the second Sunday of October at
  18147.   # 2:00AM
  18148.   timezone_difference +480
  18149.   timezone_name    "<P><S><T>"
  18150.   daylight_name    "<P><D><T>"
  18151.   start_month     4
  18152.   end_month      10
  18153.   start_week      1
  18154.   end_week       2
  18155.   start_day      1
  18156.   end_day       30
  18157.   start_time      7200
  18158.   end_time       3600
  18159.   shift        3600
  18160.   END LC_TOD
  18161.  
  18162.  
  18163. ΓòÉΓòÉΓòÉ 20.8. LC_SYNTAX Category ΓòÉΓòÉΓòÉ
  18164.  
  18165. The LC_SYNTAX category defines the variant characters from the portable 
  18166. character set. LC_SYNTAX is an IBM-specific extension. This category can be 
  18167. queried by the C library function getsyntx to determine the encoding of a 
  18168. variant character if needed. 
  18169.  
  18170. Warning: Customizing the LC_SYNTAX category is not recommended. You should use 
  18171. the LC_SYNTAX values obtained from the charmap file when you use the LOCALDEF 
  18172. utility. 
  18173.  
  18174. The operands for the characters in the LC_SYNTAX category accept the single 
  18175. byte character specification in the form of a symbolic name, the character 
  18176. itself, or the decimal, octal, or hexadecimal constant. The characters must be 
  18177. specified in the LC_CTYPE category as a punct character. The values for the 
  18178. LC_SYNTAX characters must be unique. If symbolic names are used to define the 
  18179. encoding, only the symbolic names listed for each character should be used. 
  18180.  
  18181. The code points for the LC_SYNTAX characters are set to the code points 
  18182. specified.  Otherwise, they default to the code points for the respective 
  18183. characters from the charmap file, if the file is present, or to the code points 
  18184. of the respective characters in the IBM-850 code page. 
  18185.  
  18186. The following keywords are recognized: 
  18187.  
  18188.  copy 
  18189.      Specifies the name of an existing locale to be used as the source for the 
  18190.      definition of this category. If you specify this keyword, no other keyword 
  18191.      should be present. 
  18192.  
  18193.      If the locale is not found, an error is reported and no locale output is 
  18194.      created. The copy keyword cannot specify a locale that also specifies the 
  18195.      copy keyword for the same category. 
  18196.  
  18197.  backslash 
  18198.      Specifies a string that defines the value used to represent the backslash 
  18199.      character. If this keyword is not specified, the value from the charmap 
  18200.      file for the character <backslash>, <reverse-solidus>, or <SM07> is used, 
  18201.      if it is present. 
  18202.  
  18203.  right_brace 
  18204.      Specifies a string that defines the value used to represent the right 
  18205.      brace character. If this keyword is not specified, the value from the 
  18206.      charmap file for the character <right-brace>, <right-curly-bracket>, or 
  18207.      <SM14> is used, if it is present. 
  18208.  
  18209.  left_brace 
  18210.      Specifies a string that defines the value used to represent the left brace 
  18211.      character. If this keyword is not specified, the value from the charmap 
  18212.      file for the character <left-brace>, <left-curly-bracket>, or <SM11> is 
  18213.      used, if it is present. 
  18214.  
  18215.  right_bracket 
  18216.      Specifies a string that defines the value used to represent the right 
  18217.      bracket character. If this keyword is not specified, the value from the 
  18218.      charmap file for the character <right-square-bracket>, or <SM08> is used, 
  18219.      if it is present. 
  18220.  
  18221.  left_bracket 
  18222.      Specifies a string that defines the value used to represent the left 
  18223.      bracket character. If this keyword is not specified, the value from the 
  18224.      charmap file for the character <left-square-bracket>, or <SM06> is used, 
  18225.      if it is present. 
  18226.  
  18227.  circumflex 
  18228.      Specifies a string that defines the value used to represent the circumflex 
  18229.      character. If this keyword is not specified, the value from the charmap 
  18230.      file for the character <circumflex>, <circumflex-accent>, or <SD15> is 
  18231.      used, if it is present. 
  18232.  
  18233.  tilde 
  18234.      Specifies a string that defines the value used to represent the tilde 
  18235.      character. If this keyword is not specified, the value from the charmap 
  18236.      file for the character <tilde>, or <SD19> is used, if it is present. 
  18237.  
  18238.  exclamation_mark 
  18239.      Specifies a string that defines the value used to represent the 
  18240.      exclamation mark character. If this keyword is not specified, the value 
  18241.      from the charmap file for the character <exclamation-mark>, or <SP02> is 
  18242.      used, if it is present. 
  18243.  
  18244.  number_sign 
  18245.      Specifies a string that defines the value used to represent the number 
  18246.      sign character. If this keyword is not specified, the value from the 
  18247.      charmap file for the character <number-sign>, or <SM01> is used, if it is 
  18248.      present. 
  18249.  
  18250.  vertical_line 
  18251.      Specifies a string that defines the value used to represent the vertical 
  18252.      line character. If this keyword is not specified, the value from the 
  18253.      charmap file for the character <vertical-line>, or <SM13> is used, if it 
  18254.      is present. 
  18255.  
  18256.  dollar_sign 
  18257.      Specifies a string that defines the value used to represent the dollar 
  18258.      sign character. If this keyword is not specified, the value from the 
  18259.      charmap file for the character <dollar-sign>, or <SC03> is used, if it is 
  18260.      present. 
  18261.  
  18262.  commercial_at 
  18263.      Specifies a string that defines the value used to represent the commercial 
  18264.      at character. If this keyword is not specified, the value from the charmap 
  18265.      file for the character <commercial-at>, or <SM05> is used, if it is 
  18266.      present. 
  18267.  
  18268.  grave_accent 
  18269.      Specifies a string that defines the value used to represent the grave 
  18270.      accent character. If this keyword is not specified, the value from the 
  18271.      charmap file for the character <grave-accent>, or <SD13> is used, if it is 
  18272.      present. 
  18273.  Here is an example of how the LC_SYNTAX category is defined: 
  18274.  
  18275.   #############
  18276.   LC_SYNTAX
  18277.   #############
  18278.  
  18279.   backslash     "<backslash>"
  18280.   right_brace    "<right-brace>"
  18281.   left_brace    "<left-brace>"
  18282.   right_bracket   "<right-square-bracket>"
  18283.   left_bracket   "<left-square-bracket>"
  18284.   circumflex    "<circumflex>"
  18285.   tilde       "<tilde>"
  18286.   exclamation_mark "<exclamation-mark>"
  18287.   number_sign    "<number-sign>"
  18288.   vertical_line   "<vertical-line>"
  18289.   dollar_sign    "<dollar-sign>"
  18290.   commercial_at   "<commercial-at>"
  18291.   grave_accent   "<grave-accent>"
  18292.  
  18293.   END LC_SYNTAX
  18294.  
  18295.  
  18296. ΓòÉΓòÉΓòÉ 21. Regular Expressions ΓòÉΓòÉΓòÉ
  18297.  
  18298. Regular Expressions (REs) are used to determine if a character string of 
  18299. interest is matched somewhere in a set of character strings.  You can specify 
  18300. more than one character string for which you wish to determine if a match 
  18301. exists. Regular Expressions use collating values from the current locale 
  18302. definition file in the matching process. 
  18303.  
  18304. The search for a matching sequence starts at the beginning of the string and 
  18305. stops when the first sequence matching the expression is found. The first 
  18306. sequence is the one that begins earliest in the string. If the pattern permits 
  18307. matching several sequences at this starting point, the longest sequence is 
  18308. matched. 
  18309.  
  18310. To use a regular expression, first compile it with regcomp. You can then use 
  18311. regexec to compare the compiled expression to other expressions. If an error 
  18312. occurs, regerror provides information about the error. When you have finished 
  18313. with the expression, use regfree to free it from memory. All of these functions 
  18314. are described in more detail in the C Library Reference. 
  18315.  
  18316.  
  18317. ΓòÉΓòÉΓòÉ 21.1. Basic Matching Rules ΓòÉΓòÉΓòÉ
  18318.  
  18319. Within an RE: 
  18320.  
  18321.      An ordinary character matches itself. The simplest form of regular 
  18322.       expression is a string of characters with no special meaning. 
  18323.      A special character preceded by a backslash matches itself. For basic 
  18324.       regular expressions (BREs), the special characters are: 
  18325.  
  18326.               . [ \ * ^ $
  18327.  
  18328.       For extended regular expressions (EREs), the special characters also 
  18329.       include: 
  18330.  
  18331.               ( ) + ? { |
  18332.  
  18333.       (EREs are supported when you specify the REG_EXTENDED flag.) 
  18334.      A period (.) without a backslash matches any single character.  For EREs, 
  18335.       it matches any character except the null character. 
  18336.      An expression within square brackets ([ ]), called a bracket expression, 
  18337.       matches one or more characters or collating elements. 
  18338.  
  18339.  Bracket Expressions 
  18340.  
  18341.  A bracket expression itself contains one or more expressions that represent 
  18342.  characters, collating symbols, equivalence or character classes, or range 
  18343.  expressions: 
  18344.  
  18345.  [string] Matches any of the characters specified. For example, [abc] matches 
  18346.          any of a, b, or c. 
  18347.  
  18348.  [^string] Does not match any of the characters in string. The caret 
  18349.          immediately following the left bracket ([) negates the characters that 
  18350.          follow.  For example, [^abc] matches any character or collating 
  18351.          element except a, b, or c. 
  18352.  
  18353.  [collat_sym-collat_sym] Matches any collating elements that fall between the 
  18354.          two specified collating symbols, inclusive. The two symbols must be 
  18355.          different, and the second symbol must collate equal to or higher than 
  18356.          the first. For example, in the "C" locale, [r-t] would match any of r, 
  18357.          s, or t. 
  18358.  
  18359.          Note:  To treat the hyphen (-) as itself, place it either first or 
  18360.          last in the bracket expression, for example: [-rt] or [rt-]. Both of 
  18361.          these expressions would match -, r, or t. 
  18362.  
  18363.  [[.collat_symbl.]] Matches the collating element represented by the specified 
  18364.          single or multicharacter collating symbol collat_symbl. For example, 
  18365.          assuming that <ch> is the collating symbol for ch in the current 
  18366.          locale, [[.ch.]] matches the character sequence ch. (In contrast, [ch] 
  18367.          matches c or h.) If collat_symbl is not a collating element in the 
  18368.          current locale, or if it has no characters associated with it, it is 
  18369.          treated as an invalid expression. 
  18370.  
  18371.  [[=collat_symbl=]] Matches all collating elements that have a weight 
  18372.          equivalent to the specified single or multicharacter collating symbol 
  18373.          collat_symbl. For example, assuming a, ╨ò, and ╨ô belong to the same 
  18374.          equivalence class, [[=a=]] matches any of the three.  If the collating 
  18375.          symbol does not have any equivalents, it is treated as a collating 
  18376.          symbol and matches its corresponding collating element (as for [..]). 
  18377.  
  18378.  [[:char_class:]] Matches any characters that belong to the specified character 
  18379.          class char_class. For example, [[:alnum:]] matches all alphanumeric 
  18380.          characters (characters for which isalnum would return nonzero). 
  18381.  
  18382.  Note:  To use the right bracket (]) in a bracket expression, you must specify 
  18383.  it immediately following the left bracket ([) or caret symbol (^).  For 
  18384.  example, []x] matches the characters ] and x; [^]x] does not match ] or x; 
  18385.  [x]] is not valid. 
  18386.  
  18387.  You can combine characters, special characters, and bracket expressions to 
  18388.  form REs that match multiple characters and subexpressions. When you 
  18389.  concatenate the characters and expressions, the resulting RE matches any 
  18390.  string that matches each component within the RE. For example, cd matches 
  18391.  characters 3 and 4 of the string abcde; ab[[:digit:]] matches ab3 but not abc. 
  18392.  For EREs, you can optionally enclose the concatenation in parentheses. 
  18393.  
  18394.  
  18395. ΓòÉΓòÉΓòÉ 21.2. Additional Syntax Specifiers ΓòÉΓòÉΓòÉ
  18396.  
  18397. You can also use other syntax within an RE to control what it matches: 
  18398.  
  18399.  \(expression\) Matches whatever expression matches.  You only need to enclose 
  18400.          an expression in these delimiters to use operators (such as * or +) on 
  18401.          it and to denote subexpressions for backreferencing (explained later 
  18402.          in this section). For EREs, use the parentheses without the 
  18403.          backslashes: (subexpression) 
  18404.  
  18405.  \n      Matches the same string that was matched by the nth preceding 
  18406.          expression enclosed in \( \) or, for EREs, ( ). This is called a 
  18407.          backreference. n can be 1 through 9. For example, \(ab\)\1 matches 
  18408.          abab, but does not match ac. If fewer than n subexpressions precede 
  18409.          \n, the backreference is not valid. 
  18410.  
  18411.          Note:  You cannot use backreferences in EREs. 
  18412.  
  18413.  expression* Matches zero or more consecutive occurrences of what expression 
  18414.          matches. expression can be a single character or collating symbol, a 
  18415.          subexpression, or a backreference (for BREs). For example, [ab]* 
  18416.          matches ab and ababab; b*cd matches characters 3 to 7 of cabbbcdeb. 
  18417.  
  18418.  expression\{m\} Matches exactly m occurrences of what expression matches. 
  18419.          expression can be a single character or collating symbol, a 
  18420.          subexpression, or a backreference (for BREs). For example, c\{3\} 
  18421.          matches characters 5 through 7 of ababccccd (the first 3 c characters 
  18422.          only). For EREs, use the braces without the backslashes: {m} 
  18423.  
  18424.  expression\{m,\} Matches at least m occurrences of what expression matches. 
  18425.          expression can be a single character or collating symbol, a 
  18426.          subexpression, or a backreference (for BREs). For example, 
  18427.          \(ab\)\{3,\} matches abababab, but does not match ababac. For EREs, 
  18428.          use the braces without the backslashes: {m,} 
  18429.  
  18430.  expression\{m,u\} Matches any number of occurrences, between m and u 
  18431.          inclusive, of what expression matches. expression can be a single 
  18432.          character or collating symbol, a subexpression, or a backreference 
  18433.          (for BREs). For example, bc\{1,3\} matches characters 2 through 4 of 
  18434.          abccd and characters 3 through 6 of abbcccccd For EREs, use the braces 
  18435.          without the backslashes: {m,u} 
  18436.  
  18437.  ^expression Matches only sequences that match expression that start at the 
  18438.          first character of a string or after a new-line character if the 
  18439.          REG_NEWLINE flag was specified. For example, ^ab matches ab in the 
  18440.          string abcdef, but does not match it in the string cdefab. The 
  18441.          expression can be the entire RE or any subexpression of it. 
  18442.  
  18443.          Portability Note  When ^ is the first character of a subexpression, 
  18444.          other implemenations could interpret it as a literal character. To 
  18445.          ensure portability, avoid using ^ at the beginning of a subexpression; 
  18446.          to use it as a literal character, precede it with a backslash. 
  18447.  
  18448.  expression$ Matches only sequences that match expression that end the string 
  18449.          or that precede the new-line character if the REG_NEWLINE flag was 
  18450.          specified. For example, ab$ matches ab in the string cdefab but does 
  18451.          not match it in the string abcdef. The expression must be the entire 
  18452.          RE. 
  18453.  
  18454.          Portability Note  When $ is the last character of a subexpression, it 
  18455.          is treated as a literal character. Other implementations could 
  18456.          interpret is as described above. To ensure portability, avoid using $ 
  18457.          at the end of a subexpression; to use it as a literal character, 
  18458.          precede it with a backslash. 
  18459.  
  18460.  ^expression$ Matches only an entire string, or an entire line if the 
  18461.          REG_NEWLINE flag was specified. For example, ^abcde$ matches only 
  18462.          abcde. 
  18463.  
  18464.  In addition to those listed above, you can also use the following specifiers 
  18465.  for EREs (they are not valid for BREs): 
  18466.  
  18467.  expression+ Matches what one or more occurrences of expression matches.  For 
  18468.          example, a+(bc) matches aaaaabc; (bc)+ matches characters 1 through 6 
  18469.          of bcbcbcbb. 
  18470.  
  18471.  expression? Matches zero or one consecutive occurrences of what expression 
  18472.          matches. For example, b?c matches character 2 of acabbb (zero 
  18473.          occurrences of b followed by c). 
  18474.  
  18475.  expression|expression Matches a string that matches either expression.  For 
  18476.          example, a((bc)|d) matches both abc and ad. 
  18477.  
  18478.  
  18479. ΓòÉΓòÉΓòÉ 21.3. Order of precedence ΓòÉΓòÉΓòÉ
  18480.  
  18481. Like C and C++ operators, the Regular Expression (RE) syntax specifiers are 
  18482. processed in a specific order. The order of precedence for Basic Regular 
  18483. Expressions (BREs) and Extended Regular Expressions (EREs) are described below, 
  18484. from highest to lowest. The specifiers in each category are also listed in 
  18485. order of precedence. 
  18486.  
  18487. The order of precedence for Regular Expressions is: 
  18488.  
  18489. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18490. Γöé Collation-related bracket    Γöé [==]  [::]  [..]        Γöé
  18491. Γöé symbols             Γöé                Γöé
  18492. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18493. Γöé Special characters       Γöé \spec_char           Γöé
  18494. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18495. Γöé Bracket expressions       Γöé [ΓêÖ               Γöé
  18496. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18497. Γöé Subexpressions and backrefer-  Γöé \(\)  \n            Γöé
  18498. Γöé ences              Γöé                Γöé
  18499. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18500. Γöé Repetition           Γöé *  \{m\}  \{m,\}  \{m,n\}   Γöé
  18501. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18502. Γöé Concatenation          Γöé                Γöé
  18503. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18504. Γöé Anchoring            Γöé ^  $              Γöé
  18505. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18506.  
  18507. The order of precedence for Extended Regular Expressions is: 
  18508.  
  18509. ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18510. Γöé Collation-related bracket    Γöé [==]  [::]  [..]        Γöé
  18511. Γöé symbols             Γöé                Γöé
  18512. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18513. Γöé Special characters       Γöé \spec_char           Γöé
  18514. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18515. Γöé Bracket expressions       Γöé [ΓêÖ               Γöé
  18516. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18517. Γöé Grouping            Γöé ()               Γöé
  18518. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18519. Γöé Repetition           Γöé *  +  ?  {m}  {m,}  {m,n}   Γöé
  18520. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18521. Γöé Concetenation          Γöé                Γöé
  18522. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18523. Γöé Anchoring            Γöé ^  $              Γöé
  18524. Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18525. Γöé Alternation           Γöé |               Γöé
  18526. ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18527.  
  18528.  
  18529. ΓòÉΓòÉΓòÉ 22. Mapping ΓòÉΓòÉΓòÉ
  18530.  
  18531. This appendix describes how the VisualAge for C++ compiler maps data types into 
  18532. storage and the alignment of each data type and the mapping of its bits. The 
  18533. mapping of identifier names is also discussed, as is the encoding scheme used 
  18534. by the compiler for encoding or mangling C++ function names. 
  18535.  
  18536.      Name Mapping 
  18537.      Data Mapping 
  18538.      Demangling (Decoding) C++ Function Names 
  18539.  
  18540.  
  18541. ΓòÉΓòÉΓòÉ 22.1. Name Mapping ΓòÉΓòÉΓòÉ
  18542.  
  18543. To prevent conflicts between user-defined identifiers (variable names or 
  18544. functions) and VisualAge for C++ library functions, do not use the name of any 
  18545. library function or external variable defined in the library as a user-defined 
  18546. function. 
  18547.  
  18548. If you statically link to the VisualAge for C++ runtime libraries (using the 
  18549. /Gd- option), all external names beginning with: Vio or Kbd (in the case given) 
  18550. become reserved external identifiers. These names are not reserved if you 
  18551. dynamically link to the libraries. 
  18552.  
  18553. To prevent conflicts with internal names, do not use an underscore at the start 
  18554. of any of your external names; these identifiers are reserved for use by the 
  18555. compiler and libraries. The internal VisualAge for C++ identifier names that 
  18556. are not listed in either the Language Reference or this manual all begin with 
  18557. an underscore (_). 
  18558.  
  18559. If you have an application that uses a restricted name as an identifier, change 
  18560. your code or use a macro to globally redefine the name and avoid conflicts. You 
  18561. can also use the #pragma map directive to convert the name, but this directive 
  18562. is not portable outside of SAA. 
  18563.  
  18564. A number of functions and variables that existed in the IBM C/2 and Microsoft C 
  18565. Version 6.0 compilers are implemented in the VisualAge for C++ product, but 
  18566. with a preceding underscore to conform to ANSI naming requirements. When you 
  18567. run the VisualAge for C++ compiler in extended mode (which is the default) and 
  18568. include the appropriate library header file, the original names are mapped to 
  18569. the new names for you. For example, the function name putenv is mapped to 
  18570. _putenv. When you compile in any other mode, this mapping does not take place. 
  18571.  
  18572. Note:  Because the name timezone is used as a structure field by the Windows 
  18573. operating system, the variable _timezone is not mapped to timezone. 
  18574.  
  18575.  
  18576. ΓòÉΓòÉΓòÉ 22.2. Demangling (Decoding) C++ Function Names ΓòÉΓòÉΓòÉ
  18577.  
  18578. When the VisualAge for C++ compiler compiles a program, it encodes all function 
  18579. names and certain other identifiers to include type and scoping information. 
  18580. This encoding process is called mangling.  The linker uses the mangled names to 
  18581. ensure type-safe linkage.  These mangled names are used in the object files and 
  18582. in the final executable file.  Tools that use these files must use the mangled 
  18583. names and not the original names used in the source code. 
  18584.  
  18585. VisualAge for C++ provides two methods of converting mangled names to the 
  18586. original source code names, demangling functions and the CPPFILT utility. 
  18587.  
  18588.  
  18589. ΓòÉΓòÉΓòÉ 22.2.1. Using the Demangling Functions ΓòÉΓòÉΓòÉ
  18590.  
  18591. The runtime library contains a small class hierarchy of functions that you can 
  18592. use to demangle names and examine the resulting parts of the name.  It also 
  18593. provides a C-language interface you can use in C programs.  The functions use 
  18594. no external C++ features. 
  18595.  
  18596. The demangling functions are available in both the static (.LIB) and dynamic 
  18597. (.DLL) versions of the library. The interface is documented in the <demangle.h> 
  18598. header file. 
  18599.  
  18600. Using the demangling functions, you can write programs to convert a mangled 
  18601. name to a demangled name and to determine characteristics of that name, such as 
  18602. its type qualifiers or scope. For example, given the mangled name of a 
  18603. function, the program returns the demangled name of the function and the names 
  18604. of its qualifiers.  If the mangled name refers to a class member, you can 
  18605. determine if it is static, const, or volatile.  You can also get the whole text 
  18606. of the mangled name. 
  18607.  
  18608. To demangle a name, which is represented as a character array, create a dynamic 
  18609. instance of the Name class and provide the character string to the class's 
  18610. constructor.  For example, to demangle the name f__1XFi, create: 
  18611.  
  18612.   char *rest;
  18613.   Name *name = Demangle("f__1XFi", rest);
  18614.  
  18615. The demangling functions classify names into five categories: function names, 
  18616. member function names, special names, class names, and member variable names. 
  18617. After you construct an instance of class Name, you can use the Kind member 
  18618. function of Name to determine what kind of Name the instance is. Based on the 
  18619. kind of name returned, you can ask for the text of the different parts of the 
  18620. name or of the entire name. 
  18621.  
  18622. For the mangled name f__1XFi, you can determine: 
  18623.  
  18624.   name->Kind() == MemberFunction
  18625.   ((MemberFunctionName *) name)->Scope()->Text() is "X"
  18626.   ((MemberFunctionName *) name)->RootName() is "f"
  18627.   ((MemberFunctionName *) name)->Text() is "X::f(int)"
  18628.  
  18629. If the character string passed to the Name constructor is not a mangled name, 
  18630. the Demangle function returns NULL. 
  18631.  
  18632. For further details about the demangling functions and their C++ and C 
  18633. interfaces, refer to the information contained in the <demangle.h> header file. 
  18634. If you installed using the defaults, this header file should be in the INCLUDE 
  18635. directory under the main VisualAge for C++ installation directory. 
  18636.  
  18637.  
  18638. ΓòÉΓòÉΓòÉ 22.2.2. Using the CPPFILT Utility ΓòÉΓòÉΓòÉ
  18639.  
  18640. The VisualAge for C++ product also provides the CPPFILT utility to convert 
  18641. mangled names to demangled names. You can use this utility with: 
  18642.  
  18643.      An ASCII text file to substitute demangled names for any mangled names 
  18644.       found in the text. 
  18645.      A binary (object or library) file to produce a list of demangled names 
  18646.       including exported, public, and referenced symbol names. 
  18647.  
  18648.  All CPPFILT output is sent to stdout.  You can use the standard Windows 
  18649.  redirection symbols to redirect the output to a file. 
  18650.  
  18651.  One of the applications of this utility is creating module definition files 
  18652.  for your C++ DLLs.  Because functions in the DLL have mangled names, when you 
  18653.  list the EXPORTS in your .DEF, you must use the mangled names. You can use the 
  18654.  CPPFILT utility to extract all the names from the object module for you. Copy 
  18655.  the ones you want to export into your .DEF file. 
  18656.  
  18657.  The CPPFILT syntax is: 
  18658.  
  18659.   ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18660.   Γöé                                 Γöé
  18661.   Γöé        ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ  ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ           Γöé
  18662.   Γöé              Γöé         Γöé           Γöé
  18663.   Γöé >>ΓöÇΓöÇCPPFILTΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö┤ΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ>< Γöé
  18664.   Γöé        ΓööΓöÇ/optionΓöÇΓöÿ   ΓööΓöÇfilenameΓöÇΓöÿ            Γöé
  18665.   Γöé                                 Γöé
  18666.   ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18667.  
  18668.  where option is one or more CPPFILT options and filename is the name of the 
  18669.  file containing the mangled names.  If you do not specify a filename, CPPFILT 
  18670.  reads the input from stdin.  If you specify the /B option to run CPPFILT in 
  18671.  binary mode, you must specify a filename. The file specified must be in the 
  18672.  current directory unless you specify the full path name.  CPPFILT will also 
  18673.  search for library files along the paths specified in the LIB environment 
  18674.  variable if it cannot find them in the current directory. 
  18675.  
  18676.  You can specify options in upper- or lowercase and precede them with either a 
  18677.  slash (for example, /B) or a dash (-B). By default, all options are off. 
  18678.  
  18679.  Three options apply to both text and binary files: 
  18680.  
  18681.  /H or /? Display online help on the CPPFILT command syntax and options. 
  18682.  /Q      Suppress the logo and copyright notice display. 
  18683.  /S      Demangle compiler-generated symbol names. 
  18684.  
  18685.  The following options apply only to text files: 
  18686.  
  18687.  /C      Demangle stand-alone class names, meaning names that do not appear 
  18688.          within the context of a function name or member variable. The compiler 
  18689.          does not usually produce these names.  For example, Q2_1X1Y would be 
  18690.          demangled as X::Y if you specify /C.  Otherwise it is not demangled. 
  18691.  
  18692.  /M      Produce a symbol map containing a list of the mangled names and the 
  18693.          corresponding demangled names.  The symbol map is displayed after the 
  18694.          usual CPPFILT output. 
  18695.  
  18696.  /T      Replace each mangled name in the text with its demangled name followed 
  18697.          by the mangled name. (The default is to replace the mangled name with 
  18698.          the demangled name only.) 
  18699.  
  18700.  /W width Set the width of the field for demangled names in the output to width 
  18701.          characters.  If a demangled name is shorter than width, it is padded 
  18702.          to the right with blanks; if longer, it is truncated to width 
  18703.          characters.  If you do not specify the /W option, there is no fixed 
  18704.          width for the field. 
  18705.  
  18706.  The following options apply only to binary (object and library) files: 
  18707.  
  18708.  /B      Run in binary mode.  If you do not explicitly specify this option, 
  18709.          CPPFILT runs in text mode. 
  18710.  
  18711.  /N      Generate the NONAME keyword, used in EXPORTS statements in module 
  18712.          definition files, to indicate that the exported names should be 
  18713.          referenced by their ordinal numbers only and not by name.  Use this 
  18714.          option with the /O option. 
  18715.  
  18716.  /O [ord] Generate an ordinal number for each demangled name.  You can 
  18717.          optionally specify the ordinal number, ord, that CPPFILT should use as 
  18718.          the first number.  The ordinals are generated with the @ symbol and 
  18719.          are consistent with the module definition file syntax.  For example, 
  18720.          if you specify /O 1000, the output for the first name might look like: 
  18721.  
  18722.  
  18723.                   ;ILinkedSequenceImpl::isConsistent() const
  18724.                   isConsistent__19ILinkedSequenceImplCFv   @1000
  18725.          If you specify /O 1000 /N, the output for the same name would be: 
  18726.  
  18727.                   ;ILinkedSequenceImpl::isConsistent() const
  18728.                   isConsistent__19ILinkedSequenceImplCFv   @1000 NONAME
  18729.  
  18730.  /P      Include all public (COMDAT, COMDEF, or PUBDEF) symbols in the output. 
  18731.          Note that if a COMDAT symbol occurs more than once, only the first 
  18732.          occurrence is included in the output. Subsequent occurrences of the 
  18733.          symbol appear in the output as comments. 
  18734.  
  18735.  /R      Include all referenced (EXTDEF) symbols in the output. 
  18736.  
  18737.  /X      Include all exported (EXPDEF) symbols in the output. 
  18738.  
  18739.  Note:  If you do not specify any of /P, /R, or /X options in binary mode, the 
  18740.  output includes only the demangled library and object names without any symbol 
  18741.  names. 
  18742.  
  18743.  For example, given the command: 
  18744.  
  18745.     CPPFILT /B /P /O 1000 /N C:\IBMCPP\LIB\DDE4CC.LIB
  18746.  
  18747.  CPPFILT would produce output like the following: 
  18748.  
  18749.   ;From library:  c:\ibmcpp\lib\dde4cc.lib
  18750.    ;From object file:  C:\ibmcpp\src\IILNSEQ.C
  18751.    ;PUBDEFs (Symbols available from object file):
  18752.     ;ILinkedSequenceImpl::setToPrevious(ILinkedSequenceImpl::Node*&) const
  18753.     setToPrevious__19ILinkedSequenceImplCFRPQ2_19ILinkedSequenceImpl4Node   @1000 NONAME
  18754.     ;ILinkedSequenceImpl::allElementsDo(void*,void*) const
  18755.     allElementsDo__19ILinkedSequenceImplCFPvT1   @1001 NONAME
  18756.     ;ILinkedSequenceImpl::isConsistent() const
  18757.     isConsistent__19ILinkedSequenceImplCFv   @1002 NONAME
  18758.     ;ILinkedSequenceImpl::setToNext(ILinkedSequenceImpl::Node*&) const
  18759.     setToNext__19ILinkedSequenceImplCFRPQ2_19ILinkedSequenceImpl4Node   @1003 NONAME
  18760.     ;ILinkedSequenceImpl::addAsNext(ILinkedSequenceImpl::Node*, ILinkedSequenceImpl::Node*)
  18761.     addAsNext__19ILinkedSequenceImplFPQ2_19ILinkedSequenceImpl4NodeT1   @1004 NONAME
  18762.    ;From object file:  C:\ibmcpp\src\IITBSEQ.C
  18763.    ;PUBDEFs (Symbols available from object file):
  18764.     ;ITabularSequenceImpl::setToPrevious(ITabularSequenceImpl::Cursor&) const
  18765.     setToPrevious__20ITabularSequenceImplCFRQ2_20ITabularSequenceImpl6Cursor   @1034 NONAME
  18766.     ;ITabularSequenceImpl::allElementsDo(void*)
  18767.     allElementsDo__20ITabularSequenceImplFPv   @1035 NONAME
  18768.     ;ITabularSequenceImpl::removeAll(void*,void*)
  18769.     removeAll__20ITabularSequenceImplFPvT1   @1036 NONAME
  18770.     ;ITabularSequenceImpl::addAllFrom(const ITabularSequenceImpl&)
  18771.     addAllFrom__20ITabularSequenceImplFRC20ITabularSequenceImpl   @1037 NONAME
  18772.    ;From object file:  IIAVLKSS.C
  18773.    ;PUBDEFs (Symbols available from object file):
  18774.     ;IAvlKeySortedSetImpl::allElementsDo(void*,void*) const
  18775.     allElementsDo__20IAvlKeySortedSetImplCFPvT1   @1080 NONAME
  18776.     ;IAvlKeySortedSetImpl::isFirst
  18777.   (const IAvlKeySortedSetImpl::Node*) const
  18778.     isFirst__20IAvlKeySortedSetImplCFPCQ2_20IAvlKeySortedSetImpl4Node   @1081 NONAME
  18779.     ;IAvlKeySortedSetImpl::setToPosition(unsigned long,IAvlKeySortedSetImpl::Node*&) const
  18780.     setToPosition__20IAvlKeySortedSetImplCFUlRPQ2_20IAvlKeySortedSetImpl4Node   @1082 NONAME
  18781.     ;IAvlKeySortedSetImpl::locateOrAddElementWithKey(const void*)
  18782.     locateOrAddElementWithKey__20IAvlKeySortedSetImplFPCv   @1083 NONAME
  18783.     .
  18784.     .
  18785.     .
  18786.  
  18787.  
  18788. ΓòÉΓòÉΓòÉ 22.3. Data Mapping ΓòÉΓòÉΓòÉ
  18789.  
  18790. The following section lists each data format and its equivalent C type in the 
  18791. VisualAge for C++ product, including the alignment and mapping for each. 
  18792.  
  18793. Before we begin the the list of data formats, there are some things you should 
  18794. be aware of: 
  18795.  
  18796.      the mapping of automatic variables 
  18797.  
  18798.       Automatic variables have the same mapping as other variables. When 
  18799.       optimization is turned on, automatic variables are ordered to minimize 
  18800.       padding. Automatic variables are always mapped on the stack instead of a 
  18801.       data segment. Because memory on the stack is constantly reallocated on 
  18802.       the stack, Automatic variables are not guaranteed to be retained after 
  18803.       the return of the function that used them. 
  18804.  
  18805.      the size of word and doubleword 
  18806.  
  18807.       In the VisualAge for C++ product, a word consists of 2 bytes (or 16 
  18808.       bits), and a doubleword consists of 4 bytes (32 bits). 
  18809.  
  18810.      the meaning of the Alignment item in the lists below 
  18811.  
  18812.       In the lists below, Alignment refers to the alignment of the variable 
  18813.       OUTSIDE of a structure, that is, its natural data type alignment. 
  18814.       (Alignment WITHIN a structure can be changed via #pragma pack or /Sp. 
  18815.       For more details on the pragma, see the Language Reference. For more 
  18816.       details on the compiler option, see the User's Guide.) 
  18817.  
  18818.    1. Single-Byte Character 
  18819.  
  18820.       Type                  signed char and unsigned char 
  18821.  
  18822.       Alignment             Byte-aligned. 
  18823.  
  18824.       Storage mapping       Stored in 1 byte. 
  18825.  
  18826.    2. Two-Byte Integer 
  18827.  
  18828.       Type                  short and its signed and unsigned counterparts 
  18829.  
  18830.       Alignment             Word-aligned. 
  18831.  
  18832.       Storage mapping       Byte-reversed, for example, 0x3B2C (where 2C is the 
  18833.                             least significant byte and 3B is the most 
  18834.                             significant byte) is represented in storage as: 
  18835.  
  18836.                                                         Toward high memory 
  18837.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18838.                                                         Γöé BYTEΓöé BYTEΓöé
  18839.                                                         Γöé 0  Γöé 1  Γöé
  18840.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18841.                                                         Γöé 2C  Γöé 3B  Γöé
  18842.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18843.  
  18844.    3. Four-Byte Integer 
  18845.  
  18846.       Type                  long, int, and their signed and unsigned 
  18847.                             counterparts 
  18848.  
  18849.       Alignment             Doubleword-aligned. 
  18850.  
  18851.       Storage mapping       Byte-reversed, for example, 0x4A5D3B2C (where 2C is 
  18852.                             the least significant byte and 4A is the most 
  18853.                             significant byte) is represented in storage as: 
  18854.  
  18855.                                                         Toward high memory 
  18856.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18857.                                                         Γöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé
  18858.                                                         Γöé 0  Γöé 1  Γöé 2  Γöé 3  Γöé
  18859.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18860.                                                         Γöé 2C  Γöé 3B  Γöé 5D  Γöé 4A  Γöé
  18861.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18862.  
  18863.    4. Eight-Byte Integer 
  18864.  
  18865.       Type                  long long and its signed and unsigned counterparts 
  18866.  
  18867.       Alignment             8-byte aligned. 
  18868.  
  18869.       Storage mapping       Byte-reversed, for example, 0x1208164022LL (where 
  18870.                             22 is the least significant byte and 12 is the most 
  18871.                             significant byte) is represented in storage as: 
  18872.  
  18873.                                                         Toward high memory 
  18874.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18875.                                                         Γöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé BYTEΓöé
  18876.                                                         Γöé 0  Γöé 1  Γöé 2  Γöé 3  Γöé 4  Γöé 5  Γöé 6  Γöé 7  Γöé
  18877.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18878.                                                         Γöé 22  Γöé 40  Γöé 16  Γöé 08  Γöé 12  Γöé 00  Γöé 00  Γöé 00  Γöé
  18879.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18880.  
  18881.       Note on IEEE Format 
  18882.  
  18883.       In IEEE format, a floating point number is represented in terms of sign 
  18884.       (S), exponent (E), and fraction (F): 
  18885.  
  18886.              (-1)[S] x 2[E] x 1.F
  18887.  
  18888.       In the diagrams that follow, the first two rows number the bits. Read 
  18889.       them vertically from top to bottom.  The last row indicates the storage 
  18890.       of the parts of the number. 
  18891.  
  18892.    5. Four-Byte Floating Point (IEEE Format) 
  18893.  
  18894.       Type                  float 
  18895.  
  18896.       Alignment             Doubleword-aligned. 
  18897.  
  18898.       Bit mapping           In the internal representation, there is 1 bit for 
  18899.                             the sign (S), 8 bits for the exponent (E), and 23 
  18900.                             bits for the fraction (F). The bits are mapped with 
  18901.                             the fraction in bit 0 to bit 22, the exponent in 
  18902.                             bit 23 to bit 30, and the sign in bit 31: 
  18903.  
  18904.                                                         3 32222222 2221111111111
  18905.                                                         1 09876543 21098765432109876543210
  18906.  
  18907.                                                         S EEEEEEEE FFFFFFFFFFFFFFFFFFFFFFF
  18908.  
  18909.       Storage mapping       The storage mapping is as follows: 
  18910.  
  18911.                                                         Toward high memory 
  18912.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18913.                                                         Γöé BYTE 0   Γöé BYTE 1   Γöé BYTE 2   Γöé BYTE 3   Γöé
  18914.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18915.                                                         Γöé      Γöé 111111   Γöé 22221111  Γöé 33222222  Γöé
  18916.                                                         Γöé 76543210  Γöé 54321098  Γöé 32109876  Γöé 10987654  Γöé
  18917.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18918.                                                         Γöé FFFFFFFF  Γöé FFFFFFFF  Γöé EFFFFFFF  Γöé SEEEEEEE  Γöé
  18919.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18920.  
  18921.    6. Eight-Byte Floating Point (IEEE Format) 
  18922.  
  18923.       Type                  double 
  18924.  
  18925.       Alignment             8-byte-aligned regardless of processor. 
  18926.  
  18927.       Bit mapping           In the internal representation, there is 1 bit for 
  18928.                             the sign (S), 11 bits for the exponent (E), and 52 
  18929.                             bits for the fraction (F). The bits are mapped with 
  18930.                             the fraction in bit 0 to bit 51, the exponent in 
  18931.                             bit 52 to bit 62, and the sign in bit 63: 
  18932.  
  18933.                                                         6 66655555555 554444444444333333333322222222221111111111
  18934.                                                         3 21098765432 1098765432109876543210987654321098765432109876543210
  18935.  
  18936.                                                         S EEEEEEEEEEE FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
  18937.  
  18938.       Storage mapping       The storage mapping is as follows: 
  18939.  
  18940.                                                         Toward high memory 
  18941.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18942.                                                         Γöé BYTE 0   Γöé BYTE 1   Γöé BYTE 2   Γöé ...  Γöé
  18943.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18944.                                                         Γöé      Γöé 111111   Γöé 22221111  Γöé ...  Γöé
  18945.                                                         Γöé 76543210  Γöé 54321098  Γöé 32109876  Γöé    Γöé
  18946.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18947.                                                         Γöé FFFFFFFF  Γöé FFFFFFFF  Γöé FFFFFFFF  Γöé ...  Γöé
  18948.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18949.  
  18950.                                                         Toward high memory 
  18951.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18952.                                                         Γöé byte 5   Γöé byte 6   Γöé byte 7   Γöé
  18953.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18954.                                                         Γöé 44444444  Γöé 55555544  Γöé 66665555  Γöé
  18955.                                                         Γöé 76543210  Γöé 54321098  Γöé 32109876  Γöé
  18956.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18957.                                                         Γöé FFFFFFFF  Γöé EEEEFFFF  Γöé SEEEEEEE  Γöé
  18958.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18959.  
  18960.    7. Ten-Byte Floating Point in Sixteen-Byte Field (IEEE Format) 
  18961.  
  18962.       Type                  long double 
  18963.  
  18964.       Alignment             8-byte aligned regardless of processor. 
  18965.  
  18966.       Bit mapping           In the internal representation, there is 1 bit for 
  18967.                             the sign (S), 15 bits for the exponent (E), and 64 
  18968.                             bits for the fraction (F).  The bits are mapped 
  18969.                             with the fraction in bit 0 to bit 63, the exponent 
  18970.                             in bit 64 to bit 78, and the sign in bit 79: 
  18971.  
  18972.                                                         7 777777777666666
  18973.                                                         9 876543210987654
  18974.  
  18975.                                                         S EEEEEEEEEEEEEEE
  18976.  
  18977.                                                         666655555555554444444444333333333322222222221111111111
  18978.                                                         3210987654321098765432109876543210987654321098765432109876543210
  18979.  
  18980.                                                         FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
  18981.  
  18982.       Storage mapping       The storage mapping is as follows: 
  18983.  
  18984.                                                         Toward high memory 
  18985.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18986.                                                         Γöé byte 0   Γöé byte 1   Γöé byte 2   Γöé ...  Γöé
  18987.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18988.                                                         Γöé      Γöé 111111   Γöé 22221111  Γöé ...  Γöé
  18989.                                                         Γöé 76543210  Γöé 54321098  Γöé 32109876  Γöé    Γöé
  18990.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18991.                                                         Γöé FFFFFFFF  Γöé FFFFFFFF  Γöé FFFFFFFF  Γöé ...  Γöé
  18992.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  18993.  
  18994.                                                         Toward high memory 
  18995.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  18996.                                                         Γöé BYTE 7   Γöé BYTE 8   Γöé BYTE 9   Γöé
  18997.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  18998.                                                         Γöé 66666555  Γöé 77666666  Γöé 77777777  Γöé
  18999.                                                         Γöé 43210987  Γöé 10987654  Γöé 98765432  Γöé
  19000.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19001.                                                         Γöé FFFFFFFF  Γöé EEEEEEEE  Γöé SEEEEEEE  Γöé
  19002.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19003.  
  19004.    8. Null-Terminated Character Strings 
  19005.  
  19006.       Type                  char string[n] 
  19007.  
  19008.       Size                  Length of string (not including null). 
  19009.  
  19010.       Alignment             Byte-aligned. If the length of the string is 
  19011.                             greater than a doubleword, the string is 
  19012.                             doubleword-aligned. 
  19013.  
  19014.       Storage mapping       The string "STRING" is stored in adjacent bytes as: 
  19015.  
  19016.                                                         Toward high memory 
  19017.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19018.                                                         Γöé BYTE 0 Γöé BYTE 1 Γöé BYTE 2  Γöé BYTE 3 Γöé BYTE 4  Γöé BYTE 5 Γöé BYTE 6 Γöé
  19019.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19020.                                                         Γöé 'S'   Γöé 'T'   Γöé 'R'   Γöé 'I'   Γöé 'N'   Γöé 'G'   Γöé '\0'  Γöé
  19021.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19022.  
  19023.  
  19024.    9. Fixed-Length Arrays Containing Simple Data Types 
  19025.  
  19026.       Type                  The corresponding VisualAge for C++ declaration 
  19027.                             depends on the simple data type in the array. For 
  19028.                             an array of int, for example, you would use 
  19029.                             something like: 
  19030.  
  19031.                                                           int int_array[n];
  19032.                             For an array of float, you would use something 
  19033.                             like: 
  19034.  
  19035.                                                           float float_array[n];
  19036.  
  19037.       Size                  n * (s + p), where n is the number of elements in 
  19038.                             the array, s is the size of each element, and p is 
  19039.                             the alignment padding. 
  19040.  
  19041.       Alignment             The alignment is the same as that of the simple 
  19042.                             data type of the array elements. For instance, an 
  19043.                             array of short elements would be word-aligned, 
  19044.                             while an array of int elements would be 
  19045.                             doubleword-aligned. Fixed-length arrays are always 
  19046.                             aligned according to the simple data type of the 
  19047.                             array. 
  19048.  
  19049.       Storage mapping       The first element of the array is placed in the 
  19050.                             first storage position.  For multidimensional 
  19051.                             arrays, row-major ordering is used. 
  19052.  
  19053.   10. Aligned Structures 
  19054.  
  19055.       When we talk about Aligned structures, it is assumed the default 
  19056.       alignment of /Sp8 is in effect. 
  19057.  
  19058.       Type                  struct 
  19059.  
  19060.       Size                  Sum of the sizes for each type in the struct plus 
  19061.                             padding for alignment. 
  19062.  
  19063.       Alignment             The first element of the structure is aligned 
  19064.                             according to the alignment rule of the element that 
  19065.                             has the most restrictive alignment rule. The 
  19066.                             alignment of the individual members is not changed. 
  19067.                             In the following example, types char, short, and 
  19068.                             float are used in the struct. Because float must be 
  19069.                             aligned on the doubleword boundary, and because 
  19070.                             this is the most restrictive alignment rule, the 
  19071.                             first element must be aligned on the doubleword 
  19072.                             boundary even though it is only a char. 
  19073.  
  19074.                             Note:  The first element will not necessarily 
  19075.                             occupy a doubleword, but it will be aligned on it. 
  19076.  
  19077.                                                           struct y {
  19078.                                                                char char1;   /* aligns on doubleword */
  19079.                                                                short short1;  /* aligns on word */
  19080.                                                                char char2;   /* aligns on byte */
  19081.                                                                float float1;  /* aligns on doubleword */
  19082.                                                                char char3    /*aligns on byte */
  19083.                                                               };
  19084.  
  19085.       Storage mapping       The struct is stored as follows: 
  19086.  
  19087.                                                         Toward high memory 
  19088.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19089.                                                         Γöé BYTE 0  Γöé BYTE 1  Γöé BYTE 2  Γöé BYTE 3  Γöé BYTE 4  Γöé BYTE 5  Γöé
  19090.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19091.                                                         Γöé char1   Γöé pad    Γöé short1  Γöé short1  Γöé char2   Γöé pad   Γöé
  19092.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19093.  
  19094.                                                         Toward high memory 
  19095.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19096.                                                         Γöé BYTE 6 Γöé BYTE 7 Γöé BYTE 8 Γöé BYTE 9 Γöé BYTE  Γöé
  19097.                                                         Γöé     Γöé     Γöé     Γöé     Γöé 10   Γöé
  19098.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19099.                                                         Γöé pad   Γöé pad   Γöé float1 Γöé float1 Γöé float1 Γöé
  19100.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19101.  
  19102.                                                         Toward high memory 
  19103.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19104.                                                         Γöé BYTE  Γöé BYTE  Γöé BYTE  Γöé BYTE  Γöé BYTE  Γöé
  19105.                                                         Γöé 11   Γöé 12   Γöé 13   Γöé 14   Γöé 15   Γöé
  19106.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19107.                                                         Γöé float1 Γöé char3  Γöé pad   Γöé pad   Γöé pad   Γöé
  19108.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19109.  
  19110.                             Note:  This mapping is also true for aligned 
  19111.                             structures in C++ as long as the structure does not 
  19112.                             contain virtual base classes or virtual functions. 
  19113.  
  19114.   11. Unaligned or Packed Structures 
  19115.  
  19116.       Type                  The definition of the structure variable is 
  19117.                             preceded by the keyword _Packed, or the #pragma 
  19118.                             pack directive  or /Sp option is used. For 
  19119.                             instance, the following definition would create a 
  19120.                             packed struct called mystruct with the type struct 
  19121.                             y (defined above): 
  19122.  
  19123.                                                           _Packed struct y mystruct
  19124.  
  19125.       Size                  The sum of the sizes of each type that makes up the 
  19126.                             struct. 
  19127.  
  19128.       Storage mapping       When the _Packed keyword, the #pragma pack(1) 
  19129.                             directive, or /Sp(1) option is used, the structure 
  19130.                             mystruct is stored as follows: 
  19131.  
  19132.                                                         Toward high memory 
  19133.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19134.                                                         Γöé BYTE 0   Γöé BYTE 1   Γöé BYTE 2   Γöé BYTE 3   Γöé BYTE 4   Γöé
  19135.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19136.                                                         Γöé "char1"   Γöé "short1"  Γöé "short1"  Γöé "char2"   Γöé "float1"  Γöé
  19137.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19138.  
  19139.                                                         Toward high memory 
  19140.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19141.                                                         Γöé BYTE 5     Γöé BYTE 6     Γöé BYTE 7     Γöé BYTE 8     Γöé
  19142.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19143.                                                         Γöé "float1"    Γöé "float1"    Γöé "float1"    Γöé "char3"    Γöé
  19144.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19145.                             When #pragma pack(2) or the /Sp(2) option is used, 
  19146.                             mystruct is stored as follows: 
  19147.  
  19148.                                                         Toward high memory 
  19149.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19150.                                                         Γöé BYTE 0  Γöé BYTE 1  Γöé BYTE 2  Γöé BYTE 3  Γöé BYTE 4  Γöé BYTE 5  Γöé
  19151.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19152.                                                         Γöé char1   Γöé pad    Γöé short1  Γöé short1  Γöé char2   Γöé pad   Γöé
  19153.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19154.  
  19155.                                                         Toward high memory 
  19156.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19157.                                                         Γöé BYTE 6  Γöé BYTE 7  Γöé BYTE 8  Γöé BYTE 9  Γöé BYTE 10  Γöé BYTE 11 Γöé
  19158.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  19159.                                                         Γöé "float1" Γöé "float1" Γöé "float1" Γöé "float1" Γöé "char3"  Γöé pad   Γöé
  19160.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19161.  
  19162.                             Note:  This mapping is also true for unaligned 
  19163.                             structures in C++ as long as the structure does not 
  19164.                             contain virtual base classes or virtual functions. 
  19165.  
  19166.   12. Arrays of Structures 
  19167.  
  19168.       Type                  The definition for an array of struct would look 
  19169.                             like: 
  19170.  
  19171.                                                           struct y mystruct_array[n]
  19172.                             The definition of an array of _Packed struct would 
  19173.                             look like: 
  19174.  
  19175.                                                           _Packed struct y mystruct_array[n]
  19176.  
  19177.       Alignment             Each structure is aligned according to the 
  19178.                             structure alignment rules. This may cause a 
  19179.                             fixed-length gap between consecutive structures. In 
  19180.                             the case of packed structures, there is no padding. 
  19181.  
  19182.       Storage mapping       The first element of the array is placed in the 
  19183.                             first storage position.  Row-major ordering is used 
  19184.                             for multidimensional arrays. 
  19185.  
  19186.                             Note:  This mapping is also true for aligned 
  19187.                             structures in C++ as long as the structure does not 
  19188.                             contain virtual base classes or virtual functions. 
  19189.  
  19190.   13. Structures Containing Bit Fields 
  19191.  
  19192.       Type                  struct 
  19193.  
  19194.       Size                  The sum of the sizes for each type in the struct 
  19195.                             plus padding for alignment. 
  19196.  
  19197.       Alignment             Each structure is aligned according to the 
  19198.                             structure alignment rules. 
  19199.  
  19200.       Storage mapping       Given the following structure: 
  19201.  
  19202.                                                           struct s {
  19203.                                                                char a;
  19204.                                                                int b1:4;
  19205.                                                                int b2:6;
  19206.                                                                int b3:1;
  19207.                                                                int  :0;
  19208.                                                                int b4:7;
  19209.                                                                char c;
  19210.                                                               }
  19211.                             struct s would be stored as follows: 
  19212.  
  19213.  
  19214.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19215.                                                         Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byte Γöé  byte Γöé
  19216.                                                         Γöé  0   Γöé  1   Γöé  2   Γöé  3   Γöé  4  Γöé  5  Γöé
  19217.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19218.                                                         Γöé     Γöé     1     2     3  3  4 44   4
  19219.                                                         0     8     6     4     2  6  0 23   8
  19220.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö¼ΓöÇΓöÇΓöÇΓöÇΓöÉ
  19221.                                                         Γöé  a   Γöé pad   Γöé pad   Γöé pad   Γöé b1Γöé  b2 ΓöéΓöé padΓöé
  19222.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓö┤ΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝Γö╝ΓöÇΓöÇΓöÇΓöÇΓöÿ
  19223.                                                                                
  19224.                                                                                b3
  19225.                                                         ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19226.                                                         Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byte Γöé
  19227.                                                         Γöé  6   Γöé  7   Γöé  8   Γöé  9   Γöé  10  Γöé
  19228.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19229.                                                         4     5     6    77     8    8
  19230.                                                         8     6     4    12     0    8
  19231.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö¼Γö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19232.                                                         Γöé  pad  Γöé  pad  Γöé  b4  ΓöéΓöé  pad  Γöé  pad  Γöé
  19233.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19234.                                                                      
  19235.                                                                      pad
  19236.  
  19237.                                                         ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19238.                                                         Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byte  Γöé  byteΓöé
  19239.                                                         Γöé  11   Γöé  12   Γöé  13   Γöé  14   Γöé  15  Γöé
  19240.                                                         ΓöéΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöéΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ1ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ1ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ1ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇ1
  19241.                                                         8     9     0     1     2    2
  19242.                                                         8     6     4     2     0    8
  19243.                                                         Γö£ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  19244.                                                         Γöé pad   Γöé  c   Γöé  pad  Γöé  pad  Γöé  pad Γöé
  19245.                                                         ΓööΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÿ
  19246.  
  19247.                                 a will be in byte 0 
  19248.                                 full padding in bytes 1, 2, 3 
  19249.                                 b1, b2, b3 begin in byte 4 and end in byte 5 
  19250.                                  with 5 bits of padding in byte 5 
  19251.                                 full padding in bytes 6 and 7 
  19252.                                 b4 begins in byte 8 with one bit of padding in 
  19253.                                  byte 8 
  19254.                                 full padding in bytes 9, 10, 11 
  19255.                                 c will be in byte 12 
  19256.                                 full padding in bytes 13, 14, 15 
  19257.  
  19258.  
  19259. ΓòÉΓòÉΓòÉ 23. Glossary ΓòÉΓòÉΓòÉ
  19260.  
  19261. This glossary defines terms and abbreviations that are used in this book. 
  19262. Included are terms and definitions from the following sources: 
  19263.  
  19264.      American National Standard Dictionary for Information Systems, American 
  19265.       National Standard for Information Systems X3.172-1990, copyright 1990 by 
  19266.       the American National Standards Institute (American National Standard for 
  19267.       Information Systems). Copies may be purchased from the American National 
  19268.       Standards Institute, 1430 Broadway, New York, New York 10018. Such 
  19269.       definitions are indicated by the symbol American National Standard for 
  19270.       Information Systems after the definition. 
  19271.  
  19272.      IBM Dictionary of Computing, SC20-1699. These definitions are indicated 
  19273.       by the registered trademark IBM after the definition. 
  19274.  
  19275.      X/Open CAE Specification.  Commands and Utilities, Issue 4.  July, 1992. 
  19276.       These definitions are indicated by the symbol X/Open after the 
  19277.       definition. 
  19278.  
  19279.      ISO/IEC 9945-1:1990/IEEE POSIX 1003.1-1990. These definitions are 
  19280.       indicated by the symbol ISO.1 after the definition. 
  19281.  
  19282.      The Information Technology Vocabulary, developed by Subcommittee 1, Joint 
  19283.       Technical Committee 1, of the International Organization for 
  19284.       Standardization and the International Electrotechnical Commission 
  19285.       (ISO/IEC JTC1/SC1). Definitions of published parts of this vocabulary are 
  19286.       identified by the symbol ISO-JTC1 after the definition; definitions taken 
  19287.       from draft international standards, committee drafts, and working papers 
  19288.       being developed by ISO/IEC JTC1/SC1 are identified by the symbol ISO 
  19289.       Draft after the definition, indicating that final agreement has not yet 
  19290.       been reached among the participating National Bodies of SC1. 
  19291.  
  19292.   A            J            S
  19293.   B             K            T
  19294.   C             L            U
  19295.   D             M            V
  19296.   E             N            W
  19297.   F             O            X
  19298.   G             P            Y
  19299.   H             Q            Z
  19300.   I             R
  19301.  
  19302.  
  19303. ΓòÉΓòÉΓòÉ <hidden> A ΓòÉΓòÉΓòÉ
  19304.  
  19305.  abstract class 
  19306.  
  19307.              1. A class with at least one pure virtual function that is used as 
  19308.                 a base class for other classes. The abstract class represents a 
  19309.                 concept; classes derived from it represent implementations of 
  19310.                 the concept. You cannot construct an object of an abstract 
  19311.                 class. See also base class. 
  19312.  
  19313.              2. A class that allows polymorphism. 
  19314.  
  19315.  abstract data type A mathematical model that includes a structure for storing 
  19316.            data and operations that can be performed on that data. Common 
  19317.            abstract data types include sets, trees, and heaps. 
  19318.  
  19319.  abstraction (data) See data abstraction. 
  19320.  
  19321.  access    An attribute that determines whether or not a class member is 
  19322.            accessible in an expression or declaration. It can be public, 
  19323.            protected, or private. 
  19324.  
  19325.  access specifier One of the C++ keywords public, private, or protected. 
  19326.  
  19327.  action    A description of tool or function that can be used to manipulate a 
  19328.            project's parts, or build a project's target.  Examples are compile, 
  19329.            link, and edit. 
  19330.  
  19331.  address space 
  19332.  
  19333.              1. The range of addresses available to a computer program. 
  19334.                 American National Standard for Information Systems. 
  19335.  
  19336.              2. The complete range of addresses that are available to a 
  19337.                 programmer. 
  19338.  
  19339.              3. The area of virtual storage available for a particular job. 
  19340.  
  19341.              4. The memory locations that can be referenced by a process. 
  19342.                 X/Open. ISO.1. 
  19343.  
  19344.  aggregate 
  19345.  
  19346.              1. An array or a structure. 
  19347.  
  19348.              2. A compile-time option to show the layout of a structure or 
  19349.                 union in the listing. 
  19350.  
  19351.              3. An array or a class object with no private or protected 
  19352.                 members, no constructors, no base classes, and no virtual 
  19353.                 functions. 
  19354.  
  19355.              4. In programming languages, a structured collection of data items 
  19356.                 that form a data type. ISO-JTC1. 
  19357.  
  19358.  alignment The storing of data in relation to certain machine-dependent 
  19359.            boundaries. IBM. 
  19360.  
  19361.  American National Standards Institute See American National Standard for 
  19362.            Information Systems. 
  19363.  
  19364.  angle brackets The characters < (left angle bracket) and > (right angle 
  19365.            bracket). When used in the phrase "enclosed in angle brackets", the 
  19366.            symbol < immediately precedes the object to be enclosed, and > 
  19367.            immediately follows it. When describing these characters in the 
  19368.            portable character set, the names <less-than-sign> and 
  19369.            <greater-than-sign> are used. X/Open. 
  19370.  
  19371.  animate   Make or design in such a way as to create apparently spontaneous, 
  19372.            lifelike movement. 
  19373.  
  19374.  American National Standard for Information Systems (American National 
  19375.  Standards Institute) An organization consisting of producers, consumers, and 
  19376.            general interest groups, that establishes the procedures by which 
  19377.            accredited organizations create and maintain voluntary industry 
  19378.            standards in the United States. American National Standard for 
  19379.            Information Systems. 
  19380.  
  19381.  application 
  19382.  
  19383.              1. The use to which an information processing system is put; for 
  19384.                 example, a payroll application, an airline reservation 
  19385.                 application, a network application.IBM. 
  19386.  
  19387.              2. A collection of software components used to perform specific 
  19388.                 types of user-oriented work on a computer.IBM. 
  19389.  
  19390.  array     An aggregate that consists of data objects, with identical 
  19391.            attributes, each of which may be uniquely referenced by 
  19392.            subscripting. 
  19393.  
  19394.  array element A data element in an array. 
  19395.  
  19396.  ASCII (American National Standard Code for Information Interchange) The 
  19397.            standard code, using a coded character set consisting of 7-bit coded 
  19398.            characters (8 bits including parity check), that is used for 
  19399.            information interchange among data processing systems, data 
  19400.            communication systems, and associated equipment. The ASCII set 
  19401.            consists of control characters and graphic characters. 
  19402.  
  19403.            Note:  IBM has defined an extension to ASCII code (characters 
  19404.            128-255). 
  19405.  
  19406.  automatic data Data that does not persist after a routine has finished 
  19407.            executing. Automatic data may be automatically initialized to a 
  19408.            certain value upon entry and reentry to a routine. 
  19409.  
  19410.  automatic storage Storage that is allocated on entry to a routine or block and 
  19411.            is freed on the subsequent return. Sometimes referred to as stack 
  19412.            storage or dynamic storage. 
  19413.  
  19414.  
  19415. ΓòÉΓòÉΓòÉ <hidden> B ΓòÉΓòÉΓòÉ
  19416.  
  19417.  backslash The character \. This character is named <backslash> in the portable 
  19418.            character set. 
  19419.  
  19420.  base class A class from which other classes are derived. A base class may 
  19421.            itself be derived from another base class. See also abstract class. 
  19422.  
  19423.  based on  A relationship between two classes in which one class is implemented 
  19424.            through the other. A new class is "based on" an existing class when 
  19425.            the existing class is used to implement it. 
  19426.  
  19427.  binary stream 
  19428.  
  19429.              1. An ordered sequence of untranslated characters. 
  19430.  
  19431.              2. A sequence of characters that corresponds on a one-to-one basis 
  19432.                 with the characters in the file. No character translation is 
  19433.                 performed on binary streams. IBM. 
  19434.  
  19435.  bit field A member of a structure or union that contains a specified number of 
  19436.            bits. 
  19437.  
  19438.  bit mask  A pattern of characters used to control the retention or elimination 
  19439.            of portions of another pattern of characters. 
  19440.  
  19441.  block 
  19442.  
  19443.              1. In programming languages, a compound statement that coincides 
  19444.                 with the scope of at least one of the declarations contained 
  19445.                 within it. A block may also specify storage allocation or 
  19446.                 segment programs for other purposes. ISO-JTC1. 
  19447.  
  19448.              2. A string of data elements recorded or transmitted as a unit. 
  19449.                 The elements may be characters, words, or physical records. ISO 
  19450.                 Draft. 
  19451.  
  19452.              3. The unit of data transmitted to and from a device. Each block 
  19453.                 contains one record, part of a record, or several records. 
  19454.  
  19455.  brackets  The characters [ (left bracket) and ] (right bracket), also known as 
  19456.            square brackets. When used in the phrase "enclosed in (square) 
  19457.            brackets" the symbol [ immediately precedes the object to be 
  19458.            enclosed, and ] immediately follows it. When describing these 
  19459.            characters in the portable character set, the names <left-bracket> 
  19460.            and <right-bracket> are used. X/Open. 
  19461.  
  19462.  breakpoint A point in a computer program where execution may be halted. A 
  19463.            breakpoint is usually at the beginning of an instruction where halts 
  19464.            caused by external intervention are convenient for resuming 
  19465.            execution. ISO Draft. 
  19466.  
  19467.  build     An action that invokes the WorkFrame Build tool.  The Build tool 
  19468.            manages the project's makefile, as well as build dependencies 
  19469.            between projects in a project hierarchy. 
  19470.  
  19471.  built-in  A function that the compiler automatically puts inline instead of 
  19472.            generating a call to the function. Synonymous with predefined. IBM. 
  19473.  
  19474.  
  19475. ΓòÉΓòÉΓòÉ <hidden> C ΓòÉΓòÉΓòÉ
  19476.  
  19477.  C++ class library See class library. 
  19478.  
  19479.  C++ library A system library that contains common C++ language subroutines for 
  19480.            file access, memory allocation, and other functions. 
  19481.  
  19482.  call      To transfer control to a procedure, program, routine, or subroutine. 
  19483.            IBM. 
  19484.  
  19485.  caller    A routine that calls another routine. 
  19486.  
  19487.  carriage-return character A character that in the output stream indicates that 
  19488.            printing should start at the beginning of the same physical line in 
  19489.            which the carriage-return character occurred. The carriage-return is 
  19490.            the character designated by '\r' in the C and C++ languages. It is 
  19491.            unspecified whether this character is the exact sequence transmitted 
  19492.            to an output device by the system to accomplish the movement to the 
  19493.            beginning of the line. X/Open. 
  19494.  
  19495.  CASE      Computer-Aided Software Engineering. 
  19496.  
  19497.  cast      A notation used to express the conversion of one type to another. 
  19498.  
  19499.  character 
  19500.  
  19501.              1. A letter, digit, or other symbol that is used as part of the 
  19502.                 organization, control, or representation of data. A character 
  19503.                 is often in the form of a spatial arrangement of adjacent or 
  19504.                 connected strokes. American National Standard for Information 
  19505.                 Systems. 
  19506.  
  19507.              2. A sequence of one or more bytes representing a single graphic 
  19508.                 symbol or control code. This term corresponds to the ISO C 
  19509.                 standard term multibyte character (multi-byte character), where 
  19510.                 a single-byte character is a special case of the multi-byte 
  19511.                 character. Unlike the usage in the ISO C standard, character 
  19512.                 here has no necessary relationship with storage space, and byte 
  19513.                 is used when storage space is discussed. X/Open. ISO.1. 
  19514.  
  19515.  character array An array of type char. X/Open. 
  19516.  
  19517.  character class A named set of characters sharing an attribute associated with 
  19518.            the name of the class. The classes and the characters that they 
  19519.            contain are dependent on the value of the LC_CTYPE category in the 
  19520.            current locale. X/Open. 
  19521.  
  19522.  character constant 
  19523.  
  19524.              1. A constant with a character value. IBM. 
  19525.  
  19526.              2. A string of any of the characters that can be represented, 
  19527.                 usually enclosed in apostrophes. IBM. 
  19528.  
  19529.              3. In some languages, a character enclosed in apostrophes. IBM. 
  19530.  
  19531.  character set 
  19532.  
  19533.              1. A finite set of different characters that is complete for a 
  19534.                 given purpose; for example, the character set in ISO Standard 
  19535.                 646, 7-bit Coded Character Set for Information Processing 
  19536.                 Interchange. ISO Draft. 
  19537.  
  19538.              2. All the valid characters for a programming language or for a 
  19539.                 computer system. IBM. 
  19540.  
  19541.              3. A group of characters used for a specific reason; for example, 
  19542.                 the set of characters a printer can print. IBM. 
  19543.  
  19544.              4. See also portable character set. 
  19545.  
  19546.  character string A contiguous sequence of characters terminated by and 
  19547.            including the first null byte. X/Open. 
  19548.  
  19549.  child     A node that is subordinate to another node in a tree structure. 
  19550.            Only the root node of a tree is not a child. 
  19551.  
  19552.  child class See derived class. 
  19553.  
  19554.  class 
  19555.  
  19556.              1. A group of objects that share a common definition and that 
  19557.                 therefore share common properties, operations, and behavior. 
  19558.  
  19559.              2. A C++ aggregate that may contain functions, types, and 
  19560.                 user-defined operators in addition to data. Classes can be 
  19561.                 defined hierarchically, allowing one class to be an expansion 
  19562.                 of another, and classes can restrict access to their members. 
  19563.  
  19564.  class hierarchy A tree-like structure showing relationships among classes. It 
  19565.            places one abstract class at the top (a base class) and one or more 
  19566.            layers of derived classes below it. 
  19567.  
  19568.  class library A collection of classes. 
  19569.  
  19570.  class template A blueprint describing how a set of related classes can be 
  19571.            constructed. 
  19572.  
  19573.  class name A unique identifier of a class type that becomes a reserved word 
  19574.            within its scope. 
  19575.  
  19576.  C library A system library that contains common C language subroutines for 
  19577.            file access, string operators, character operations, memory 
  19578.            allocation, and other functions. IBM. 
  19579.  
  19580.  client program A program that uses a class. The program is said to be a client 
  19581.            of the class. 
  19582.  
  19583.  coded character set 
  19584.  
  19585.              1. A set of graphic characters and their code point assignments. 
  19586.                 The set may contain fewer characters than the total number of 
  19587.                 possible characters: some code points may be unassigned. IBM. 
  19588.  
  19589.              2. A coded set whose elements are single characters; for example, 
  19590.                 all characters of an alphabet. ISO Draft. 
  19591.  
  19592.              3. Loosely, a code. American National Standard for Information 
  19593.                 Systems. 
  19594.  
  19595.  code page 
  19596.  
  19597.              1. An assignment of graphic characters and control function 
  19598.                 meanings to all code points; for example, assignment of 
  19599.                 characters and meanings to 256 code points for an 8-bit code, 
  19600.                 or assignment of characters and meanings to 128 code points for 
  19601.                 a 7-bit code. 
  19602.  
  19603.              2. A particular assignment of hexadecimal identifiers to graphic 
  19604.                 characters. 
  19605.  
  19606.  code point 
  19607.  
  19608.              1. A 1-byte code representing one of 256 potential characters. 
  19609.  
  19610.              2. An identifier in an alert description that represents a short 
  19611.                 unit of text.  The code point is replaced with the text by an 
  19612.                 alert display program. 
  19613.  
  19614.  collating element The smallest entity used to determine the logical ordering 
  19615.            of character or wide-character strings. A collating element consists 
  19616.            of either a single character, or two or more characters collating as 
  19617.            a single entity. The value of the LC_COLLATE category in the current 
  19618.            locale determines the current set of collating elements. X/Open. 
  19619.  
  19620.  collating sequence 
  19621.  
  19622.              1. A specified arrangement used in sequencing. ISO-JTC1. American 
  19623.                 National Standard for Information Systems. 
  19624.  
  19625.              2. An ordering assigned to a set of items, such that any two sets 
  19626.                 in that assigned order can be collated. American National 
  19627.                 Standard for Information Systems. 
  19628.  
  19629.              3. The relative ordering of collating elements as determined by 
  19630.                 the setting of the LC_COLLATE category in the current locale. 
  19631.                 The character order, as defined for the LC_COLLATE category in 
  19632.                 the current locale, defines the relative order of all collating 
  19633.                 elements, such that each element occupies a unique position in 
  19634.                 the order. This is the order used in ranges of characters and 
  19635.                 collating elements in regular expressions and pattern matching. 
  19636.                 In addition, the definition of the collating weights of 
  19637.                 characters and collating elements uses collating elements to 
  19638.                 represent their respective positions within the collation 
  19639.                 sequence. 
  19640.  
  19641.  collation The logical ordering of character or wide-character strings 
  19642.            according to defined precedence rules. These rules identify a 
  19643.            collation sequence between the collating elements, and such 
  19644.            additional rules that can be used to order strings consisting or 
  19645.            multiple collating elements. X/Open. 
  19646.  
  19647.  collection 
  19648.  
  19649.              1. In a general sense, an implementation of an abstract data type 
  19650.                 for storing elements. 
  19651.  
  19652.              2. An abstract class without any ordering, element properties, or 
  19653.                 key properties. All abstract Collection Classes are derived 
  19654.                 from Collection. 
  19655.  
  19656.  Collection Class Library A set of classes that provide basic functions for 
  19657.            collections, and can be used as base classes. 
  19658.  
  19659.  Collection Classes A set of classes that implement abstract data types for 
  19660.            storing elements. 
  19661.  
  19662.  COM       Component Object Model. 
  19663.  
  19664.  command   A request to perform an operation or run a program. When parameters, 
  19665.            arguments, flags, or other operands are associated with a command, 
  19666.            the resulting character string is a single command. 
  19667.  
  19668.  compilation unit 
  19669.  
  19670.              1. A portion of a computer program sufficiently complete to be 
  19671.                 compiled correctly. IBM. 
  19672.  
  19673.              2. A single compiled file and all its associated include files. 
  19674.  
  19675.              3. An independently compilable sequence of high-level language 
  19676.                 statements. Each high-level language product has different 
  19677.                 rules for what makes up a compilation unit. 
  19678.  
  19679.  Complex Mathematics library A C++ class library that provides the facilities 
  19680.            to manipulate complex numbers and perform standard mathematical 
  19681.            operations on them. 
  19682.  
  19683.  Compound Object Model (COM) The underlying model for all OLE services. It 
  19684.            consists of a variety of APIs and object interfaces that allow 
  19685.            container components to communicate and interact with one another. 
  19686.  
  19687.  composite The combination of two or more film, video, or electronic images 
  19688.            into a single frame or display. 
  19689.  
  19690.  condition 
  19691.  
  19692.              1. A relational expression that can be evaluated to a value of 
  19693.                 either true or false. IBM. 
  19694.  
  19695.              2. An exception that has been enabled, or recognized, by the 
  19696.                 Language Environment and thus is eligible to activate user and 
  19697.                 language condition handlers. Any alteration to the normal 
  19698.                 programmed flow of an application. Conditions can be detected 
  19699.                 by the hardware/operating system and result in an interrupt. 
  19700.                 They can also be detected by language-specific generated code 
  19701.                 or language library code. 
  19702.  
  19703.  const 
  19704.  
  19705.              1. An attribute of a data object that declares that the object 
  19706.                 cannot be changed. 
  19707.  
  19708.              2. An attribute of a function that declares that the function will 
  19709.                 not modify data members of its class. 
  19710.  
  19711.  constant 
  19712.  
  19713.              1. In programming languages, a language object that takes only one 
  19714.                 specific value. ISO-JTC1. 
  19715.  
  19716.              2. A data item with a value that does not change. IBM. 
  19717.  
  19718.  constant expression An expression having a value that can be determined during 
  19719.            compilation and that does not change during the running of the 
  19720.            program. IBM. 
  19721.  
  19722.  constructor A special class member function that has the same name as the 
  19723.            class and is used to construct and, possibly, initialize objects of 
  19724.            its class type. A return type is not specified. 
  19725.  
  19726.  container An object that holds other objects.IBM. Containers built with the 
  19727.            Compound Document Framework are also servers and can therefore be 
  19728.            embedded inside other containers. A container can hold zero or more 
  19729.            embedded components. 
  19730.  
  19731.  control   A graphic object that represents operations or properties of other 
  19732.            objects. See also tree control. 
  19733.  
  19734.  control character 
  19735.  
  19736.              1. A character whose occurrence in a particular context specifies 
  19737.                 a control function. ISO Draft. 
  19738.  
  19739.              2. Synonymous with nonprinting character. IBM. 
  19740.  
  19741.              3. A character, other than a graphic character, that affects the 
  19742.                 recording, processing, transmission, or interpretation of text. 
  19743.                 X/Open. 
  19744.  
  19745.  conversion 
  19746.  
  19747.              1. In programming languages, the transformation between values 
  19748.                 that represent the same data item but belong to different data 
  19749.                 types. Information may be lost because of conversion since 
  19750.                 accuracy of data representation varies among different data 
  19751.                 types. ISO-JTC1. 
  19752.  
  19753.              2. The process of changing from one method of data processing to 
  19754.                 another or from one data processing system to another. IBM. 
  19755.  
  19756.              3. The process of changing from one form of representation to 
  19757.                 another; for example to change from decimal representation to 
  19758.                 binary representation. IBM. 
  19759.  
  19760.              4. A change in the type of a value. For example, when you add 
  19761.                 values having different data types, the compiler converts both 
  19762.                 values to a common form before adding the values. 
  19763.  
  19764.  conversion function A member function that specifies a conversion from its 
  19765.            class type to another type. 
  19766.  
  19767.  copy constructor A constructor used to make a copy of an object from another 
  19768.            object of the same type. 
  19769.  
  19770.  critical section 
  19771.  
  19772.              1. Code that must be executed by one thread while all other 
  19773.                 threads in the process are suspended. 
  19774.  
  19775.              2. In Windows, a synchronization object. A critical section is not 
  19776.                 a kernel object; that is, it is not managed by the low-level 
  19777.                 components of the operating system and is not manipulated using 
  19778.                 handles. 
  19779.  
  19780.              3. In Windows, a small section of code that requires exclusive 
  19781.                 access to some shared data before the code can execute. 
  19782.                 Critical threads synchronize threads only within a single 
  19783.                 process, and they allow only one thread at a time to gain 
  19784.                 access to a region of data. 
  19785.  
  19786.                 See also mutex, semaphore, and event. Contrast with kernel 
  19787.                 object. 
  19788.  
  19789.  C/2       A version of the C language designed for the OS/2 environment. 
  19790.  
  19791.  current working directory 
  19792.  
  19793.              1. A directory, associated with a process, that is used in 
  19794.                 path-name resolution for path names that do not begin with a 
  19795.                 slash. X/Open. ISO.1. 
  19796.  
  19797.              2. In DOS, the directory that is searched when a file name is 
  19798.                 entered with no indication of the directory that lists the file 
  19799.                 name. DOS assumes that the current directory is the root 
  19800.                 directory unless a path to another directory is specified. IBM. 
  19801.  
  19802.              3. In the OS/2 operating system, the first directory in which the 
  19803.                 operating system looks for programs and files and stores 
  19804.                 temporary files and output. IBM. 
  19805.  
  19806.              4. In the AIX operating system, a directory that is active and 
  19807.                 that can be displayed. Relative path name resolution begins in 
  19808.                 the current directory. IBM. 
  19809.  
  19810.  cursor    A reference to an element at a specific position in a data 
  19811.            structure. 
  19812.  
  19813.  
  19814. ΓòÉΓòÉΓòÉ <hidden> D ΓòÉΓòÉΓòÉ
  19815.  
  19816.  data abstraction A data type with a private representation and a public set of 
  19817.            operations. The C++ language uses the concept of classes to 
  19818.            implement data abstraction. 
  19819.  
  19820.  data member The smallest possible piece of complete data. Elements are 
  19821.            composed of data members. 
  19822.  
  19823.  data structure The internal data representation of an implementation. 
  19824.  
  19825.  data type The properties and internal representation that characterize data. 
  19826.  
  19827.  DBCS (Double-Byte Character Set) See double-byte character set. 
  19828.  
  19829.  decimal constant 
  19830.  
  19831.              1. A numerical data type used in standard arithmetic operations. 
  19832.  
  19833.              2. A number containing any of the digits 0 through 9. IBM. 
  19834.  
  19835.  declaration Introduces a name to a program and specifies how the name is to be 
  19836.            interpreted. 
  19837.  
  19838.  declare   To specify the interpretation that C++ gives to each identifier. 
  19839.  
  19840.  default constructor A constructor that takes no arguments, or a constructor 
  19841.            for which all the arguments have default values. 
  19842.  
  19843.  define directive A preprocessor statement that directs the preprocessor to 
  19844.            replace an identifier or macro invocation with special code. 
  19845.  
  19846.  definition 
  19847.  
  19848.              1. A data description that reserves storage and may provide an 
  19849.                 initial value. 
  19850.  
  19851.              2. A declaration that allocates storage, and may initialize a data 
  19852.                 object or specify the body of a function. 
  19853.  
  19854.  delete 
  19855.  
  19856.              1. A C++ keyword that identifies a free-storage deallocation 
  19857.                 operator. 
  19858.  
  19859.              2. A C++ operator used to destroy objects created by operator new. 
  19860.  
  19861.  demangling The conversion of mangled names back to their original source code 
  19862.            names. During C++ compilation, identifiers such as function and 
  19863.            static class member names are mangled (encoded) with type and 
  19864.            scoping information to ensure type-safe linkage. These mangled names 
  19865.            appear in the object file and the final executable file. Demangling 
  19866.            (decoding) converts these names back to their original names to make 
  19867.            program debugging easier. See also mangling. 
  19868.  
  19869.  denormal  Pertaining to a number with a value so close to 0 that its exponent 
  19870.            cannot be represented normally. The exponent can be represented in a 
  19871.            special way at the possible cost of a loss of significance. 
  19872.  
  19873.  derivation 
  19874.  
  19875.              1. The creation of a new or derived class from an existing base 
  19876.                 class. 
  19877.  
  19878.              2. The relationship between a class and the classes above or below 
  19879.                 it in a class hierarchy. 
  19880.  
  19881.  derived class A class that inherits from a base class. You can add new data 
  19882.            members and member functions to the derived class. You can 
  19883.            manipulate a derived class object as if it were a base class object. 
  19884.            The derived class can override virtual functions of the base class. 
  19885.  
  19886.            Synonym for child class and subclass. 
  19887.  
  19888.  destructor A special member function that has the same name as its class, 
  19889.            preceded by a tilde (~), and that "cleans up" after an object of 
  19890.            that class, for example, by freeing storage that was allocated when 
  19891.            the object was created. A destructor has no arguments, and no return 
  19892.            type is specified. 
  19893.  
  19894.  device    A computer peripheral or an object that appears to the application 
  19895.            as such. X/Open. ISO.1. 
  19896.  
  19897.  difference Given two sets A and B, the difference (A-B) is the set of all 
  19898.            elements contained in A but not in B. 
  19899.  
  19900.  directory A type of file containing the names and controlling information for 
  19901.            other files or other directories. IBM. 
  19902.  
  19903.  display   To direct the output to the user's terminal. If the output is not 
  19904.            directed to the terminal, the results are undefined. X/Open. 
  19905.  
  19906.  double-byte character set (DBCS) A set of characters in which each character 
  19907.            is represented by 2 bytes. Languages such as Japanese, Chinese, and 
  19908.            Korean, which contain more symbols than can be represented by 256 
  19909.            code points, require double-byte character sets. 
  19910.  
  19911.            Because each character requires 2 bytes, you need hardware and 
  19912.            supporting software that are DBCS-enabled to enter, display, and 
  19913.            print DBCS characters. 
  19914.  
  19915.  double-precision Pertaining to the use of two computer words to represent a 
  19916.            number in accordance with the required precision. ISO-JTC1. American 
  19917.            National Standard for Information Systems. 
  19918.  
  19919.  doubleword A contiguous sequence of bits or characters that comprises two 
  19920.            computer words and can be addressed as a unit. For the C Set++ for 
  19921.            AIX compiler, a doubleword is 32 bits (4 bytes). 
  19922.  
  19923.  dump      To copy data in a readable format from main or auxiliary storage 
  19924.            onto an external medium such as tape, diskette, or printer. IBM. 
  19925.  
  19926.  dynamic   Pertaining to an operation that occurs at the time it is needed 
  19927.            rather than at a predetermined or fixed time. IBM. 
  19928.  
  19929.  dynamic link library (DLL) A file containing executable code and data bound to 
  19930.            a program at load time or run time. The code and data in a dynamic 
  19931.            link library can be shared by several applications simultaneously. 
  19932.  
  19933.  dynamic storage Synonym for automatic storage. 
  19934.  
  19935.  
  19936. ΓòÉΓòÉΓòÉ <hidden> E ΓòÉΓòÉΓòÉ
  19937.  
  19938.  EBCDIC (extended binary-coded decimal interchange code) A coded character set 
  19939.            of 256 8-bit characters. 
  19940.  
  19941.  element   The component of an array, subrange, enumeration, or set. 
  19942.  
  19943.  element equality A relation that determines whether two elements are equal. 
  19944.  
  19945.  empty string 
  19946.  
  19947.              1. A string whose first byte is a null byte. Synonymous with null 
  19948.                 string. X/Open. 
  19949.  
  19950.              2. A character array whose first element is a null character. 
  19951.                 ISO.1. 
  19952.  
  19953.  encapsulation The hiding of the internal representation of objects and 
  19954.            implementation details from the client program. 
  19955.  
  19956.  entry point In assembler language, the address or label of the first 
  19957.            instruction that is executed when a routine is entered for 
  19958.            execution. 
  19959.  
  19960.  enumeration constant An identifier that is defined in an enumeration and that 
  19961.            has an associated constant integer value. You can use an enumeration 
  19962.            constant anywhere an integer constant is allowed. 
  19963.  
  19964.  enumerator In the C and C++ language, an enumeration constant and its 
  19965.            associated value. IBM. 
  19966.  
  19967.  environment variable Any of a number of variables that describe the way an 
  19968.            operating system is going to run or the devices it is going to 
  19969.            recognize.IBM. 
  19970.  
  19971.  equivalence class 
  19972.  
  19973.              1. A grouping of characters that are considered equal for the 
  19974.                 purpose of collation; for example, many languages place an 
  19975.                 uppercase character in the same equivalence class as its 
  19976.                 lowercase form, but some languages distinguish between accented 
  19977.                 and unaccented character forms for the purpose of collation. 
  19978.                 IBM. 
  19979.  
  19980.              2. A set of collating elements with the same primary collation 
  19981.                 weight. 
  19982.  
  19983.                 Elements in an equivalence class are typically elements that 
  19984.                 naturally group together, such as all accented letters based on 
  19985.                 the same base letter. 
  19986.  
  19987.                 The collation order of elements within an equivalence class is 
  19988.                 determined by the weights assigned on any subsequent levels 
  19989.                 after the primary weight. X/Open. 
  19990.  
  19991.  escape sequence 
  19992.  
  19993.              1. A representation of a character. An escape sequence contains 
  19994.                 the \ symbol followed by one of the characters: a, b, f, n, r, 
  19995.                 t, v, ', ", x, \, or followed by one or more octal or 
  19996.                 hexadecimal digits. 
  19997.  
  19998.              2. A sequence of characters that represent, for example, 
  19999.                 nonprinting characters, or the exact code point value to be 
  20000.                 used to represent variant and nonvariant characters regardless 
  20001.                 of code page. 
  20002.  
  20003.              3. In the C and C++ language, an escape character followed by one 
  20004.                 or more characters. The escape character indicates that a 
  20005.                 different code, or a different coded character set, is used to 
  20006.                 interpret the characters that follow. Any member of the 
  20007.                 character set used at runtime can be represented using an 
  20008.                 escape sequence. 
  20009.  
  20010.              4. A character that is preceded by a backslash character and is 
  20011.                 interpreted to have a special meaning to the operating system. 
  20012.  
  20013.              5. A sequence sent to a terminal to perform actions such as moving 
  20014.                 the cursor, changing from normal to reverse video, and clearing 
  20015.                 the screen. Synonymous with multibyte control. IBM. 
  20016.  
  20017.  event 
  20018.  
  20019.              1. Any user action (such as a mouse click) or system activity 
  20020.                 (such as screen updating) that provokes a response from the 
  20021.                 application. 
  20022.  
  20023.              2. In Windows, a synchronization kernel object used to signal that 
  20024.                 an operation has completed. See also kernal object. Compare to 
  20025.                 critical section, mutex, semaphore, manual-reset event, and 
  20026.                 auto-reset event. 
  20027.  
  20028.  exception 
  20029.  
  20030.              1. A user or system error detected by the system and passed to an 
  20031.                 operating system or user exception handler. 
  20032.  
  20033.              2. For C++, any user, logic, or system error detected by a 
  20034.                 function that does not itself deal with the error but passes 
  20035.                 the error on to a handling routine (also called "throwing the 
  20036.                 exception"). 
  20037.  
  20038.  exception handler 
  20039.  
  20040.              1. A function that is invoked when an exception is detected, and 
  20041.                 that either corrects the problem and returns execution to the 
  20042.                 program, or terminates the program. 
  20043.  
  20044.              2. In C++, a catch block that catches a C++ exception when it is 
  20045.                 thrown from a function in a try block. 
  20046.  
  20047.  exception handling A type of error handling that allows control and 
  20048.            information to be passed to an exception handler when an exception 
  20049.            occurs. Under the OS/2 operating system, exceptions are generated by 
  20050.            the system and handled by user code. In C++, try, catch, and throw 
  20051.            expressions are the constructs used to implement C++ exception 
  20052.            handling. 
  20053.  
  20054.  executable file A regular file acceptable as a new process image file by the 
  20055.            equivalent of the exec family of functions, and thus usable as one 
  20056.            form of a utility. The standard utilities described as compilers can 
  20057.            produce executable files, but other unspecified methods of producing 
  20058.            executable files may also be provided. The internal format of an 
  20059.            executable file is unspecified, but a conforming application cannot 
  20060.            assume an executable file is a text file. X/Open. 
  20061.  
  20062.  extension 
  20063.  
  20064.              1. An element or function not included in the standard language. 
  20065.  
  20066.              2. File name extension. 
  20067.  
  20068.  eyecatcher A recognizable sequence of bytes that determines which parameters 
  20069.            were passed in which registers. This sequence is used for functions 
  20070.            that have not been prototyped or have a variable number of 
  20071.            parameters. 
  20072.  
  20073.  
  20074. ΓòÉΓòÉΓòÉ <hidden> F ΓòÉΓòÉΓòÉ
  20075.  
  20076.  file descriptor A small positive integer that the system uses instead of the 
  20077.            file name to identify an open file. 
  20078.  
  20079.  file scope A name declared outside all blocks and classes has file scope and 
  20080.            can be used after the point of declaration in a source file. 
  20081.  
  20082.  filter 
  20083.  
  20084.              1. A command whose operation consists of reading data from 
  20085.                 standard input or a list of input files and writing data to 
  20086.                 standard output. Typically, its function is to perform some 
  20087.                 transformation on the data stream. 
  20088.  
  20089.              2. In WorkFrame, the value of a type.  The filter of a type can be 
  20090.                 expressed as a file mask; a regular expression; a logical-OR, 
  20091.                 logical-AND, or logical-NOT of a list of types; or a filter 
  20092.                 determined by a PAM. 
  20093.  
  20094.  first element The element visited first in an iteration over a collection. 
  20095.            Each collection has its own definition for first element. For 
  20096.            example, the first element of a sorted set is the element with the 
  20097.            smallest value. 
  20098.  
  20099.  flat collection A collection that has no hierarchical structure. 
  20100.  
  20101.  folder    A directory. 
  20102.  
  20103.  font      A particular size and style of typeface that contains definitions of 
  20104.            character sets, marker sets, and pattern sets. 
  20105.  
  20106.  for statement A looping statement that contains the word for followed by a 
  20107.            list of expressions enclosed in parentheses (the condition) and a 
  20108.            statement (the action). Each expression in the parenthesized list is 
  20109.            separated by a semicolon. You can omit any of the expressions, but 
  20110.            you cannot omit the semicolons. 
  20111.  
  20112.  frame 
  20113.  
  20114.              1. A complete television picture that is composed of two scanned 
  20115.                 fields, one of the even lines and one of the odd lines. In the 
  20116.                 NTSC system, a frame has 525 horizontal lines and is scanned in 
  20117.                 1/30th of a second. 
  20118.  
  20119.              2. A border around a window. 
  20120.  
  20121.  function  A named group of statements that can be called and evaluated and can 
  20122.            return a value to the calling statement. IBM. See also member 
  20123.            function. 
  20124.  
  20125.  function call An expression that moves the path of execution from the current 
  20126.            function to a specified function and evaluates to the return value 
  20127.            provided by the called function. A function call contains the name 
  20128.            of the function to which control moves and a parenthesized list of 
  20129.            values. IBM. 
  20130.  
  20131.  function declarator The part of a function definition that names the function, 
  20132.            provides additional information about the return value of the 
  20133.            function, and lists the function parameters. 
  20134.  
  20135.  function definition The complete description of a function. A function 
  20136.            definition contains an optional storage class specifier, an optional 
  20137.            type specifier, a function declarator, optional parameter 
  20138.            declarations, and a block statement (the function body). 
  20139.  
  20140.  function prototype A function declaration that provides type information for 
  20141.            each parameter. It is the first line of the function (header) 
  20142.            followed by a ; (semicolon). The declaration is required by the 
  20143.            compiler at the time that the function is declared, so that the 
  20144.            compiler can check the type. 
  20145.  
  20146.  function template Provides a blueprint describing how a set of related 
  20147.            individual functions can be constructed. 
  20148.  
  20149.  
  20150. ΓòÉΓòÉΓòÉ <hidden> G ΓòÉΓòÉΓòÉ
  20151.  
  20152.  gain      The ability to change the audibility of the sound, such as during a 
  20153.            fade in or fade out of music. 
  20154.  
  20155.  global    Pertaining to information available to more than one program or 
  20156.            subroutine. IBM. 
  20157.  
  20158.  global variable A symbol defined in one program module that is used in other 
  20159.            independently compiled program modules. 
  20160.  
  20161.  GMT       Greenwich Mean Time. 
  20162.  
  20163.  graphical user interface (GUI) Type of computer interface consisting of a 
  20164.            visual metaphor of a real-world scene, often of a desktop. 
  20165.  
  20166.  graphics  A picture defined in terms of graphic primitives and graphic 
  20167.            attributes. 
  20168.  
  20169.  Greenwich Mean Time The solar time at the meridian of Greenwich, formerly used 
  20170.            as the prime basis of standard time throughout the world. GMT has 
  20171.            been superseded by coordinate universal time (UTC). 
  20172.  
  20173.  GUI       Graphical user interface. 
  20174.  
  20175.  
  20176. ΓòÉΓòÉΓòÉ <hidden> H ΓòÉΓòÉΓòÉ
  20177.  
  20178.  header file A text file that is used by a group of functions, programs, or 
  20179.            users. It can contain system-defined control information or user 
  20180.            data and generally consists of declarations. Synonymous with include 
  20181.            file. 
  20182.  
  20183.  heap      An unordered flat collection that allows duplicate elements. 
  20184.  
  20185.  heap storage An area of storage used for allocation of storage whose lifetime 
  20186.            is not related to the execution of the current routine. The heap 
  20187.            consists of the initial heap segment and zero or more increments. 
  20188.  
  20189.  hexadecimal constant A constant, usually starting with special characters, 
  20190.            that contains only hexadecimal digits. Three examples for the 
  20191.            hexadecimal constant with value 0 would be '\x00', '0x0', or '0X00'. 
  20192.  
  20193.  
  20194. ΓòÉΓòÉΓòÉ <hidden> I ΓòÉΓòÉΓòÉ
  20195.  
  20196.  identifier 
  20197.  
  20198.              1. One or more characters used to identify or name a data element 
  20199.                 and possibly to indicate certain properties of that data 
  20200.                 element. American National Standard for Information Systems. 
  20201.  
  20202.              2. In programming languages, a token that names a data object such 
  20203.                 as a variable, an array, a record, a subprogram, or a function. 
  20204.                 American National Standard for Information Systems. 
  20205.  
  20206.              3. A sequence of letters, digits, and underscores used to identify 
  20207.                 a data object or function. IBM. 
  20208.  
  20209.  if statement A conditional statement that contains the keyword if, followed by 
  20210.            an expression in parentheses (the condition), a statement (the 
  20211.            action), and an optional else clause (the alternative action). IBM. 
  20212.  
  20213.  include directive A preprocessor directive that causes the preprocessor to 
  20214.            replace the statement with the contents of a specified file. 
  20215.  
  20216.  include file A text file that contains declarations used by a group of 
  20217.            functions, programs, or users. Synonymous with header file. IBM. 
  20218.  
  20219.  include statement In the C and C++ languages, a preprocessor statement that 
  20220.            causes the preprocessor to replace the statement with the contents 
  20221.            of a specified file. IBM. 
  20222.  
  20223.  incomplete type A type that has no value or meaning when it is first declared. 
  20224.            There are three incomplete types: void, arrays of unknown size and 
  20225.            structures and unions of unspecified content. A void type can never 
  20226.            be completed. Arrays of unknown size and structures or unions of 
  20227.            unspecified content can be completed in further declarations. 
  20228.  
  20229.  indirection 
  20230.  
  20231.              1. A mechanism for connecting objects by storing, in one object, a 
  20232.                 reference to another object. 
  20233.  
  20234.              2. In the C and C++ languages, the application of the unary 
  20235.                 operator * to a pointer to access the object the pointer points 
  20236.                 to. 
  20237.  
  20238.  inheritance 
  20239.  
  20240.              1. An object-oriented programming technique that allows you to use 
  20241.                 existing classes as bases for creating other classes. 
  20242.  
  20243.              2. A mechanism by which a derived class can use the attributes, 
  20244.                 relationships, and member functions defined in more abstract 
  20245.                 classes related to it (its base classes). See also multiple 
  20246.                 inheritance. 
  20247.  
  20248.  initializer An expression used to initialize objects. In the C++ language, 
  20249.            there are three types of initializers: 
  20250.  
  20251.              1. An expression followed by an assignment operator is used to 
  20252.                 initialize fundamental data type objects or class objects that 
  20253.                 have copy constructors. 
  20254.              2. An expression enclosed in braces ( { } ) is used to initialize 
  20255.                 aggregates. 
  20256.              3. A parenthesized expression list is used to initialize base 
  20257.                 classes and members using constructors. 
  20258.  
  20259.  inlined function A function call that the compiler replaces with the actual 
  20260.            code for the function. You can direct the compiler to inline a 
  20261.            function with the inline keyword. 
  20262.  
  20263.  input stream A sequence of control statements and data submitted to a system 
  20264.            from an input unit. 
  20265.  
  20266.  instance (of a class) An object that is a member of that class. An object 
  20267.            created according to the definition of that class. 
  20268.  
  20269.  instantiate To create or generate a particular instance or object of a data 
  20270.            type. For example, an instance box1 of class box could be 
  20271.            instantiated with the declaration: 
  20272.  
  20273.                       box box1;
  20274.  
  20275.  instruction A program statement that specifies an operation to be performed by 
  20276.            the computer, along with the values or locations of operands.  This 
  20277.            statement represents the programmer's request to the processor to 
  20278.            perform a specific operation. 
  20279.  
  20280.  instruction scheduling An optimization technique that reorders instructions in 
  20281.            code to minimize execution time. 
  20282.  
  20283.  integer constant A decimal, octal, or hexadecimal constant. 
  20284.  
  20285.  internationalization The capability of a computer program to adapt to the 
  20286.            requirements of different native languages, local customs, and coded 
  20287.            character sets. X/Open. 
  20288.  
  20289.  interrupt A temporary suspension of a process caused by an external event, 
  20290.            performed in such a way that the process can be resumed. 
  20291.  
  20292.  intrinsic function A function supplied by a program as opposed to a function 
  20293.            supplied by the compiler. 
  20294.  
  20295.  I/O Stream Library A class library that provides the facilities to deal with 
  20296.            many varieties of input and output. 
  20297.  
  20298.  iteration The process of repeatedly applying a function to a series of 
  20299.            elements in a collection until some condition is satisfied. 
  20300.  
  20301.  
  20302. ΓòÉΓòÉΓòÉ <hidden> K ΓòÉΓòÉΓòÉ
  20303.  
  20304.  kernel    The core of an operating system, usually responsible for basic I/O 
  20305.            and process execution. 
  20306.  
  20307.  keyword 
  20308.  
  20309.              1. A predefined word reserved for the C or C++ language that you 
  20310.                 cannot use as an identifier. 
  20311.  
  20312.              2. A symbol that identifies a parameter. 
  20313.  
  20314.  
  20315. ΓòÉΓòÉΓòÉ <hidden> L ΓòÉΓòÉΓòÉ
  20316.  
  20317.  label     An identifier within or attached to a set of data elements. 
  20318.  
  20319.                        ISO Draft.
  20320.  
  20321.  last element The element accessed last in an iteration over a collection. Each 
  20322.            collection has its own definition for last element. For example, the 
  20323.            last element of a sorted set is the element with the largest value. 
  20324.  
  20325.  leaves    In a tree, nodes without children.  Synonymous with terminals. 
  20326.  
  20327.  lexically Relating to the left-to-right order of units. 
  20328.  
  20329.  library 
  20330.  
  20331.              1. A collection of functions, function calls, subroutines, or 
  20332.                 other data. 
  20333.  
  20334.              2. A set of object modules that can be specified in a link 
  20335.                 command. 
  20336.  
  20337.  link      To interconnect items of data or portions of one or more computer 
  20338.            programs; for example, linking of object programs by a linkage 
  20339.            editor to produce an executable file. 
  20340.  
  20341.  linkage editor Synonym for linker. 
  20342.  
  20343.  linker    A program that resolves cross-references between separately compiled 
  20344.            object modules and then assigns final addresses to create a single 
  20345.            executable program. 
  20346.  
  20347.  literal 
  20348.  
  20349.              1. In programming languages, a lexical unit that directly 
  20350.                 represents a value; for example, 14 represents the integer 
  20351.                 fourteen, "APRIL" represents the string of characters APRIL, 
  20352.                 3.0005E2 represents the number 300.05. ISO-JTC1. 
  20353.  
  20354.              2. A symbol or a quantity in a source program that is itself data, 
  20355.                 rather than a reference to data. IBM. 
  20356.  
  20357.              3. A character string whose value is given by the characters 
  20358.                 themselves; for example, the numeric literal 7 has the value 7, 
  20359.                 and the character literal CHARACTERS has the value CHARACTERS. 
  20360.                 IBM. 
  20361.  
  20362.  loader    A routine, commonly a computer program, that reads data into main 
  20363.            storage. American National Standard for Information Systems. 
  20364.  
  20365.  load module All or part of a computer program in a form suitable for loading 
  20366.            into main storage for execution.  A load module is usually the 
  20367.            output of a linkage editor. ISO Draft. 
  20368.  
  20369.  local 
  20370.  
  20371.              1. In programming languages, pertaining to the relationship 
  20372.                 between a language object and a block such that the language 
  20373.                 object has a scope contained in that block. ISO-JTC1. 
  20374.  
  20375.              2. Pertaining to that which is defined and used only in one 
  20376.                 subdivision of a computer program. American National Standard 
  20377.                 for Information Systems. 
  20378.  
  20379.  locale    The definition of the subset of a user's environment that depends on 
  20380.            language and cultural conventions. 
  20381.  
  20382.  localization The process of establishing information within a computer system 
  20383.            specific to the operation of particular native languages, local 
  20384.            customs, and coded character sets. X/Open. 
  20385.  
  20386.  local scope A name declared in a block, which can only be used in that block. 
  20387.  
  20388.  
  20389. ΓòÉΓòÉΓòÉ <hidden> M ΓòÉΓòÉΓòÉ
  20390.  
  20391.  macro     An identifier followed by arguments (may be a parenthesized list of 
  20392.            arguments) that the preprocessor replaces with the replacement code 
  20393.            located in a preprocessor #define directive. 
  20394.  
  20395.  main function An external function with the identifier main that is the first 
  20396.            user function-aside from exit routines and C++ static object 
  20397.            constructors-to get control when program execution begins. Each C 
  20398.            and C++ program must have exactly one function named main. 
  20399.  
  20400.  make      An action in which a project's target is built from a makefile by a 
  20401.            make utility. 
  20402.  
  20403.  makefile  A text file containing a list of your application's parts.  The make 
  20404.            utility uses makefiles to maintain application parts and 
  20405.            dependencies. 
  20406.  
  20407.  mangling  The encoding during compilation of identifiers such as function and 
  20408.            variable names to include type and scope information.  The prelinker 
  20409.            uses these mangled names to ensure type-safe linkage. See also 
  20410.            demangling. 
  20411.  
  20412.  map file  A listing file that can be created during the prelink or link step 
  20413.            and that contains information on the size and mapping of segments 
  20414.            and symbols. 
  20415.  
  20416.  mask      A pattern of bits or characters that controls the keeping, deleting, 
  20417.            or testing of portions of another pattern of bits or characters. 
  20418.            ISO-JTCI. ANSI. 
  20419.  
  20420.  MBCS      See multibyte character set. 
  20421.  
  20422.  member    Data, functions, or types contained in classes, structures, or 
  20423.            unions. 
  20424.  
  20425.  member function 
  20426.  
  20427.              1. In C++, an operator or function that is declared as a member of 
  20428.                 a class. A member function has access to the private and 
  20429.                 protected data members and member functions of objects of its 
  20430.                 class. Member functions are also called methods. 
  20431.  
  20432.              2. A function that performs operations on a class. 
  20433.  
  20434.  message   A request from one object that the receiving object implement a 
  20435.            method. Because data is encapsulated and not directly accessible, a 
  20436.            message is the only way to send data from one object to another. 
  20437.            Each message specifies the name of the receiving object, the method 
  20438.            to be implemented, and any parameters the method needs for 
  20439.            implementation. 
  20440.  
  20441.  method    Synonym for member function. 
  20442.  
  20443.  migrate   To move to a changed operating environment,  usually to a new 
  20444.            release or version of a system. IBM. 
  20445.  
  20446.  mix 
  20447.  
  20448.              1. An attribute that determines how the foreground of a graphic 
  20449.                 primitive is combined with the existing color of graphics 
  20450.                 output. Also known as foreground mix. Contrast with background 
  20451.                 mix. 
  20452.  
  20453.              2. The combination of audio or video sources during 
  20454.                 postproduction. 
  20455.  
  20456.  mode      A collection of attributes that specifies a file's type and its 
  20457.            access permissions. X/Open. ISO.1. 
  20458.  
  20459.  model     In Compound Document Framework, the data portion of a document 
  20460.            component. The model and the view comprise the two pieces of a 
  20461.            document component. Compound Document Framework provides an IModel 
  20462.            base class from which other model classes can be derived. 
  20463.  
  20464.  module    A program unit that usually performs a particular function or 
  20465.            related functions, and that is distinct and identifiable with 
  20466.            respect to compiling, combining with other units, and loading. 
  20467.  
  20468.  module definition file A file used by the linker that contains module 
  20469.            statements that define general attributes of the executable being 
  20470.            linked, segment attributes, and imported or exported functions and 
  20471.            data. 
  20472.  
  20473.  multibyte character A mixture of single-byte characters from a single-byte 
  20474.            character set and double-byte characters from a double-byte 
  20475.            character set. 
  20476.  
  20477.  multibyte character set (MBCS) A character set whose characters consist of 
  20478.            more than 1 byte.  Used in languages such as Japanese, Chinese, and 
  20479.            Korean, where the 256 possible values of a single-byte character set 
  20480.            are not sufficient to represent all possible characters. 
  20481.  
  20482.  multicharacter collating element A sequence of two or more characters that 
  20483.            collate as an entity.  For example, in some coded character sets, an 
  20484.            accented character is represented by a non-spacing accent, followed 
  20485.            by the letter.  Other examples are the Spanish elements ch and ll. 
  20486.            X/Open. 
  20487.  
  20488.  multimedia Computer-controlled presentations combining any of the following: 
  20489.            text, graphics, animation, full-motion images, still video images, 
  20490.            and sound. 
  20491.  
  20492.  multiple inheritance 
  20493.  
  20494.              1. An object-oriented programming technique implemented in C++ 
  20495.                 through derivation, in which the derived class inherits members 
  20496.                 from more than one base class. 
  20497.  
  20498.              2. The structuring of inheritance relationships among classes so a 
  20499.                 derived class can use the attributes, relationships, and 
  20500.                 functions used by more than one base class. 
  20501.  
  20502.                 See also inheritance and class lattice. 
  20503.  
  20504.  multitasking 
  20505.  
  20506.              1. A mode of operation that allows concurrent performance or 
  20507.                 interleaved execution of more than one task or program. 
  20508.  
  20509.              2. A process that allows a computer or operating system to run 
  20510.                 multiple applications or tasks concurrently by dividing the 
  20511.                 processor's time between them rapidly. 
  20512.  
  20513.                 See also preemptive multitasking. Contrast with nonpreemptive 
  20514.                 multitasking. 
  20515.  
  20516.  multithread Pertaining to concurrent operation of more than one path of 
  20517.            execution within a computer. 
  20518.  
  20519.  multithreading A process that allows a multitasking operating system to 
  20520.            multitask subportions (threads) of an application smoothly. 
  20521.  
  20522.  mutex 
  20523.  
  20524.              1. In Windows, a flag that prevents threads from interacting with 
  20525.                 the 16-bit kernel when another thread is executing code there. 
  20526.                 See also nonreentrant. 
  20527.  
  20528.              2. A synchronization kernel object that synchronizes data access 
  20529.                 across multiple processes. A mutex object is either signaled or 
  20530.                 nonsignaled and is owned by a thread. See also critical 
  20531.                 section, semaphore, event, signaled, and nonsignaled. 
  20532.  
  20533.  
  20534. ΓòÉΓòÉΓòÉ <hidden> N ΓòÉΓòÉΓòÉ
  20535.  
  20536.  name      In the C++ language, a name is commonly referred to as an 
  20537.            identifier. However, syntactically, a name can be an identifier, 
  20538.            operator function name, conversion function name, destructor name, 
  20539.            or qualified name. 
  20540.  
  20541.  native    The rendering mechanism and format (RMF) that best represents the 
  20542.            object and is the best one for rendering. 
  20543.  
  20544.            For example, a native of Cincinnati understands the streets in the 
  20545.            area better than someone who has just moved there. Therefore, a 
  20546.            Cincinnati native can get from point A to point B quicker than a 
  20547.            newcomer. Likewise, a native RMF can get the data transferred from 
  20548.            point A to point B more efficiently than the additional RMFs. We can 
  20549.            use additional RMFs when we cannot use the native, or optimal, 
  20550.            approach. 
  20551.  
  20552.  nested class A class defined within the scope of another class. 
  20553.  
  20554.  new 
  20555.  
  20556.              1. A C++ keyword identifying a free storage allocation operator. 
  20557.  
  20558.              2. A C++ operator used to create class objects. 
  20559.  
  20560.  new-line character A control character that causes the print or display 
  20561.            position to move to the first position on the next line. This 
  20562.            control character is represented by \n in the C language. 
  20563.  
  20564.  node      In a tree structure, a point at which subordinate items of data 
  20565.            originate. 
  20566.  
  20567.  nonmember function A function that occurs outside a class. 
  20568.  
  20569.  nonreentrant The state of 16-bit code in the kernel where two threads cannot 
  20570.            access it at the same time without risking a system crash. 
  20571.  
  20572.            In Windows 95, processes are preempted and any thread is likely to 
  20573.            be interrupted at any point in its execution. 
  20574.  
  20575.            See also mutex. 
  20576.  
  20577.  NT file system (NTFS) A Windows NT disk drive file system that restores 
  20578.            disk-based data after a system failure. NTFS can manipulate 
  20579.            extremely large storage media and has file names up to 255 
  20580.            characters in length. 
  20581.  
  20582.  NTFS      See NT file system. 
  20583.  
  20584.  NULL      In the C and C++ languages, a pointer that does not point to a data 
  20585.            object. IBM. 
  20586.  
  20587.  null character (\0) The ASCII or EBCDIC character with the hex value 00 (all 
  20588.            bits turned off). It is used to represent the absence of a printed 
  20589.            or displayed character. This character is named <NUL> in the 
  20590.            portable character set. 
  20591.  
  20592.  null pointer The value that is obtained by converting the number 0 into a 
  20593.            pointer; for example, (void *) 0.  The C and C++ languages guarantee 
  20594.            that this value will not match that of any legitimate pointer, so it 
  20595.            is used by many functions that return pointers to indicate an error. 
  20596.            X/Open. 
  20597.  
  20598.  null string 
  20599.  
  20600.              1. A string whose first byte is a null byte. Synonymous with empty 
  20601.                 string. X/Open. 
  20602.  
  20603.              2. A character array whose first element is a null character. 
  20604.                 ISO.1. 
  20605.  
  20606.  null value A parameter position for which no value is specified. IBM. 
  20607.  
  20608.  number sign The character #, also known as pound sign and hash sign. This 
  20609.            character is named <number-sign> in the portable character set. 
  20610.  
  20611.  
  20612. ΓòÉΓòÉΓòÉ <hidden> O ΓòÉΓòÉΓòÉ
  20613.  
  20614.  object 
  20615.  
  20616.              1. A computer representation of something that a user can work 
  20617.                 with to perform a task. An object can appear as text or an 
  20618.                 icon. 
  20619.  
  20620.              2. A collection of data and member functions that operate on that 
  20621.                 data, which together represent a logical entity in the system. 
  20622.                 In object-oriented programming, objects are grouped into 
  20623.                 classes that share common data definitions and member 
  20624.                 functions. Each object in the class is said to be an instance 
  20625.                 of the class. 
  20626.  
  20627.              3. In Visual Builder, an instance of an object class consisting of 
  20628.                 attributes, a data structure, and operational member functions. 
  20629.                 It can represent a person, place, thing, event, or concept. 
  20630.                 Each instance has the same properties, attributes, and member 
  20631.                 functions as other instances of the object class, though it has 
  20632.                 unique values assigned to its attributes. 
  20633.  
  20634.              4. In Windows, any item that is or can be linked into another 
  20635.                 Windows application, such as a sound, graphic, piece of text, 
  20636.                 or portion of a spreadsheet. An object must be from an 
  20637.                 application that supports OLE. See object linking and embedding 
  20638.                 (OLE). 
  20639.  
  20640.  object code Machine-executable instructions, usually generated by a compiler 
  20641.            from source code written in a higher level language (such as the C++ 
  20642.            language). For programs that must be linked, object code consists of 
  20643.            relocatable machine code. 
  20644.  
  20645.  object linking and embedding (OLE) 
  20646.  
  20647.              1. An API that supports compound documents, cross-application 
  20648.                 macro control, and common object registration. OLE defines 
  20649.                 protocols for in-place editing, drag-and-drop data transfers, 
  20650.                 structured storage, custom controls, and more. 
  20651.  
  20652.              2. A data-sharing scheme that allows dissimilar applications to 
  20653.                 create single complex documents cooperatively. The documents 
  20654.                 can consist of material that a single application could not 
  20655.                 have created on its own. 
  20656.  
  20657.  object module 
  20658.  
  20659.              1. All or part of an object program sufficiently complete for 
  20660.                 linking.  Assemblers and compilers usually produce object 
  20661.                 modules. ISO Draft. 
  20662.  
  20663.              2. A set of instructions in machine language produced by a 
  20664.                 compiler from a source program. IBM. 
  20665.  
  20666.  object-oriented programming A programming approach based on the concepts of 
  20667.            data abstraction and inheritance. Unlike procedural programming 
  20668.            techniques, object-oriented programming concentrates on what data 
  20669.            objects comprise the problem and how they are manipulated, not on 
  20670.            how something is accomplished. 
  20671.  
  20672.  octal constant The digit 0 (zero) followed by any digits 0 through 7. 
  20673.  
  20674.  OLE       See object linking and embedding. 
  20675.  
  20676.  open file A file that is currently associated with a file descriptor. X/Open. 
  20677.            ISO.1. 
  20678.  
  20679.  operator function An overloaded operator that is either a member of a class or 
  20680.            that takes at least one argument that is a class type or a reference 
  20681.            to a class type. See overloading. 
  20682.  
  20683.  operator precedence In programming languages, an order relation defining the 
  20684.            sequence of the application of operators within an expression. 
  20685.            ISO-JTC1. 
  20686.  
  20687.  overflow  A condition that occurs when a portion of the result of an operation 
  20688.            exceeds the capacity of the intended unit of storage. 
  20689.  
  20690.  overloading An object-oriented programming technique where one or more 
  20691.            function declarations are specified for a single name in the same 
  20692.            scope. 
  20693.  
  20694.  
  20695. ΓòÉΓòÉΓòÉ <hidden> P ΓòÉΓòÉΓòÉ
  20696.  
  20697.  pack      To store data in a compact form in such a way that the original form 
  20698.            can be recovered. 
  20699.  
  20700.  pad       To fill unused positions in a field with data, usually 0's, 1's, or 
  20701.            blanks. 
  20702.  
  20703.  parameter 
  20704.  
  20705.              1. In the C and C++ languages, an object declared as part of a 
  20706.                 function declaration or definition that acquires a value on 
  20707.                 entry to the function, or an identifier following the macro 
  20708.                 name in a function-like macro definition. X/Open. 
  20709.  
  20710.              2. Data passed between programs or procedures. IBM. 
  20711.  
  20712.  parameter declaration A description of a value that a function receives. A 
  20713.            parameter declaration determines the storage class and the data type 
  20714.            of the value. 
  20715.  
  20716.  parent process 
  20717.  
  20718.              1. The program that originates the creation of other processes by 
  20719.                 means of spawn or exec function calls. See also child process. 
  20720.  
  20721.              2. A process that creates other processes. 
  20722.  
  20723.  part      In Visual Builder, a part is a self-contained object with a 
  20724.            standardized public interface consisting of a set of external 
  20725.            features that allow the part to interact with other parts. A part is 
  20726.            implemented as a class that supports the INotifier protocol and has 
  20727.            a part interface defined. 
  20728.  
  20729.  path name 
  20730.  
  20731.              1. A string that is used to identify a file. A path name consists 
  20732.                 of, at most, {PATH_MAX} bytes, including the terminating null 
  20733.                 character.  It has an optional beginning slash, followed by 
  20734.                 zero or more file names separated by slashes.  If the path name 
  20735.                 refers to a directory, it may also have one or more trailing 
  20736.                 slashes.  Multiple successive slashes are considered to be the 
  20737.                 same as one slash.  A path name that begins with two successive 
  20738.                 slashes may be interpreted in an implementation-dependent 
  20739.                 manner, although more than two leading slashes will be treated 
  20740.                 as a single slash.  The interpretation of the path name is 
  20741.                 described in pathname resolution. ISO.1. 
  20742.  
  20743.              2. A file name specifying all directories leading to the file. 
  20744.  
  20745.  pattern   A sequence of characters used either with regular expression 
  20746.            notation or for path name expansion, as a means of selecting various 
  20747.            characters strings or path names, respectively. The syntaxes of the 
  20748.            two patterns are similar, but not identical. X/Open. 
  20749.  
  20750.  pipe      To direct data so that the output from one process becomes the input 
  20751.            to another process.  The standard output of one command can be 
  20752.            connected to the standard input of another with the pipe operator 
  20753.            (|).  Two commands connected in this way constitute a pipeline. IBM. 
  20754.  
  20755.  pointer   A variable that holds the address of a data object or function. 
  20756.  
  20757.  pointer to member An operator used to access the address of nonstatic members 
  20758.            of a class. 
  20759.  
  20760.  polymorphism The technique of taking an abstract view of an object or function 
  20761.            and using any concrete objects or arguments that are derived from 
  20762.            this abstract view. 
  20763.  
  20764.  portable character set The set of characters specified in POSIX 1003.2, 
  20765.            section 2.4: 
  20766.  
  20767.                       <NUL>
  20768.                       <alert>
  20769.                       <backspace>
  20770.                       < tab>
  20771.                       <newline>
  20772.                       <vertical-tab>
  20773.                       <form-feed>
  20774.                       <carriage-return>
  20775.                       <space>
  20776.                       <exclamation-mark>   !
  20777.                       <quotation-mark>    "
  20778.                       <number-sign>      #
  20779.                       <dollar-sign>      $
  20780.                       <percent-sign>     %
  20781.                       <ampersand>       &
  20782.                       <apostrophe>      '
  20783.                       <left-parenthesis>   (
  20784.                       <right-parenthesis>   )
  20785.                       <asterisk>       *
  20786.                       <plus-sign>       +
  20787.                       <comma>         ,
  20788.                       <hyphen>        -
  20789.                       <hyphen-minus>     -
  20790.                       <period>        .
  20791.                       <slash>         /
  20792.                       <zero>         0
  20793.                       <one>          1
  20794.                       <two>          2
  20795.                       <three>         3
  20796.                       <four>         4
  20797.                       <five>         5
  20798.                       <six>          6
  20799.                       <seven>         7
  20800.                       <eight>         8
  20801.                       <nine>         9
  20802.                       <colon>         :
  20803.                       <semicolon>       ;
  20804.                       <less-than-sign>    <
  20805.                       <equals-sign>      =
  20806.                       <greater-than-sign>   >
  20807.                       <question-mark>     ?
  20808.                       <commercial-at>     @
  20809.  
  20810.                       <A>           A
  20811.                       <B>           B
  20812.                       <C>           C
  20813.                       <D>           D
  20814.                       <E>           E
  20815.                       <F>           F
  20816.                       <G>           G
  20817.                       <H>           H
  20818.                       <I>           I
  20819.                       <J>           J
  20820.                       <K>           K
  20821.                       <L>           L
  20822.                       <M>           M
  20823.                       <N>           N
  20824.                       <O>           O
  20825.                       <P>           P
  20826.                       <Q>           Q
  20827.                       <R>           R
  20828.                       <S>           S
  20829.                       <T>           T
  20830.                       <U>           U
  20831.                       <V>           V
  20832.                       <W>           W
  20833.                       <X>           X
  20834.                       <Y>           Y
  20835.                       <Z>           Z
  20836.  
  20837.                       <left-square-bracket>  [
  20838.                       <backslash>       \
  20839.                       <reverse-solidus>    \
  20840.                       <right-square-bracket> ]
  20841.                       <circumflex>      ^
  20842.                       <circumflex-accent>   ^
  20843.                       <underscore>      _
  20844.                       <low-line>       _
  20845.                       <grave-accent>     `
  20846.  
  20847.                       <a>           a
  20848.                       <b>           b
  20849.                       <c>           c
  20850.                       <d>           d
  20851.                       <e>           e
  20852.                       <f>           f
  20853.                       <g>           g
  20854.                       <h>           h
  20855.                       <i>           i
  20856.                       <j>           j
  20857.                       <k>           k
  20858.                       <l>           l
  20859.                       <m>           m
  20860.                       <n>           n
  20861.                       <o>           o
  20862.                       <p>           p
  20863.                       <q>           q
  20864.                       <r>           r
  20865.                       <s>           s
  20866.                       <t>           t
  20867.                       <u>           u
  20868.                       <v>           v
  20869.                       <w>           w
  20870.                       <x>           x
  20871.                       <y>           y
  20872.                       <z>           z
  20873.  
  20874.                       <left-brace>      {
  20875.                       <left-curly-bracket>  {
  20876.                       <vertical-line>     |
  20877.                       <right-brace>      }
  20878.                       <right-curly-bracket>  }
  20879.                       <tilde>         ~
  20880.  
  20881.  portability The ability of a programming language to compile successfully on 
  20882.            different operating systems without requiring changes to the source 
  20883.            code. 
  20884.  
  20885.  precedence The priority system for grouping different types of operators with 
  20886.            their operands. 
  20887.  
  20888.  predefined macros Frequently used routines provided by an application or 
  20889.            language for the programmer. 
  20890.  
  20891.  preemptive multitasking The operating system's ability to interrupt a thread 
  20892.            at (almost) any time and assign the processor to a waiting thread. 
  20893.            Multiple applications can thus run simultaneously, and a single 
  20894.            application cannot control all of the system resources. 
  20895.  
  20896.            Contrast with nonpreemptive multitasking. 
  20897.  
  20898.  preparation Any activity that the source performs before rendering the data. 
  20899.            For example, the drag item may require that the source create a 
  20900.            secondary thread for the source rendering to take place in. The 
  20901.            system remains responsive to users so that they can do other tasks. 
  20902.  
  20903.  preprocessor A phase of the compiler that examines the source program for 
  20904.            preprocessor statements, which are then executed, resulting in the 
  20905.            alteration of the source program. 
  20906.  
  20907.  private   Pertaining to a class member that is accessible only to member 
  20908.            functions and friends of that class. 
  20909.  
  20910.  process 
  20911.  
  20912.              1. A collection of code, data, and other system resources, 
  20913.                 including at least one thread of execution, that performs a 
  20914.                 data processing task. 
  20915.  
  20916.              2. A running application, its address space, and its resources. 
  20917.  
  20918.              3. An instance of a running program. A Win32 process owns a 4-GB 
  20919.                 address space containing the code and data for an application's 
  20920.                 .exe file; it does not execute anything. It also owns certain 
  20921.                 resources, such as files, dynamic memory allocations, and 
  20922.                 threads. 
  20923.  
  20924.              4. A program running under OS/2, along with the resources 
  20925.                 associated with it (memory, threads, file system resources, and 
  20926.                 so on). 
  20927.  
  20928.  program 
  20929.  
  20930.              1. One or more files containing a set of instructions conforming 
  20931.                 to a particular programming language syntax. 
  20932.  
  20933.              2. A self-contained, executable module. Multiple copies of the 
  20934.                 same program can be run in different processes. 
  20935.  
  20936.  program group In Windows NT, a window displaying a group of programs. 
  20937.  
  20938.  project 
  20939.  
  20940.              1. A container that groups related objects (tasks) into a primary 
  20941.                 window. When the user opens the object, the object has its own 
  20942.                 primary window. 
  20943.  
  20944.              2. In WorkFrame, the complete set of data objects (called project 
  20945.                 parts) 
  20946.  
  20947.                                  and actions needed to build
  20948.                 a single target, such as a dynamic link library (DLL) or 
  20949.                 executable file (EXE). 
  20950.  
  20951.  protected Pertaining to a class member that is only accessible to member 
  20952.            functions and friends of that class, or to member functions and 
  20953.            friends of classes derived from that class. 
  20954.  
  20955.  prototype A function declaration or definition that includes both the return 
  20956.            type of the function and the types of its arguments. 
  20957.  
  20958.  public    Pertaining to a class member that is accessible to all functions. 
  20959.  
  20960.  pure virtual function A virtual function that has a function initializer of 
  20961.            the form = 0;. 
  20962.  
  20963.  
  20964. ΓòÉΓòÉΓòÉ <hidden> Q ΓòÉΓòÉΓòÉ
  20965.  
  20966.  qualified name Used to qualify a nonclass type name such as a member by its 
  20967.            class name. 
  20968.  
  20969.  queue     A sequence with restricted access in which elements can only be 
  20970.            added at the back end (or bottom) and removed from the front end (or 
  20971.            top). A queue is characterized by first-in, first-out behavior and 
  20972.            chronological order. 
  20973.  
  20974.  
  20975. ΓòÉΓòÉΓòÉ <hidden> R ΓòÉΓòÉΓòÉ
  20976.  
  20977.  redirection In the shell, a method of associating files with the input or 
  20978.            output of commands. X/Open. 
  20979.  
  20980.  reentrant The attribute of a program or routine that allows the same copy of a 
  20981.            program or routine to be used concurrently by two or more tasks. 
  20982.  
  20983.  register storage class specifier A specifier that indicates to the compiler 
  20984.            within a block scope data definition, or a parameter declaration, 
  20985.            that the object being described will be heavily used. 
  20986.  
  20987.  regular expression 
  20988.  
  20989.              1. A mechanism to select specific strings from a set of character 
  20990.                 strings. 
  20991.  
  20992.              2. A set of characters, meta-characters, and operators that define 
  20993.                 a string or group of strings in a search pattern. 
  20994.  
  20995.              3. A string containing wildcard characters and operations that 
  20996.                 define a set of one or more possible strings. 
  20997.  
  20998.  regular file A file that is a randomly accessible sequence of bytes, with no 
  20999.            further structure imposed by the system. X/Open. ISO.1. 
  21000.  
  21001.  relation  An unordered flat collection class that uses keys, allows for 
  21002.            duplicate elements, and has element equality. 
  21003.  
  21004.  resource file A file that contains data used by an application, such as text 
  21005.            strings and icons. 
  21006.  
  21007.  return    A language construct that ends an execution sequence in a procedure. 
  21008.            IBM. 
  21009.  
  21010.  root      A node that has no parent. All other nodes of a tree are descendants 
  21011.            of the root. 
  21012.  
  21013.  RTTI       Run-time type identification. 
  21014.  
  21015.  run-time library A compiled collection of functions whose members can be 
  21016.            referred to by an application program during run-time execution. 
  21017.            Typically used to refer to a dynamic library that is provided in 
  21018.            object code, such that references to the library are resolved during 
  21019.            the linking step.  The run-time library itself is not statically 
  21020.            bound into the application modules. 
  21021.  
  21022.  run-time type identification (RTTI) A mechanism in the C++ language for 
  21023.            determining the class of an object at run time. It consists of two 
  21024.            operators, one for determining the run-time type of an object 
  21025.            (typeid) and one for doing type conversions that are checked at run 
  21026.            time (dynamic_cast). A type_info class describes the RTTI available 
  21027.            and defines the type returned by the typeid operator. 
  21028.  
  21029.  
  21030. ΓòÉΓòÉΓòÉ <hidden> S ΓòÉΓòÉΓòÉ
  21031.  
  21032.  SBCS (Single-Byte Character Set) See single-byte character set. 
  21033.  
  21034.  scalar    An arithmetic object, or a pointer to an object of any type. 
  21035.  
  21036.  scan      To search backward and forward at high speed on a CD audio device. 
  21037.            Scanning is analogous to fast forwarding. 
  21038.  
  21039.  scope     That part of a source program in which an object is defined and 
  21040.            recognized. 
  21041.  
  21042.  semaphore A synchronization kernel object used for resource-counting. A 
  21043.            semaphore offers a thread the ability to query the number of 
  21044.            resources available. If one or more resources are available, the 
  21045.            count of available resources is decremented. 
  21046.  
  21047.            See also critical section, mutex, and event. 
  21048.  
  21049.  sequence  A sequentially ordered flat collection. 
  21050.  
  21051.  server    In Compound Document Framework, an application or a document 
  21052.            component that supplies an object. For example, a drawing program 
  21053.            that provides a picture that can be placed inside a word processing 
  21054.            document is referred to as a server. 
  21055.  
  21056.  shell     A program that interprets sequences of text input as commands. It 
  21057.            may operate on an input stream or it may interactively prompt and 
  21058.            read commands from a terminal. X/Open. 
  21059.  
  21060.            This feature is provided as part of OpenEdition MVS Shell and 
  21061.            Utilities feature licensed program. 
  21062.  
  21063.  signal 
  21064.  
  21065.              1. A condition that may or may not be reported during program 
  21066.                 execution. For example, SIGFPE is the signal used to represent 
  21067.                 erroneous arithmetic operations such as a division by zero. 
  21068.  
  21069.              2. A mechanism by which a process may be notified of, or affected 
  21070.                 by, an event occurring in the system. Examples of such events 
  21071.                 include hardware exceptions and specific actions by processes. 
  21072.                 The term signal is also used to refer to the event itself. 
  21073.                 X/Open. ISO.1. 
  21074.  
  21075.              3. In AIX operating system operations, a method of interprocess 
  21076.                 communication that simulates software interrupts. IBM. 
  21077.  
  21078.  signal handler A function to be called when the signal is reported. 
  21079.  
  21080.  single-byte character set (SBCS) A set of characters in which each character 
  21081.            is represented by a 1-byte code. 
  21082.  
  21083.  slash     The character /, also known as solidus. This character is named 
  21084.            <slash> in the portable character set. 
  21085.  
  21086.  sorted set A sorted flat collection with element equality. 
  21087.  
  21088.  source directory A directory where a project's parts are physically stored. A 
  21089.            project may have many source directories. 
  21090.  
  21091.  source file A file that contains source statements for such items as 
  21092.            high-level language programs and data description specifications. 
  21093.            IBM. 
  21094.  
  21095.  source program A set of instructions written in a programming language that 
  21096.            must be translated to machine language before the program can be 
  21097.            run. IBM. 
  21098.  
  21099.  space character The character defined in the portable character set as 
  21100.            <space>. The space character is a member of the space character 
  21101.            class of the current locale, but represents the single character, 
  21102.            and not all of the possible members of the class. X/Open. 
  21103.  
  21104.  specifiers Used in declarations to indicate storage class, fundamental data 
  21105.            type and other properties of the object or function being declared. 
  21106.  
  21107.  stack     A data structure in which new elements are added to and removed from 
  21108.            the top of the structure.  A stack is characterized by 
  21109.            Last-In-First-Out (LIFO) behavior. 
  21110.  
  21111.  stack frame The physical representation of the activation of a routine. The 
  21112.            stack frame is allocated and freed on a LIFO (last in, first out) 
  21113.            basis. 
  21114.  
  21115.  stack storage Synonym for automatic storage. 
  21116.  
  21117.  standard error An output stream usually intended to be used for diagnostic 
  21118.            messages. 
  21119.  
  21120.  standard input An input stream usua