Release 3.9 the Clang Team

Total Page:16

File Type:pdf, Size:1020Kb

Release 3.9 the Clang Team Clang Documentation Release 3.9 The Clang Team Aug 19, 2017 Contents 1 Introduction 3 2 What’s New in Clang 3.9? 5 3 Additional Information 9 4 Using Clang as a Compiler 11 5 Using Clang as a Library 275 6 Using Clang Tools 303 7 Design Documents 321 8 Indices and tables 371 i ii Clang Documentation, Release 3.9 • Introduction • What’s New in Clang 3.9? – Major New Features – Attribute Changes in Clang – Windows Support – C Language Changes in Clang – C++ Language Changes in Clang – OpenCL C Language Changes in Clang – OpenMP Support in Clang – AST Matchers – Static Analyzer • Additional Information Written by the LLVM Team Contents 1 Clang Documentation, Release 3.9 2 Contents CHAPTER 1 Introduction This document contains the release notes for the Clang C/C++/Objective-C frontend, part of the LLVM Compiler Infrastructure, release 3.9. Here we describe the status of Clang in some detail, including major improvements from the previous release and new feature work. For the general LLVM release notes, see the LLVM documentation. All LLVM releases may be downloaded from the LLVM releases web site. For more information about Clang or LLVM, including information about the latest release, please check out the main please see the Clang Web Site or the LLVM Web Site. 3 Clang Documentation, Release 3.9 4 Chapter 1. Introduction CHAPTER 2 What’s New in Clang 3.9? Some of the major new features and improvements to Clang are listed here. Generic improvements to Clang as a whole or to its underlying infrastructure are described first, followed by language-specific sections with improvements to Clang’s support for those languages. Major New Features • Clang will no longer pass --build-id by default to the linker. In modern linkers that is a relatively expensive option. It can be passed explicitly with -Wl,--build-id. To have clang always pass it, build clang with -DENABLE_LINKER_BUILD_ID. • On Itanium ABI targets, attribute abi_tag is now supported for compatibility with GCC. Clang’s implementation of abi_tag is mostly compatible with GCC ABI version 10. Improvements to Clang’s diagnostics Clang’s diagnostics are constantly being improved to catch more issues, explain them more clearly, and provide more accurate source information about them. The improvements since the 3.8 release include: • -Wcomma is a new warning to show most uses of the builtin comma operator. • -Wfloat-conversion has two new sub-warnings to give finer grain control for floating point to integer conversion warnings. – -Wfloat-overflow-conversion detects when a constant floating point value is converted to an integer type and will overflow the target type. – -Wfloat-zero-conversion detects when a non-zero floating point value is converted to a zero integer value. 5 Clang Documentation, Release 3.9 Attribute Changes in Clang • The nodebug attribute may now be applied to static, global, and local variables (but not parameters or non- static data members). This will suppress all debugging information for the variable (and its type, if there are no other uses of the type). Windows Support TLS is enabled for Cygwin and defaults to -femulated-tls. Proper support, including correct mangling and overloading, added for MS-specific “__unaligned” type qualifier. clang-cl now has limited support for the precompiled header flags /Yc, /Yu, and /Fp. If the precompiled header is passed on the compile command with /FI, then the precompiled header flags are honored. But if the precompiled header is included by an #include <stdafx.h> in each source file instead of by a /FIstdafx.h flag, these flag continue to be ignored. clang-cl has a new flag, /imsvc <dir>, for adding a directory to the system include search path (where warnings are disabled by default) without having to set %INCLUDE%. C Language Changes in Clang The -faltivec and -maltivec flags no longer silently include altivec.h on Power platforms. RenderScript support has been added to the frontend and enabled by the ‘-x renderscript’ option or the ‘.rs’ file extension. C++ Language Changes in Clang • Clang now enforces the rule that a using-declaration cannot name an enumerator of a scoped enumeration. namespace Foo { enum classE { e }; } namespace Bar { using Foo::E::e; // error constexpr auto e= Foo::E::e; // ok } • Clang now enforces the rule that an enumerator of an unscoped enumeration declared at class scope can only be named by a using-declaration in a derived class. class Foo { enum E { e }; } using Foo::e; // error static constexpr auto e= Foo::e; // ok C++1z Feature Support Clang’s experimental support for the upcoming C++1z standard can be enabled with -std=c++1z. Changes to C++1z features since Clang 3.8: 6 Chapter 2. What’s New in Clang 3.9? Clang Documentation, Release 3.9 • The [[fallthrough]], [[nodiscard]], and [[maybe_unused]] attributes are supported in C++11 onwards, and are largely synonymous with Clang’s existing attributes [[clang::fallthrough]], [[gnu::warn_unused_result]], and [[gnu::unused]]. Use -Wimplicit-fallthrough to warn on unannotated fallthrough within switch statements. • In C++1z mode, aggregate initialization can be performed for classes with base classes: struct A{ int n; }; structB :A{ int x, y; }; B b={1,2,3}; // b.n == 1, b.x == 2, b.y == 3 • The range in a range-based for statement can have different types for its begin and end iterators. This is permitted as an extension in C++11 onwards. • Lambda-expressions can explicitly capture *this (to capture the surrounding object by copy). This is permitted as an extension in C++11 onwards. • Objects of enumeration type can be direct-list-initialized from a value of the underlying type. E{n} is equivalent to E(n), except that it implies a check for a narrowing conversion. • Unary fold-expressions over an empty pack are now rejected for all operators other than &&, ||, and ,. OpenCL C Language Changes in Clang Clang now has support for all OpenCL 2.0 features. In particular, the following features have been completed since the previous release: • Pipe builtin functions (s6.13.16.2-4). • Dynamic parallelism support via the enqueue_kernel Clang builtin function, as well as the kernel query functions from s6.13.17.6. • Address space conversion functions to_{global/local/private}. • nosvm attribute support. • Improved diagnostic and generation of Clang Blocks used in OpenCL kernel code. • opencl_unroll_hint pragma. Several miscellaneous improvements have been made: • Supported extensions are now part of the target representation to give correct diagnostics for unsupported target features during compilation. For example, when compiling for a target that does not support the double precision floating point extension, Clang will give an error when encountering the cl_khr_fp64 pragma. Several missing extensions were added covering up to and including OpenCL 2.0. • Clang now comes with the OpenCL standard headers declaring builtin types and functions up to and including OpenCL 2.0 in lib/Headers/opencl-c.h. By default, Clang will not include this header. It can be included either using the regular -I<path to header location> directive or (if the default one from installation is to be used) using the -finclude-default-header frontend flag. Example: echo "bool is_wg_uniform(int i){return get_enqueued_local_size(i)==get_local_ ,!size(i);}" > test.cl clang -cc1 -finclude-default-header -cl-std=CL2.0 test.cl All builtin function declarations from OpenCL 2.0 will be automatically visible in test.cl. 2.6. OpenCL C Language Changes in Clang 7 Clang Documentation, Release 3.9 • Image types have been improved with better diagnostics for access qualifiers. Images with one access qualifier type cannot be used in declarations for another type. Also qualifiers are now propagated from the frontend down to libraries and backends. • Diagnostic improvements for OpenCL types, address spaces and vectors. • Half type literal support has been added. For example, 1.0h represents a floating point literal in half precision, i.e., the value 0xH3C00. • The Clang driver now accepts OpenCL compiler options -cl-* (following the OpenCL Spec v1.1-1.2 s5.8). For example, the -cl-std=CL1.2 option from the spec enables compilation for OpenCL 1.2, or -cl-mad-enable will enable fusing multiply-and-add operations. • Clang now uses function metadata instead of module metadata to propagate information related to OpenCL kernels e.g. kernel argument information. OpenMP Support in Clang Added support for all non-offloading features from OpenMP 4.5, including using data members in private clauses of non-static member functions. Additionally, data members can be used as loop control variables in loop-based directives. Currently Clang supports OpenMP 3.1 and all non-offloading features of OpenMP 4.0/4.5. Offloading features are under development. Clang defines macro _OPENMP and sets it to OpenMP 3.1 (in accordance with OpenMP standard) by default. User may change this value using -fopenmp-version=[31|40|45] option. The codegen for OpenMP constructs was significantly improved to produce much more stable and faster code. AST Matchers • has and hasAnyArgument: Matchers no longer ignore parentheses and implicit casts on the argument before ap- plying the inner matcher. The fix was done to allow for greater control by the user. In all existing checkers that use this matcher all instances of code hasAnyArgument(<inner matcher>) or has(<inner matcher>) must be changed to hasAnyArgument(ignoringParenImpCasts(<inner matcher>)) or has(ignoringParenImpCasts(<inner matcher>)). Static Analyzer The analyzer now checks for incorrect usage of MPI APIs in C and C++. This check can be enabled by passing the following command to scan-build: -enable-checker optin.mpi.MPI-Checker. The analyzer now checks for improper instance cleanup up in Objective-C -dealloc methods under manual re- tain/release.
Recommended publications
  • Using the GNU Compiler Collection (GCC)
    Using the GNU Compiler Collection (GCC) Using the GNU Compiler Collection by Richard M. Stallman and the GCC Developer Community Last updated 23 May 2004 for GCC 3.4.6 For GCC Version 3.4.6 Published by: GNU Press Website: www.gnupress.org a division of the General: [email protected] Free Software Foundation Orders: [email protected] 59 Temple Place Suite 330 Tel 617-542-5942 Boston, MA 02111-1307 USA Fax 617-542-2652 Last printed October 2003 for GCC 3.3.1. Printed copies are available for $45 each. Copyright c 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with the Invariant Sections being \GNU General Public License" and \Funding Free Software", the Front-Cover texts being (a) (see below), and with the Back-Cover Texts being (b) (see below). A copy of the license is included in the section entitled \GNU Free Documentation License". (a) The FSF's Front-Cover Text is: A GNU Manual (b) The FSF's Back-Cover Text is: You have freedom to copy and modify this GNU Manual, like GNU software. Copies published by the Free Software Foundation raise funds for GNU development. i Short Contents Introduction ...................................... 1 1 Programming Languages Supported by GCC ............ 3 2 Language Standards Supported by GCC ............... 5 3 GCC Command Options .........................
    [Show full text]
  • The GNU Compiler Collection on Zseries
    The GNU Compiler Collection on zSeries Dr. Ulrich Weigand Linux for zSeries Development, IBM Lab Böblingen [email protected] Agenda GNU Compiler Collection History and features Architecture overview GCC on zSeries History and current status zSeries specific features and challenges Using GCC GCC optimization settings GCC inline assembly Future of GCC GCC and Linux Apache Samba mount cvs binutils gdb gcc Linux ls grep Kernel glibc DB2 GNU - essentials UDB SAP R/3 Unix - tools Applications GCC History Timeline January 1984: Start of the GNU project May 1987: Release of GCC 1.0 February 1992: Release of GCC 2.0 August 1997: EGCS project announced November 1997: Release of EGCS 1.0 April 1999: EGCS / GCC merge July 1999: Release of GCC 2.95 June 2001: Release of GCC 3.0 May/August 2002: Release of GCC 3.1/3.2 March 2003: Release of GCC 3.3 (estimated) GCC Features Supported Languages part of GCC distribution: C, C++, Objective C Fortran 77 Java Ada distributed separately: Pascal Modula-3 under development: Fortran 95 Cobol GCC Features (cont.) Supported CPU targets i386, ia64, rs6000, s390 sparc, alpha, mips, arm, pa-risc, m68k, m88k many embedded targets Supported OS bindings Unix: Linux, *BSD, AIX, Solaris, HP/UX, Tru64, Irix, SCO DOS/Windows, Darwin (MacOS X) embedded targets and others Supported modes of operation native compiler cross-compiler 'Canadian cross' builds GCC Architecture: Overview C C++ Fortran Java ... front-end front-end front-end front-end tree Optimizer rtx i386 s390 rs6000 sparc ... back-end back-end back-end
    [Show full text]
  • Porting Codewarrior Projects to Xcode
    Porting CodeWarrior Projects to Xcode 2006-09-05 Intel and Intel Core are registered Apple Computer, Inc. trademarks of Intel Corportation or its © 2003, 2006 Apple Computer, Inc. subsidiaries in the United States and other All rights reserved. countries. Java and all Java-based trademarks are No part of this publication may be trademarks or registered trademarks of Sun reproduced, stored in a retrieval system, or Microsystems, Inc. in the U.S. and other transmitted, in any form or by any means, countries. mechanical, electronic, photocopying, recording, or otherwise, without prior OpenGL is a registered trademark of Silicon written permission of Apple Computer, Inc., Graphics, Inc. with the following exceptions: Any person PowerPC and and the PowerPC logo are is hereby authorized to store documentation trademarks of International Business on a single computer for personal use only Machines Corporation, used under license and to print copies of documentation for therefrom. personal use provided that the Simultaneously published in the United documentation contains Apple’s copyright States and Canada. notice. Even though Apple has reviewed this document, The Apple logo is a trademark of Apple APPLE MAKES NO WARRANTY OR Computer, Inc. REPRESENTATION, EITHER EXPRESS OR IMPLIED, WITH RESPECT TO THIS Use of the “keyboard” Apple logo DOCUMENT, ITS QUALITY, ACCURACY, MERCHANTABILITY, OR FITNESS FOR A (Option-Shift-K) for commercial purposes PARTICULAR PURPOSE. AS A RESULT, THIS without the prior written consent of Apple DOCUMENT IS PROVIDED “AS IS,” AND YOU, THE READER, ARE ASSUMING THE may constitute trademark infringement and ENTIRE RISK AS TO ITS QUALITY AND unfair competition in violation of federal ACCURACY.
    [Show full text]
  • Section “Common Predefined Macros” in the C Preprocessor
    The C Preprocessor For gcc version 12.0.0 (pre-release) (GCC) Richard M. Stallman, Zachary Weinberg Copyright c 1987-2021 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation. A copy of the license is included in the section entitled \GNU Free Documentation License". This manual contains no Invariant Sections. The Front-Cover Texts are (a) (see below), and the Back-Cover Texts are (b) (see below). (a) The FSF's Front-Cover Text is: A GNU Manual (b) The FSF's Back-Cover Text is: You have freedom to copy and modify this GNU Manual, like GNU software. Copies published by the Free Software Foundation raise funds for GNU development. i Table of Contents 1 Overview :::::::::::::::::::::::::::::::::::::::: 1 1.1 Character sets:::::::::::::::::::::::::::::::::::::::::::::::::: 1 1.2 Initial processing ::::::::::::::::::::::::::::::::::::::::::::::: 2 1.3 Tokenization ::::::::::::::::::::::::::::::::::::::::::::::::::: 4 1.4 The preprocessing language :::::::::::::::::::::::::::::::::::: 6 2 Header Files::::::::::::::::::::::::::::::::::::: 7 2.1 Include Syntax ::::::::::::::::::::::::::::::::::::::::::::::::: 7 2.2 Include Operation :::::::::::::::::::::::::::::::::::::::::::::: 8 2.3 Search Path :::::::::::::::::::::::::::::::::::::::::::::::::::: 9 2.4 Once-Only Headers::::::::::::::::::::::::::::::::::::::::::::: 9 2.5 Alternatives to Wrapper #ifndef ::::::::::::::::::::::::::::::
    [Show full text]
  • Microsoft Visual Studio: an Integrated Windows Program Development Environment
    Microsoft Visual Studio: An Integrated Windows Program Development Environment Microsoft Visual Studio • Self-contained environment for Windows program development: – Creating/editing – Compiling/linking (building) – Testing/debugging • IDE that accompanies Visual C++, Visual Basic, Visual C#, and other Microsoft Windows programming languages • See Chapter 2 & Appendix C of the Deitel text • Also Appendix C of the Gregory text Some Visual Studio Components • The Editors: C, C++, C#, VB source program text editors • cut/paste, color cues, indentation • generate source text files Resource Editors • Resources: Windows static data • Determine look and feel of an application – icons, bitmaps, cursors, menus, dialog boxes, etc. • graphical • generate resource script (.rc) files • integrated with text editor • created visually .NET Language Compilers • Unmanaged Code C/C++ Compiler – translates source programs to machine language – generates object (.obj) files for linker • Managed Code .NET Language Compilers – Many of them ? multi-language interoperability – Translate source programs to MSIL – Generate a “Portable Executable” that must be translated to target machine language by the CLR • Resource Compiler – Reads .rc file – Generates binary resource (.res) file for linker The Linker • Reads compiler .obj and .res files • Accesses C/C++/Windows libraries • Generates executable (.exe or .dll) Program Build and Run in the .NET Framework Common Language Runtime The Debugger • Powerful source code debugger • Integrated with all parts of Visual
    [Show full text]
  • Object Pascal Language Guide
    Object Pascal Language Guide Borland® Object Pascal Borland Software Corporation 100 Enterprise Way, Scotts Valley, CA 95066-3249 www.borland.com Borland Software Corporation may have patents and/or pending patent applications covering subject matter in this document. The furnishing of this document does not give you any license to these patents. COPYRIGHT © 1983, 2002 Borland Software Corporation. All rights reserved. All Borland brand and product names are trademarks or registered trademarks of Borland Software Corporation. Other brand and product names are trademarks or registered trademarks of their respective holders. Printed in the U.S.A. ALP0000WW21000 1E0R0102 0203040506-9 8 7654321 D3 Contents Chapter 1 Qualified identifiers . 4-2 Introduction 1-1 Reserved words . 4-3 Directives. 4-3 What’s in this manual? . 1-1 Numerals. 4-4 Using Object Pascal . 1-1 Labels . 4-4 Typographical conventions . 1-2 Character strings . 4-4 Other sources of information . 1-2 Comments and compiler directives. 4-5 Software registration and technical support . 1-3 Expressions . 4-5 Part I Operators. 4-6 Arithmetic operators . 4-6 Basic language description Boolean operators . 4-7 Logical (bitwise) operators . 4-8 Chapter 2 String operators . 4-9 Overview 2-1 Pointer operators. 4-9 Program organization . 2-1 Set operators . 4-10 Pascal source files . 2-1 Relational operators . 4-11 Other files used to build applications . 2-2 Class operators. 4-12 Compiler-generated files . 2-3 The @ operator . 4-12 Example programs. 2-3 Operator precedence rules . 4-12 A simple console application . 2-3 Function calls . 4-13 A more complicated example .
    [Show full text]
  • Migrating Large Codebases to C++ Modules
    Migrating large codebases to C++ Modules Yuka Takahashi - The University of Tokyo Princeton University Oksana Shadura - UNL Vassil Vassilev Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !1 Agenda 1. Motivation of C++ Modules 2. C++ Modules in ROOT 3. C++ Modules in CMSSW 4. CMS Performance Results 5. Conclusion Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !2 Motivation of C++ Modules Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !3 Motivation of C++ Modules C++ Modules technology: - Cache parsed header file information - Avoid header re-parsing - Avoid runtime header parsing (In ROOT) - Part of C++20 Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !4 Motivation of C++ Modules #include <vector> Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !5 Motivation of C++ Modules #include <vector> Textual Include Precompiled Headers (PCH) Modules Expensive Inseparable Fragile Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !6 Motivation of C++ Modules …… TVirtualPad.h …… # 286 "/usr/include/c++/v1/vector" 2 3 #include "TVirtualPad.h" namespace std { inline namespace __1 { template <bool> class __vector_base_common vector #include <vector> Preprocess { __attribute__ #include <set> ((__visibility__("hidden"), __always_inline__)) __vector_base_common() Textual Include{} …… int main() { # 394 "/usr/include/c++/v1/set" 3 namespace std {inline namespace __1 { … set template <…> class set { original code public: typedef _Key key_type; …… .o Compile Parse int main { one big file! …… Yuka Takahashi 13.03.2019 Migrating large codebases to C++ Modules, ACAT 2019 !7 Motivation of C++ Modules Textual Include .c .o 1.
    [Show full text]
  • 24Th Embarcadero Developer Camp
    RAD Studio XE3 The Developer Force Multiplier Mac OS X Windows 8 Mountain Lion C++11 64-bit Metropolis UI C99 Boost Visual LiveBindings C++ Bjarne Stroustrup C with Objects (1979) Modeled OO after Simula and Ada ○ But syntax and RTL based on C Classes Inheritance Inlining Default arguments Type checking CFront compiler A Brief History of C++ C++11 – A new Standard Language Library Rvalue references and move constructors Variadic templates constexpr - Generalized constant New string literals expressions User-defined literals Core language usability enhancements Multithreading memory model Initializer lists Uniform initialization Thread-local storage Type inference Explicitly defaulted and deleted Range-based for-loop special member functions Lambda functions and expressions Type long long int Alternative function syntax Static assertions Object construction improvement Allow sizeof to work on members Explicit overrides and final of classes without an explicit object Null pointer constant Control and query object alignment Strongly typed enumerations Allow garbage collected Right angle bracket implementations Explicit conversion operators Alias templates Threading facilities Unrestricted unions Tu p le types Hash tables Regular expressions General-purpose smart pointers Extensible random number facility Wrapper reference Polymorphic wrappers for function objects Type traits for metaprogramming 64-bit C++Builder for Windows C++11 support in BCC64 compiler VCL and FireMonkey Dinkumware STL for
    [Show full text]
  • The Amulet V3.0 Reference Manual Brad A
    The Amulet V3.0 Reference Manual Brad A. Myers, Ellen Borison, Alan Ferrency, Rich McDaniel, Robert C. Miller, Andrew Faulring, Bruce D. Kyle, Patrick Doane, Andy Mickish, Alex Klimovitski March, 1997 CMU-CS-95-166-R2 CMU-HCII-95-102-R2 School of Computer Science Carnegie Mellon University Pittsburgh, PA 15213 This manual describes Version 3.0 of the Amulet User Interface Toolkit, and replaces all previous versions: CMU-CS-95-166-R1/ CMU-HCII-95-102-R1 (Jan, 1996), CMU-CS-95-166/ CMU-HCII-95-102 (June, 1995), and all change documents. Copyright © 1997 - Carnegie Mellon University This research was sponsored by NCCOSC under Contract No. N66001-94-C-6037, Arpa Order No. B326. The views and conclusions contained in this document are those of the authors and should not be interpreted as representing the official poli- cies, either expressed or implied, of NCCOSC or the U.S. Government. Keywords: User Interface Development Environments, User Interface Management Systems, Constraints, Prototype-Instance Object System, Widgets, Object-Oriented Programming, Direct Manipulation, Input/Output, Amulet, Garnet. Abstract The Amulet User Interface Development Environment con- tains a comprehensive set of tools that make it significantly easier to design and implement highly interactive, graphical, direct manipulation user interfaces. Applications imple- mented in Amulet will run without modification on Unix, PC, and Macintosh platforms. Amulet provides a high lev- el of support, while still being Look-and-Feel independent and providing applications with tremendous flexibility. Amulet currently provides a low-level toolkit layer, which is an object-oriented, constraint-based graphical system that allows properties of graphical objects to be specified in a simple, declar- ative manner, and then maintained automatically by the system.
    [Show full text]
  • Syntactic Sugar and Obfuscated Code: Why Learning C Is Challenging for Novice Programmers
    TECHNICAL REPORT Syntactic sugar and obfuscated code: Why learning C is challenging for novice programmers Michael Wirth School of Computer Science University of Guelph Sally sold C shells by the C shore. But should she have? C is an inherently complex language, not from the perspective of the language, because it is a small language in comparison to the likes of Ada or C++. However there is an inherent complexity to learning the language because of its assembly-like heritage. This white-paper overviews some of the more challenging aspects of C from the perspective of the novice programmer, and offers alternatives from other languages, where the usability may be improved. 1. Introduction 2. C - Language Synopsis 3. Datatypes 4. Symbolic confusion 5. Permissiveness 6. Incoherent control structures 7. Lack of consistency 8. Arrays 9. Pointers and memory 10. Functions and parameter passing 11. Failure to build on existing knowledge 12. Code brevity and condensation 13. Input snaffus 14. Hoodwinking the compiler 15. C code is just plain crazy 16. Conclusion June 2018 TECHNICAL REPORT 1. Introduction The debate over the choice of programming language use in CS1 (the core introductory programming course) has been going on as long as languages have been used to teach programming. Fundamentally CS1 has three basic goals. The first involves disseminating the basic principles of programming, such as decision statements, repetition, modularity, testing, readability etc. The second involves teaching how the basic principles are implemented in a specific programming language. The third involves showing how programming can be used to solve problems. It is the latter which spurs interest in programming - taking a problem, and deriving a solution which can then be turned into a program.
    [Show full text]
  • Xcode Build Setting Reference
    Xcode Build Setting Reference 2006-10-03 Simultaneously published in the United Apple Computer, Inc. States and Canada. © 2006 Apple Computer, Inc. Even though Apple has reviewed this document, All rights reserved. APPLE MAKES NO WARRANTY OR REPRESENTATION, EITHER EXPRESS OR IMPLIED, WITH RESPECT TO THIS No part of this publication may be DOCUMENT, ITS QUALITY, ACCURACY, MERCHANTABILITY, OR FITNESS FOR A reproduced, stored in a retrieval system, or PARTICULAR PURPOSE. AS A RESULT, THIS transmitted, in any form or by any means, DOCUMENT IS PROVIDED “AS IS,” AND mechanical, electronic, photocopying, YOU, THE READER, ARE ASSUMING THE ENTIRE RISK AS TO ITS QUALITY AND recording, or otherwise, without prior ACCURACY. written permission of Apple Computer, Inc., IN NO EVENT WILL APPLE BE LIABLE FOR with the following exceptions: Any person DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES is hereby authorized to store documentation RESULTING FROM ANY DEFECT OR on a single computer for personal use only INACCURACY IN THIS DOCUMENT, even if and to print copies of documentation for advised of the possibility of such damages. personal use provided that the THE WARRANTY AND REMEDIES SET FORTH ABOVE ARE EXCLUSIVE AND IN documentation contains Apple’s copyright LIEU OF ALL OTHERS, ORAL OR WRITTEN, notice. EXPRESS OR IMPLIED. No Apple dealer, agent, or employee is authorized to make any The Apple logo is a trademark of Apple modification, extension, or addition to this Computer, Inc. warranty. Some states do not allow the exclusion or Use of the “keyboard” Apple logo limitation of implied warranties or liability for (Option-Shift-K) for commercial purposes incidental or consequential damages, so the above limitation or exclusion may not apply to without the prior written consent of Apple you.
    [Show full text]
  • Xcode Build Settings Reference
    Xcode Build Settings Reference All variables are prefixed with "$" to uniquely identify them on this page. Submitting updates to this page. $ACTION Description Identifies the type of build to perform on the target. Type String • build : Build the product and place it in the product build directory $(CONFIGURATION_BUILD_DIR) . • clean : Remove the product and build files in the product build directory $(CONFIGURATION_BUILD_DIR) and the intermediate build files directory $(CONFIGURATION_TEMP_DIR) . • install : Build the product and place it in its Values installation destination $(INSTALL_PATH) . • installhdrs : Copy the product’s public and private header files into the public headers directory $(PUBLIC_HEADERS_FOLDER_PATH) and the private headers directory $(PRIVATE_HEADERS_FOLDER_PATH) , respectively. • installsrc : Copy the target's source files into the project directory $(SRCROOT) . Default build Value $AD_HOC_CODE_SIGNING_ALLOWED Internal setting used by Xcode to determine if ad-hoc signing Description identities can be used. Type Boolean Default NO Value $ADDITIONAL_SDKS The locations of any sparse SDKs that should be layered on top of the one specified by $(SDKROOT) . If more than one Description SDK is listed, the first one has highest precedence. Every SDK specified in this setting should be a "sparse" SDK, i.e. not an SDK for an entire OS X release. Type String Default empty string Value $ALTERNATE_GROUP The group name or gid for the files listed under the Description $(ALTERNATE_PERMISSIONS_FILES) setting. Type String Default $(INSTALL_GROUP) Value $ALTERNATE_MODE Permissions used for the the files listed under the Description $(ALTERNATE_PERMISSIONS_FILES) setting. Type String Default $(INSTALL_MODE_FLAG) Value $ALTERNATE_OWNER The owner name or uid for the files listed under the Description $(ALTERNATE_PERMISSIONS_FILES) setting. Type String Default $(INSTALL_OWNER) Value $ALTERNATE_PERMISSIONS_FILES List of files to which the alternate owner, group and Description permissions are applied.
    [Show full text]