code: def create_pyx_as_pxd_pipeline(context, result):
      from .ParseTreeTransforms import (
          AlignFunctionDefinitions,
          MarkClosureVisitor,
          WithTransform,
          AnalyseDeclarationsTransform,
      )
      from .Optimize import ConstantFolding, FlattenInListTransform
      from .Nodes import StatListNode
  
      pipeline = []
      pyx_pipeline = create_pyx_pipeline(
          context,
          context.options,
          result,
          exclude_classes=[
              AlignFunctionDefinitions,
              MarkClosureVisitor,
              ConstantFolding,
              FlattenInListTransform,
              WithTransform,
          ],
      )
      for stage in pyx_pipeline:
          pipeline.append(stage)
          if isinstance(stage, AnalyseDeclarationsTransform):
              # This is the last stage we need.
              break
  
      def fake_pxd(root):
          for entry in root.scope.entries.values():
              if not entry.in_cinclude:
                  entry.defined_in_pxd = 1
                  if (
                      entry.name == entry.cname
                      and entry.visibility != "extern"
                  ):
                      # Always mangle non-extern cimported entries.
                      entry.cname = entry.scope.mangle(
                          Naming.func_prefix, entry.name
                      )
          return StatListNode(root.pos, stats=[]), root.scope
  
      pipeline.append(fake_pxd)
      return pipeline
  
imports: from __future__ import absolute_import
  import itertools
  from time import time
  from .None import Errors
  from .None import DebugFlags
  from .None import Options
  from .Errors import CompileError, InternalError, AbortError
  from .None import Naming
label_desc: Use image node_id 15 for calling a global function with example usage: create_pyx_as_pxd_pipeline(context, result) and returns: pipeline, StatListNode,  root