This is not a feature I've ever tried to use, and it's apparently not in the spec yet. :) Rooting through the compiler source, it seems like only the suffixes in the set "INZQRG" are supported. And the code below seems to work (using 'G').

1
2
3
4
5
6
7
8
9
10
11
12
13
 

[<Measure>] type year
[<AutoOpen>]
module NumericLiterals =
    [<AutoOpen>]
    module NumericLiteralG =
        let FromOne()           =  1.<year>
        let FromInt32(x:int)    =  float x * 1.<year>
        let FromDouble(x:float) = x * 1.<year>
let a = 1G 
let b = 2G 
By on 6/13/2009 10:13 AM ()

Rooting through the compiler source, it seems like only the suffixes in the set "INZQRG" are supported.  

Ha :) And that's an acronym for...? 

By on 6/14/2009 1:12 AM ()

Is the plan to allow an extended set of suffixes in the future?

By on 6/16/2009 4:19 AM ()
IntelliFactory Offices Copyright (c) 2011-2012 IntelliFactory. All rights reserved.
Home | Products | Consulting | Trainings | Blogs | Jobs | Contact Us | Terms of Use | Privacy Policy | Cookie Policy
Built with WebSharper