contentsconceptssyntaxlibrariessampleserrorsindex
Full text search
   
  Warning    

An ambiguous construct was detected.

The first problem occurs in code such as the following:

     SET STREAM s TO "6"
  DO WHEN "3" < "04" < s

All the values in this test could be interpreted as either numbers or strings. As numbers, the test would be true. As strings, false (because the "3" in the first value is greater than the "0" in the second value). By default, the test does string comparison. To coerce the test to a numeric comparison, coerce one of the strings to a number. The simplest way is to do:

     SET STREAM s TO "6"
  DO WHEN +"3" < "04" < s

The REOPEN problem occurs in code such as the following:

   DOWN-TRANSLATE

GLOBAL STREAM s

DOCUMENT-START
  OPEN s AS BUFFER
  PUT (s AND #MAIN-OUTPUT) "abcd%/%_efgh%/%_ijkl%/%_mnop%n"
  CLOSE s
  REOPEN s

BREAK-WIDTH 5 50

REPLACEMENT-BREAK "%_" "%n"

This code will not have the desired effect: the BREAK-WIDTH declaration is actually a modifier applied to the REOPEN action. To get it to affect the #MAIN-OUTPUT stream, you could put the REPLACEMENT-BREAK declaration between the end of the DOCUMENT-START rule and the BREAK-WIDTH declaration.

Additional Information

The current comparison uses string comparison, but all the entries could be numeric values.
or
In a REOPEN action, the BREAK-WIDTH sequence could be a modifier or a separate declaration. If it's a modifier, preceding it with the WITH keyword will prevent this message. If it's a declaration, it must be moved somewhere else so it doesn't immediately follow a dynamic repeat action. It is assumed to be a modifier.

 
----

Top [CONTENTS] [CONCEPTS] [SYNTAX] [LIBRARIES] [SAMPLES] [ERRORS] [INDEX]

Generated: April 21, 1999 at 2:02:11 pm
If you have any comments about this section of the documentation, send email to [email protected]

Copyright © OmniMark Technologies Corporation, 1988-1999.