equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2000-2009 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: |
|
15 * include this file to make ASSERT macros more useful |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef __ASSERTFILEANDLINE_H_ |
|
21 #define __ASSERTFILEANDLINE_H_ |
|
22 |
|
23 #ifdef _DEBUG |
|
24 #ifdef ASSERT |
|
25 #undef ASSERT |
|
26 #endif |
|
27 /** |
|
28 @internalComponent |
|
29 */ |
|
30 #define __ASSERT_PANIC__(l) User::Panic(KPanicFileName().Right(12),l) |
|
31 #define __ASSERT_FILE__(s) _LIT(KPanicFileName,s) |
|
32 #define ASSERT(x) { __ASSERT_FILE__(__FILE__); __ASSERT_DEBUG(x, __ASSERT_PANIC__(__LINE__) ); } |
|
33 #endif |
|
34 |
|
35 #endif |