aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-05-14 09:07:27 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-05-14 09:07:27 +0000
commit28ae62c51eb78d6d9231eac86b6fc01165feb5e0 (patch)
tree2accb378f64635932858229444fc4907bb7139b3
parent88f87d9997cafef4734f84da3c1e6b31f234d726 (diff)
downloadpaludis-28ae62c51eb78d6d9231eac86b6fc01165feb5e0.tar.gz
paludis-28ae62c51eb78d6d9231eac86b6fc01165feb5e0.tar.xz
Use warn_unused_result for sr. Fixes: ticket:227
-rwxr-xr-xmisc/make_sr.bash11
1 files changed, 7 insertions, 4 deletions
diff --git a/misc/make_sr.bash b/misc/make_sr.bash
index aa1b881..9614095 100755
--- a/misc/make_sr.bash
+++ b/misc/make_sr.bash
@@ -216,9 +216,11 @@ while read a ; do
if [[ ${want_key_types[${k}]/->} != ${want_key_types[${k}]} ]] ; then
echo " ${current_class} & set_${want_keys[${k}]}($(make_const_ref ${want_key_types[${k}]% ->*}));"
echo
- echo " const ${want_key_types[${k}]%-> *} get_raw_${want_keys[${k}]}() const;"
+ echo " const ${want_key_types[${k}]%-> *} get_raw_${want_keys[${k}]}() const"
+ echo " PALUDIS_ATTRIBUTE((warn_unused_result));"
echo
- echo " std::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> ${want_keys[${k}]}() const;"
+ echo " std::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> ${want_keys[${k}]}() const"
+ echo " PALUDIS_ATTRIBUTE((warn_unused_result));"
echo
fi
done
@@ -243,7 +245,8 @@ while read a ; do
fi
for (( k = 0 ; k < ${#want_comparison_operators[@]} ; k++ )) ; do
- echo " bool operator${want_comparison_operators[${k}]} (const ${a} & other) const;"
+ echo " bool operator${want_comparison_operators[${k}]} (const ${a} & other) const"
+ echo " PALUDIS_ATTRIBUTE((warn_unused_result));"
done
echo
@@ -426,7 +429,7 @@ while read a ; do
echo ">"
fi
done
- echo " create();"
+ echo " create() PALUDIS_ATTRIBUTE((warn_unused_result));"
echo
echo " ///\\}"