class_docstr: Replace variable that can be computed later, but only if this leads to a
  one-liner that's going to be a great inlining candidate.
class_docstr_tok: ["Replace","variable","that","can","be","computed","later",",","but","only","if","this","leads","to","a","one-liner","that","'s","going","to","be","a","great","inlining","candidate","."]
code: def visit_FunctionDef(self, node):
      # Only handle trivial cases, because this can lead to more inlining
      # opportunities.
      if all(
          isinstance(s, (ast.Return, ast.Assign)) for s in node.body
      ):
          r = super(
              PreInliningForwardSubstitution, self
          ).visit_FunctionDef(node)
          return r
      return node
  
file_path: catboost/contrib/python/pythran/pythran/optimizations/forward_substitution.py
imports: from pythran.analyses import LazynessAnalysis, UseDefChains, DefUseChains
  from pythran.analyses import Literals, Ancestors, Identifiers, CFG, IsAssigned
  from pythran.passmanager import Transformation
  import pythran.graph
  from collections import defaultdict
  import gast
label_desc: Use image node_id 1 for calling the PreInliningForwardSubstitution obj's underlying member method code with example usage: obj.visit_FunctionDef(node) and returns: node, r