JetBrains Rider 2024.3 Help

Predefined File Templates for C++

This topic lists all predefined file templates for C++ in JetBrains Rider 2024.3. For more information about file templates, refer to Create files from templates.

Template

Details

Struct

Create new header and source files containing an empty C++ Struct in the current project.

Scope C++ projects

Body

$HEADER$#pragma once struct $STRUCT$ {$END$};

Parameters

  • HEADER - Inserts the file header specified in settings

  • NAME - Evaluates to the current file name without extension

  • STRUCT - Evaluates to the current file name without extension and with all non-alphanumeric characters replaced with underscores

  • PCH - Evaluates to an include directive for the precompiled header file or to an empty string if the project does not use precompiled headers

  • END - The caret position after the template is applied.

Class

Create new header and source files containing an empty C++ Class in the current project.

Scope C++ projects

Body

$HEADER$#pragma once class $CLASS$ {public:$END$};

Parameters

  • HEADER - Inserts the file header specified in settings

  • CLASS - Evaluates to the current file name without extension and with all non-alphanumeric characters replaced with underscores

  • NAME - Evaluates to the current file name without extension

  • PCH - Evaluates to an include directive for the precompiled header file or to an empty string if the project does not use precompiled headers

  • END - The caret position after the template is applied.

Module interface unit

Module interface unit

Scope C++ projects

Body

$HEADER$export module $MODULE$;

Parameters

  • HEADER - Inserts the file header specified in settings

  • MODULE - Evaluates to the current file name without extension

Header file

Header file

Scope C++ projects

Body

$HEADER$#pragma once

Parameters

  • HEADER - Inserts the file header specified in settings

Source file

Source file

Scope C++ projects

Body

$HEADER$$PCH$

Parameters

  • HEADER - Inserts the file header specified in settings

  • PCH - Evaluates to an include directive for the precompiled header file or to an empty string if the project does not use precompiled headers

Last modified: 18 August 2024