Skip to content
Commit a94ac61f authored by Ed Tanous's avatar Ed Tanous Committed by Ed Tanous
Browse files

Make the router const correct



Subtly, the individual members of a const std::pair are not implicitly
const.  In most cases, this is solved by a compiler error, but it seems
that flat_map allows implicitly pulling out by a non const reference,
even when the underlying container is const.  This is not how the maps
should work.

This commit changes the router to declare a "ChildMap" type, which can
then use the value_type to make this const correctness stuff more
reasonable to manage.

Tested: Code compiles.  No-op const change.

Signed-off-by: default avatarEd Tanous <edtanous@google.com>
Change-Id: Id99079a86e392a03416a69506934dbfff7bc3b29
parent c5a4c82a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment