Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Namespaces
Variants
    Actions

      std::generator<Ref,V,Allocator>::promise_type

      From cppreference.com
      <cpp‎ |coroutine‎ |generator
       
       
      Utilities library
       
      Coroutine support
      Coroutine traits
      Coroutine handle
      No-op coroutines
      Trivial awaitables
      Range generators
      (C++23)
       
      Ranges library
      Range adaptors
       
       
      class generator<Ref, V, Allocator>::promise_type;
      (since C++23)

      The promise type ofstd::generator.

      Contents

      [edit]Data members

      Member Description
      std::add_pointer_t<std::generator::yielded>value_ A pointer to the yielded value. Default value isnullptr.
      (exposition-only member object*)
      std::exception_ptrexcept_ A pointer to an exception object.
      (exposition-only member object*)

      [edit]Member functions

      (constructor)
      (implicitly declared)
      constructs thepromise_type object
      (public member function)
      (destructor)
      (implicitly declared)
      destroys thepromise_type object
      (public member function)
      issues thegenerator object
      (public member function)
      issues an awaiter for initial suspend point
      (public member function)
      issues an awaiter for final suspend point
      (public member function)
      processes the object obtained fromco_yield
      (public member function)
      await_transform
      [deleted]
      maps the object obtained fromco_await to an awaiter
      (public member function)
      handlesco_return; or the exit out of coroutine's body
      (public member function)
      processes exceptions that leaked from the coroutine's body
      (public member function)
      [static](C++23)
      allocates memory usingAllocator
      (public static member function)[edit]
      [static](C++23)
      deallocates memory previously obtained fromoperator new
      (public static member function)[edit]

      [edit]Example

      This section is incomplete
      Reason: no example

      [edit]See also

      used for coroutines with no observable effects
      (class)[edit]
      Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/coroutine/generator/promise_type&oldid=178285"

      [8]ページ先頭

      ©2009-2025 Movatter.jp