code: def setupFeatures(self):
          
          if self.featureWriters:
              featureFile = parseLayoutFeatures(self.ufo)
  
              for writer in self.featureWriters:
                  writer.write(self.ufo, featureFile, compiler=self)
  
              # stringify AST to get correct line numbers in error messages
              self.features = featureFile.asFea()
          else:
              # no featureWriters, simply read existing features' text
              self.features = tounicode(self.ufo.features.text or "", "utf-8")
docs: Make the features source.
  
          **This should not be called externally.** Subclasses
          may override this method to handle the file creation
          in a different way if desired.