×
Namespaces

Variants
Actions

Archived:Using TRAP IGNORE in a backward-compatible manner

From Nokia Developer Wiki
Jump to: navigation, search

Archived.pngArchived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.

Article Metadata
CompatibilityArticle
Keywords: TRAP_IGNORE, TTrap
Created: tepaa (01 Apr 2008)
Last edited: lpvalente (04 Aug 2012)

Overview

S60 3rd Edition supports the TRAP_IGNORE template that catches leaves and does nothing on error. You can add TRAP_IGNORE support for older editions of the S60 platform when adding this define into a visible header:

#if !defined(EKA2)
#define TRAP_IGNORE(_s) {TInt _ignore;TTrap __t;if (__t.Trap(_ignore)==0)
{_s;TTrap::UnTrap();}}
#endif

Using this is similar to using it in the S60 3rd Edition platform environment:

TRAP_IGNORE( SomeLeavingFunctionL());

Postconditions

TRAP_IGNORE is supported.

This page was last modified on 4 August 2012, at 21:28.
39 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×