Possible to inline assembly or IL in C# code? why??
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
VulpesRank #55 · 29.2K reputationPosted Aug 21, 2014, 1:09 AM EDT
It's no surprise that you can't use inline assembly language as C# applications are not compiled directly to native code and are intended to be platform independent.
Although the language designers could have allowed for the inclusion of inline IL code, given that you can write an IL dll using Ilasm.exe and then reference that from a C# application, they probably felt that the former would have been an unnecessary refinement in what was intended - initially at least - to be a simple language.