From ab3c4bee58daadf98161064eba1b914db60a91ca Mon Sep 17 00:00:00 2001 From: Frank Birbacher Date: Wed, 14 Jun 2023 23:42:50 +0300 Subject: [PATCH] Create overview for UDL (#86) Introduce the UDL abbreviation and describe the feature in the overview of the topic. --- sources/modules/functions/user-defined-literals.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sources/modules/functions/user-defined-literals.md b/sources/modules/functions/user-defined-literals.md index bb1bcd6..a9894ed 100644 --- a/sources/modules/functions/user-defined-literals.md +++ b/sources/modules/functions/user-defined-literals.md @@ -1,4 +1,4 @@ -## Functions: user-defined literals {#udl} +## Functions: user-defined literals (UDL) {#udl} _Skeleton descriptions are typeset in italic text,_ _so please don't remove these descriptions when editing the topic._ @@ -8,6 +8,11 @@ _so please don't remove these descriptions when editing the topic._ _Provides a short natural language abstract of the module’s contents._ _Specifies the different levels of teaching._ +Literals are a way to write values in the code, such as strings and numbers. +User-defined literals (UDL) allow to add a suffix to a string or number to change the meaning. +The suffix selects a function (an operator) that can alter the value and type of the literal. +The C++ library provides certain operators already and a user can add more by providing such operators. + ------------------------------------------------------------------------- Level Objectives ---------------- --------------------------------------------------------