为什么 Flow 需要注释导出函数的参数?

Why does Flow require annotation of parameter of exported function?

以下代码 (Flow playground):

/* @flow */

function a(p) {}
module.exports = a

抛出异常

3: function a(p) {}
              ^ parameter `p`. Missing annotation

这是为什么?我希望参数 p.

会自动假定类型 any

来自documentation

Module Boundaries

Flow requires annotations at the boundaries of modules. This allows Flow to analyze modules in isolation which improves the performance of checking types across module boundaries. We’ve found that this helps to improve the self-documenting nature of module interfaces as well.