danielwertheim

danielwertheim


notes from a passionate developer

Sections


Tags


Disclaimer

This is a personal blog. The opinions expressed here represent my own and not those of my employer, nor current or previous. All content is published "as is", without warranty of any kind and I don't take any responsibility and can't be liable for any claims, damages or other liabilities that might be caused by the content.

Daniel Wertheim
Author

Daniel Wertheim

UTF-8 BOM adventures in C#

Time for a quick look at UTF-8 encoding and byte order marker (BOM). Lets jump right into some code. You are probably going to nail this as you most likely will be alert now, given the title and all, but would you have expected this test to pass? [Fact] public void Utf8Strings() { var initial =…

Daniel Wertheim Daniel Wertheim