|
철자를 고치면 제대로 됩니다.
방금 컴파일 해봤습니다..
(C++ Builder 5.0에서..)
다만 메세지를 보니.. __cdel등은 윈도우에서만 나오는 메세지입니다.
님이 컴파일러 설정을 틀리게 해놓은거 같군요..
빌더라면.. 님의 소스를 컴파일 하기 위해서는 consol wizard를 이용하셔서..
VCL등을 사용하지 않도록 해서 컴파일해보시기 바랍니다.
조준회 님이 쓰신 글 :
: 철자가 틀렸군요..ㅡㅡ^
:
: 김희섭 님이 쓰신 글 :
: : 안녕하세요 ~ ^^
: :
: : 책보구 구조체 공부하구 있는데요 . ;;
: :
: : 밑의 소스에서 . .
: :
: : StructFunction.obj : error LNK2001: unresolved external symbol "void __cdecl hakdisp2(struct student *)" (?hakdisp2@@YAXPAUstudent@@@Z)
: : Debug/StructFunction.exe : fatal error LNK1120: 1 unresolved externals
: :
: : 이런 에러가 나는데요 . ;;
: :
: : 구조체는 아직 생소해서 . .;;
: :
: : 원인이 뭔지 모르겠네요 ㅠ _ ㅠ
: :
: : #include <stdio.h>
: :
: : struct student {
: : char name[20];
: : int kuko, sansu;
: : };
: :
: : void hakdisp1(struct student s);
: : void hakdisp2(struct student *s);
: :
: : void main() {
: : struct student haksang = {"홍길동", 90, 99};
: :
: : hakdisp1(haksang);
: : hakdisp2(&haksang);
: : }
: :
: : void hakdisp1(struct student s) {
: : printf("%s %d %d\n", s.name, s.kuko, s.sansu);
: : }
: :
: : void hadisp2(struct student *s) {
: : printf("%s %d %d\n", s->name, s->kuko, s->sansu);
: : }
: :
: : 그럼 모두들 좋은 하루 되세요 ^^
: :
: : ( _ _ )
|