User Tools

Site Tools


gams:error_286

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
gams:error_286 [2008/02/22 13:22]
Franz Nelissen
— (current)
Line 1: Line 1:
-====== Error 286:Invalid in-line/​end-of-line comment delimiter specification ... ====== 
-The full error message is:  
-<​code>​ 
-286  Invalid in-line/​end-of-line comment delimiter specification - format ​ 
-            single delimiter -  $inlinecom { } 
-                             ​- ​ $eolcom # 
-      -or-  double delimiter -  $inlinecom /* */ 
-                             ​- ​ $eolcom _$ 
-</​code>​ 
-This happens if a delimiter has been redefined twice, e.g.: 
-<​code>​ 
-eolcom ! 
-display '​test';​ !test 
-$eolcom ! 
-</​code>​ 
-GAMS will interpret the second ! as a end of line comment and thus interpret the whole statement as a  
-a eolcom statement without an argument, which triggers the error message. ​ 
- 
-A more complicated situation may arise, if the second definition of the delimiter happens in a include file. If you want to set an eolcom or inline comment in an include file you have to do disable the current eolcom and the redefine it again. ​ 
-<​code>​ 
-$offeolcom $eolcom ! 
-</​code>​ 
-Then it does not matter what kind of eolcom character you used in the calling GAMS file. Since 
-all those dollar option are scoped, the calling gams file keeps its eolcom character. To make this totally save one could use: 
-<​code>​ 
-%$offeolcom offinline comment * dollar $ eolcom !  ​ 
-</​code>​ 
-Note the use of %$, it means use the current $ symbol. Again, ​ since everything is scoped, it will not do damage the the calling file processing. 
- 
- 
- 
  
IMPRESSUM / LEGAL NOTICEPRIVACY POLICY gams/error_286.1203682930.txt.gz ยท Last modified: 2008/02/22 13:22 by Franz Nelissen