Firstly, Singaporean or Malaysian immigration might be suspicious of why you would leave as soon as you entered. If you're staying for a full day, that's fine but not if you're turning around as soon as you entered.
Secondly, Thai immigration doesn't take kindly to same day air border runs. Each individual will have different experiences, but I've heard a lot of horror stories.
Land based runs are better. Especially if you use a service, which brings you across and back.
No, it's a form of discrimination. Most other countries grant privileges to their citizens that foreigners don't get. Australia and New Zealand treat foreigners the same or even better than locals. These two countries are WOKE as f***.