Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.
Specifies that one or more variables should be shared among all threads.
shared
(var)
where,
var
One more more variables to share. If more than one variable is specified, separate variable names with a comma.
Another way to share variables among threads is with the copyprivate clause.
shared
applies to the following directives:
For more information, see 2.7.2.4 shared.
See private for an example of using shared
.