user27953: I am trying to compile the following code:
logger.log_info(F(R"(some text here that may take
    multiple lines
    and here it is done.)"));

But the compiler exists with the following error:

error: unterminated raw string

I am able to use either R or F, but not both together. How should I be able to use them together?

user70020: If you put:
    #define DO_NOTHING(s) (s)

    DO_NOTHING(R"xyz(Hello
    World)xyz")

you can see g++ choke on preprocessing the raw string literal in the macro invocation with the latest esp8266 board package as of writing (version 2.7.4).  This comes with g++ 4.8.2 for xtensa.
    ~/.arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++ -E  donothing.h

You may need to adjust the command-line for your system.  donothing.h is just the macro and invocation described above.
Result:
# 1 "donothing.h"
# 1 "<command-line>"
# 1 "donothing.h"


donothing.h:3:13: warning: missing terminating " character [enabled by default]
 DO_NOTHING(R"xyz(Hello
             ^
(R"xyz(Hello World)
donothing.h:4:10: warning: missing terminating " character [enabled by default]
 World)xyz")
          ^
      xyz")

This does not happen with g++ 9.3.0 on an amd64 Linux target.
As a workaround you can reconstruct (more or less) what the F() macro does with the following:
    void setup() {
      Serial.begin(9600);
    }

    void loop() {
      static const char pgm_str[] PROGMEM = (R"xyz(Hello
    World)xyz");

      Serial.println(FPSTR(pgm_str));
      delay(4000);
    }


27953: <p>I am trying to compile the following code:</p>
<pre><code>logger.log_info(F(R&quot;(some text here that may take
    multiple lines
    and here it is done.)&quot;));
</code></pre>
<p>But the compiler exists with the following error:</p>
<blockquote>
<p>error: unterminated raw string</p>
</blockquote>
<p>I am able to use either <code>R</code> or <code>F</code>, but not both together. <strong>How should I be able to use them together?</strong></p>
 70020: <p>If you put:</p>
<pre><code>    #define DO_NOTHING(s) (s)

    DO_NOTHING(R&quot;xyz(Hello
    World)xyz&quot;)
</code></pre>
<p>you can see g++ choke on preprocessing the raw string literal in the macro invocation with the latest esp8266 board package as of writing (version 2.7.4).  This comes with g++ 4.8.2 for xtensa.</p>
<pre><code>    ~/.arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++ -E  donothing.h
</code></pre>
<p>You may need to adjust the command-line for your system.  donothing.h is just the macro and invocation described above.</p>
<p>Result:</p>
<pre><code># 1 &quot;donothing.h&quot;
# 1 &quot;&lt;command-line&gt;&quot;
# 1 &quot;donothing.h&quot;


donothing.h:3:13: warning: missing terminating &quot; character [enabled by default]
 DO_NOTHING(R&quot;xyz(Hello
             ^
(R&quot;xyz(Hello World)
donothing.h:4:10: warning: missing terminating &quot; character [enabled by default]
 World)xyz&quot;)
          ^
      xyz&quot;)
</code></pre>
<p>This does not happen with g++ 9.3.0 on an amd64 Linux target.</p>
<p>As a workaround you can reconstruct (more or less) what the F() macro does with the following:</p>
<pre><code>    void setup() {
      Serial.begin(9600);
    }

    void loop() {
      static const char pgm_str[] PROGMEM = (R&quot;xyz(Hello
    World)xyz&quot;);

      Serial.println(FPSTR(pgm_str));
      delay(4000);
    }
</code></pre>
