This comment was made this week at http://www.macrobusiness.com.au (link may be locked)
The solution to that problem is to restrict foreign investment in residential property to new builds.
That way farmers can sell their farm on retirement to a local and use the proceeds (which may be less than if they sold to a foreign buyer) to purchase a home at lower cost due to the abundant foreign investment in new housing stock.
Of course it is unlikely that foreign investors will be interested in investing in an illiquid asset like housing if the market is efficient and ponzi speculation on capital gains is not encouraged.
High prices for farms and for houses have a common cause.
Flogging assets and IOUs rather than goods and services off shore.