class_docstr: Writes a single pyi file
class_docstr_tok: ["Writes","a","single","pyi","file"]
code: def write_extensions(
      self,
      extensions: Sequence[d.FieldDescriptorProto],
      scl_prefix: SourceCodeLocation,
  ) -> None:
      wl = self._write_line
  
      for ext in extensions:
          wl(f"{ext.name.upper()}_FIELD_NUMBER: {self._builtin('int')}")
  
      for i, ext in enumerate(extensions):
          scl = scl_prefix + [i]
  
          wl(
              "{}: {}[{}, {}]",
              ext.name,
              self._import(
                  "google.protobuf.internal.extension_dict",
                  "_ExtensionFieldDescriptor",
              ),
              self._import_message(ext.extendee),
              self.python_type(ext),
          )
          self._write_comments(scl)
  
imports: from __future__ import annotations
  import sys
  from collections import defaultdict
  from contextlib import contextmanager
  from typing import Any, Callable, Dict, Iterable, Iterator, List, Optional, Set, Sequence, Tuple
  import google.protobuf.descriptor_pb2
  from google.protobuf.compiler import plugin_pb2
  from google.protobuf.internal.containers import RepeatedCompositeFieldContainer
  from google.protobuf.internal.well_known_types import WKTBASES
  from .None import extensions_pb2
label_desc: Use image node_id 15 for calling the PkgWriter obj's underlying member method code with example usage: obj.write_extensions(extensions, scl_prefix) without return types