compiler: don't read known type, simplify Import::finalize_methods

With the current export format, if we already know the type, we don't
have to read and parse the definition.

We only use the finalizer in Import::finalize_methods, so make it a
local variable.  To match Finalize_methods::type, only put struct
types into real_for_named.

Change-Id: I9cf0b03917abb1bc09f1a09dfb53ec80c81dd326
Reviewed-by: Than McIntosh <>
Reviewed-by: Cherry Zhang <>
2 files changed