Since the actual output of a similar Nd-Fe-B magnet will not be very close to the intrinsic coercive field of the material [a measure of the magnet materials' ability to resist demagnetization], it is unlikely that such a magnet would permanently demagnetize another. However, while in the presence of the second magnet, the first magnet would experience a temporary partial demagnetization. How much, and to what extent, would be dependent on, as DrDick says, the magnet geometry.