It seems that webkit_web_view_load_uri() with a named anchor works only for an anchor located at the beginning of the page. For all anchors below a certain location in the page, load_uri() doesn't work, it scrolls at the end of the page. The bug occurs with Devhelp, see this bug: https://bugzilla.gnome.org/show_bug.cgi?id=749495 The bug is 100% reproducible, for some links.
It looks like the bug is fixed on my Fedora 23 system.