[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Conversion to Logical from Text
Hi, Section "6.2.8 Conversion to Logical" says that | Text, level 3 and higher applications examine the text; if the text | matches the text "TRUE" ignoring case, then return TRUE, if the text | matches the text "FALSE" ignoring case, then return FALSE, otherwise | return Error. Note that case is ignored no matter what the value of | “case-sensitive” is. It is implementation-defined what happens if the | text does not match “TRUE” or “FALSE” in a case-sensitive manner- it may | return a logical value or an Error. I think that's wrong and even worse than trying to interpret text as numbers because it will definitely not work in different locales. Instead, we should define that similar to "Conversion to Number", e.g. Text: An application may return FALSE, an error value, or the results of its attempt to convert the text value to a logical (and fall back to FALSE or error if it fails to do so). Note that portable spreadsheet files cannot depend on any particular conversion, and shall avoid implicit conversions from text to logical. Opinions? Eike -- Automatic string conversions considered dangerous. They are the GOTO statements of spreadsheets. --Robert Weir on the OpenDocument formula subcommittee's list.
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]