Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
std::launch(3)		      C++ Standard Libary		std::launch(3)

NAME
       std::launch - std::launch

Synopsis
	  Defined in header <future>
	  enum class launch : /* unspecified */	{

	      async =	 /* unspecified	*/,
	      deferred = /* unspecified	*/,	   (since C++11)
	      /* implementation-defined	*/

	  };

	  std::launch  is  a BitmaskType. It specifies the launch policy for a
       task executed by
	  the std::async function.

	  The following	constants denoting individual bits are defined by  the
       standard
	  library:

	  Constant		Explanation
	  std::launch::async	 the  task  is executed	on a different thread,
       potentially by
				creating and launching it first
	  std::launch::deferred	the task is executed on	the calling thread the
       first time its
				result is requested (lazy evaluation)

	  In addition, implementations are allowed to:

	    * define additional	bits and bitmasks to specify  restrictions  on
       task interactions
	      applicable to a subset of	launch policies, and
	    *  enable  those additional	bitmasks for the first (default) over-
       load of std::async.

	  Defect reports

	  The following	behavior-changing defect reports were applied retroac-
       tively to
	  previously published C++ standards.

	     DR	   Applied to	       Behavior	as published		  Cor-
       rect behavior
	  LWG 2102 C++11      std::launch was an			it  is
       not
			      implementation-defined  type		imple-
       mentation-defined

See also
	  async	  runs a function asynchronously (potentially in a new thread)
       and returns a
	  (C++11) std::future that will	hold the result
		  (function template)

http://cppreference.com		  2024.06.10			std::launch(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=std::launch&sektion=3&manpath=FreeBSD+Ports+15.1.quarterly>

home | help