---
title: "setExceptionHangingMask(_:)"
framework: Exception Handling
role: symbol
role_heading: Instance Method
platforms: [Mac Catalyst 13.0+, macOS 10.0+]
path: "exceptionhandling/nsexceptionhandler/setexceptionhangingmask(_:)"
---

# setExceptionHangingMask(_:)

Sets the bit mask of constants specifying the types of exceptions that will halt execution for debugging.

## Declaration

```swift
func setExceptionHangingMask(_ aMask: Int)
```

## Parameters

- `aMask`: A bit mask composed of one or more constants specifying the types of exceptions that will halt execution for debugging. You specify multiple constants by performing a bitwise-OR operation. See doc://com.apple.Exception-Handling/documentation/ExceptionHandling/system-hang-constants for information about the constants.

## See Also

### Getting and setting exception masks

- [exceptionHandlingMask()](exceptionhandling/nsexceptionhandler/exceptionhandlingmask().md)
- [exceptionHangingMask()](exceptionhandling/nsexceptionhandler/exceptionhangingmask().md)
- [setExceptionHandlingMask(_:)](exceptionhandling/nsexceptionhandler/setexceptionhandlingmask(_:).md)
