From eca05d2a3398f25be13282072da1ff1c284afcd7 Mon Sep 17 00:00:00 2001 From: Andreas Rumpf Date: Thu, 4 Feb 2010 00:47:59 +0100 Subject: cleanup of library docs --- lib/pure/parseutils.nim | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'lib/pure/parseutils.nim') diff --git a/lib/pure/parseutils.nim b/lib/pure/parseutils.nim index 0878f87eb..04d2a7973 100755 --- a/lib/pure/parseutils.nim +++ b/lib/pure/parseutils.nim @@ -7,7 +7,7 @@ # distribution, for details about the copyright. # -## Helpers for parsing. +## This module contains helpers for parsing tokens, numbers, identifiers, etc. {.deadCodeElim: on.} @@ -25,8 +25,6 @@ template newException(exceptn, message: expr): expr = const Whitespace = {' ', '\t', '\v', '\r', '\l', '\f'} - Letters = {'A'..'Z', 'a'..'z'} - Digits = {'0'..'9'} IdentChars = {'a'..'z', 'A'..'Z', '0'..'9', '_'} IdentStartChars = {'a'..'z', 'A'..'Z', '_'} ## copied from strutils @@ -218,6 +216,9 @@ proc parseBiggestFloat*(s: string, number: var biggestFloat, start = 0): int = result = i - start proc parseFloat*(s: string, number: var float, start = 0): int = + ## parses a float starting at `start` and stores the value into `number`. + ## Result is the number of processed chars or 0 if there occured a parsing + ## error. var bf: biggestFloat result = parseBiggestFloat(s, bf, start) number = bf -- cgit 1.4.1-2-gfad0