#include now works
git-svn-id: http://picoc.googlecode.com/svn/trunk@182 21eae674-98b7-11dd-bd71-f92a316d2d60
This commit is contained in:
parent
456a83da75
commit
8d76edfe4b
2
parse.c
2
parse.c
|
@ -366,7 +366,7 @@ int ParseStatement(struct ParseState *Parser)
|
||||||
if (LexGetToken(Parser, &LexerValue, TRUE) != TokenStringConstant)
|
if (LexGetToken(Parser, &LexerValue, TRUE) != TokenStringConstant)
|
||||||
ProgramFail(Parser, "\"filename.h\" expected");
|
ProgramFail(Parser, "\"filename.h\" expected");
|
||||||
|
|
||||||
//ScanFile(LexerValue->Val->String); // XXX - need to dereference char * here
|
PlatformScanFile(LexerValue->Val->Pointer.Segment->Val->Array.Data);
|
||||||
CheckTrailingSemicolon = FALSE;
|
CheckTrailingSemicolon = FALSE;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
3
tests/18_include.c
Normal file
3
tests/18_include.c
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
printf("including\n");
|
||||||
|
#include "18_include.h"
|
||||||
|
printf("done\n");
|
3
tests/18_include.expect
Normal file
3
tests/18_include.expect
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
including
|
||||||
|
included
|
||||||
|
done
|
1
tests/18_include.h
Normal file
1
tests/18_include.h
Normal file
|
@ -0,0 +1 @@
|
||||||
|
printf("included\n");
|
|
@ -13,7 +13,8 @@ TESTS= 00_assignment.test \
|
||||||
13_integer_literals.test \
|
13_integer_literals.test \
|
||||||
14_if.test \
|
14_if.test \
|
||||||
16_nesting.test \
|
16_nesting.test \
|
||||||
17_enum.test
|
17_enum.test \
|
||||||
|
18_include.test
|
||||||
|
|
||||||
%.test: %.expect %.c
|
%.test: %.expect %.c
|
||||||
@echo Test: $*...
|
@echo Test: $*...
|
||||||
|
|
Loading…
Reference in a new issue