Homebrew How to correctly handle exceptions?

VegaRoXas

Well-Known Member
OP
Member
Joined
Mar 29, 2015
Messages
290
Trophies
0
XP
378
Country
Gambia, The
So I want to handle exceptions, for example an std:out_of_range exception. But how do I do this? I am already using try & catch.
c:/Users/0/Desktop/3DSProjects/BTC/source/main.cpp: In function 'void ApplyTheme
(std::string)':
c:/Users/0/Desktop/3DSProjects/BTC/source/main.cpp:47:9: error: exception handli
ng disabled, use -fexceptions to enable
catch (...) {
^
This happens when I run make. Where do I add the -fexceptions?
 

TheCruel

Developer
Banned
Joined
Dec 6, 2013
Messages
1,350
Trophies
2
XP
3,131
Country
United States
The 3ds (and even all embedded systems) commonly have exceptions disabled. Search your makefile for the "-fno-exceptions" flag and remove it if you want.
 

VegaRoXas

Well-Known Member
OP
Member
Joined
Mar 29, 2015
Messages
290
Trophies
0
XP
378
Country
Gambia, The
The 3ds (and even all embedded systems) commonly have exceptions disabled. Search your makefile for the "-fno-exceptions" flag and remove it if you want.
I removed the flag but my 3ds is still freezing when the exception is being throwed. I try and catched everything where the exception could occur. Any help? :3
It says "terminate called after throwing an instance of 'std::out_of_range' \n terminate called recursively"
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Psionic Roshambo @ Psionic Roshambo: Lol