Revert "Fix build: make ptr fields public." to fix the build error in better way.

This reverts commit 7c093e1397a8e4d4ab562115543b3b63526ed541.
Use Foo::from(ptr) to construct objects (to fix build error on master).
Merge branch 'rust-servo': Use Foo::from(ptr) to construct objects (to fix build error on master).