3

I've been working on a compiler for a while but after changing to PowerPack 1.9.9.9 and the release version of VS2010 I'm no unable to compile the following line:

let lexbuf = Lexing.from_string text

I get the following two error:

"The value, constructor, namespace or type 'from_string' is not defined" pretty obviopus what it's trying to tell me but what's the resolution?

Rune FS
  • 21,497
  • 7
  • 62
  • 96

2 Answers2

4

My quick guess is that this function has been renamed to fromString (because, in general, functions with underscores such as of_seq are now written in camelCase).

Tomas Petricek
  • 240,744
  • 19
  • 378
  • 553
  • pretty close but they introduce unicode parsing/lexing with the latest version of the powerpack so fromString is for unicode and the equivalent is fromBytes but thanks (and I don't need unicode parsing) – Rune FS Jul 22 '10 at 19:29
2

Lexing.LexBuffer<_>.FromString ?

desco
  • 16,642
  • 1
  • 45
  • 56
  • I'll avoid you the checkmark, it did help me on the way. It's fromBytes that the equivalent of the from_string from earlier version of the PowerPack – Rune FS Jul 22 '10 at 19:28