From 9bd3c79199faf81023a5109ae4999708be79d303 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Mon, 3 Sep 2007 14:28:02 +0000 Subject: [PATCH] Fix the n-ary loader --- source/loader.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/loader.h b/source/loader.h index 70fb7c2..6a0a1e3 100644 --- a/source/loader.h +++ b/source/loader.h @@ -81,17 +81,17 @@ private: Loads a statement by calling a function that takes an array of values. */ template -class LoaderFunc1 &>: public LoaderAction +class LoaderFunc1 &>: public LoaderAction { public: - typedef void (L::*FuncType)(const std::list &); + typedef void (L::*FuncType)(const std::vector &); LoaderFunc1(FuncType f): func(f) { } void execute(Loader &l, const Statement &st) const { std::vector values; values.reserve(st.args.size()); - for(ValueArray::iterator i=st.args.begin(); i!=st.args.end(); ++i) + for(ValueArray::const_iterator i=st.args.begin(); i!=st.args.end(); ++i) values.push_back(i->get()); (dynamic_cast(l).*func)(values); } -- 2.45.2