fmradio/fmradioengine/inc/debug.h
changeset 0 f3d95d9c00ab
equal deleted inserted replaced
-1:000000000000 0:f3d95d9c00ab
       
     1 /*
       
     2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Central place for nice debug-type macros & functions
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef DEBUG_H
       
    20 #define DEBUG_H
       
    21 
       
    22 //INCLUDES
       
    23 #include <f32file.h>
       
    24 #ifdef _DEBUG
       
    25 #define FTRACE(a) {a;}
       
    26 #define FDEBUGVAR(a) a
       
    27 #else
       
    28 #define FTRACE(a)
       
    29 #define FDEBUGVAR(a)
       
    30 #endif // _DEBUG
       
    31 
       
    32 
       
    33     /**
       
    34     * Declare the FPrint function
       
    35     * @since Series 60 2.7
       
    36     * @return none
       
    37     */
       
    38 inline void FPrint(const TRefByValue<const TDesC> aFmt, ...)
       
    39    {
       
    40    VA_LIST list;
       
    41    VA_START(list,aFmt);
       
    42    TInt tmpInt = VA_ARG(list, TInt);
       
    43    TInt tmpInt2 = VA_ARG(list, TInt);
       
    44    TInt tmpInt3 = VA_ARG(list, TInt);
       
    45    VA_END(list);
       
    46    #ifdef _DEBUG
       
    47    RDebug::Print(aFmt, tmpInt, tmpInt2, tmpInt3);
       
    48    #endif
       
    49    }
       
    50 
       
    51 #endif // DEBUG_H
       
    52 
       
    53 // End of File