VirtualBox

Ignore:
Timestamp:
Feb 1, 2019 2:47:32 PM (6 years ago)
Author:
vboxsync
Message:

Runtime: Get rid of the "register" keyword usage as all compilers we care about don't honor it for a long time already and it got deprecated in C++11 and removed entirely in C++17, fixes compile time warnings with a recent clang

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/common/table/avl_Base.cpp.h

    r76553 r77118  
    267267        else
    268268        {
    269             register unsigned char uchHeight = (unsigned char)(KMAX(uchLeftHeight, uchRightHeight) + 1);
     269            unsigned char uchHeight = (unsigned char)(KMAX(uchLeftHeight, uchRightHeight) + 1);
    270270            if (uchHeight == pNode->uchHeight)
    271271                break;
     
    299299KAVL_DECL(bool) KAVL_FN(Insert)(PPKAVLNODECORE ppTree, PKAVLNODECORE pNode)
    300300{
    301     KAVLSTACK               AVLStack;
    302     PPKAVLNODECORE          ppCurNode = ppTree;
    303     register PKAVLNODECORE  pCurNode;
    304     register KAVLKEY        Key = pNode->Key; NOREF(Key);
     301    KAVLSTACK                  AVLStack;
     302    PPKAVLNODECORE             ppCurNode = ppTree;
     303    PKAVLNODECORE              pCurNode;
     304    KAVLKEY                    Key = pNode->Key; NOREF(Key);
    305305#ifdef KAVL_RANGE
    306     register KAVLKEY        KeyLast = pNode->KeyLast; NOREF(KeyLast);
     306    KAVLKEY                    KeyLast = pNode->KeyLast; NOREF(KeyLast);
    307307#endif
    308308
     
    399399KAVL_DECL(PKAVLNODECORE) KAVL_FN(Remove)(PPKAVLNODECORE ppTree, KAVLKEY Key)
    400400{
    401     KAVLSTACK                AVLStack;
    402     PPKAVLNODECORE           ppDeleteNode = ppTree;
    403     register PKAVLNODECORE   pDeleteNode;
     401    KAVLSTACK        AVLStack;
     402    PPKAVLNODECORE   ppDeleteNode = ppTree;
     403    PKAVLNODECORE    pDeleteNode;
    404404
    405405    AVLStack.cEntries = 0;
     
    426426    {
    427427        /* find the rightmost node in the left tree. */
    428         const unsigned          iStackEntry = AVLStack.cEntries;
    429         PPKAVLNODECORE          ppLeftLeast = &pDeleteNode->pLeft;
    430         register PKAVLNODECORE  pLeftLeast = KAVL_GET_POINTER(ppLeftLeast);
     428        const unsigned  iStackEntry = AVLStack.cEntries;
     429        PPKAVLNODECORE  ppLeftLeast = &pDeleteNode->pLeft;
     430        PKAVLNODECORE   pLeftLeast = KAVL_GET_POINTER(ppLeftLeast);
    431431
    432432        while (pLeftLeast->pRight != KAVL_NULL)
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette