Skip to content

Commit

Permalink
Use a using type alieas instead of a typedef in the docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
Lastique committed Dec 2, 2023
1 parent f081d0f commit 958af1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/unique_resource.qbk
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ Using the resource traits allow us to further improve the example given in the p
}
};

// A shorthand typedef for unique file descriptor wrappers
typedef boost::scope::unique_resource< int, fd_deleter, fd_resource_traits > unique_fd;
// A shorthand type alias for unique file descriptor wrappers
using unique_fd = boost::scope::unique_resource< int, fd_deleter, fd_resource_traits >;

// Writes a string to a file
void write_string(std::string const& filename, std::string const& str)
Expand Down

0 comments on commit 958af1c

Please sign in to comment.