[vala/0.42] codegen: Fix canonical string for quark of error domains
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/0.42] codegen: Fix canonical string for quark of error domains
- Date: Mon, 26 Nov 2018 09:13:58 +0000 (UTC)
commit f92ab64b705b7a10a2b3070cb78eda77ddcab394
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Sun Nov 18 18:50:29 2018 +0100
codegen: Fix canonical string for quark of error domains
codegen/valaccode.vala | 2 +-
tests/girwriter/GirTest-1.0.gir-expected | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/codegen/valaccode.vala b/codegen/valaccode.vala
index 1bb92171e..28f0c01a2 100644
--- a/codegen/valaccode.vala
+++ b/codegen/valaccode.vala
@@ -126,7 +126,7 @@ namespace Vala {
}
public static string get_ccode_quark_name (ErrorDomain edomain) {
- return get_ccode_lower_case_name (edomain) + "-quark";
+ return "%s-quark".printf (get_ccode_lower_case_name (edomain).replace ("_", "-"));
}
public static bool is_reference_counting (TypeSymbol sym) {
diff --git a/tests/girwriter/GirTest-1.0.gir-expected b/tests/girwriter/GirTest-1.0.gir-expected
index 2b372d3ba..52be88f50 100644
--- a/tests/girwriter/GirTest-1.0.gir-expected
+++ b/tests/girwriter/GirTest-1.0.gir-expected
@@ -22,7 +22,7 @@
<enumeration name="SkippedFlags" c:type="GirTestSkippedFlags" glib:type-name="GirTestSkippedFlags"
glib:get-type="gir_test_skipped_flags_get_type" introspectable="0">
<member name="value1" c:identifier="GIR_TEST_SKIPPED_FLAGS_VALUE1" value="0"/>
</enumeration>
- <enumeration name="ErrorTest" c:type="GirTestErrorTest" glib:error-domain="gir_test_error_test-quark">
+ <enumeration name="ErrorTest" c:type="GirTestErrorTest" glib:error-domain="gir-test-error-test-quark">
<member name="failed" c:identifier="GIR_TEST_ERROR_TEST_FAILED" value="0"/>
<member name="smelly" c:identifier="GIR_TEST_ERROR_TEST_SMELLY" value="1"/>
<member name="fishy" c:identifier="GIR_TEST_ERROR_TEST_FISHY" value="23"/>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]