hello everybody i'm nick and this we're going to take a deep dive into the record type that was added in c sharp NUMBER_TOKEN and was enhanced even further in c sharp NUMBER_TOKEN. we're going to take a look at how it works and all the features around it but also we're going to take a look at how exactly they managed to add the feature in the language without touching the clr and this is a very common mechanism that the c-sharp team is actually using to add features without having to be very invasive when they do so so even if you know how record works check that part of the video because i do think you're going to find it interesting if you like those content and you want to see more make sure you subscribe and hitting the notification bell to get already when i upload a new video now before i move on i want to let you know that i just launched my from zero to hero dependency injection in dotnet course in that course i take you from the very basics of dependency injection to the fundamentals we do a deep dive into the di framework itself we see how we can use some pretty advanced patterns and approaches with the built-in di framework then see how we can extend it even further to add other behaviors and then to top it all off we build the dependency injection framework from scratch this is by far the most complete dependency injection course you will find out there trust me i checked all of them and will teach you everything you need from the very basics to some pretty pretty advanced stuff and it all comes from real world experience building huge scale microservices now the first NUMBER_TOKEN of you who want to buy this course can use this code right here to get NUMBER_TOKEN off so check it in the description but if you want and thank you very much for supporting the channel so let's start from the beginning i have a project here in dot net NUMBER_TOKEN running c sharp NUMBER_TOKEN and what i want to do first is i want to go on and create a new record so record is a new type we can create here and many people actually seem to think that record is allocated in the memory in some different way or it's like a a structure behind the scenes or something a record just by itself is just a class with special properties that's it it's still a reference type allocated on the heap nothing changes there so i'm gonna go ahead and create a person record here and as you can see this is a perfectly valid record i don't have to have like angle brackets or like this syntax this is still valid syntax but i don't need to i have this shorthand um way of writing a record and i can actually have properties here so i can say full name here and i can also say like date only date of birth so this is a perfectly valid record i can also write this record like this i can go on and actually delete all that and write in this syntax and have them properties written in this way so this is string full name and this is date only date of birth these can be immutable but ideally if we want this to be a one for one to this you want them to be init only because they should only be initialized when you create the record and then these can be default here so these two approaches well same idea now you can totally see why we want to go with the first one is more concise we don't need to expand to this full version
START_SELFPROMO_TOKEN if you like those content and you want to see more make sure you subscribe and hitting the notification bell to get already when i upload a new video now before i move on i want to let you know that i just launched my from zero to hero dependency injection in dotnet course in that course i take you from the very basics of dependency injection to the fundamentals we do a deep dive into the di framework itself we see how we can use some pretty advanced patterns and approaches with the built-in di framework then see how we can extend it even further to add other behaviors and then to top it all off we build the dependency injection framework from scratch this is by far the most complete dependency injection course you will find out there trust me i checked all of them and will teach you everything you need from the very basics to some pretty pretty advanced stuff and it all comes from real world experience building huge scale microservices now the first NUMBER_TOKEN of you who want to buy this course can use this code right here to get NUMBER_TOKEN off so check it in the description but if you want and thank you very much for supporting the channel so END_SELFPROMO_TOKEN