• R/O
  • HTTP
  • SSH
  • HTTPS

コミット

タグ
未設定

よく使われているワード(クリックで追加)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

コミットメタ情報

リビジョンdb481e755ad34c73cd77ad6b42f2100026cbd8c3 (tree)
日時2019-03-05 23:01:22
作者dhrname <dhrname@user...>
コミッターdhrname

ログメッセージ

Modify the Makefile

変更サマリ

差分

--- a/source_code/Makefile
+++ b/source_code/Makefile
@@ -2,8 +2,7 @@ CC = gcc
22 DEBUGMODE = -Wall -std=c11 -O0 -g -pg
33 NODEBUGMODE = -Wall -std=c11 -O2
44 SHELL = /bin/sh
5-.SUFFIXES:
6-.SUFFIXES: .c .o
5+HEADERS = shadowstar.h star.h orderedpair/exception.h orderedpair/pair.h orderedpair/list/item.h orderedpair/list/tree/btree.h orderedpair/list/tree/nodelist/ntree.h
76
87 all : startest star
98 .PHONY : all
@@ -11,15 +10,13 @@ all : startest star
1110 %.o : %.c
1211 $(CC) $(NODEBUGMODE) -c $< -o $@
1312
14-star.o: star.c shadowstar.h star.h orderedpair/exception.h orderedpair/pair.h orderedpair/list/item.h orderedpair/list/tree/btree.h orderedpair/list/tree/nodelist/ntree.h
13+star.o: $(HEADERS)
1514
16-shadowstar.o: shadowstar.c shadowstar.h star.h orderedpair/exception.h orderedpair/pair.h orderedpair/list/item.h orderedpair/list/tree/btree.h orderedpair/list/tree/nodelist/ntree.h
15+shadowstar.o: $(HEADERS)
1716
1817 star: shadowstar.o star.o
1918 $(CC) $(NODEBUGMODE) -o ../$@ shadowstar.o star.o
2019
21-startest.o: startest.c
22-
2320 startest: shadowstar.o startest.o
2421 $(CC) $(NODEBUGMODE) -o ../$@ shadowstar.o startest.o
2522
--- a/source_code/shadowstar.c
+++ b/source_code/shadowstar.c
@@ -1359,6 +1359,11 @@ static inline ST_Token_Mode* alloca_tokens(uint_fast64_t filelength)
13591359 return s;
13601360 }
13611361
1362+static inline uint64_t pair (uint64_t x, uint64_t y)
1363+{
1364+ return (((x+y) * (x+y+1) / 2 ) + x + 1);
1365+}
1366+
13621367 /*ST_main 関数
13631368 * 引数sはソースコードの文字列。
13641369 * 引数filelengthはsの長さ
--- a/source_code/star.h
+++ b/source_code/star.h
@@ -32,3 +32,5 @@
3232 #include "orderedpair/list/item.h"
3333
3434 #include "orderedpair/list/tree/nodelist/ntree.h"
35+
36+#include "class/class.h"
--- a/source_code/startest.c
+++ b/source_code/startest.c
@@ -819,6 +819,14 @@ printf("\n%d\n", i);
819819 che = "testsuite/f.st";
820820 assert( tests_file_length == ST_readFile(che, tests_callback_file) );
821821 ST_readFile(che, ST_main);
822+ tests_file_length = 0;
823+ che = "testsuite/g.st";
824+ assert( tests_file_length == ST_readFile(che, tests_callback_file) );
825+ ST_readFile(che, ST_main);
826+ tests_file_length = 0;
827+ che = "testsuite/h.st";
828+ assert( tests_file_length == ST_readFile(che, tests_callback_file) );
829+ ST_readFile(che, ST_main);
822830
823831 elapsed = clock() - before;
824832 printf("Time is %.3f seconds\n", elapsed/CLOCKS_PER_SEC);
Binary files a/source_code/startest.o and b/source_code/startest.o differ