Syntax highlighting using Mediawiki formatting: Difference between revisions

Content added Content deleted
m (Moved Oberon-07 to the right place)
(→‎{{header|Oberon-07}}: Fixed String handling)
Line 652: Line 652:
''(* includes "DEFINITION" - an oberonc extension *)''
''(* includes "DEFINITION" - an oberonc extension *)''
rwCount := 0;
rwCount := 0;
AddRw("'''ARRAY'''");AddRw("'''BEGIN'''");AddRw("'''BY'''");AddRw("'''CASE'''");AddRw("'''CONST'''");
AddRw("ARRAY");AddRw("BEGIN");AddRw("BY");AddRw("CASE");AddRw("CONST");
AddRw("'''DEFINITION'''");AddRw("'''DIV'''");AddRw("'''DO'''");AddRw("'''ELSE'''");
AddRw("DEFINITION");AddRw("DIV");AddRw("DO");AddRw("ELSE");
AddRw("'''ELSIF'''");AddRw("'''END'''");AddRw("'''FALSE'''");AddRw("'''FOR'''");AddRw("'''IF'''");
AddRw("ELSIF");AddRw("END");AddRw("FALSE");AddRw("FOR");AddRw("IF");
AddRw("'''IMPORT'''");AddRw("'''IN'''");AddRw("'''IS'''");AddRw("'''MOD'''");AddRw("'''MODULE'''");
AddRw("IMPORT");AddRw("IN");AddRw("IS");AddRw("MOD");AddRw("MODULE");
AddRw("'''NIL'''");AddRw("'''OF'''");AddRw("'''OR'''");AddRw("'''POINTER'''");
AddRw("NIL");AddRw("OF");AddRw("OR");AddRw("POINTER");
AddRw("'''PROCEDURE'''");AddRw("'''RECORD'''");AddRw("'''REPEAT'''");AddRw("'''RETURN'''");
AddRw("PROCEDURE");AddRw("RECORD");AddRw("REPEAT");AddRw("RETURN");
AddRw("'''THEN'''");AddRw("'''TO'''");AddRw("'''TRUE'''");AddRw("'''TYPE'''");AddRw("'''UNTIL'''");
AddRw("THEN");AddRw("TO");AddRw("TRUE");AddRw("TYPE");AddRw("UNTIL");
AddRw("'''VAR'''");AddRw("'''WHILE'''")
AddRw("VAR");AddRw("WHILE")
'''END''' InitReservedWords;
'''END''' InitReservedWords;
Line 774: Line 774:
'''END'''
'''END'''
'''END'''
'''END'''
'''ELSIF''' ch = quote '''THEN''' ''(* start of a string *)''
inString := '''TRUE''';
OutAndNextChar
'''ELSIF''' ch = "(" '''THEN''' ''(* comment starting or "just" "(" *)''
'''ELSIF''' ch = "(" '''THEN''' ''(* comment starting or "just" "(" *)''
NextChar;
NextChar;
Line 846: Line 849:
'''END''' ToWiki.
'''END''' ToWiki.

=={{header|Phix}}==
=={{header|Phix}}==
Note the utility I use for this on a day-to-day basis (pwa/p2js.exw/<Ctrl M>) must be easily over 50,000 lines of code by now...<br>
Note the utility I use for this on a day-to-day basis (pwa/p2js.exw/<Ctrl M>) must be easily over 50,000 lines of code by now...<br>