C and C++


LANG.STRUCT.REGISTER : Register Keyword

要旨

A use of the register keyword, which is deprecated.

プロパティ

クラス名 Register Keyword
日本語クラス名 Register Keyword
クラス分類 スタイル (style)
ニーモニック LANG.STRUCT.REGISTER
カテゴリー
AUTOSARC++14 AUTOSARC++14:A1-1-1 All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features.
  AUTOSARC++14:A7-1-4 The register keyword shall not be used.
MisraC++2023 MisraC++2023:4.1.2 Deprecated features should not be used
JSF++ JSF++:140 The register storage class specifier shall not be used.
対応言語 C および C++ で利用可能です。
有効/無効設定 このワーニングクラスのチェックはデフォルトで無効になっており、プロジェクトには非正規の C向けAST が必要になります。有効にするにはプロジェクト設定ファイル (configuration file) に以下の WARNING_FILTER ルールと RETAIN_UNNORMALIZED_C_AST 設定を追加してください。
RETAIN_UNNORMALIZED_C_AST = Yes
WARNING_FILTER += allow class="Register Keyword"
注:非正規化された AST を継続して使用した場合、使用ディスク容量が増加し解析時間が長くなる可能性があります。

void lang_struct_register(register int a) {  /* 'Register Keyword' warning issued here */
    register int x;                          /* 'Register Keyword' warning issued here */
}

関連のある設定ファイルパラメータ

設定ファイルの以下のパラメータがこのワーニングクラスのチェックに影響します。