Fix code example by adding a missing import.

Fixes #1557890.

Backported from trunk.
1 file changed