GCC Wikia
(整形)
 
Default (トーク | 投稿記録)
1行目: 1行目:
  +
{{header}}
 
  +
== このページを編集する際は,[[編集に関する方針]]に従ってください. ==
   
 
== 概要 ==
 
== 概要 ==
 
*[[gcc-4.1.0/gcc/coverage.c]]にて定義
 
*[[gcc-4.1.0/gcc/coverage.c]]にて定義
  +
*
 
== 引数 ==
 
*const char *filename
 
   
 
== 実装 ==
 
== 実装 ==
 
<code>
 
<code>
945 /* Perform file-level initialization. Read in data file, generate name
+
945 /* Perform file-level initialization. Read in data file, generate name
946 of graph file. */
+
946 of graph file. */
 
947
 
947
 
948 void
 
948 void
17行目: 16行目:
 
951 int len = strlen (filename);
 
951 int len = strlen (filename);
 
952
 
952
953 /* Name of da file. */
+
953 /* Name of da file. */
 
954 [[da_file_name]] = [[xmalloc]] (len + strlen ([[GCOV_DATA_SUFFIX]]) + 1);
 
954 [[da_file_name]] = [[xmalloc]] (len + strlen ([[GCOV_DATA_SUFFIX]]) + 1);
 
955 strcpy ([[da_file_name]], filename);
 
955 strcpy ([[da_file_name]], filename);
 
956 strcat ([[da_file_name]], [[GCOV_DATA_SUFFIX]]);
 
956 strcat ([[da_file_name]], [[GCOV_DATA_SUFFIX]]);
 
957
 
957
958 /* Name of bbg file. */
+
958 /* Name of bbg file. */
 
959 [[bbg_file_name]] = [[xmalloc]] (len + strlen ([[GCOV_NOTE_SUFFIX]]) + 1);
 
959 [[bbg_file_name]] = [[xmalloc]] (len + strlen ([[GCOV_NOTE_SUFFIX]]) + 1);
 
960 strcpy ([[bbg_file_name]], filename);
 
960 strcpy ([[bbg_file_name]], filename);
29行目: 28行目:
 
963 [[read_counts_file]] ();
 
963 [[read_counts_file]] ();
 
964 }
 
964 }
  +
 
</code>
 
</code>
   
  +
{{related}}
 
  +
[[特別:Whatlinkshere/Tree|{{int:Whatlinkshere}}]]

2007年9月28日 (金) 00:00時点における版

このページを編集する際は,編集に関する方針に従ってください.

概要

実装

 945 /* Perform file-level initialization. Read in data file, generate name
 946    of graph file.  */
947 
948 void
949 coverage_init (const char *filename)
950 {
951   int len = strlen (filename);
952 
 953   /* Name of da file.  */
954   da_file_name = xmalloc (len + strlen (GCOV_DATA_SUFFIX) + 1);
955   strcpy (da_file_name, filename);
956   strcat (da_file_name, GCOV_DATA_SUFFIX);
957 
 958   /* Name of bbg file.  */
959   bbg_file_name = xmalloc (len + strlen (GCOV_NOTE_SUFFIX) + 1);
960   strcpy (bbg_file_name, filename);
961   strcat (bbg_file_name, GCOV_NOTE_SUFFIX);
962 
963   read_counts_file ();
964 }


リンク元