This allows STL style iterator dereference. It's the same
as gsi_stmt () or .phi ().
* gimple-iterator.h (gimple_stmt_iterator::operator*): Add.
(gphi_iterator::operator*): Likewise.
struct gimple_stmt_iterator
{
+ gimple *operator * () const { return ptr; }
+
/* Sequence node holding the current statement. */
gimple_seq_node ptr;
/* Iterator over GIMPLE_PHI statements. */
struct gphi_iterator : public gimple_stmt_iterator
{
+ gphi *operator * () const { return as_a <gphi *> (ptr); }
+
gphi *phi () const
{
return as_a <gphi *> (ptr);