Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

capability: Deprecate NewPid and NewFile for NewPid2 and NewFile2 #14

Merged
merged 1 commit into from
Feb 23, 2018

Commits on Feb 20, 2018

  1. capability: Deprecate NewPid and NewFile for NewPid2 and NewFile2

    The old methods had an internal Load(), which is unnecessary for some
    use cases.  For example, if you're going to drop all capabilities, you
    don't need to load the current set first.  This commit deprecates the
    old New* functions and adds New*2 functions which do not include the
    internal Load.  Callers who do need the Load will need to call it
    explicitly after initializing their Capabilities object.  Callers who
    do not need the Load can just add the "2" to the function name and get
    more efficient/robust behavior.
    
    The "Deprecated:" paragraph syntax is recommended in [1]:
    
      To signal that an identifier should not be used, add a paragraph to
      its doc comment that begins with "Deprecated:" followed by some
      information about the deprecation.
    
    [1]: https://blog.golang.org/godoc-documenting-go-code
    wking committed Feb 20, 2018
    Configuration menu
    Copy the full SHA
    c9101b3 View commit details
    Browse the repository at this point in the history