12.07.2015 Views

RealView 编译工具编译器参考指南 - ARM Information Center

RealView 编译工具编译器参考指南 - ARM Information Center

RealView 编译工具编译器参考指南 - ARM Information Center

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

语 言 扩 展模 式仅 在 C90 和 C99 的 GNU 模 式 下 支 持 。错 误如 果 编 译 器 检 测 到 有 关 void 指 针 或 函 数 指 针 的 算 法 , 则 会 生 成 警 告 。示 例int ptr_arith_0(void){void * pointer;return sizeof *pointer;}int ptr_arith_1(void){static int diff;diff = ptr_arith_0 - ptr_arith_1;return sizeof ptr_arith_0;}3.7.14 语 句 表 达 式语 句 表 达 式 允 许 将 包 括 声 明 在 内 的 整 段 代 码 放 在 花 括 号 ({ }) 中 。语 句 表 达 式 的 结 果 是 语 句 列 表 中 的 最 后 一 项 。限 制不 允 许 使 用 以 语 句 表 达 式 为 目 标 的 跳 转 。在 C++ 模 式 中 , 还 不 允 许 跳 转 出 去 。 在 语 句 表 达 式 中 , 不 允 许 使 用 变 长 数 组 、可 析 构 的 实 体 、 try 语 句 、 捕 获 、 局 部 非 POD 类 定 义 以 及 动 态 初 始 化 的 局 部 静态 变 量 。示 例int bar(int b, int foo){if (({int y = foo;int z;if (y > 0) z = y;else z = -y;z>b;<strong>ARM</strong> DUI 0348BC Copyright © 2007-2009 <strong>ARM</strong> Limited. All rights reserved. 3-29ID090708Non-Confidential, Unrestricted Access

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!