[m-rev.] trivial diff: fix syntax error in non-rbmm grades

Julien Fischer juliensf at csse.unimelb.edu.au
Sat Dec 8 22:36:38 AEDT 2007


Estimated hours taken: 0.1
Branches: main

Fix a syntax error in the library.

library/region_builtin.m:
 	Escape backslashes in C code correctly.

 	Use backslashes to escape quotation marks rather than double quotes.

Julien.

Index: region_builtin.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/library/region_builtin.m,v
retrieving revision 1.4
diff -u -r1.4 region_builtin.m
--- region_builtin.m	7 Dec 2007 07:35:45 -0000	1.4
+++ region_builtin.m	8 Dec 2007 11:32:58 -0000
@@ -47,7 +47,7 @@

  :- implementation.

-:- pragma foreign_decl("C", "#include ""mercury_region.h""").
+:- pragma foreign_decl("C", "#include \"mercury_region.h\"").

  :- pragma foreign_type("C", region, "MR_Region *",
      [can_pass_as_mercury_type]).
@@ -59,7 +59,7 @@
  #ifdef MR_USE_REGIONS
      Region = MR_region_create_region();
  #else
-    MR_fatal_error(""create_region: non-rbmm grade"");
+    MR_fatal_error(\"create_region: non-rbmm grade\");
  #endif
  ").

@@ -70,7 +70,7 @@
  #ifdef MR_USE_REGIONS
      MR_region_remove_region(Region);
  #else
-    MR_fatal_error(""remove_region: non-rbmm grade"");
+    MR_fatal_error(\"remove_region: non-rbmm grade\");
  #endif
  ").

@@ -81,7 +81,8 @@
  #ifdef MR_USE_REGIONS
      MR_region_print_profiling_info();
  #else
-    printf(""There is no rbmm profiling info to print in a non-rbmm grade.\n"");
+    printf(
+        \"There is no rbmm profiling info to print in a non-rbmm grade.\\n\");
  #endif
  ").


--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list