Upcoming webinar on Localization and Design Pattern Automation

Hel­lo, just a quick note to say that I’m doing a webi­nar with the Post­Sharp folks on a tech­nique my team devel­oped whilst work­ing on Here Be Mon­sters (a MMORPG that had more text than the first 3 Har­ry Porter books com­bined) which allowed us to localise the whole game with a hand­ful of lines of code …

Upcom­ing webi­nar on Local­iza­tion and Design Pat­tern Automa­tionRead More »

Fasterflect vs HyperDescriptor vs FastMember vs Reflection

The oth­er day I had a small task to inspect return val­ues of meth­ods and if the fol­low­ing prop­er­ty exists then set it to emp­ty array.         pub­lic long[] Achieve­ments { get; set; } This need­ed to hap­pen once on every web request, and I decid­ed to imple­ment it as a Post­Sharp attribute. WHY I …

Faster­flect vs Hyper­De­scrip­tor vs Fast­Mem­ber vs Reflec­tionRead More »

Beware of implicit boxing of value types

In the last post, we looked at some inef­fi­cien­cies with ref­er­ence types in .Net and per­haps over­sold val­ue types a lit­tle  In any case, now that we’ve made the ini­tial sale and you’re back for more, let’s talk about some pit­falls wrt the use of val­ue types you should be aware of. Specif­i­cal­ly let’s focus on cas­es …

Beware of implic­it box­ing of val­ue typesRead More »

Smallest .Net ref type is 12 bytes (or why you should consider using value types)

(Update 2015/07/21 : read the next post in this series to learn about the places where implic­it box­ing hap­pens with val­ue types and how you can pre­vent them)   I chanced upon Sasha Goldshtein’s excel­lent book, Pro .Net Per­for­mance : Opti­mize Your C# Appli­ca­tion, a few years back and I thor­ough­ly enjoyed it. Even though …

Small­est .Net ref type is 12 bytes (or why you should con­sid­er using val­ue types)Read More »

Seven ineffective coding habits many F# programmers don’t have

This post is part of the F# Advent Cal­en­dar in Eng­lish 2014 project. Check out all the oth­er great posts there! Spe­cial thanks to Sergey Tihon for orga­niz­ing this. A good cod­ing habit is an incred­i­bly pow­er­ful tool, it allows us to make good deci­sions with min­i­mal cog­ni­tive effort and can be the dif­fer­ence between …

Sev­en inef­fec­tive cod­ing habits many F# pro­gram­mers don’t haveRead More »

A look at Microsoft Orleans through Erlang-tinted glasses

Some time ago, Microsoft announced Orleans, an imple­men­ta­tion of the actor mod­el in .Net which is designed for the cloud envi­ron­ment where instances are ephemer­al. We’re cur­rent­ly work­ing on a num­ber of projects in Erlang and have run into some assump­tions in dis­trib­uted Erlang which doesn’t hold true in a cloud-host­ed envi­ron­ment where nodes are …

A look at Microsoft Orleans through Erlang-tint­ed glass­esRead More »

Announcing libraries for C# and F# to make it easier to integrate with Sentry

Here at Gamesys social team, we’re rethink­ing our cur­rent approach to log­ging in gen­er­al, from both serv­er and client’s per­spec­tive. Hav­ing looked at many dif­fer­ent alter­na­tives (it was a lit­tle hard to imag­ine how crowd­ed a space log aggre­ga­tion and visu­al­iza­tion is..) one of the ser­vices which we have decid­ed to exper­i­ment with is Sen­try. …

Announc­ing libraries for C# and F# to make it eas­i­er to inte­grate with Sen­tryRead More »

C# – extern alias, and ILMerge’d assemblies

Sup­pose you want to merge an assem­bly A (AssemblyA.dll) with anoth­er assem­bly B (AssemblyB.dll) with ILMerge into a merged assem­bly (Merged.dll), and every­thing works fine until the user of your merged assem­bly also ref­er­ences that AssemblyB.dll, at which point that user will get Ambigu­ous ref­er­ence errors for any ref­er­ence to types defined in assem­bly B, …

C# – extern alias, and ILMerge’d assem­bliesRead More »

Be Lazy, but be ware of initialization exception

.Net 4 intro­duced the Lazy<T> type which allows you to cre­ate an object that can be lazi­ly ini­tial­ized so that you can delay the cre­ation of large objects, for instance. How­ev­er, if your ini­tial­iza­tion log­ic has the poten­tial to except at run­time (e.g. time out excep­tions read­ing from some exter­nal data source) then you should …

Be Lazy, but be ware of ini­tial­iza­tion excep­tionRead More »

LINQ OrderBy – using Comparer<T>.Create and F#’s Object Expressions

.Net 4.5 intro­duced a handy lit­tle new method Comparer<T>.Create to aid the cre­ation of bespoke com­par­ers, which is great because it means that you don’t have to define a new Com­par­er class when it is going to be need­ed once. In case you’re won­der­ing, it’s still not pos­si­ble to define anony­mous imple­men­ta­tion of inter­faces in …

LINQ Order­By – using Comparer<T>.Create and F#’s Object Expres­sionsRead More »

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.