File tree Expand file tree Collapse file tree 3 files changed +14
-6
lines changed Expand file tree Collapse file tree 3 files changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ namespace xmlpp
31
31
#ifndef DOXYGEN_SHOULD_SKIP_THIS
32
32
/* * Helper class for propagating an exception through C code.
33
33
* Should not be used by applications.
34
+ * Does not exist in systems that don't support std::exception_ptr.
34
35
*
35
36
* @newin{2,40}
36
37
*/
Original file line number Diff line number Diff line change @@ -26,6 +26,8 @@ extern "C" {
26
26
27
27
namespace xmlpp {
28
28
29
+ class SaxParserCallback ; // Remove, when handle_exception() is made protected.
30
+
29
31
/* * XML parser.
30
32
*
31
33
*/
@@ -163,10 +165,8 @@ class Parser : NonCopyable
163
165
virtual void on_validity_warning (const Glib::ustring& message);
164
166
165
167
// TODO: When we can break ABI/API, remove handleException() and make
166
- // handle_exception() virtual.
168
+ // handle_exception() protected virtual.
167
169
virtual void handleException (const exception& e);
168
- // / To be called in an exception handler.
169
- void handle_exception ();
170
170
virtual void check_for_exception ();
171
171
172
172
// TODO: In a future API/ABI-break, change the name of this function to
@@ -204,6 +204,11 @@ class Parser : NonCopyable
204
204
// bool include_default_attributes_;
205
205
// int set_options_;
206
206
// int clear_options_;
207
+
208
+ private:
209
+ friend SaxParserCallback; // Remove, when handle_exception() is made protected.
210
+ // / To be called in an exception handler.
211
+ void handle_exception ();
207
212
};
208
213
209
214
/* * Equivalent to Parser::parse_stream().
Original file line number Diff line number Diff line change @@ -38,10 +38,8 @@ class Validator : NonCopyable
38
38
virtual void on_validity_warning (const Glib::ustring& message);
39
39
40
40
// TODO: When we can break ABI/API, remove handleException() and make
41
- // handle_exception() virtual.
41
+ // handle_exception() protected virtual.
42
42
virtual void handleException (const exception& e);
43
- // / To be called in an exception handler.
44
- void handle_exception ();
45
43
virtual void check_for_exception ();
46
44
virtual void check_for_validity_messages ();
47
45
@@ -52,6 +50,10 @@ class Validator : NonCopyable
52
50
exception* exception_;
53
51
Glib::ustring validate_error_;
54
52
Glib::ustring validate_warning_; // Built gradually - used in an exception at the end of parsing.
53
+
54
+ private:
55
+ // / To be called in an exception handler.
56
+ void handle_exception ();
55
57
};
56
58
57
59
} // namespace xmlpp
You can’t perform that action at this time.
0 commit comments