code: def add_implicit_resolver(
      tag, regexp, first=None, Loader=None, Dumper=Dumper
  ):
      """
      Add an implicit scalar detector.
      If an implicit scalar value matches the given regexp,
      the corresponding tag is assigned to the scalar.
      first is a sequence of possible initial characters or None.
      """
      if Loader is None:
          loader.Loader.add_implicit_resolver(tag, regexp, first)
          loader.FullLoader.add_implicit_resolver(tag, regexp, first)
          loader.UnsafeLoader.add_implicit_resolver(tag, regexp, first)
      else:
          Loader.add_implicit_resolver(tag, regexp, first)
      Dumper.add_implicit_resolver(tag, regexp, first)
  
imports: from error import *
  from tokens import *
  from events import *
  from nodes import *
  from loader import *
  from dumper import *
label_desc: Use image node_id 22 for calling a global function with example usage: add_implicit_resolver(tag, regexp, first, Loader, Dumper) without return types