Github user jeking3 commented on a diff in the pull request:

    https://github.com/apache/thrift/pull/1103#discussion_r81469715
  
    --- Diff: lib/cpp/src/thrift/concurrency/PosixThreadFactory.h ---
    @@ -39,7 +39,14 @@ class PosixThreadFactory : public ThreadFactory {
       /**
        * POSIX Thread scheduler policies
        */
    -  enum POLICY { OTHER, FIFO, ROUND_ROBIN };
    +  class Policy {
    +  public:
    +    enum value {
    +      OTHER       = 0,
    +      FIFO        = 1,
    +      ROUND_ROBIN = 2
    +    };
    --- End diff --
    
    Intention was to make it more readable.
    
    In code, OTHER, FIFO, ROUND_ROBIN mixed with NORMAL, LOWER, HIGHER... this 
adds a scope to them, i.e. "Policy::FIFO" and "Priority::NORMAL".
    
    I can revert it if needed, I just wanted to make the code more 
maintainable.  I suspect these options are not used that often anyway.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to