Snippets created by fholm
Sorted Map
Sorted Map
13 people like this
Posted: 1 years ago by fholmExample of annoying enumeration syntax
Example of annoying enumeration syntax
11 people like this
Posted: 1 years ago by fholmUgly hack to call F# functions as static methods
Ugly hack to call F# functions as static methods
3 people like this
Posted: 1 years ago by fholmreference to array element
Nice thing you can do in F# that you can't do in C#, pulling a reference to an array element as a local var.
18 people like this
Posted: 1 years ago by fholmRead only ref
F# implementation of RO_ref from the "Effective ML" talk.
74 people like this
Posted: 1 years ago by fholmAbstract Console.ReadLine as an infinite sequence
Abstracts console input as an infinite sequence of strings
7 people like this
Posted: 1 years ago by fholmIronJS Boxing Struct
This is the struct IronJS uses internally to do NaN-tagging of boxed values, using the technique described here http://blog.mozilla.com/rob-sayre/2010/08/02/mozillas-new-javascript-value-representation/ and here http://article.gmane.org/gmane.comp.lang.lua.general/58908
8 people like this
Posted: 1 years ago by fholmCaching the function object created
Caching the function object created
13 people like this
Posted: 1 years ago by fholmStruct Tuple
Two/Three/Four-element generic tuples implemented as a value types for writing more efficient F# code.
47 people like this
Posted: 1 years ago by fholmTop-Down-Operator-Precedence Parser
F# implementation of a generic Top-Down-Operator-Precedence Parser as described in this paper http://portal.acm.org/citation.cfm?id=512931 Example starts at line ~300
57 people like this
Posted: 1 years ago by fholmString repeater
A function that efficiently creates a new string containing a given string multiple times. The function is implemented using .NET StringBuilder class.
8 people like this
Posted: 1 years ago by fholmUnion constructors can be used as functions
Union constructors can be used as functions
13 people like this
Posted: 1 years ago by fholmPerl Style "Regex Matches?" operator
Perl Style "Regex Matches?" operator
35 people like this
Posted: 1 years ago by fholm
Lexer
Hand-written efficient JavaScript lexer from the IronJS project https://github.com/fholm/IronJS
16 people like this
Posted: 1 years ago by fholmCompiler Regression in VS2010-SP1
Compiler regression in VS2010-SP1 ?
21 people like this
Posted: 1 years ago by fholmPretty Print Source Code Errors
A snippet that allows you to pretty print source code errors
13 people like this
Posted: 1 years ago by fholmType-a-head search tree for strings
This is a search tree for strings I've built for work to back fast type-a-head for AJAX forms, it could be made million times more space efficient but there was no real need for it so.
3 people like this
Posted: 1 years ago by fholmNullable Refs without using AllowNullLiteral
Nullable Refs without using AllowNullLiteral
3 people like this
Posted: 1 years ago by fholmML style module example
ML style module example
1 people like this
Posted: 1 years ago by fholmWrapped Class/Interface
Wrapped Class/Interface Remark: better this way - see example
0 people like this
Posted: 1 years ago by fholmRope
Simple implementation of the rope data structure, http://en.wikipedia.org/wiki/Rope_(computer_science)
2 people like this
Posted: 1 years ago by fholmFholm
Fast Concatenated String
2 people like this
Posted: 1 years ago by fholmEfficient Immutable String Concat
Efficient Immutable String Concat
4 people like this
Posted: 1 years ago by fholmAsync File Crawl
Async File Crawl
6 people like this
Posted: 11 months ago by fholmQuotation property name + comp + value extract
for zec_ on irc
0 people like this
Posted: 11 months ago by fholmInterface workaround for circular dependency problem
Interface workaround for circular dependency problem
3 people like this
Posted: 10 months ago by fholm