carbon2-commit: Merge further, this time by hand.

Aidan Kehoe kehoea at parhasard.net
Sun Feb 7 12:41:10 EST 2010


changeset:   5053:675f9511928b
tag:         tip
user:        Aidan Kehoe <kehoea at parhasard.net>
date:        Sun Feb 07 16:45:48 2010 +0000
files:       src/ChangeLog.carbon2 src/console-carbon.c src/device-carbon.c src/emacs.c src/event-carbon.c src/faces.c src/frame-carbon.c src/glyphs-carbon.c src/intl-carbon.c src/objects-carbon.c src/select-carbon.c
description:
Merge further, this time by hand.

src/ChangeLog.carbon2 addition:

2010-02-07  Aidan Kehoe  <kehoea at parhasard.net>

	* select-carbon.c (pasteboard_get_utext_or_text)
	(carbon_get_foreign_selection):
	* objects-carbon.c (carbon_finalize_color_instance)
	(get_truename, carbon_finalize_font_instance):
	* intl-carbon.c (Fcarbon_current_locale)
	(complex_vars_of_intl_carbon):
	* glyphs-carbon.c (carbon_print_image_instance)
	(carbon_finalize_image_instance, data_provider_release_data)
	(xpm_to_eimage, carbon_xpm_instantiate):
	* frame-carbon.c (release_bitmap_context)
	(release_bitmap_context):
	* faces.c (complex_vars_of_faces):
	* event-carbon.c:
	* emacs.c (main_1):
	* device-carbon.c:
	* console-carbon.c (carbon_device_to_console_connection)
	(carbon_semi_canonicalize_console_connection)
	(carbon_canonicalize_console_connection)
	(carbon_semi_canonicalize_device_connection)
	(carbon_canonicalize_device_connection):
	Merge some changes by hand here.


diff -r e28c53a27914 -r 675f9511928b src/ChangeLog.carbon2
--- a/src/ChangeLog.carbon2	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/ChangeLog.carbon2	Sun Feb 07 16:45:48 2010 +0000
@@ -1,3 +1,27 @@
+2010-02-07  Aidan Kehoe  <kehoea at parhasard.net>
+
+	* select-carbon.c (pasteboard_get_utext_or_text)
+	(carbon_get_foreign_selection): 
+	* objects-carbon.c (carbon_finalize_color_instance)
+	(get_truename, carbon_finalize_font_instance): 
+	* intl-carbon.c (Fcarbon_current_locale)
+	(complex_vars_of_intl_carbon): 
+	* glyphs-carbon.c (carbon_print_image_instance)
+	(carbon_finalize_image_instance, data_provider_release_data)
+	(xpm_to_eimage, carbon_xpm_instantiate): 
+	* frame-carbon.c (release_bitmap_context)
+	(release_bitmap_context): 
+	* faces.c (complex_vars_of_faces):
+	* event-carbon.c: 
+	* emacs.c (main_1): 
+	* device-carbon.c: 
+	* console-carbon.c (carbon_device_to_console_connection)
+	(carbon_semi_canonicalize_console_connection)
+	(carbon_canonicalize_console_connection)
+	(carbon_semi_canonicalize_device_connection)
+	(carbon_canonicalize_device_connection):
+	Merge some changes by hand here.
+
 2010-02-07  Aidan Kehoe  <kehoea at parhasard.net>
 
 	* objects-carbon.c:
diff -r e28c53a27914 -r 675f9511928b src/console-carbon.c
--- a/src/console-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/console-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -42,7 +42,7 @@
   if (NILP (connection))
     return Qnil;
   else
-    connection = build_string ("carbon");
+    connection = build_ascstring ("carbon");
   return connection;
 }
 
@@ -51,7 +51,7 @@
 {
   struct gcpro gcpro1;
   GCPRO1 (connection);
-  connection = build_string ("carbon");
+  connection = build_ascstring ("carbon");
   RETURN_UNGCPRO (connection);
 }
 
@@ -61,7 +61,7 @@
   Lisp_Object hostname = Qnil;
   struct gcpro gcpro1, gcpro2;
   GCPRO2 (connection, hostname);
-  connection = build_string ("carbon");
+  connection = build_ascstring ("carbon");
   RETURN_UNGCPRO (connection);
 }
 
@@ -70,7 +70,7 @@
 {
   struct gcpro gcpro1;
   GCPRO1 (connection);
-  connection = build_string("carbon");
+  connection = build_ascstring("carbon");
   RETURN_UNGCPRO (connection);
 }
 
@@ -79,7 +79,7 @@
 {
   struct gcpro gcpro1;
   GCPRO1 (connection);
-  connection = build_string("carbon");
+  connection = build_ascstring("carbon");
   RETURN_UNGCPRO (connection);
 }
 
diff -r e28c53a27914 -r 675f9511928b src/device-carbon.c
--- a/src/device-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/device-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -83,7 +83,7 @@
   CGColorSpaceRelease (DEVICE_CARBON_COLOR_SPACE (d));
 
   /* xfree (DEVICE_CARBON_DATA (d), void *); */
-  xfree (d->device_data, void *);
+  xfree (d->device_data);
 }
 
 static Lisp_Object
diff -r e28c53a27914 -r 675f9511928b src/emacs.c
--- a/src/emacs.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/emacs.c	Sun Feb 07 16:45:48 2010 +0000
@@ -2739,7 +2739,7 @@
       Vinvocation_directory = Ffile_name_directory (Vinvocation_directory);
 
 #ifdef RUN_TEMACS_UNDER_XCODE
-      Vinvocation_directory = concat2(Vinvocation_directory, build_string("../../../../../src/"));
+      Vinvocation_directory = concat2(Vinvocation_directory, build_ascstring("../../../../../src/"));
 #endif
     }
 
diff -r e28c53a27914 -r 675f9511928b src/event-carbon.c
--- a/src/event-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/event-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -199,7 +199,7 @@
 	goto dispose_desc_and_return_error;
 
       /* Don't include NULL terminator bytes.  */
-      file_list = Fcons (make_ext_string (buf, buf_size - 2, Qcarbon_unicode), file_list);
+      file_list = Fcons (make_extstring (buf, buf_size - 2, Qcarbon_unicode), file_list);
       
       CFRelease (urlref);
       CFRelease (pathname);
@@ -717,7 +717,7 @@
 emacs_carbon_format_magic_event (Lisp_Event *emacs_event,
 				 Lisp_Object pstream)
 {
-#define FROB(msg) case msg: write_c_string (pstream, "type=" #msg); break
+#define FROB(msg) case msg: write_ascstring (pstream, "type=" #msg); break
   
   switch (EVENT_MAGIC_CARBON_EVENT (emacs_event))
     {
@@ -731,7 +731,7 @@
   
   if (!NILP (EVENT_CHANNEL (emacs_event)))
     {
-      write_c_string (pstream, " ");
+      write_ascstring (pstream, " ");
       print_internal (EVENT_CHANNEL (emacs_event), pstream, 1);
     }
 }
diff -r e28c53a27914 -r 675f9511928b src/faces.c
--- a/src/faces.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/faces.c	Sun Feb 07 16:45:48 2010 +0000
@@ -2258,8 +2258,8 @@
     bg_fb = acons (list1 (Qmswindows), build_ascstring ("white"), bg_fb);
 #endif
 #ifdef HAVE_CARBON
-    fg_fb = acons (list1 (Qcarbon), build_string ("black"), fg_fb);
-    bg_fb = acons (list1 (Qcarbon), build_string ("white"), bg_fb);
+    fg_fb = acons (list1 (Qcarbon), build_ascstring ("black"), fg_fb);
+    bg_fb = acons (list1 (Qcarbon), build_ascstring ("white"), bg_fb);
 #endif
     set_specifier_fallback (Fget (Vdefault_face, Qforeground, Qnil), fg_fb);
     set_specifier_fallback (Fget (Vdefault_face, Qbackground, Qnil), bg_fb);
@@ -2478,7 +2478,7 @@
       {
 	/* display device */
 	inst_list = Fcons (Fcons (list1 (Qcarbon), 
-				  build_string (*carbonfontptr)),
+				  build_ascstring (*carbonfontptr)),
 			   inst_list);
       }
     }
diff -r e28c53a27914 -r 675f9511928b src/frame-carbon.c
--- a/src/frame-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/frame-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -113,7 +113,7 @@
 static OSStatus
 main_view_destruct (EventRef UNUSED (event), main_view_data *data)
 {
-  xfree (data, main_view_data *);
+  xfree (data);
   
   return noErr;
 }
@@ -331,7 +331,7 @@
 {
   Binbyte *data = CGBitmapContextGetData (context);
   if (data)
-    xfree (data, Binbyte *);
+    xfree (data);
 
   CGContextRelease (context);
 }
diff -r e28c53a27914 -r 675f9511928b src/glyphs-carbon.c
--- a/src/glyphs-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/glyphs-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -66,7 +66,7 @@
     case IMAGE_COLOR_PIXMAP:
     case IMAGE_POINTER:
       write_fmt_string (printcharfun, " (0x%lx", (unsigned long) IMAGE_INSTANCE_CARBON_IMAGE_REF (p));
-      write_c_string (printcharfun, ")");
+      write_ascstring (printcharfun, ")");
       break;
       
     default:
@@ -95,14 +95,14 @@
 		CGImageRelease (IMAGE_INSTANCE_CARBON_IMAGE_REF_SLICE (p, i));
 	      IMAGE_INSTANCE_CARBON_IMAGE_REF_SLICE (p, i) = 0;
 	    }
-	  xfree (IMAGE_INSTANCE_CARBON_IMAGE_REF_SLICES (p), CGImageRef *);
+	  xfree (IMAGE_INSTANCE_CARBON_IMAGE_REF_SLICES (p));
 	  IMAGE_INSTANCE_CARBON_IMAGE_REF_SLICES (p) = 0;
 	}
     }
   
   if (p->data)
     {
-      xfree (p->data, void *);
+      xfree (p->data);
       p->data = 0;
     }
 }
@@ -146,7 +146,7 @@
 static void
 data_provider_release_data (void *info, const void * UNUSED (data), size_t UNUSED (size))
 {
-  xfree (info, Binbyte *);
+  xfree (info);
 }
 
 static CGImageRef
@@ -472,7 +472,7 @@
   colortbl = xnew_array_and_zero (CGColorRef, xpmimage.ncolors);
   if (!colortbl)
     {
-      xfree (*data, Binbyte *);
+      xfree (*data);
       XpmFreeXpmImage (&xpmimage);
       XpmFreeXpmInfo (&xpminfo);
       return 0;
@@ -526,8 +526,8 @@
 	}
 
     label_no_color:
-      xfree (*data, Binbyte *);
-      xfree (colortbl, CGColorRef *);
+      xfree (*data);
+      xfree (colortbl);
       XpmFreeXpmImage (&xpmimage);
       XpmFreeXpmInfo (&xpminfo);
       return 0;
@@ -557,7 +557,7 @@
 
   for (i = 0; i < (int) xpmimage.ncolors; i++)
     CGColorRelease (colortbl[i]);
-  xfree (colortbl, CGColorRef *);
+  xfree (colortbl);
 
   return TRUE;
 }
@@ -609,9 +609,9 @@
       while (nsymbols--)
 	{
 	  CGColorRelease (color_symbols[nsymbols].color);
-	  xfree (color_symbols[nsymbols].name, Ibyte *);
+	  xfree (color_symbols[nsymbols].name);
 	}
-      xfree(color_symbols, struct color_symbol *);
+      xfree(color_symbols);
     }
 
   /* build a bitmap from the eimage */
@@ -621,7 +621,7 @@
       signal_image_error ("XPM to EImage conversion failed",
 			  image_instance);
     }
-  xfree (eimage, Binbyte *);
+  xfree (eimage);
 
   /* Now create the pixmap and set up the image instance */
   init_image_instance_from_image_ref (ii, image_ref, dest_mask,
diff -r e28c53a27914 -r 675f9511928b src/intl-carbon.c
--- a/src/intl-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/intl-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -302,7 +302,7 @@
                         Qunbound);
         }
 
-      res = make_ext_string (buf, size - 2, Qcarbon_unicode);
+      res = make_extstring (buf, size - 2, Qcarbon_unicode);
 
       CFRelease(userLocaleStr);
       CFRelease(userLocaleRef);
@@ -341,7 +341,7 @@
                     build_msg_string ("Converts to the Unicode encoding for "
                                       "Carbon/Quartz 2D calls.\nThe encoding "
                                       "used is standard UTF-16 big-endian."),
-                    Qmnemonic, build_string ("CARBON-U")),
+                    Qmnemonic, build_ascstring ("CARBON-U")),
              list4 (Qunicode_type, Qutf_16, Qlittle_endian, Qnil)));
 #else
   Fmake_coding_system_internal
@@ -350,7 +350,7 @@
                     build_msg_string ("Converts to the Unicode encoding for "
                                       "Carbon/Quartz 2D calls.\nThe encoding "
                                       "used is UTF-16 little-endian."),
-                    Qmnemonic, build_string ("CARBON-U")),
+                    Qmnemonic, build_ascstring ("CARBON-U")),
              list4 (Qunicode_type, Qutf_16, Qlittle_endian, Qt)));
 #endif
 }
diff -r e28c53a27914 -r 675f9511928b src/objects-carbon.c
--- a/src/objects-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/objects-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -942,7 +942,7 @@
   if (c->data)
     {
       CGColorRelease (COLOR_INSTANCE_CARBON_COLOR (c));
-      xfree (c->data, void *);
+      xfree (c->data);
       c->data = 0;
     }
 }
@@ -1262,7 +1262,7 @@
   eicat_rawz (fname, bold_italic);
   
   *truename = make_string (eidata (fname), eilen (fname));
-  xfree (enamestr, Ibyte *);
+  xfree (enamestr);
   return 1;
 }
 
@@ -1369,7 +1369,7 @@
 {
   if (f->data)
     {
-      xfree (f->data, void *);
+      xfree (f->data);
       f->data = 0;
     }
 }
diff -r e28c53a27914 -r 675f9511928b src/select-carbon.c
--- a/src/select-carbon.c	Sun Feb 07 16:25:42 2010 +0000
+++ b/src/select-carbon.c	Sun Feb 07 16:45:48 2010 +0000
@@ -211,7 +211,7 @@
 		return Qnil;
 	      }
 	      
-	      Lisp_Object data = make_ext_string (CFDataGetBytePtr (flavor_data), CFDataGetLength (flavor_data), Qcarbon_unicode);
+	      Lisp_Object data = make_extstring (CFDataGetBytePtr (flavor_data), CFDataGetLength (flavor_data), Qcarbon_unicode);
 	      
 	      CFRelease (flavor_data);
 	      CFRelease (flavor_type_array);
@@ -256,7 +256,7 @@
     return Qnil;
   
   /* Can only handle text for now.  */
-  if (!NILP (target_type) && !x_sym_p (target_type) && NILP (Fstring_equal (target_type, build_string ("UTF8_STRING"))))
+  if (!NILP (target_type) && !x_sym_p (target_type) && NILP (Fstring_equal (target_type, build_ascstring ("UTF8_STRING"))))
     return Qnil;
   
   (void) PasteboardSynchronize (clipboard);



More information about the XEmacs-Patches mailing list