From d9be77329582a864993eb0b3ab49bec19e3972cf Mon Sep 17 00:00:00 2001 From: Konstantin Aladyshev Date: Sun, 24 Oct 2021 13:36:26 +0300 Subject: Update lesson 48 Signed-off-by: Konstantin Aladyshev --- Lessons/Lesson_48/README.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/Lessons/Lesson_48/README.md b/Lessons/Lesson_48/README.md index 96e08a1..850c218 100644 --- a/Lessons/Lesson_48/README.md +++ b/Lessons/Lesson_48/README.md @@ -369,7 +369,7 @@ unsigned char HIIStringsUNIStrings[] = { As you can see this time our strings got into the `HIIStringsUNIStrings` array. -If you execute our application under OVMF now you would get: +If you execute our application under OVMF now you would get correct output: ``` FS0:\> HIIStringsUNI.efi en-US ID=1: English @@ -379,3 +379,16 @@ fr-FR ID=1: Francais fr-FR ID=2: Bonjour! fr-FR ID=3: Au revoir! ``` + +You can see now how important to reference our strings with the `STRING_TOKEN` macro, but keep in mind that in reality this macro simply does nothing to its value (https://github.com/tianocore/edk2/blob/master/BaseTools/Source/C/Include/Common/UefiInternalFormRepresentation.h): +``` +// +// References to string tokens must use this macro to enable scanning for +// token usages. +// +// +// STRING_TOKEN is not defined in UEFI specification. But it is placed +// here for the easy access by C files and VFR source files. +// +#define STRING_TOKEN(t) t +``` -- cgit v1.2.3-18-g5258