I don't think that the concept of generalization is (directly) related to the "shape" of the function close to the point where it attains a minimum.
The concept of generalisation refers to when a trained model is able "perform well" on unseen data (that is, data not seen during the training phase). If a trained model does not generalise well, then it might have "overfitted" or "underfitted".
Overfitting means that the model performs well on the training data, but not on other data. In other words, in the case of overfitting, the model learns the structure of the training data, but not of the whole population (of interest) or it learns the "noise" (that is, the data which is not part of the population of interest) present in the training data. This also implies that the training data is not a "good" sample of the population, that is, it doesn't "summarise" well all characteristics of the population. In practice, this is often the case (for large populations).
Underfitting occurs when the model is not even able to learn enough about the training data during the training phase. For example, underfitting occurs when you try to train a linear model but the data does not have a linear relationship.
So, being able to generalise (or not) depends on the model (including the number of parameters), but also on the data you are given.
Does the right one generalize better compared to the left one?
The shape of the function will only be useful during the training phase. More specifically, in this case, you might reach one of the two minima faster than the other (depending also on the optimisation algorithms, model, etc., that you use).
I would like to note that, in machine learning, we often minimise a function of functions (which in mathematics is called a "functional"). Why is that? For "simplicity", consider a simple neural network (NN) model (e.g. a multi-layer perceptron). We usually train such NN using gradient descent (or one of its variants) by minimising a function (e.g. the mean squared error). Essentially, when we train such a NN, we want to find the function (which is represented by the parameters of the NN) that minimises e.g. the MSE. In this case, the mean squared error (MSE) is the functional we attempt to minimise. Note that the MSE is a function of the parameters of the current NN and that a NN is a model that represents a function.
Let's go back to your question. If, during the training phase, you get one minimum rather than the other, you will get different NNs (say $A$ and $B$). Note, again, that the point where our MSE function attains one its minima, in this context of training a NN (and often, in general, in machine learning) is a function (and not just a scalar). I know that, at the beginning (and if you're not a math guy), it might be difficult to think of functions as points (actually, more precisely, we should call them "vectors") that minimise other functions, but this concept exists and actually underlies a great amount of machine learning techniques (e.g. training NNs using back-propagation by minimising a cost function).
So, why do I think that we can't say much about the generalisation ability of NNs $A$ and $B$?
Suppose that we have access, after the training phase, to both NNs $A$ and $B$ (that is, the ones that correspond to the "points" where your function attains the two (visible) minima. $A$ and $B$ will perform equally well on the training data (or even validation data). We might then conclude that both generalise in the same way. But this might be a wrong conclusion because both the training and the validation data (as I mentioned above) might not be good samples of the population. So, we can't really say which NN (or "minima"), $A$ or $B$, generalises better. They might generalise more or less in the same way (according to their performance e.g. on the validation dataset) or not (because the validation dataset is not a good sample of the population).
To conclude, the concept of generalisation is a little bit more complex than function minimisation, because it is also related to data. In machine learning, we often minimise a functional (a function whose parameters are functions). If your functional attains the same minimum at two different points (actually, functions), during training, one might be faster to reach than the other. However, if you have two NNs that represent these two minima, we can't say much about their generalisation ability. Essentially, we can just hope that the validation dataset is a good sample of the population.