title: Passing arguments to C++ programme for debugging in VSCode
body: <p>I want to debug a C++ project in VSCode (on a Mac, using either GDB or LLDB). The program itself takes command line arguments like</p>
  
  <pre><code>./prog -input cf file_x.txt
  </code></pre>
  
  <p>This works fine when starting a debugging session in GDB on the command line.</p>
  
  <p>In VSCode, I tried to adapt <code>launch.json</code> to read like this (only relevant lines shown):</p>
  
  <pre><code>"program": "${workspaceRoot}/build/prog",
              "args": [
                "-input cf",
                 "path_to/file_x.txt"
              ]
  </code></pre>
  
  <p>With this, I get <code>@"Unknown option: \"-input cf\"\r\n"</code> in the output and the process is not debugged; alternatively, I tried only one argument like so:</p>
  
  <pre><code>"program": "${workspaceRoot}/build/prog",
              "args": [
                "-input cf path_to/file_x.txt"
              ]
  </code></pre>
  
  <p>resulting in the same message. Have I missed something important?</p>