From: Brian Norris Date: Thu, 24 Jan 2013 01:21:19 +0000 (-0800) Subject: model: add const to get_thread(ModelAction *act) X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=523dbecc6fc18e58918a1f36860be5eb0ab42ce2;p=cdsspec-compiler.git model: add const to get_thread(ModelAction *act) --- diff --git a/model.cc b/model.cc index b6ef861..ede2bcc 100644 --- a/model.cc +++ b/model.cc @@ -2687,7 +2687,7 @@ Thread * ModelChecker::get_thread(thread_id_t tid) const * @param act The ModelAction * @return A Thread reference */ -Thread * ModelChecker::get_thread(ModelAction *act) const +Thread * ModelChecker::get_thread(const ModelAction *act) const { return get_thread(act->get_tid()); } diff --git a/model.h b/model.h index 5a127b1..960e9e1 100644 --- a/model.h +++ b/model.h @@ -108,7 +108,7 @@ public: void add_thread(Thread *t); void remove_thread(Thread *t); Thread * get_thread(thread_id_t tid) const; - Thread * get_thread(ModelAction *act) const; + Thread * get_thread(const ModelAction *act) const; bool is_enabled(Thread *t) const; bool is_enabled(thread_id_t tid) const;