Skip to content

Conversation

@rhysd
Copy link

@rhysd rhysd commented May 28, 2019

Fixes #117

For supporting -fno-exceptions compiler option, this patch adds PICOJSON_DISABLE_EXCEPTION preprocessor macro switch. When it is defined, picojson utilizes std::abort instead of throw.

I confirmed picojson.h can be compiled with clang++ -fno-exception with this patch and all tests passed by make test.

@rhysd rhysd force-pushed the allow-disable-exception branch from e3b558b to ae24181 Compare May 28, 2019 11:38
@rhysd rhysd changed the title Add $PICOJSON_DISABLE_EXCEPTION to support -fno-exceptions Add PICOJSON_DISABLE_EXCEPTION macro switch to support -fno-exceptions May 28, 2019
@ajtulloch
Copy link

Looks good IMO, this would be useful for some cases I'm interested in.

@kripton
Copy link

kripton commented Jun 20, 2021

@kazuho : Anything blocking to get this merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

picojson does not support -fno-exceptions

3 participants