The bug
When you middle click on farmland you get a dirt block despite the fact that farmland is an item as well.
How to reproduce
Furrow a dirt block and middle click it
You will get a dirt blockUse the following command
/give @p farmland
You will have a farmland block
The reason
The following is based on decompiled version of Minecraft 1.9 using MCP 9.24 beta. All method and class names are the names used in the decompiled version.
The reason why this happens is because the net.minecraft.block.BlockFarmland.func_185473_a(World, BlockPos, IBlockState)
method returns a dirt item stack.
public ItemStack func_185473_a(World worldIn, BlockPos pos, IBlockState state)
{
// Replaced this
//return new ItemStack(Blocks.dirt);
return new ItemStack(Blocks.farmland);
}
Possibly WAI, though Grum's comment on MC-83729 indicates otherwise.