It doesn't matter what time of day you eat. It is what and how much you eat and how much physical activity you do during the whole day that determines whether you gain, lose, or maintain your weight. No matter when you eat, your body will store extra calories as fat. If you want a snack before bedtime, think first about how many calories you've eaten that day.