diff gcc/calls.c @ 35:3f5886e153cb

modify cbc_replace_args
author kent <kent@cr.ie.u-ryukyu.ac.jp>
date Tue, 22 Dec 2009 20:49:36 +0900
parents 959d4c8c8abc
children 27e6f95b2c21
line wrap: on
line diff
--- a/gcc/calls.c	Tue Dec 22 20:46:05 2009 +0900
+++ b/gcc/calls.c	Tue Dec 22 20:49:36 2009 +0900
@@ -2400,20 +2400,29 @@
   else if ( CbC_IS_CbC_GOTO (exp) )
     {
       // TODO: 関数からコードセグメントへの遷移
-      char *name_callee = IDENTIFIER_POINTER(DECL_NAME(fndecl));
-      warning(0, "no warning: code segment `%s' has been called from a function.", name_callee);
+      /*
+      if (fndecl)
+	{
+	  char *name_callee = IDENTIFIER_POINTER(DECL_NAME(fndecl));
+	  warning(0, "no warning: code segment `%s' has been called from a function.", name_callee);
+        }
+      else
+	{
+	  warning(0, "no warning: unnamed code segment has been called from a function.");
+	}
+	*/
       args_size.constant = CbC_PRETENDED_STACK_SIZE;
     }
   else if ( fndecl && CbC_IS_CODE_SEGMENT (TREE_TYPE (fndecl)) )
     {
       // 警告コードセグメントを関数呼び出し
-      char *name= IDENTIFIER_POINTER(DECL_NAME(fndecl));
-      warning (0, "code segment `%s' has been \"called\" instead \"goto\".", name);
+      //char *name= IDENTIFIER_POINTER(DECL_NAME(fndecl));
+      //warning (0, "code segment `%s' has been \"called\" instead \"goto\".", name);
     }
   else if (CbC_IS_CODE_SEGMENT(TREE_TYPE (current_function_decl)) )
     {
       // code segment内部からの関数呼び出し。なんも問題ない。
-      warning (0, "no warning: normal call from a code segment.");
+      //warning (0, "no warning: normal call from a code segment.");
     }
 #endif