Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Why is dereferenced element in const vector of int pointers mutable? – stackoverflow.com

I am not sure the true meaning of Const vector so I compiled the code below to get an idea but am now more confused. vector v; int x = 1, y = 2; v.push_back(&x); v....

from Hot Questions - Stack Exchange OnStackOverflow
via Blogspot



This post first appeared on ONLINE WEB TRICKS, please read the originial post: here

Share the post

Why is dereferenced element in const vector of int pointers mutable? – stackoverflow.com

×

Subscribe to Online Web Tricks

Get updates delivered right to your inbox!

Thank you for your subscription

×