Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Can SFML operate with C++ Exceptions disabled  (Read 2091 times)

0 Members and 1 Guest are viewing this topic.

Clairvoire

  • Newbie
  • *
  • Posts: 29
    • AOL Instant Messenger - Clairvoire
    • View Profile
    • http://clairvoire.deviantart.com
Can SFML operate with C++ Exceptions disabled
« on: September 19, 2011, 11:25:38 pm »
Does SFML depend on C++ exceptions in such a way that if I disable them, it will hinder it's ability to work?  I went over the code and found no place where they were used, but I wanted to make sure.

OniLinkPlus

  • Hero Member
  • *****
  • Posts: 500
    • View Profile
Can SFML operate with C++ Exceptions disabled
« Reply #1 on: September 20, 2011, 12:32:23 am »
I think Laurent specifically avoided exceptions so that bindings would be possible.
I use the latest build of SFML2

Clairvoire

  • Newbie
  • *
  • Posts: 29
    • AOL Instant Messenger - Clairvoire
    • View Profile
    • http://clairvoire.deviantart.com
Can SFML operate with C++ Exceptions disabled
« Reply #2 on: September 20, 2011, 02:05:05 am »
Ah, good to know!  Following the Google code style guide, and it expressly forbids C++ exceptions.  

Thanks!

Disch

  • Full Member
  • ***
  • Posts: 220
    • View Profile
Can SFML operate with C++ Exceptions disabled
« Reply #3 on: September 20, 2011, 04:26:43 am »
There's nothing wrong with exceptions when used properly.  Any guide that outright forbids them is not one that I would take to heart.

thePyro_13

  • Full Member
  • ***
  • Posts: 156
    • View Profile
Can SFML operate with C++ Exceptions disabled
« Reply #4 on: September 20, 2011, 05:07:47 am »
Do you understand the reason they don't use exceptions(because it would conflict to much with their older non-exception code)?

They even state that projects which do not need to tie into their existing systems are free to use exceptions, and that given their time again, they would prefer to use exceptions everywhere.

Just keep in mind, some of the stuff in their guide really doesn't apply to anyone but Google.

Not that it makes a difference for SMFL anyway. Just some food for thought encase you would otherwise want to use exceptions.

 

anything