title: error: conversion from ‘void’ to non-scalar type ‘QString’ requested
body: <pre><code>#include "mainwindow.h"
  #include &lt;QApplication&gt;
  #include &lt;QString&gt;
  #include &lt;QDebug&gt;
  
  int main(int argc, char *argv[])
  {
      QApplication a(argc, argv);
      MainWindow w;
      w.show();
  
      QString h;
      h = "fsdfsdfsf";
  
      QString j = h.chop(3);
      qDebug() &lt;&lt; "j: " &lt;&lt; j;
  
      return a.exec();
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>error: conversion from ‘void’ to non-scalar type ‘QString’ requested
  </code></pre>
  
  <p>Where am I going wrong here?</p>